14040 words

500Mb ObjectDb database opening issue

#1
2016-01-14 06:54

Hi,

I have observed that 500 Mb objectDb database opening time is very slow (~3 seconds) for following code

long time = System.currentTimeMillis();
 
m_EntityMgrFactory = Persistence.createEntityManagerFactory( "objectdb:" + aFilename );
m_EntityManager = m_EntityMgrFactory.createEntityManager();
 
LOGGER.info( String.format( "took [%d] ms", System.currentTimeMillis() - time ) );

Does exist any way to speed-up open time for big databases? Definitely, it's too long for 500 Mb database!

We gonna work with ObjectDb databases which may have size more than 5Gb and opening database time is very critical for us!

INFO : (AppDataStoreManager.java:277 thread:Thread-8): doOpenDataStore(): took [2583] ms

Opened Issue #264

Symphony Teleca (Harman)
Teleca
Teleca's picture
Joined on 2013-12-09
User Post #9
#2
2016-01-14 09:29

Obviously this is not the normal opening time for a database.

Opening time is not affected by the size of the database (since during opening ObjectDB just read the database file header). To some extent it is affected by the number of persistent types in the database since they are checked and analyzed. But it should not take more than a fraction of a second to open a database of any size.

Please provide more details. If you can make this specific database available for download it would help.

ObjectDB Support
ObjectDB - Fast Object Database for Java (JPA/JDO)
support
support's picture
Joined on 2010-05-03
User Post #2,381
#3
2016-01-14 11:25

Attached test database (440 Mb)!

Updated also initial post with Log4J output!

Symphony Teleca (Harman)
Teleca
Teleca's picture
Joined on 2013-12-09
User Post #11
#4
2016-01-15 14:59

The database file is opened very quickly in the Explorer.

If it takes longer in the application it is probably because of loading and analysing the relevant persistent types. This database has only 5 simple entity classes so this behaviour is unexpected, unless there is something in these entity classes (or referenced classes) that requires massive work during class loading (i.e. outside of the scope of ObjectDB).

Can you provide a simple test case that demonstrates the issue, i.e. a console application with your entity classes that just open the database?

Alternatively, please check opening the database with a Profiler to understand what activity is done during these 3 seconds.

ObjectDB Support
ObjectDB - Fast Object Database for Java (JPA/JDO)
support
support's picture
Joined on 2010-05-03
User Post #2,383
#5
2016-01-21 10:34

I will prepare test application ASAP, please wait...

Symphony Teleca (Harman)
Teleca
Teleca's picture
Joined on 2013-12-09
User Post #12
#6
2016-01-22 10:38

Below attached demo application & demo presentation which show problem with long data base open operation issue. Could you check from ObjectDb side which operations are take so long time during opening big database ~480 Mb

Symphony Teleca (Harman)
Teleca
Teleca's picture
Joined on 2013-12-09
User Post #13
#7
2016-01-25 10:03
+----------------------------------------------------------------------------------------------------+----------------+-------------+
|                                                Name                                                |   Time (ms)    |   Samples   |
+----------------------------------------------------------------------------------------------------+----------------+-------------+
|    +---java.lang.Thread.run()                                                                      |  1,825   81 %  |  15   63 %  |
|    | |                                                                                             |                |             |
|    | +---com.anritsu.pa3.application.pa3guiapplication.managers.AppDataImportManager$4.run()       |  1,794   80 %  |   2    8 %  |
|    |   |                                                                                           |                |             |
|    |   +---com.anritsu.pa3.application.pa3datastore.AppDataStoreManager.openDataStore(String)      |  1,794   80 %  |   2    8 %  |
|    |     |                                                                                         |                |             |
|    |     +---com.anritsu.pa3.application.pa3datastore.AppDataStoreManager.doOpenDataStore(String)  |  1,794   80 %  |   2    8 %  |
|    |       |                                                                                       |                |             |
|    |       +---javax.persistence.Persistence.createEntityManagerFactory(String)                    |    904   40 %  |   1    4 %  |
|    |       | |                                                                                     |                |             |
|    |       | +---com.objectdb.jpa.Provider.createEntityManagerFactory(String, Map)                 |    904   40 %  |   1    4 %  |
|    |       |   |                                                                                   |                |             |
|    |       |   +---com.objectdb.jpa.Provider.createEntityManagerFactory(String, Map)               |    904   40 %  |   1    4 %  |
|    |       |     |                                                                                 |                |             |
|    |       |     +---com.objectdb.o.UNM.w(ClassLoader, String)                                     |    904   40 %  |   1    4 %  |
|    |       |       |                                                                               |                |             |
|    |       |       +---com.objectdb.o.UNM.x(ClassLoader)                                           |    904   40 %  |   1    4 %  |
|    |       |         |                                                                             |                |             |
|    |       |         +---com.objectdb.o.UNM$z.<init>(ClassLoader)                                  |    904   40 %  |   1    4 %  |
|    |       |           |                                                                           |                |             |
|    |       |           +---com.objectdb.o.RCL.<clinit>()                                           |    904   40 %  |   1    4 %  |
|    |       |             |                                                                         |                |             |
|    |       |             +---com.objectdb.o.CFG.<clinit>()                                         |    904   40 %  |   1    4 %  |
|    |       |               |                                                                       |                |             |
|    |       |               +---com.objectdb.o.CFG.ad(CFG)                                          |    904   40 %  |   1    4 %  |
|    |       |                 |                                                                     |                |             |
|    |       |                 +---com.objectdb.o.CFG.af()                                           |    904   40 %  |   1    4 %  |
|    |       |                   |                                                                   |                |             |
|    |       |                   +---com.objectdb.o.CFG.ak(String[])                                 |    904   40 %  |   1    4 %  |
|    |       |                     |                                                                 |                |             |
|    |       |                     +---com.objectdb.o.CFG.al(String)                                 |    904   40 %  |   1    4 %  |
|    |       |                       |                                                               |                |             |
|    |       |                       +---com.objectdb.o.CFG.an(int)                                  |    904   40 %  |   1    4 %  |
|    |       |                         |                                                             |                |             |
|    |       |                         +---java.net.NetworkInterface.getHardwareAddress()            |    904   40 %  |   1    4 %  |
|    |       |                                                                                       |                |             |
|    |       +---com.objectdb.jpa.EMF.createEntityManager()                                          |    889   40 %  |   1    4 %  |
|    |         |                                                                                     |                |             |
|    |         +---com.objectdb.o.OMF.an(String, String)                                             |    889   40 %  |   1    4 %  |
|    |           |                                                                                   |                |             |
|    |           +---com.objectdb.jpa.EMF.ao(String, String)                                         |    889   40 %  |   1    4 %  |
|    |             |                                                                                 |                |             |
|    |             +---com.objectdb.o.OMF.ao(String, String)                                         |    889   40 %  |   1    4 %  |
|    |               |                                                                               |                |             |
|    |               +---java.lang.ClassLoader.loadClass(String)                                     |    889   40 %  |   1    4 %  |
+----------------------------------------------------------------------------------------------------+----------------+-------------+
Symphony Teleca (Harman)
Teleca
Teleca's picture
Joined on 2013-12-09
User Post #14
#8
2016-01-25 13:08

