Quick search by citation:

22 U.S. Code § 4007 - Retirement for expiration of time in class

(a) Maximum time
(1) The Secretary shall, by regulation, establish maximum time in class limitations for—
(A)
career members of the Senior Foreign Service,
(B)
Foreign Service officers, and
(C)
other career members of the Service who are in such occupational categories as may be designated by the Secretary and who are assigned to salary classes in the Foreign Service Schedule to which Foreign Service officers may also be assigned.
(2)
Maximum time in class limitations under this subsection (which may not be less than 3 years for career members of the Senior Foreign Service) may apply with respect to the time a member may remain in a single salary class or in a combination of salary classes.
(3) The Secretary may, by regulation, increase or decrease any maximum time in class established under this subsection as the needs of the Service may require. If maximum time in class is decreased, the Secretary shall provide any member of the Service who is in a category and salary class subject to the new time in class limitation an opportunity to remain in class (notwithstanding the new limitation) for a period which is at least as long as the shorter of—
(A)
the period which the member would have been permitted to remain in class but for the decrease in maximum time in class, or
(B)
such minimum period as the Secretary determines is necessary to provide members of the Service who are in the same category and salary class as that member a reasonable opportunity to be promoted into the next higher class or combination of classes, as the case may be.
(b) Limited career extensionMembers of the Service whose maximum time in class under subsection (a) expires—
(1)
after they have attained the highest salary class for their respective occupational categories, or
(2)
in the case of members of the Senior Foreign Service, while they are in salary classes designated by the Secretary,
may continue to serve only under limited extentions of their career appointments. Such limited extensions may not exceed 5 years in duration and may be granted and renewed by the Secretary in accordance with the recommendations of selection boards established under section 4002 of this title. Members of the Service serving under such limited career extensions shall continue to be career members of the Service.
(c) Members subject to retirement; reception of retirement benefitsAny member of the Service
(1)
whose maximum time in class under subsection (a) expires and who is not promoted to a higher class or combination of classes, as the case may be, or
(2)
whose limited career extension under subsection (b) expires and is not renewed,
shall be retired from the Service and receive benefits in accordance with section 4009 of this title, subject to any career extension under subsection (d) of this section.
(d) ExtensionsNotwithstanding any other provision of this section—
(1)
the career appointment of a member of the Service whose maximum time in class under subsection (a) expires, or whose limited career extension under subsection (b) expires, while that member is occupying a position to which he or she was appointed by the President, by and with the advice and consent of the Senate, shall be extended until the appointment to that position is terminated; and
(2)
if the Secretary determines it to be in the public interest, the Secretary may extend temporarily the career appointment of a career member of the Service whose maximum time in class or limited career extension expires, but in no case may any extension under this paragraph exceed one year and such extensions may be granted only in special circumstances.