TSDB-Client offers graceful shutdown. Clients are blocked during shutdown until the server has processed all requests. We recommend that you enable graceful shutdown to prevent data loss.

Sample code

tsdb.close();   // Equivalent to tsdb.close(false);
        

Forced shutdown

If graceful shutdown is not required, directly shut down the client.

Sample code

tsdb.close(true);