Thank you for the test application.

Strangely, we get different results:

1/23/2016 15:38:42.3842: INFO : (AppPropertyManager.java:144 thread:main): setInitialLoggerSettings(): Reconfiguration of log4j completed.
1/23/2016 15:38:42.3842: INFO : (AppMain.java:34 thread:main): main(): Java version used:1.8.0_66x32
1/23/2016 15:38:42.3842: INFO : (AppMain.java:35 thread:main): main(): PA3 Application start loading...
1/23/2016 15:38:43.3843: INFO : (AppPropertyManager.java:163 thread:AWT-EventQueue-0): setInitialImportLoggerSettings(): Reconfiguration of log4j for import to initial setting completed.
1/23/2016 15:38:43.3843: INFO : (AppCore.java:139 thread:AWT-EventQueue-0): start(): PA3 Application loading completed...
1/23/2016 15:40:23.4023: INFO : (AppDataStoreManager.java:242 thread:Thread-6): doOpenDataStore(): openDataStore: D:\odb\files\anritsu\F1018 Slow Open.odb.pa3
1/23/2016 15:40:24.4024: INFO : (AppDataStoreManager.java:257 thread:Thread-6): doOpenDataStore(): openDataStore took [624] ms
1/23/2016 15:42:31.4231: INFO : (AppCore.java:484 thread:AWT-EventQueue-0): onAppClose(): Pa3 application onAppClose(): Start
1/23/2016 15:42:31.4231: INFO : (AppDataStoreManager.java:82 thread:AWT-EventQueue-0): closeDataStore(): Close Pa3 datastore
1/23/2016 15:42:31.4231: INFO : (Pa3Utils.java:288 thread:AWT-EventQueue-0): interruptApplication(): PA3 Application was successfully closed.
1/23/2016 15:42:35.4235: INFO : (AppPropertyManager.java:144 thread:main): setInitialLoggerSettings(): Reconfiguration of log4j completed.
1/23/2016 15:42:35.4235: INFO : (AppMain.java:34 thread:main): main(): Java version used:1.8.0_66x32
1/23/2016 15:42:35.4235: INFO : (AppMain.java:35 thread:main): main(): PA3 Application start loading...
1/23/2016 15:42:36.4236: INFO : (AppPropertyManager.java:163 thread:AWT-EventQueue-0): setInitialImportLoggerSettings(): Reconfiguration of log4j for import to initial setting completed.
1/23/2016 15:42:36.4236: INFO : (AppCore.java:139 thread:AWT-EventQueue-0): start(): PA3 Application loading completed...
1/23/2016 15:42:47.4247: INFO : (AppDataStoreManager.java:242 thread:Thread-6): doOpenDataStore(): openDataStore: D:\odb\files\anritsu\F1018 Slow Open.odb.pa3
1/23/2016 15:42:48.4248: INFO : (AppDataStoreManager.java:257 thread:Thread-6): doOpenDataStore(): openDataStore took [594] ms
1/23/2016 15:55:48.5548: INFO : (AppCore.java:484 thread:AWT-EventQueue-0): onAppClose(): Pa3 application onAppClose(): Start
1/23/2016 15:55:48.5548: INFO : (AppDataStoreManager.java:82 thread:AWT-EventQueue-0): closeDataStore(): Close Pa3 datastore

i.e. about 600ms rather than 3 seconds (on a 4 years old i3 based computer).

We also tried the following simple test (with your persistent classes in the classpath):

import javax.persistence.*;
 
public class F1018 {
 
    public static void main(String[] args) {
 
        String path = "temp.odb";
 
        for (int i = 0; i < 10; i++)
        {  
            long ms = System.currentTimeMillis();
 
            EntityManagerFactory emf =
                Persistence.createEntityManagerFactory(path);
            EntityManager em = emf.createEntityManager();
 
            ms = System.currentTimeMillis() - ms;
            System.out.println("Open " + path + " time: " + ms);
 
            em.close();
            emf.close();
 
            path = "objectdb:D:\\odb\\files\\anritsu\\F1018 Slow Open.odb.pa3";
        }
    }
}

and the results are:

Open temp.odb time: 493
Open objectdb:D:\odb\files\anritsu\F1018 Slow Open.odb.pa3 time: 94
Open objectdb:D:\odb\files\anritsu\F1018 Slow Open.odb.pa3 time: 23
Open objectdb:D:\odb\files\anritsu\F1018 Slow Open.odb.pa3 time: 26
Open objectdb:D:\odb\files\anritsu\F1018 Slow Open.odb.pa3 time: 27
Open objectdb:D:\odb\files\anritsu\F1018 Slow Open.odb.pa3 time: 30
Open objectdb:D:\odb\files\anritsu\F1018 Slow Open.odb.pa3 time: 24
Open objectdb:D:\odb\files\anritsu\F1018 Slow Open.odb.pa3 time: 42
Open objectdb:D:\odb\files\anritsu\F1018 Slow Open.odb.pa3 time: 27
Open objectdb:D:\odb\files\anritsu\F1018 Slow Open.odb.pa3 time: 22

These results show that opening your specific database takes less than 100 milliseconds (excluding loading of ObjectDB into the JVM, which is done in this test before opening your database file, by creating another temporary database file).

Try to load ObjectDB in the background (e.g. by opening a temporary database file as in the test above) and see if later it helps in speeding up the opening of your database.

Regarding your new profiling info at #14, please try running the following code on your computer (e.g. as a simple console application):

    Enumeration e = NetworkInterface.getNetworkInterfaces();
    while (e.hasMoreElements()) {
        NetworkInterface ni = (NetworkInterface)e.nextElement();
        byte[] hardwareAddress = ni.getHardwareAddress();
    }

If takes more than a few milliseconds on your machine then maybe this is the cause.

Another thing to check, if you use XML to define JPA/JDO entity/persistence capable classes, check the XML header, since sometimes XML validation requires searching the Internet.

ObjectDB Support
ObjectDB - Fast Object Database for Java (JPA/JDO)
support
support's picture
Joined on 2010-05-03
User Post #2,392
#9
2016-01-26 11:08

By requirement we MUST use only jdk1.7x32 Java, could you check with this Java the same test case?

Symphony Teleca (Harman)
Teleca
Teleca's picture
Joined on 2013-12-09
User Post #15
#10
2016-01-26 20:43

Similar results with JDK 1.7.0_79 32 bit:

Open temp.odb time: 370
Open objectdb:D:\odb\files\anritsu\F1018 Slow Open.odb.pa3 time: 79
Open objectdb:D:\odb\files\anritsu\F1018 Slow Open.odb.pa3 time: 28
Open objectdb:D:\odb\files\anritsu\F1018 Slow Open.odb.pa3 time: 27
Open objectdb:D:\odb\files\anritsu\F1018 Slow Open.odb.pa3 time: 37
Open objectdb:D:\odb\files\anritsu\F1018 Slow Open.odb.pa3 time: 20
Open objectdb:D:\odb\files\anritsu\F1018 Slow Open.odb.pa3 time: 20
Open objectdb:D:\odb\files\anritsu\F1018 Slow Open.odb.pa3 time: 23
Open objectdb:D:\odb\files\anritsu\F1018 Slow Open.odb.pa3 time: 19
Open objectdb:D:\odb\files\anritsu\F1018 Slow Open.odb.pa3 time: 19

