title: OrientDB connection pools
body: <p>I'm using OrientDB 2.2.5 for the backend for a multi threaded Java web application and I've tried numerous different connection methods. Each method seems to have a problem.</p>
  
  <p>I essentially need something that I can call concurrently to use the OrientDB database, be it a static method or object instance.</p>
  
  <p>I've tried various methods and had issues with record locking, or various other exceptions. The documentation shows a depreciated connection pool method (<code>ODatabaseDocumentPool</code>), and various other sources on the internet show a mixtures of ways (<code>ODatabaseDocumentTx</code>, <code>OPartitionedDatabasePool</code>). </p>
  
  <p>Please could someone provide a reusable method for connecting to the instance (currently just a plocal) and issuing a basic query. Please also include any connection cleanup logic (I think it's this that has caused me issues with records being locked, even several seconds after the last update). </p>
  
  <p>Any help/ pointers would be greatly appreciated. </p>