Hi Andrey, Could you send me your project then, I know that you described which code you changed but better to look it in one piece.
On Tue, Feb 4, 2014 at 4:03 PM, Andrey Yesyev <[email protected]>wrote: > I tried to shutdown graph, but either I did it wrong or something else > going on there... > Andrey, could you please be more specific how to shutdown it according to > my code? > > > On Tuesday, February 4, 2014 6:14:48 AM UTC-5, Andrey Lomakin wrote: > >> Andrey, >> I looked through you code, you did not do graph.shutdown() before db drop >> so internal graph context is not cleared and graph db tries to check that >> schema is needed for graph database is present without db open. >> So just do graph.shutdown() but I do suggest you to wait till tomorrow, >> we release new version of graph db relation management tool with much >> better performance. >> >> >> >> On Tue, Feb 4, 2014 at 9:05 AM, Andrey Lomakin <[email protected]>wrote: >> >>> Hi Andrey, >>> Could you wait till Tuesday, I will check it ? >>> >>> >>> On Mon, Feb 3, 2014 at 11:30 PM, Andrey Yesyev <[email protected]>wrote: >>> >>>> Hi there, >>>> >>>> I'm back with a bunch of questions again. >>>> >>>> Today I faced a strange issue. >>>> I'm running tests, trying to figure out pros and cons of OrientDB. Each >>>> test I run in a new DB, so I'm creating and dropping DBs with the same >>>> name. >>>> Here is how I'm doing this >>>> >>>> Create DB >>>> public static void createDB() >>>> throws IOException { >>>> >>>> if (dbUrl.startsWith("remote")) { >>>> OServerAdmin server = new OServerAdmin(dbUrl).connect(dbUser, >>>> dbPassword); >>>> if (!server.existsDatabase("plocal")) { >>>> server.createDatabase("graph", "plocal"); >>>> } >>>> server.close(); >>>> } >>>> else { >>>> //OGraphDatabase database = new OGraphDatabase(dbUrl); >>>> OrientGraph database = new OrientGraph(dbUrl); >>>> if (!database.getRawGraph().exists()) { >>>> database.getRawGraph().create(); >>>> } >>>> database.getRawGraph().close(); >>>> } >>>> >>>> } >>>> >>>> >>>> >>>> Drop DB >>>> public static void dropDB() >>>> throws IOException { >>>> >>>> if (dbUrl.startsWith("remote")) { >>>> OServerAdmin server = new OServerAdmin(dbUrl).connect(dbUser, >>>> dbPassword); >>>> if (server.existsDatabase("plocal")) { >>>> server.dropDatabase("plocal"); >>>> } >>>> server.close(); >>>> } >>>> else { >>>> OrientGraph database = >>>> new OrientGraph(dbUrl); >>>> if (database.getRawGraph().exists()) { >>>> if (database.isClosed()) { >>>> database.getRawGraph().open(dbUser, dbPassword); >>>> } >>>> OIndexManager indexManager = database.getRawGraph(). >>>> getMetadata().getIndexManager(); >>>> for (@SuppressWarnings("rawtypes") OIndex index : >>>> indexManager.getIndexes()) { >>>> index.delete(); >>>> } >>>> database.drop(); >>>> } >>>> database.getRawGraph().close(); >>>> } >>>> } >>>> >>>> Get DB >>>> >>>> public static synchronized OrientGraph getDatabase() { >>>> return new >>>> OrientGraph(OGraphDatabasePool.global().acquire(dbUrl, >>>> dbUser, dbPassword)); >>>> } >>>> >>>> I'm actually using project from this thread https://groups.google. >>>> com/forum/#!searchin/orient-database/bemchmark/orient- >>>> database/VF_j5rGeffA/hzyC9PVj9lAJ . Have to say thanks to Milen Dyankov for >>>> a great job he did there. >>>> I changed it a little bit though... >>>> >>>> So, here is the problem I faced. >>>> I'm using OrientDB 1.6.4, remote connection. >>>> >>>> 1. Create DB >>>> 2. Do my tests. 4 threads simultaneously writing to DB >>>> 3. Drop DB >>>> 4. Create DB >>>> 5. Get an exception trying to create a vertex >>>> OrientVertex vertex = db.addVertex("OGraphVertex", null); >>>> >>>> com.orientechnologies.orient.enterprise.channel.binary.OResponseProcessingException: >>>>>> Exception during response processing. >>>>> >>>>> at com.orientechnologies.orient.enterprise.channel.binary. >>>>>> OChannelBinaryAsynchClient.throwSerializedException( >>>>>> OChannelBinaryAsynchClient.java:264) >>>>> >>>>> at com.orientechnologies.orient.enterprise.channel.binary. >>>>>> OChannelBinaryAsynchClient.handleStatus(OChannelBinaryAsynchClient. >>>>>> java:231) >>>>> >>>>> at com.orientechnologies.orient.enterprise.channel.binary. >>>>>> OChannelBinaryAsynchClient.beginResponse(OChannelBinaryAsynchClient. >>>>>> java:202) >>>>> >>>>> at com.orientechnologies.orient.enterprise.channel.binary. >>>>>> OChannelBinaryAsynchClient.beginResponse(OChannelBinaryAsynchClient. >>>>>> java:113) >>>>> >>>>> at com.orientechnologies.orient.client.remote.OStorageRemote. >>>>>> beginResponse(OStorageRemote.java:1856) >>>>> >>>>> at com.orientechnologies.orient.client.remote.OStorageRemote. >>>>>> createRecord(OStorageRemote.java:328) >>>>> >>>>> at com.orientechnologies.orient.client.remote.OStorageRemoteThread. >>>>>> createRecord(OStorageRemoteThread.java:216) >>>>> >>>>> at com.orientechnologies.orient.core.db.raw.ODatabaseRaw.save( >>>>>> ODatabaseRaw.java:265) >>>>> >>>>> at com.orientechnologies.orient.core.db.record. >>>>>> ODatabaseRecordAbstract.executeSaveRecord( >>>>>> ODatabaseRecordAbstract.java:816) >>>>> >>>>> at com.orientechnologies.orient.core.tx.OTransactionNoTx. >>>>>> saveRecord(OTransactionNoTx.java:77) >>>>> >>>>> at com.orientechnologies.orient.core.db.record. >>>>>> ODatabaseRecordTx.save(ODatabaseRecordTx.java:270) >>>>> >>>>> at com.orientechnologies.orient.core.db.record. >>>>>> ODatabaseRecordTx.save(ODatabaseRecordTx.java:38) >>>>> >>>>> at com.orientechnologies.orient.core.record.ORecordAbstract. >>>>>> save(ORecordAbstract.java:312) >>>>> >>>>> at com.orientechnologies.orient.core.record.impl.ODocument. >>>>>> save(ODocument.java:1323) >>>>> >>>>> at com.orientechnologies.orient.core.record.impl.ODocument. >>>>>> save(ODocument.java:1312) >>>>> >>>>> at com.orientechnologies.orient.core.record.impl.ODocument. >>>>>> save(ODocument.java:1301) >>>>> >>>>> at com.tinkerpop.blueprints.impls.orient.OrientElement. >>>>>> save(OrientElement.java:148) >>>>> >>>>> at com.tinkerpop.blueprints.impls.orient.OrientElement. >>>>>> save(OrientElement.java:134) >>>>> >>>>> at com.tinkerpop.blueprints.impls.orient.OrientBaseGraph. >>>>>> addVertex(OrientBaseGraph.java:356) >>>>> >>>>> at com.commsen.graphdbtests.orientdb.OrientdbInsertPerformanceTest. >>>>>> createVertex(OrientdbInsertPerformanceTest.java:25) >>>>> >>>>> at com.commsen.graphdbtests.orientdb.OrientdbInsertPerformanceTest. >>>>>> doAddDocuments_(OrientdbInsertPerformanceTest.java:120) >>>>> >>>>> at com.commsen.graphdbtests.orientdb.OrientdbInsertPerformanceTest. >>>>>> access$000(OrientdbInsertPerformanceTest.java:17) >>>>> >>>>> at com.commsen.graphdbtests.orientdb.OrientdbInsertPerformanceTest$ >>>>>> 1.call(OrientdbInsertPerformanceTest.java:160) >>>>> >>>>> at com.commsen.graphdbtests.orientdb.OrientdbInsertPerformanceTest$ >>>>>> 1.call(OrientdbInsertPerformanceTest.java:157) >>>>> >>>>> at java.util.concurrent.FutureTask.run(FutureTask.java:262) >>>>> >>>>> at java.util.concurrent.ThreadPoolExecutor.runWorker( >>>>>> ThreadPoolExecutor.java:1145) >>>>> >>>>> at java.util.concurrent.ThreadPoolExecutor$Worker.run( >>>>>> ThreadPoolExecutor.java:615) >>>>> >>>>> at java.lang.Thread.run(Thread.java:744) >>>>> >>>>> Caused by: com.orientechnologies.orient.core.exception.ODatabaseException: >>>>>> Database 'plocal:c:/projects/GraphDBs/orientdb-community-1.6.4/ >>>>>> databases//graphdb_tests_orient' is closed >>>>> >>>>> at com.orientechnologies.orient.core.db.record. >>>>>> ODatabaseRecordAbstract.checkOpeness(ODatabaseRecordAbstract.java: >>>>>> 1088) >>>>> >>>>> at com.orientechnologies.orient.core.db.record. >>>>>> ODatabaseRecordAbstract.getMetadata(ODatabaseRecordAbstract.java:556) >>>>> >>>>> at com.orientechnologies.orient.core.db.record. >>>>>> ODatabaseRecordAbstract.getMetadata(ODatabaseRecordAbstract.java:87) >>>>> >>>>> at com.orientechnologies.orient.core.db. >>>>>> ODatabaseRecordWrapperAbstract.getMetadata( >>>>>> ODatabaseRecordWrapperAbstract.java:156) >>>>> >>>>> at com.orientechnologies.orient.core.record. >>>>>> ORecordSchemaAwareAbstract.setClassNameIfExists( >>>>>> ORecordSchemaAwareAbstract.java:111) >>>>> >>>>> at com.orientechnologies.orient.core.serialization.serializer. >>>>>> record.string.ORecordSerializerSchemaAware2CSV.fromString( >>>>>> ORecordSerializerSchemaAware2CSV.java:377) >>>>> >>>>> at com.orientechnologies.orient.core.serialization.serializer. >>>>>> record.string.ORecordSerializerStringAbstract.fromStream( >>>>>> ORecordSerializerStringAbstract.java:80) >>>>> >>>>> at com.orientechnologies.orient.core.record. >>>>>> ORecordSchemaAwareAbstract.deserializeFields( >>>>>> ORecordSchemaAwareAbstract.java:150) >>>>> >>>>> at com.orientechnologies.orient.core.record.impl.ODocument. >>>>>> deserializeFields(ODocument.java:1371) >>>>> >>>>> at com.orientechnologies.orient.core.record.impl.ODocument. >>>>>> checkForFields(ODocument.java:1261) >>>>> >>>>> at com.orientechnologies.orient.core.record. >>>>>> ORecordSchemaAwareAbstract.validate(ORecordSchemaAwareAbstract. >>>>>> java:58) >>>>> >>>>> at com.orientechnologies.orient.core.db.document. >>>>>> ODatabaseDocumentTx.save(ODatabaseDocumentTx.java:265) >>>>> >>>>> at com.orientechnologies.orient.core.db.document. >>>>>> ODatabaseDocumentTx.save(ODatabaseDocumentTx.java:227) >>>>> >>>>> at com.orientechnologies.orient.core.db.document. >>>>>> ODatabaseDocumentTx.save(ODatabaseDocumentTx.java:45) >>>>> >>>>> at com.orientechnologies.orient.server.network.protocol.binary. >>>>>> OBinaryNetworkProtocolAbstract.createRecord( >>>>>> OBinaryNetworkProtocolAbstract.java:332) >>>>> >>>>> at com.orientechnologies.orient.server.network.protocol. >>>>>> binary.ONetworkProtocolBinary.createRecord( >>>>>> ONetworkProtocolBinary.java:1284) >>>>> >>>>> at com.orientechnologies.orient.server.network.protocol. >>>>>> binary.ONetworkProtocolBinary.executeRequest( >>>>>> ONetworkProtocolBinary.java:268) >>>>> >>>>> at com.orientechnologies.orient.server.network.protocol.binary. >>>>>> OBinaryNetworkProtocolAbstract.execute(OBinaryNetworkProtocolAbstract >>>>>> .java:125) >>>>> >>>>> at com.orientechnologies.common.thread.OSoftThread.run( >>>>>> OSoftThread.java:45) >>>>> >>>>> >>>> If I call >>>> >>>> db.isClosed() >>>> >>>> it returns FALSE. >>>> >>>> Any ideas? >>>> >>>> Thanks! >>>> >>>> -Andrey >>>> >>>> >>>> >>>> >>>> -- >>>> >>>> --- >>>> 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/groups/opt_out. >>>> >>> >>> >>> >>> -- >>> Best regards, >>> Andrey Lomakin. >>> >>> Orient Technologies >>> the Company behind OrientDB >>> >>> >> >> >> -- >> Best regards, >> Andrey Lomakin. >> >> Orient Technologies >> the Company behind OrientDB >> >> -- > > --- > 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/groups/opt_out. > -- Best regards, Andrey Lomakin. Orient Technologies the Company behind OrientDB -- --- 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/groups/opt_out.