Note that the profiling info at #7 above is based on sampling (with apparently very few samples) so it may be very inaccurate. You will have to find the bottleneck using your runtime environment, and then, if it is an issue with ObjectDB we will probably can repair it. Try to isolate the issue from your application.

ObjectDB Support
ObjectDB - Fast Object Database for Java (JPA/JDO)
support
support's picture
Joined on 2010-05-03
User Post #2,396
#11
2016-01-26 20:51

Similar results with your test application:

1/26/2016 20:49:23.4923: INFO : (AppPropertyManager.java:144 thread:main): setInitialLoggerSettings(): Reconfiguration of log4j completed.
1/26/2016 20:49:23.4923: INFO : (AppMain.java:34 thread:main): main(): Java version used:1.7.0_79x32
1/26/2016 20:49:23.4923: INFO : (AppMain.java:35 thread:main): main(): PA3 Application start loading...
1/26/2016 20:49:24.4924: INFO : (AppPropertyManager.java:163 thread:AWT-EventQueue-0): setInitialImportLoggerSettings(): Reconfiguration of log4j for import to initial setting completed.
1/26/2016 20:49:25.4925: INFO : (AppCore.java:139 thread:AWT-EventQueue-0): start(): PA3 Application loading completed...
1/26/2016 20:49:39.4939: INFO : (AppDataStoreManager.java:242 thread:Thread-6): doOpenDataStore(): openDataStore: D:\odb\files\anritsu\F1018 Slow Open.odb.pa3
1/26/2016 20:49:39.4939: INFO : (AppDataStoreManager.java:257 thread:Thread-6): doOpenDataStore(): openDataStore took [700] ms
1/26/2016 20:49:44.4944: INFO : (AppCore.java:484 thread:AWT-EventQueue-0): onAppClose(): Pa3 application onAppClose(): Start
1/26/2016 20:49:44.4944: INFO : (AppDataStoreManager.java:82 thread:AWT-EventQueue-0): closeDataStore(): Close Pa3 datastore
1/26/2016 20:49:44.4944: INFO : (Pa3Utils.java:288 thread:AWT-EventQueue-0): interruptApplication(): PA3 Application was successfully closed.
ObjectDB Support
ObjectDB - Fast Object Database for Java (JPA/JDO)
support
support's picture
Joined on 2010-05-03
User Post #2,397
#12
2016-01-29 07:43

Our H/W is:

1. OS: Windows 7x64 with 12 Gb of RAM
2. CPU: Intel Core TM i5-3570, 3.4GHz
3. PC included in DOMAIN

According to post #8 we tried to load Object DB in background (on loading application) and got following results:

1/29/2016 11:58:35.5835: INFO : (AppMain.java:34 thread:main): main(): Java version used:1.7.0_07x32
1/29/2016 11:58:35.5835: INFO : (AppMain.java:35 thread:main): main(): PA3 Application start loading...
1/29/2016 11:58:36.5836: INFO : (AppPropertyManager.java:163 thread:AWT-EventQueue-0): setInitialImportLoggerSettings(): Reconfiguration of log4j for import to initial setting completed.
1/29/2016 11:58:39.5839: INFO : (AppDataStoreManager.java:258 thread:AWT-EventQueue-0): openTempDataStore(): openTempDataStore took [2660] ms
1/29/2016 11:58:39.5839: INFO : (AppCore.java:138 thread:AWT-EventQueue-0): start(): PA3 Application loading completed...
1/29/2016 11:58:54.5854: INFO : (AppDataStoreManager.java:274 thread:Thread-7): doOpenDataStore(): openDataStore: D:\tmp\Huge Logs\Perfomance\TC_7_1_7_1_3@2015-11-07_09.20.15_480MB\TC_7_1_7_1_3@2015-11-07_09.20.15_480MB.pa3
1/29/2016 11:58:54.5854: INFO : (AppDataStoreManager.java:289 thread:Thread-7): doOpenDataStore(): openDataStore took [38] ms
1/29/2016 11:59:32.5932: INFO : (AppDataStoreManager.java:82 thread:AWT-EventQueue-0): closeDataStore(): Close Pa3 datastore


Yes, performance was improved on second opening database, but we just moved long operation to start application, it means problem still exists.

We got results also for following code on our PCs

public PA3_DB_STATUS openTempDataStore()
   {
      long time = System.currentTimeMillis();
 
      String tmpDataBaseName = "temp.odb";
 
      try
      {
         Enumeration e = NetworkInterface.getNetworkInterfaces();
 
         while ( e.hasMoreElements() )
         {
            NetworkInterface ni = (NetworkInterface)e.nextElement();
            byte[] hardwareAddress = ni.getHardwareAddress();
         }
      }
      catch ( SocketException aException )
      {
 
      }
 
      LOGGER.info( String.format( "openTempDataStore: getNetworkInterfaces took [%d] ms ", System.currentTimeMillis() - time ) );
 
      try
      {
         m_EntityMgrFactory = Persistence.createEntityManagerFactory( tmpDataBaseName );
         m_EntityManager = m_EntityMgrFactory.createEntityManager();
 
         m_EntityManager.close();
         m_EntityManager = null;
 
         m_EntityMgrFactory.close();
         m_EntityMgrFactory = null;
 
         Files.deleteIfExists( Paths.get( tmpDataBaseName ) );
 
         LOGGER.info( String.format( "openTempDataStore took [%d] ms ", System.currentTimeMillis() - time ) );
      }
      catch ( Exception aException )
      {
         LOGGER.error( Pa3Utils.exceptionToString( aException ) );
 
         return PA3_DB_STATUS.STATUS_FAIL;
      }
 
      return PA3_DB_STATUS.STATUS_OK;
   }

Results are below:

1/29/2016 12:55:40.5540: INFO : (AppMain.java:34 thread:main): main(): Java version used:1.7.0_07x32
1/29/2016 12:55:40.5540: INFO : (AppMain.java:35 thread:main): main(): PA3 Application start loading...
1/29/2016 12:55:40.5540: INFO : (AppPropertyManager.java:163 thread:AWT-EventQueue-0): setInitialImportLoggerSettings(): Reconfiguration of log4j for import to initial setting completed.
1/29/2016 12:55:41.5541: INFO : (AppDataStoreManager.java:269 thread:AWT-EventQueue-0): openTempDataStore(): openTempDataStore: getNetworkInterfaces took [80] ms
1/29/2016 12:55:44.5544: INFO : (AppDataStoreManager.java:284 thread:AWT-EventQueue-0): openTempDataStore(): openTempDataStore took [2540] ms
1/29/2016 12:55:44.5544: INFO : (AppCore.java:138 thread:AWT-EventQueue-0): start(): PA3 Application loading completed...
1/29/2016 12:55:45.5545: INFO : (AppCore.java:483 thread:AWT-EventQueue-0): onAppClose(): Pa3 application onAppClose(): Start
1/29/2016 12:55:45.5545: INFO : (Pa3Utils.java:288 thread:AWT-EventQueue-0): interruptApplication(): PA3 Application was successfully closed.

