I personally believe this verse alludes to more than the tribulation the Thessalonians were experiencing. I believe it speaks of the bigger picture of the Tribulation of Revelation 6-19. Why? The phrase, "It is a righteous thing with God," takes me back to Genesis 18.
Concerning the impending doom of Sodom, Abraham asked God, "Shall not the Judge of all the earth do right?" (Gen 18:25) God did, indeed, pour out His wrath on Sodom. Before He did, He raptured Lot and his family when He sent an angel to grab them by the hand and pull them out of the city.
And turning the cities of Sodom and Gomorrha into ashes condemned them with an overthrow, making them an ensample unto those that after should live ungodly; and delivered just Lot, vexed with the filthy conversation of the wicked: (For that righteous man dwelling among them, in seeing and hearing, vexed his righteous soul from day to day with their unlawful deeds;) The Lord knoweth how to deliver the godly out of temptations, and to reserve the unjust unto the day of judgment to be punished…2Pe 2:6-9
The word translated "out of" is the Greek word ek. Ek does not mean "to protect them while they are going through it." It means "to be taken out completely." Before God poured out His judgment on Sodom, He "took out" Lot and his family. God will take His children out before He pours out His wrath on a Christ-rejecting, sinful, corrupt world during the Tribulation.