implment disconnect and database
update