Ps. Are you using loaded ObjectDb as service maybe during your tests? We could not understand why our and ObjectDb team results are different? We tried Demo Application v2 on several PCs, but results the same!

Symphony Teleca (Harman)
Teleca
Teleca's picture
Joined on 2013-12-09
User Post #16
#13
2016-01-29 08:58

Stack for Demo Application v2

+-----------------------------------------------------------------------------------------------------------------------+----------------+----------------+
|                                                         Name                                                          |   Time (ms)    |    Samples     |
+-----------------------------------------------------------------------------------------------------------------------+----------------+----------------+
|  +---<All threads>                                                                                                    |  4,648  100 %  |  1,311  100 %  |
|    |                                                                                                                  |                |                |
|    +---java.awt.EventDispatchThread.run()                                                                             |  4,555   98 %  |    242   18 %  |
|    | |                                                                                                                |                |                |
|    | +---com.anritsu.pa3.application.AppMain$1.run()                                                                  |  4,352   94 %  |    240   18 %  |
|    |   |                                                                                                              |                |                |
|    |   +---com.anritsu.pa3.application.pa3guiapplication.core.AppCore.start()                                         |  3,822   82 %  |    211   16 %  |
|    |   | |                                                                                                            |                |                |
|    |   | +---com.anritsu.pa3.application.pa3datastore.AppDataStoreManager.openTempDataStore()                         |  2,542   55 %  |    142   11 %  |
|    |   | | |                                                                                                          |                |                |
|    |   | | +---javax.persistence.Persistence.createEntityManagerFactory(String)                                       |  2,293   49 %  |    129   10 %  |
|    |   | | | |                                                                                                        |                |                |
|    |   | | | +---com.objectdb.jpa.Provider.createEntityManagerFactory(String, Map)                                    |  2,262   49 %  |    128   10 %  |
|    |   | | |   |                                                                                                      |                |                |
|    |   | | |   +---com.objectdb.jpa.Provider.createEntityManagerFactory(String, Map)                                  |  2,262   49 %  |    128   10 %  |
|    |   | | |     |                                                                                                    |                |                |
|    |   | | |     +---com.objectdb.o.UNM.w(ClassLoader, String)                                                        |  2,230   48 %  |    125   10 %  |
|    |   | | |     | |                                                                                                  |                |                |
|    |   | | |     | +---com.objectdb.o.UNM.x(ClassLoader)                                                              |  2,230   48 %  |    125   10 %  |
|    |   | | |     |   |                                                                                                |                |                |
|    |   | | |     |   +---com.objectdb.o.UNM$z.<init>(ClassLoader)                                                     |  2,230   48 %  |    125   10 %  |
|    |   | | |     |     |                                                                                              |                |                |
|    |   | | |     |     +---com.objectdb.o.RCL.<clinit>()                                                              |  2,230   48 %  |    125   10 %  |
|    |   | | |     |       |                                                                                            |                |                |
|    |   | | |     |       +---com.objectdb.o.CFG.<clinit>()                                                            |  2,230   48 %  |    125   10 %  |
|    |   | | |     |         |                                                                                          |                |                |
|    |   | | |     |         +---com.objectdb.o.CFG.ad(CFG)                                                             |  2,230   48 %  |    125   10 %  |
|    |   | | |     |           |                                                                                        |                |                |
|    |   | | |     |           +---com.objectdb.o.CFG.af()                                                              |  2,199   47 %  |    123    9 %  |
|    |   | | |     |           | |                                                                                      |                |                |
|    |   | | |     |           | +---com.objectdb.o.CFG.ak(String[])                                                    |  2,199   47 %  |    123    9 %  |
|    |   | | |     |           |   |                                                                                    |                |                |
|    |   | | |     |           |   +---com.objectdb.o.CFG.al(String)                                                    |  2,199   47 %  |    123    9 %  |
|    |   | | |     |           |     |                                                                                  |                |                |
|    |   | | |     |           |     +---com.objectdb.o.CFG.an(int)                                                     |  2,199   47 %  |    123    9 %  |
|    |   | | |     |           |       |                                                                                |                |                |
|    |   | | |     |           |       +---java.net.NetworkInterface.getNetworkInterfaces()                             |  1,341   29 %  |     74    6 %  |
|    |   | | |     |           |       |                                                                                |                |                |
|    |   | | |     |           |       +---java.net.NetworkInterface.getHardwareAddress()                               |    858   18 %  |     49    4 %  |
|    |   | | |     |           |                                                                                        |                |                |
|    |   | | |     |           +---com.objectdb.o.CFG.ae()                                                              |     15    0 %  |      1    0 %  |
|    |   | | |     |           |                                                                                        |                |                |
|    |   | | |     |           +---com.objectdb.o.CNM.<init>(CFG)                                                       |     15    0 %  |      1    0 %  |
|    |   | | |     |                                                                                                    |                |                |
|    |   | | |     +---com.objectdb.jpa.Provider.newEMF(PersistenceUnitInfo, Map)                                       |     31    1 %  |      3    0 %  |
|    |   | | |                                                                                                          |                |                |
|    |   | | +---com.objectdb.jpa.EMF.createEntityManager()                                                             |    187    4 %  |      9    1 %  |
|    |   | | |                                                                                                          |                |                |
|    |   | | +---java.net.NetworkInterface.getNetworkInterfaces()                                                       |     31    1 %  |      2    0 %  |
|    |   | | |                                                                                                          |                |                |
|    |   | | +---com.objectdb.o.OMF.close()                                                                             |     15    0 %  |      1    0 %  |
|    |   | | |                                                                                                          |                |                |
|    |   | | +---java.net.NetworkInterface.getHardwareAddress()                                                         |     15    0 %  |      1    0 %  |
|    |   | |                                                                                                            |                |                |
|    |   | +---com.anritsu.pa3.application.pa3guiapplication.core.AppCore.initUI()                                      |    826   18 %  |     42    3 %  |
|    |   | |                                                                                                            |                |                |
|    |   | +---com.jidesoft.swing.AbstractLayoutPersistence.loadLayoutDataFromFile(String)                              |    218    5 %  |     14    1 %  |
|    |   | |                                                                                                            |                |                |
|    |   | +---com.anritsu.pa3.application.pa3guiapplication.core.AppCore.createTabs()                                  |    156    3 %  |      9    1 %  |
|    |   | |                                                                                                            |                |                |
|    |   | +---com.anritsu.pa3.application.pa3guiapplication.core.AppResultArchiveView.<init>(AppResultArchiveManager)  |     62    1 %  |      3    0 %  |
|    |   | |                                                                                                            |                |                |
|    |   | +---com.anritsu.pa3.application.pa3guiapplication.core.AppCore.addEventListeners()                           |     15    0 %  |      1    0 %  |
|    |   |                                                                                                              |                |                |
|    |   +---com.anritsu.pa3.application.pa3guiapplication.core.AppCore.initInstance(String, AppSplashScreen)           |    280    6 %  |     16    1 %  |
|    |   |                                                                                                              |                |                |
|    |   +---com.jidesoft.plaf.LookAndFeelFactory.installJideExtension()                                                |    234    5 %  |     12    1 %  |
|    |   |                                                                                                              |                |                |
|    |   +---java.lang.ClassLoader.loadClass(String)                                                                    |     15    0 %  |      1    0 %  |
|    |                                                                                                                  |                |                |
|    +---java.lang.Thread.run()                                                                                         |     93    2 %  |    455   35 %  |
|    |                                                                                                                  |                |                |
|    +---java.lang.ref.Finalizer$FinalizerThread.run()                                                                  |      0    0 %  |    228   17 %  |
|    |                                                                                                                  |                |                |
|    +---java.lang.ref.Reference$ReferenceHandler.run()                                                                 |      0    0 %  |    228   17 %  |
|    |                                                                                                                  |                |                |
|    +---sun.awt.image.ImageFetcher.run()                                                                               |      0    0 %  |    158   12 %  |
+-----------------------------------------------------------------------------------------------------------------------+----------------+----------------+
Symphony Teleca (Harman)
Teleca
Teleca's picture
Joined on 2013-12-09
User Post #17
#14
2016-01-29 11:50

