after I had seen your post, I was thinking what's the longest deployment ever,
That is correct!
I know that after WWII USS Antietam (CV 36) was deployed to the Far East for three years after WWII....no foolin'....
USS ANTIETAM was laid down on 15 March 1943 by the Philadelphia Navy Yard; launched on 20 August 1944 sponsored by Mrs. Millard E. Tydings, the wife of Senator Tydings of Maryland; and commissioned on 28 January 1945, Capt. James R. Tague in command.
The aircraft carrier completed fitting out at Philadelphia until 2 March 1945 when she got underway for her shakedown cruise. The ship arrived in Hampton Roads on the 5th and conducted operations from Norfolk until 22 March when she stood out of Chesapeake Bay bound for Trinidad in the British West Indies. At the conclusion of her shakedown cruise, ANTIETAM returned to Philadelphia on 28 April to begin post-shakedown availability. She completed repairs on 19 May and departed Philadelphia that same day.
After a three-day stop at Norfolk, the warship resumed her voyage to the Panama Canal in company with USS HIGBEE (DD 806), USS GEORGE W. INGRAM (APD 43), and USS IRA JEFFERY (APD 44). She arrived at Cristobal on 31 May 1945, transited the canal the next day, and continued her voyage up the coast to San Diego. She stopped at San Diego from 10 to 13 June before beginning the first leg of her transpacific voyage. ANTIETAM arrived in Pearl Harbor on the 19th and remained in the Hawaiian Islands conducting training missions until 12 August. On that day, she shaped a course for the western Pacific.
Three days out of Oahu, she received word of the Japanese capitulation and the consequent cessation of hostilities. Thus, by the time of her arrival in Eniwetok Atoll on 19 August 1945, her mission changed from combat to occupation support duty. On the 21st she exited the lagoon in company with USS CABOT (CVL 28) and a screen of destroyers bound for Japan. En route, she suffered some internal damage which forced her into port at Apra Harbor Guam, for inspections. The inspection party deemed the damage minimal; and the carrier remained operational, resuming her course on the 27th. By that time, however, her destination had been changed to the coast of the Asian mainland. She stopped at Okinawa between 30 August and 1 September and arrived in Chinese waters near Shanghai the following day.
The aircraft carrier remained in the Far East for a little more than three years. The Yellow Sea constituted her primary theater of operations while her air group provided support for the Allied occupation of North China, Manchuria, and Korea. During the latter stages of that assignment, her airmen conducted surveillance missions in that area as a result of the civil war in China between communist and nationalist factions which later resulted in the expulsion of Chiang Kai-shek's forces from mainland China and the establishment of Mao Tse-Tung's communist People's Republic of China. Throughout the period, however, she did depart the Yellow Sea on occasion for visits to Japan, the Philippines, Okinawa, and the Marianas. Early in 1949, she concluded her mission in the Orient and headed back to the United States for deactivation.