Session close unexpectedly destroying temporary table
As noted in the comments, if your session disconnects for any reason, you're going to have problems with even a global temp table disappearing.

Here's a neat workaround: create real user tables in TempDB. This works perfectly fine:

USE tempdb;
GO
CREATE TABLE dbo.persistent(ID INT);
GO


And then you can access that table from any session (via tempdb.dbo.persistent.)

I'm not saying this is a good idea - it's a bad one in the same way that global temp tables are a bad idea, like contention across multiple sessions, having problems when you have an AG failover or a service restart, or filling up your TempDB drives - but as long as you're trying to use global temp tables, this would be a workaround.