How did you run the code at #12 above? can you try it in a simple console application to check if the problem is related to the way in which ObjectDB is loaded? Make sure that everything is available locally and not on a remote storage.

ObjectDB Support
ObjectDB - Fast Object Database for Java (JPA/JDO)
support
support's picture
Joined on 2010-05-03
User Post #2,400
#15
2016-01-29 13:44

I already attached simple demo application related to #12. Please check again! The test steps are the same as for demo version 1.

1. Launch App (ObjectDb will be loaded in BG)
2. Open huge log
3. Check Log4J logs
 

Symphony Teleca (Harman)
Teleca
Teleca's picture
Joined on 2013-12-09
User Post #18
#16
2016-01-29 13:54

The purpose of the new test application is unclear. We already saw several times that the delay doesn't happen on our computers, so what is the purpose of moving database access to startup and testing it again on our computers?

Since the problem happens in your environment we will have to continue with diagnosis on your computers. Therefore, the questions in #14 are for proceeding from that point.

ObjectDB Support
ObjectDB - Fast Object Database for Java (JPA/JDO)
support
support's picture
Joined on 2010-05-03
User Post #2,401
#17
2016-01-29 14:11

The purpose of Demo App v2 is to show that problems are in OjectDb, we got the logs from several PCs (ALL PCs were new without any extra S/W like ObjectDb) and results the same.

Statement that ALL WORKS FINE on ObjectDb team computer's is not correct, please find the reason why it works so fast please on your PC, may it be that during your tests ObjectDb was already once launched?

We checked also getHardwareAddress() interface directly and it takes not more 80ms on our PCs, but inside of ObjectDb engine it takes ~2 sec, why?

Let's repeat, that this issue observed only for first loading database (~3 sec loading).

Symphony Teleca (Harman)
Teleca
Teleca's picture
Joined on 2013-12-09
User Post #19
#18
2016-01-29 14:21

> The purpose of Demo App v2 is to show that problems are in OjectDb

Let's assume that there is a problem in ObjectDB that has to be fixed in order to eliminate the initialization time that you experience. In that case, obviously it is in our interest to solve the problem. However, the way to proceed is to explore the problem where it happens and not where it doesn't happen. Unfortunately it doesn't happen on our computers (otherwise we could locate the issue and repair it already). Therefore, we have no way to proceed without your help.

You tested the application on several computers, but probably all of them on the same network and maybe with similar configuration. We will still need your help in finding the exact cause of this issue.

One thing you should try is to remove all activations from the objectdb.conf file. With an OEM license your end users do not need activation codes, and you should avoid including activation codes in your distributed application. Maybe checking all these activation codes takes much more time on your system than on ours (it is unclear why).

Other things to check that may help understanding the cause is opening a database file in a console application, on computers outside of your network, and using different configurations (without activation code).

ObjectDB Support
ObjectDB - Fast Object Database for Java (JPA/JDO)
support
support's picture
Joined on 2010-05-03
User Post #2,402
#19
2016-01-29 14:49

Thank you for suggestion to remove all activation codes. I removed all of them, but there is no differences in result

With activation codes ~15 codes was observed

1/29/2016 18:53:21.5321: INFO : (AppDataStoreManager.java:269 thread:AWT-EventQueue-0): openTempDataStore(): openTempDataStore: getNetworkInterfaces took [58] ms
1/29/2016 18:53:24.5324: INFO : (AppDataStoreManager.java:284 thread:AWT-EventQueue-0): openTempDataStore(): openTempDataStore took [2636] ms

With removed activation codes

1/29/2016 18:56:00.560: INFO : (AppDataStoreManager.java:269 thread:AWT-EventQueue-0): openTempDataStore(): openTempDataStore: getNetworkInterfaces took [50] ms
1/29/2016 18:56:03.563: INFO : (AppDataStoreManager.java:284 thread:AWT-EventQueue-0): openTempDataStore(): openTempDataStore took [2510] ms

Also checked to open DB without network connection (disabled local connection). Results below:

1/29/2016 19:03:34.334: INFO : (AppDataStoreManager.java:269 thread:AWT-EventQueue-0): openTempDataStore(): openTempDataStore: getNetworkInterfaces took [50] ms
1/29/2016 19:03:36.336: INFO : (AppDataStoreManager.java:284 thread:AWT-EventQueue-0): openTempDataStore(): openTempDataStore took [1580] ms
Symphony Teleca (Harman)
Teleca
Teleca's picture
Joined on 2013-12-09
User Post #20
#20
2016-01-29 14:59

Could you please check the profiler again. Without activation codes it should show different results.

Please try also opening an empty database in a console application with no activation codes.

ObjectDB Support
ObjectDB - Fast Object Database for Java (JPA/JDO)
support
support's picture
Joined on 2010-05-03
User Post #2,403
#21
2016-01-29 15:06

Call stack without activation codes but local network is active below:

