How to deal with threading

Using threads on the server is not safe. The server doesn’t know that you are using threads, could kill them (as you found out) and doesn’t work with data tables (see here).

You can use threads on your uplink modules, but you might still have problems working with the data tables.

You should look at Background Tasks. They are the official way to start a background thread that is data table friendly, doesn’t stop when your request stops, doesn’t timeout and can be monitored or killed by another function.

2 Likes