Remove database session on shutdown