+-----------------------------------------------------------------------------------------------------------------------+----------------+--------------+
|                                                         Name                                                          |   Time (ms)    |   Samples    |
+-----------------------------------------------------------------------------------------------------------------------+----------------+--------------+
|  +---<All threads>                                                                                                    |  4,477  100 %  |  679  100 %  |
|    |                                                                                                                  |                |              |
|    +---java.awt.EventDispatchThread.run()                                                                             |  4,305   96 %  |  239   35 %  |
|    | |                                                                                                                |                |              |
|    | +---com.anritsu.pa3.application.AppMain$1.run()                                                                  |  4,212   94 %  |  234   34 %  |
|    |   |                                                                                                              |                |              |
|    |   +---com.anritsu.pa3.application.pa3guiapplication.core.AppCore.start()                                         |  3,260   73 %  |  184   27 %  |
|    |   | |                                                                                                            |                |              |
|    |   | +---com.anritsu.pa3.application.pa3datastore.AppDataStoreManager.openTempDataStore()                         |  2,511   56 %  |  138   20 %  |
|    |   | | |                                                                                                          |                |              |
|    |   | | +---javax.persistence.Persistence.createEntityManagerFactory(String)                                       |  2,262   51 %  |  126   19 %  |
|    |   | | | |                                                                                                        |                |              |
|    |   | | | +---com.objectdb.jpa.Provider.createEntityManagerFactory(String, Map)                                    |  2,262   51 %  |  126   19 %  |
|    |   | | |   |                                                                                                      |                |              |
|    |   | | |   +---com.objectdb.jpa.Provider.createEntityManagerFactory(String, Map)                                  |  2,262   51 %  |  126   19 %  |
|    |   | | |     |                                                                                                    |                |              |
|    |   | | |     +---com.objectdb.o.UNM.w(ClassLoader, String)                                                        |  2,184   49 %  |  121   18 %  |
|    |   | | |     | |                                                                                                  |                |              |
|    |   | | |     | +---com.objectdb.o.UNM.x(ClassLoader)                                                              |  2,184   49 %  |  121   18 %  |
|    |   | | |     |   |                                                                                                |                |              |
|    |   | | |     |   +---com.objectdb.o.UNM$z.<init>(ClassLoader)                                                     |  2,184   49 %  |  121   18 %  |
|    |   | | |     |     |                                                                                              |                |              |
|    |   | | |     |     +---com.objectdb.o.RCL.<clinit>()                                                              |  2,184   49 %  |  121   18 %  |
|    |   | | |     |       |                                                                                            |                |              |
|    |   | | |     |       +---com.objectdb.o.CFG.<clinit>()                                                            |  2,184   49 %  |  121   18 %  |
|    |   | | |     |         |                                                                                          |                |              |
|    |   | | |     |         +---com.objectdb.o.CFG.ad(CFG)                                                             |  2,152   48 %  |  120   18 %  |
|    |   | | |     |         | |                                                                                        |                |              |
|    |   | | |     |         | +---com.objectdb.o.CFG.af()                                                              |  2,152   48 %  |  120   18 %  |
|    |   | | |     |         |   |                                                                                      |                |              |
|    |   | | |     |         |   +---com.objectdb.o.CFG.ak(String[])                                                    |  2,152   48 %  |  120   18 %  |
|    |   | | |     |         |     |                                                                                    |                |              |
|    |   | | |     |         |     +---com.objectdb.o.CFG.al(String)                                                    |  2,152   48 %  |  120   18 %  |
|    |   | | |     |         |       |                                                                                  |                |              |
|    |   | | |     |         |       +---com.objectdb.o.CFG.an(int)                                                     |  2,152   48 %  |  120   18 %  |
|    |   | | |     |         |         |                                                                                |                |              |
|    |   | | |     |         |         +---java.net.NetworkInterface.getNetworkInterfaces()                             |  1,310   29 %  |   74   11 %  |
|    |   | | |     |         |         |                                                                                |                |              |
|    |   | | |     |         |         +---java.net.NetworkInterface.getHardwareAddress()                               |    826   18 %  |   45    7 %  |
|    |   | | |     |         |         |                                                                                |                |              |
|    |   | | |     |         |         +---com.objectdb.o.SYH.T()                                                       |     15    0 %  |    1    0 %  |
|    |   | | |     |         |                                                                                          |                |              |
|    |   | | |     |         +---com.objectdb.o.CFG.<init>(String, LFL)                                                 |     31    1 %  |    1    0 %  |
|    |   | | |     |                                                                                                    |                |              |
|    |   | | |     +---com.objectdb.jpa.Provider.newEMF(PersistenceUnitInfo, Map)                                       |     78    2 %  |    5    1 %  |
|    |   | | |                                                                                                          |                |              |
|    |   | | +---com.objectdb.jpa.EMF.createEntityManager()                                                             |    187    4 %  |    9    1 %  |
|    |   | | | |                                                                                                        |                |              |
|    |   | | | +---com.objectdb.o.OMF.an(String, String)                                                                |    187    4 %  |    9    1 %  |
|    |   | | |   |                                                                                                      |                |              |
|    |   | | |   +---com.objectdb.jpa.EMF.ao(String, String)                                                            |    171    4 %  |    8    1 %  |
|    |   | | |   |                                                                                                      |                |              |
|    |   | | |   +---com.objectdb.jpa.EMF.ar(STO, TYM)                                                                  |     15    0 %  |    1    0 %  |
|    |   | | |                                                                                                          |                |              |
|    |   | | +---java.net.NetworkInterface.getNetworkInterfaces()                                                       |     31    1 %  |    1    0 %  |
|    |   | | |                                                                                                          |                |              |
|    |   | | +---java.lang.String.format(String, Object[])                                                              |     15    0 %  |    1    0 %  |
|    |   | | |                                                                                                          |                |              |
|    |   | | +---java.net.NetworkInterface.getHardwareAddress()                                                         |     15    0 %  |    1    0 %  |
|    |   | |                                                                                                            |                |              |
|    |   | +---com.anritsu.pa3.application.pa3guiapplication.core.AppCore.initUI()                                      |    343    8 %  |   18    3 %  |
|    |   | |                                                                                                            |                |              |
|    |   | +---com.jidesoft.swing.AbstractLayoutPersistence.loadLayoutDataFromFile(String)                              |    202    5 %  |   15    2 %  |
|    |   | |                                                                                                            |                |              |
|    |   | +---com.anritsu.pa3.application.pa3guiapplication.core.AppCore.createTabs()                                  |    171    4 %  |   10    1 %  |
|    |   | |                                                                                                            |                |              |
|    |   | +---com.anritsu.pa3.application.pa3guiapplication.core.AppResultArchiveView.<init>(AppResultArchiveManager)  |     31    1 %  |    2    0 %  |
|    |   | |                                                                                                            |                |              |
|    |   | +---com.anritsu.pa3.application.pa3guiapplication.managers.AppResultArchiveManager.<init>()                  |      0    0 %  |    1    0 %  |
|    |   |                                                                                                              |                |              |
|    |   +---com.anritsu.pa3.application.pa3guiapplication.core.AppCore.initInstance(String, AppSplashScreen)           |    733   16 %  |   39    6 %  |
|    |   |                                                                                                              |                |              |
|    |   +---com.jidesoft.plaf.LookAndFeelFactory.installJideExtension()                                                |    218    5 %  |   11    2 %  |
|    |                                                                                                                  |                |              |
|    +---java.lang.Thread.run()                                                                                         |     93    2 %  |  226   33 %  |
|    |                                                                                                                  |                |              |
|    +---sun.awt.image.ImageFetcher.run()                                                                               |     78    2 %  |  214   32 %  |
+-----------------------------------------------------------------------------------------------------------------------+----------------+--------------+

 

Symphony Teleca (Harman)
Teleca
Teleca's picture
Joined on 2013-12-09
User Post #21
#22
2016-01-29 15:12

This is strange, because with no activation codes the calls to  NetworkInterface methods are unexpected.

Please double check that the activation codes are removed from the objectdb.conf file that is actually in use (maybe you have more than one configuration file embedded in the application).

ObjectDB Support
ObjectDB - Fast Object Database for Java (JPA/JDO)
support
support's picture
Joined on 2010-05-03
User Post #2,404
#23
2016-01-29 15:09

Call stack without activation codes & network connection also disabled below:

