Hi Lvc, thanks i will try it.
Do i have to include the *instance.shutdown() with some kind of hook? Could you give perhaps an example. Regards, Nhat On Friday, April 4, 2014 3:49:13 PM UTC+2, Lvc@ wrote: > > Hi Nhat, > By default even if last database is closed, the storage remains open: > > STORAGE_KEEP_OPEN( > "storage.keepOpen", > "Tells to the engine to not close the storage when a database is > closed. Storages will be closed when the process shuts down", > Boolean.class, Boolean.TRUE), > > If you don't want this behavior set this: > > OGlobalConfiguration.STORAGE_KEEP_OPEN.setValue(false); > > And assure to close the JVM with: > > Orient.instance.shutdown(); > > Lvc@ > > > > On 4 April 2014 15:36, Nhat Nguyen <[email protected]<javascript:> > > wrote: > >> Hi, >> >> i acquire for each operation a new database connection (via >> ODatabaseDocumentPool.global().acquire(.....)), >> After i get the acquired connection i pack everything in a >> try/catch/finally block >> >> ... connection=ODatabaseDocumentPool.global().acquire(.....) >> try{ >> //stuff >> } >> catch(Exception ...){} >> finally{connection.close();} >> >> But when i am going to debug my code and stop the running programm (hard >> stop) my connection wont close. Thats what i guess happens. >> Is there a posibility where i check if any connection has been >> interrupted or still open? And then maybe a posibility how i can close all >> of them. >> >> >> Log Output when i restart the programm: >> >> Warning: segment file 'manindex.0.ocl' was not closed correctly last time >> .... >> many more >> >> and then the programm wouldn´t run. Then i have to connect to the >> database via "console.bat" and drop the database and set it up again. >> >> Version used: 1.7-rc2 >> >> Regards, >> Nhat >> >> -- >> >> --- >> You received this message because you are subscribed to the Google Groups >> "OrientDB" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected] <javascript:>. >> For more options, visit https://groups.google.com/d/optout. >> > > -- --- You received this message because you are subscribed to the Google Groups "OrientDB" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
