About multithreading

manual

Database Management Settings

Explains settings and performance tuning of the ObjectDB Java object database for JPA/JDO. The <database> configuration element specifies back end (database engine) settings which are relevant on the server side and in embedded mode. The default configuration file contains the following <database> element: ...

 
manual

Locking in JPA

Explains how to use optimistic locking and pessimistic locking in JPA. JPA 2 supports both optimistic locking and pessimistic locking . Locking is essential to avoid update collisions resulting from simultaneous updates to the same data by two concurrent users. Locking in ObjectDB (and in JPA) is always at the da ...

 
forum_thread

Multithreading Test and Deadlock

I move on to testing the multi threaded part of ObjectDB. From the same code (MyMain.java), I set the thread count from 1 to 4 and not only do I found it's slower overall (each thread only needs to insert 250K entities) but the threads are stuck with a deadlock. All threads share the same EntityManagerFactory but they have their own EntityManager. The stack trace is attached. ... try build 2.2.3_05 that should fix it. Regarding multithreading speed - currently in ObjectDB embedded mode multithreading improves performance in reading but not in writing. You can see ...

 
forum_thread

Multi-Threading/Distributed-Database Questions...

Greetings ObjectDB team, All below questions assume a very large database (~1,000,000,000 objects): Q1: In what cases would ObjectDB utilize multi-threading ? how about in JOIN operations ? Q2: Is it true that two read-only JPQL queries accessing the same database file actually run simultaneously if placed into two independent threads ? no I/O synchronization bottlenecks ?... in different threads is executed in parallel using multithreading, so one user thread that runs queries will not block another ... Please see more details about parallel execution and multithreading in this previous thread . References from objects in one ...

 
forum_thread

Explorer and multi-thread

When I use explorer.exe to browse the database in objectdb, eclipse tells me another app occupy it, then how can objectdb support multi-thread? ... 2011-05-17 08:58 Multithreading refers to the ability to use the same database in multiple ...

 
forum_thread

Are Queries in ObjectDB Multithreaded ?

Greating again ObjectDB team, Will ObjectDB query engine use multithreading whenever possible ? Generally, would a single query with multiple JOINs on the same class and some filtration criteria be faster than multiple queries each with a separate thread than join them using merge functions that filters none compliances ? e.g.: searching for two words with a boolean operator AND and the filtration criteria that both are within 10 word distance Thank you indeed !... again ObjectDB team, Will ObjectDB query engine use multithreading whenever possible ? Thank you indeed ! ... operations. Additional testing is required before enabling multithreading further, and that is expected in future versions. However, ...

 
issue

Deadlock on Schema Update during Multithreading activity

A possible deadlock was detected when new types are registered during multithreading activity against ObjectDB. Until this issue is fixed, the recommended workaround is to complete registration of all the persistable types before starting any multithreading activity against ObjectDB. A single class can be registered by:     emf.getMetamodel().entity(MyClass.class); All the classes can be registered by: ... was detected when new types are registered during multithreading activity against ObjectDB. Until this issue is fixed, ... of all the persistable types before starting any multithreading activity against ObjectDB. A single class can be ...

 
forum_thread

Multi-thread access to single EM's entities

If my entity classes have synchronized getters and setters, is it reliable for multiple threads to access a single EM's managed entities, as long as only the thread that created the EM interacts directly with it?  I've tested this and it seems to work... but I know better than to depend on the observable behavior of multithreaded code. When I run this example and examine the database, the entity contains the value set by the second thread, as expected.   #1 2012-04-09 02:22 If my entity classes have synchronized getters and setters, is it reliable for multiple threads to access a singl ...

 
forum_thread

Failing to read entities under load in multithreaded tests

Hi, We are experiencing an issue in our application that only occurs under load - we sometimes fail to read entities from the database. #1 2012-03-17 08:11 Hi, We are experiencing an issue in our application that only occurs under load - we sometimes fail to re ...

 
forum_thread

Exception on creation when running multithreaded

Hi, I'm trying to test the creation of an object from my datamodel(Organisation) and the creation process includes the creation of an acl for the newly created organisation all in the same transaction. The process is as followed: 1. The organisation gets created 2. The acl is being searched to check if it already exists 3. if it exists it will be updated, otherwise it will be created   #1 2011-08-04 07:08 Hi, I'm trying to test the creation of an object from my datamodel(Organisation) and the creation pro ...