+-----------------------------------------------------------------------------------------------------------------------+----------------+--------------+
|                                                         Name                                                          |   Time (ms)    |   Samples    |
+-----------------------------------------------------------------------------------------------------------------------+----------------+--------------+
|  +---<All threads>                                                                                                    |  3,307  100 %  |  476  100 %  |
|    |                                                                                                                  |                |              |
|    +---java.awt.EventDispatchThread.run()                                                                             |  3,151   95 %  |  174   37 %  |
|    | |                                                                                                                |                |              |
|    | +---com.anritsu.pa3.application.AppMain$1.run()                                                                  |  3,026   92 %  |  169   36 %  |
|    |   |                                                                                                              |                |              |
|    |   +---com.anritsu.pa3.application.pa3guiapplication.core.AppCore.start()                                         |  2,340   71 %  |  134   28 %  |
|    |   | |                                                                                                            |                |              |
|    |   | +---com.anritsu.pa3.application.pa3datastore.AppDataStoreManager.openTempDataStore()                         |  1,606   49 %  |   88   18 %  |
|    |   | | |                                                                                                          |                |              |
|    |   | | +---javax.persistence.Persistence.createEntityManagerFactory(String)                                       |  1,357   41 %  |   76   16 %  |
|    |   | | | |                                                                                                        |                |              |
|    |   | | | +---com.objectdb.jpa.Provider.createEntityManagerFactory(String, Map)                                    |  1,357   41 %  |   76   16 %  |
|    |   | | |   |                                                                                                      |                |              |
|    |   | | |   +---com.objectdb.jpa.Provider.createEntityManagerFactory(String, Map)                                  |  1,357   41 %  |   76   16 %  |
|    |   | | |     |                                                                                                    |                |              |
|    |   | | |     +---com.objectdb.o.UNM.w(ClassLoader, String)                                                        |  1,294   39 %  |   72   15 %  |
|    |   | | |     | |                                                                                                  |                |              |
|    |   | | |     | +---com.objectdb.o.UNM.x(ClassLoader)                                                              |  1,294   39 %  |   72   15 %  |
|    |   | | |     |   |                                                                                                |                |              |
|    |   | | |     |   +---com.objectdb.o.UNM$z.<init>(ClassLoader)                                                     |  1,294   39 %  |   72   15 %  |
|    |   | | |     |     |                                                                                              |                |              |
|    |   | | |     |     +---com.objectdb.o.RCL.<clinit>()                                                              |  1,294   39 %  |   72   15 %  |
|    |   | | |     |       |                                                                                            |                |              |
|    |   | | |     |       +---com.objectdb.o.CFG.<clinit>()                                                            |  1,294   39 %  |   72   15 %  |
|    |   | | |     |         |                                                                                          |                |              |
|    |   | | |     |         +---com.objectdb.o.CFG.ad(CFG)                                                             |  1,263   38 %  |   71   15 %  |
|    |   | | |     |         | |                                                                                        |                |              |
|    |   | | |     |         | +---com.objectdb.o.CFG.af()                                                              |  1,232   37 %  |   70   15 %  |
|    |   | | |     |         | | |                                                                                      |                |              |
|    |   | | |     |         | | +---com.objectdb.o.CFG.ak(String[])                                                    |  1,232   37 %  |   70   15 %  |
|    |   | | |     |         | |   |                                                                                    |                |              |
|    |   | | |     |         | |   +---com.objectdb.o.CFG.al(String)                                                    |  1,232   37 %  |   70   15 %  |
|    |   | | |     |         | |     |                                                                                  |                |              |
|    |   | | |     |         | |     +---com.objectdb.o.CFG.an(int)                                                     |  1,232   37 %  |   70   15 %  |
|    |   | | |     |         | |       |                                                                                |                |              |
|    |   | | |     |         | |       +---java.net.NetworkInterface.getNetworkInterfaces()                             |    795   24 %  |   44    9 %  |
|    |   | | |     |         | |       |                                                                                |                |              |
|    |   | | |     |         | |       +---java.net.NetworkInterface.getHardwareAddress()                               |    436   13 %  |   26    5 %  |
|    |   | | |     |         | |                                                                                        |                |              |
|    |   | | |     |         | +---com.objectdb.o.CNM.<init>(CFG)                                                       |     31    1 %  |    1    0 %  |
|    |   | | |     |         |                                                                                          |                |              |
|    |   | | |     |         +---com.objectdb.o.CFG.<init>(String, LFL)                                                 |     31    1 %  |    1    0 %  |
|    |   | | |     |                                                                                                    |                |              |
|    |   | | |     +---com.objectdb.jpa.Provider.newEMF(PersistenceUnitInfo, Map)                                       |     62    2 %  |    4    1 %  |
|    |   | | |                                                                                                          |                |              |
|    |   | | +---com.objectdb.jpa.EMF.createEntityManager()                                                             |    187    6 %  |    9    2 %  |
|    |   | | |                                                                                                          |                |              |
|    |   | | +---java.net.NetworkInterface.getNetworkInterfaces()                                                       |     46    1 %  |    2    0 %  |
|    |   | | |                                                                                                          |                |              |
|    |   | | +---java.lang.ClassLoader.loadClass(String)                                                                |     15    0 %  |    1    0 %  |
|    |   | |                                                                                                            |                |              |
|    |   | +---com.anritsu.pa3.application.pa3guiapplication.core.AppCore.initUI()                                      |    312    9 %  |   17    4 %  |
|    |   | |                                                                                                            |                |              |
|    |   | +---com.jidesoft.swing.AbstractLayoutPersistence.loadLayoutDataFromFile(String)                              |    187    6 %  |   16    3 %  |
|    |   | |                                                                                                            |                |              |
|    |   | +---com.anritsu.pa3.application.pa3guiapplication.core.AppCore.createTabs()                                  |    156    5 %  |    9    2 %  |
|    |   | |                                                                                                            |                |              |
|    |   | +---com.anritsu.pa3.application.pa3guiapplication.core.AppResultArchiveView.<init>(AppResultArchiveManager)  |     46    1 %  |    3    1 %  |
|    |   | |                                                                                                            |                |              |
|    |   | +---com.anritsu.pa3.application.pa3guiapplication.core.AppCore.addEventListeners()                           |     31    1 %  |    1    0 %  |
|    |   |                                                                                                              |                |              |
|    |   +---com.anritsu.pa3.application.pa3guiapplication.core.AppCore.initInstance(String, AppSplashScreen)           |    686   21 %  |   35    7 %  |
|    |                                                                                                                  |                |              |
|    +---java.lang.Thread.run()                                                                                         |     93    3 %  |  174   37 %  |
|    |                                                                                                                  |                |              |
|    +---sun.awt.image.ImageFetcher.run()                                                                               |     62    2 %  |  128   27 %  |
+-----------------------------------------------------------------------------------------------------------------------+----------------+--------------+
Symphony Teleca (Harman)
Teleca
Teleca's picture
Joined on 2013-12-09
User Post #22
#24
2016-01-29 15:15

ObjectDB conf file which was used for tests above:

<!-- ObjectDB Configuration -->

<objectdb>

<general>
  <temp path="Logs/cache/" threshold="1024mb" />
  <network inactivity-timeout="0" />
  <url-history size="50" user="true" password="true" />
  <log path="Logs/" max="8mb" stdout="false" stderr="false" />
  <log-archive path="Logs/archive/" retain="90" />
  <logger name="*" level="info" />
</general>

<database>
  <size initial="256kb" resize="256kb" page="2kb" />
  <recovery enabled="false" sync="false" path="." max="128mb" />
  <recording enabled="false" sync="false" path="." mode="write" />
  <locking version-check="false" />
  <processing cache="64mb" max-threads="20" />
  <query-cache results="64mb" programs="500" />
  <extensions drop="temp,tmp" memory="mem" />
</database>

<entities>
  <enhancement agent="false" reflection="warning" />
  <cache ref="weak" level2="64mb" />
  <persist serialization="false" />
  <cascade-persist always="auto" on-persist="false" on-commit="true" />
  <dirty-tracking arrays="false" />
</entities>

<schema>
</schema>

<server>
  <connection port="6136" max="0" />
  <data path="$objectdb/db" />
  <!--
  <replication url="objectdb://localhost/test.odb;user=admin;password=admin" />
  -->
</server>

<users>
  <user username="admin" password="admin">
   <dir path="/" permissions="access,modify,create,delete" />
  </user>
  <user username="$default" password="$$$###">
   <dir path="/$user/" permissions="access,modify,create,delete">
    <quota directories="5" files="20" disk-space="5mb" />
   </dir>
  </user>
  <user username="user1" password="user1" />
</users>

<ssl enabled="false">
  <server-keystore path="$objectdb/ssl/server-kstore" password="pwd" />
  <client-truststore path="$objectdb/ssl/client-tstore" password="pwd" />
</ssl>

</objectdb>
Symphony Teleca (Harman)
Teleca
Teleca's picture
Joined on 2013-12-09
User Post #23
#25
2016-01-29 15:18

To verify that this file is used add an XML syntax error.

If your test application is still running well then this file is not used.

ObjectDB Support
ObjectDB - Fast Object Database for Java (JPA/JDO)
support
support's picture
Joined on 2010-05-03
User Post #2,405
#26
2016-01-29 15:21

ObjectDB conf is located inside of pa3Framework.jar, I have corrupted it like shown below, but I could launch application without any problems 8-(.

1. What I should see if conf file is corrupted?
2. Where conf file should be located for application?


<!-- ObjectDB Configuration -->

wwwwwwwwwwww

<objectdb>

<general>
  <temp path="Logs/cache/" threshold="1024mb" />
  <network inactivity-timeout="0" />
  <url-history size="50" user="true" password="true" />
  <log path="Logs/" max="8mb" stdout="false" stderr="false" />
  <log-archive path="Logs/archive/" retain="90" />
  <logger name="*" level="info" />
</general>

<database>
  <size initial="256kb" resize="256kb" page="2kb" />
  <recovery enabled="false" sync="false" path="." max="128mb" />
  <recording enabled="false" sync="false" path="." mode="write" />
  <locking version-check="false" />
  <processing cache="64mb" max-threads="20" />
  <query-cache results="64mb" programs="500" />
  <extensions drop="temp,tmp" memory="mem" />
</database>

<entities>
  <enhancement agent="false" reflection="warning" />
  <cache ref="weak" level2="64mb" />
  <persist serialization="false" />
  <cascade-persist always="auto" on-persist="false" on-commit="true" />
  <dirty-tracking arrays="false" />
</entities>

<schema>
</schema>

<server>
  <connection port="6136" max="0" />
  <data path="$objectdb/db" />
  <!--
  <replication url="objectdb://localhost/test.odb;user=admin;password=admin" />
  -->
</server>

<users>
  <user username="admin" password="admin">
   <dir path="/" permissions="access,modify,create,delete" />
  </user>
  <user username="$default" password="$$$###">
   <dir path="/$user/" permissions="access,modify,create,delete">
    <quota directories="5" files="20" disk-space="5mb" />
   </dir>
  </user>
  <user username="user1" password="user1" />
</users>

<ssl enabled="false">
  <server-keystore path="$objectdb/ssl/server-kstore" password="pwd" />
  <client-truststore path="$objectdb/ssl/client-tstore" password="pwd" />
</ssl>

</objectdb>
Symphony Teleca (Harman)
Teleca
Teleca's picture
Joined on 2013-12-09
User Post #24
#27
2016-01-29 15:28

It seems you have 2 objectdb.conf files, one in pa3Application and the other in pa3Framework.

Try removing the activation codes from both.

ObjectDB Support
ObjectDB - Fast Object Database for Java (JPA/JDO)
support
support's picture
Joined on 2010-05-03
User Post #2,407
#28
2016-01-29 15:30

Oh, you right! Thanks! After removing all activation codes with enabled network I got successful result below

1/29/2016 19:33:10.3310: INFO : (AppDataStoreManager.java:269 thread:AWT-EventQueue-0): openTempDataStore(): openTempDataStore: getNetworkInterfaces took [62] ms
1/29/2016 19:33:10.3310: INFO : (AppDataStoreManager.java:284 thread:AWT-EventQueue-0): openTempDataStore(): openTempDataStore took [396] ms
1/29/2016 19:33:10.3310: INFO : (AppCore.java:138 thread:AWT-EventQueue-0): start(): PA3 Application loading completed...
1/29/2016 19:33:27.3327: INFO : (AppDataStoreManager.java:300 thread:Thread-7): doOpenDataStore(): openDataStore: D:\tmp\Huge Logs\Perfomance\TC_7_1_7_1_3@2015-11-07_09.20.15_480MB\TC_7_1_7_1_3@2015-11-07_09.20.15_480MB.pa3
1/29/2016 19:33:27.3327: INFO : (AppDataStoreManager.java:315 thread:Thread-7): doOpenDataStore(): openDataStore took [79] ms

If we have OEM licence, do we need activation key in CONF file just for build, right? And could we remove it from CONF in delivery?

Symphony Teleca (Harman)
Teleca
Teleca's picture
Joined on 2013-12-09
User Post #25
#29
2016-02-09 13:57

> If we have OEM licence, do we need activation key in CONF file just for build, right? And could we remove it from CONF in delivery?

Yes, this is correct. Sorry for the late response. We only get notifications for new posts, so we haven't got a notification regarding your update of post #28 above. It is better not to use editing for this purpose.

Following your report we also improved ObjectDB to handle multi activation codes better, and starting build 2.6.6_01 multi activation codes are processed much faster (may still be useful for you on development).

ObjectDB Support
ObjectDB - Fast Object Database for Java (JPA/JDO)
support
support's picture
Joined on 2010-05-03
User Post #2,418

Post Reply

Please read carefully the posting instructions - before posting to the ObjectDB website.

  • You may have to disable pop up blocking in order to use the toolbar (e.g. in Chrome).
  • Use ctrl + right click to open the browser context menu in the editing area (e.g. for using a browser spell checker).
  • To insert formatted lines (e.g. Java code, stack trace) - select a style in the toolbar and then insert the text in the new created block.
  • Avoid overflow of published source code examples by breaking long lines.
  • You may mark in paragraph code words (e.g. class names) with the code style (can be applied by ctrl + D).
  • Long stack traces (> 50 lines) and complex source examples (> 100 lines) should be posted as attachments.
Attachments:
Maximum file size: 32 MB
Cancel