Your browser was unable to load all of the resources. They may have been blocked by your firewall, proxy or browser configuration.
Press Ctrl+F5 or Ctrl+Shift+R to have your browser try again.

Quickbuild Server Won't Start Quickbuild 10.0 #4373

angeloo ·

Hello,

Our server seemed to have just failed to start on us and saw this once doing a server.bat console start:

C:\Quickbuild\bin>server.bat console
wrapper | --> Wrapper Started as Console
wrapper | Java Service Wrapper Standard Edition 64-bit 3.5.43
wrapper | Copyright (C) 1999-2020 Tanuki Software, Ltd. All Rights Reserved.
wrapper | http://wrapper.tanukisoftware.com
wrapper | Licensed to Robin Shen for QuickBuild
wrapper |
wrapper | Launching a JVM...
jvm 1 | WrapperManager: Initializing...
jvm 1 | 2021-10-20 14:19:28,731 INFO Cleaning cached plugin libraries...
jvm 1 | 2021-10-20 14:19:57,012 INFO Cleaning temp directory...
jvm 1 | 2021-10-20 14:19:57,231 INFO Benchmarking...
jvm 1 | 2021-10-20 14:19:59,231 INFO Booting QuickBuild from 'C:\Quickbuild'...
jvm 1 | 2021-10-20 14:19:59,231 INFO Starting framework...
jvm 1 | 2021-10-20 14:20:11,918 INFO Caching plugin libraries...
jvm 1 | 2021-10-20 14:20:43,840 INFO Starting QuickBuild server...
jvm 1 | 2021-10-20 14:20:43,840 INFO Initializing velocity...
jvm 1 | 2021-10-20 14:20:45,340 INFO Checking data version...
jvm 1 | 2021-10-20 14:20:46,262 INFO QuickBuild version table found. Catalog: QUICKBUILD, Schema: PUBLIC, Name: QB_SETTING, Type: TABLE
jvm 1 | 2021-10-20 14:20:46,778 INFO Checking data...
jvm 1 | 2021-10-20 14:20:46,966 WARN Embedded H2 database is used and connection pool size is limited to 1 for stability reason. For production usage, please switch to an external database.
jvm 1 | WrapperStartStopApp:
jvm 1 | WrapperStartStopApp Error: Encountered an error running start main: java.lang.reflect.InvocationTargetException
jvm 1 | WrapperStartStopApp Error: java.lang.reflect.InvocationTargetException
jvm 1 | WrapperStartStopApp Error: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
jvm 1 | WrapperStartStopApp Error: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
jvm 1 | WrapperStartStopApp Error: at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
jvm 1 | WrapperStartStopApp Error: at java.base/java.lang.reflect.Method.invoke(Method.java:567)
jvm 1 | WrapperStartStopApp Error: at com.pmease.quickbuild.bootstrap.Bootstrap.boot(Bootstrap.java:655)
jvm 1 | WrapperStartStopApp Error: at com.pmease.quickbuild.bootstrap.Bootstrap.main(Bootstrap.java:126)
jvm 1 | WrapperStartStopApp Error: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
jvm 1 | WrapperStartStopApp Error: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
jvm 1 | WrapperStartStopApp Error: at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
jvm 1 | WrapperStartStopApp Error: at java.base/java.lang.reflect.Method.invoke(Method.java:567)
jvm 1 | WrapperStartStopApp Error: at org.tanukisoftware.wrapper.WrapperStartStopApp.run(WrapperStartStopApp.java:429)
jvm 1 | WrapperStartStopApp Error: at java.base/java.lang.Thread.run(Thread.java:835)
jvm 1 | WrapperStartStopApp Error: Caused by: java.lang.RuntimeException: java.lang.reflect.InvocationTargetException
jvm 1 | WrapperStartStopApp Error: at com.pmease.quickbuild.bootstrap.BootstrapUtils.wrapAsUnchecked(BootstrapUtils.java:56)
jvm 1 | WrapperStartStopApp Error: at com.pmease.quickbuild.equinoxadapter.EquinoxAdapter.startup(EquinoxAdapter.java:61)
jvm 1 | WrapperStartStopApp Error: ... 12 more
jvm 1 | WrapperStartStopApp Error: Caused by: java.lang.reflect.InvocationTargetException
jvm 1 | WrapperStartStopApp Error: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
jvm 1 | WrapperStartStopApp Error: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
jvm 1 | WrapperStartStopApp Error: at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
jvm 1 | WrapperStartStopApp Error: at java.base/java.lang.reflect.Method.invoke(Method.java:567)
jvm 1 | WrapperStartStopApp Error: at com.pmease.quickbuild.equinoxadapter.EquinoxAdapter.startup(EquinoxAdapter.java:59)
jvm 1 | WrapperStartStopApp Error: ... 12 more
jvm 1 | WrapperStartStopApp Error: Caused by: java.lang.ArrayIndexOutOfBoundsException: Index 0 out of bounds for length 0
jvm 1 | WrapperStartStopApp Error: at org.h2.store.LobStorageBackend$LobInputStream.fillBuffer(LobStorageBackend.java:777)
jvm 1 | WrapperStartStopApp Error: at org.h2.store.LobStorageBackend$LobInputStream.readFully(LobStorageBackend.java:753)
jvm 1 | WrapperStartStopApp Error: at org.h2.store.LobStorageBackend$LobInputStream.read(LobStorageBackend.java:739)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.type.descriptor.java.DataHelper.extractBytes(DataHelper.java:183)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.type.descriptor.java.SerializableTypeDescriptor.wrap(SerializableTypeDescriptor.java:137)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.type.descriptor.java.SerializableTypeDescriptor.wrap(SerializableTypeDescriptor.java:44)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.type.descriptor.sql.BlobTypeDescriptor$1.doExtract(BlobTypeDescriptor.java:65)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.type.descriptor.sql.BasicExtractor.extract(BasicExtractor.java:64)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.type.AbstractStandardBasicType.nullSafeGet(AbstractStandardBasicType.java:267)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.type.AbstractStandardBasicType.nullSafeGet(AbstractStandardBasicType.java:263)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.type.AbstractStandardBasicType.nullSafeGet(AbstractStandardBasicType.java:253)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.type.AbstractStandardBasicType.hydrate(AbstractStandardBasicType.java:338)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.persister.entity.AbstractEntityPersister.hydrate(AbstractEntityPersister.java:2969)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.loader.plan.exec.process.internal.EntityReferenceInitializerImpl.loadFromResultSet(EntityReferenceInitializerImpl.java:324)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.loader.plan.exec.process.internal.EntityReferenceInitializerImpl.hydrateEntityState(EntityReferenceInitializerImpl.java:251)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.loader.plan.exec.process.internal.AbstractRowReader.readRow(AbstractRowReader.java:107)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.loader.plan.exec.internal.EntityLoadQueryDetails$EntityLoaderRowReader.readRow(EntityLoadQueryDetails.java:256)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.loader.plan.exec.process.internal.ResultSetProcessorImpl.extractResults(ResultSetProcessorImpl.java:129)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.loader.plan.exec.internal.AbstractLoadPlanBasedLoader.executeLoad(AbstractLoadPlanBasedLoader.java:138)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.loader.plan.exec.internal.AbstractLoadPlanBasedLoader.executeLoad(AbstractLoadPlanBasedLoader.java:102)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.loader.entity.plan.AbstractLoadPlanBasedEntityLoader.load(AbstractLoadPlanBasedEntityLoader.java:186)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.persister.entity.AbstractEntityPersister.load(AbstractEntityPersister.java:4126)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.event.internal.DefaultLoadEventListener.loadFromDatasource(DefaultLoadEventListener.java:503)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.event.internal.DefaultLoadEventListener.doLoad(DefaultLoadEventListener.java:468)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.event.internal.DefaultLoadEventListener.load(DefaultLoadEventListener.java:213)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.event.internal.DefaultLoadEventListener.proxyOrLoad(DefaultLoadEventListener.java:275)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.event.internal.DefaultLoadEventListener.onLoad(DefaultLoadEventListener.java:151)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.internal.SessionImpl.fireLoad(SessionImpl.java:1106)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.internal.SessionImpl.access$2000(SessionImpl.java:176)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.internal.SessionImpl$IdentifierLoadAccessImpl.load(SessionImpl.java:2587)
jvm 1 | WrapperStartStopApp Error: at org.hibernate.internal.SessionImpl.get(SessionImpl.java:991)
jvm 1 | WrapperStartStopApp Error: at com.pmease.quickbuild.entitymanager.impl.AbstractEntityManager.get(AbstractEntityManager.java:92)
jvm 1 | WrapperStartStopApp Error: at com.pmease.quickbuild.persistence.SessionInterceptor.invoke(SessionInterceptor.java:116)
jvm 1 | WrapperStartStopApp Error: at com.pmease.quickbuild.entitymanager.impl.DefaultDataManager.initialize(DefaultDataManager.java:278)
jvm 1 | WrapperStartStopApp Error: at com.pmease.quickbuild.persistence.SessionInterceptor.invoke(SessionInterceptor.java:54)
jvm 1 | WrapperStartStopApp Error: at com.pmease.quickbuild.Quickbuild.startServer(Quickbuild.java:815)
jvm 1 | WrapperStartStopApp Error: at com.pmease.quickbuild.Quickbuild.start(Quickbuild.java:293)
jvm 1 | WrapperStartStopApp Error: ... 17 more
jvm 1 | 2021-10-20 14:20:50,262 INFO Stopping QuickBuild server...
jvm 1 | 2021-10-20 14:20:50,325 INFO Stopping plugins...
jvm 1 | 2021-10-20 14:20:50,340 INFO Stopping task scheduler...
jvm 1 | 2021-10-20 14:20:50,340 INFO Closing session factory...
jvm 1 | 2021-10-20 14:20:50,731 INFO QuickBuild server stopped.
wrapper | <-- Wrapper Stopped
Press any key to continue . . .

Any idea on what's causing this..? As well as the solution?

TIA.

  • replies 11
  • views 2384
  • stars 0
robinshen ADMIN ·

Looks like the embedded h2 database is corrupted for some reason. The embedded database is for demonstration purpose and should not be used for production environment. You may need to delete the sampledb directory and then restore the database from an old backup.

angeloo ·

Hi Robin,

Thanks for the quick follow-up.

I have a dbbackup, from about a year ago... Used for upgrading from 8.0 to 10.0.

Currently this is the DB back up that exist. Anyways, I tried to restore this using the command: restore "C:\Quickbuild\dbbackup~2020-06-13_09-28-46"

Ran into these issues:

C:\Quickbuild\bin>restore "C:\Quickbuild\dbbackup~2020-06-13_09-28-46"
java version "12.0.2" 2019-07-16
Java(TM) SE Runtime Environment (build 12.0.2+10)
Java HotSpot(TM) 64-Bit Server VM (build 12.0.2+10, mixed mode, sharing)

2021-10-20 16:12:53,481 INFO Cleaning cached plugin libraries...
2021-10-20 16:12:53,528 INFO Cleaning temp directory...
2021-10-20 16:12:55,606 INFO Extracting backup file...
Exception in thread "main" java.lang.RuntimeException: java.io.FileNotFoundException: C:\Quickbuild\dbbackup~2020-06-13_09-28-46 (Access is denied)
at com.pmease.quickbuild.bootstrap.BootstrapUtils.wrapAsUnchecked(BootstrapUtils.java:56)
at com.pmease.quickbuild.bootstrap.BootstrapUtils.unzip(BootstrapUtils.java:288)
at com.pmease.quickbuild.bootstrap.Restore.main(Restore.java:41)
Caused by: java.io.FileNotFoundException: C:\Quickbuild\dbbackup~2020-06-13_09-28-46 (Access is denied)
at java.base/java.io.FileInputStream.open0(Native Method)
at java.base/java.io.FileInputStream.open(FileInputStream.java:213)
at java.base/java.io.FileInputStream. (FileInputStream.java:155)
at com.pmease.quickbuild.bootstrap.BootstrapUtils.unzip(BootstrapUtils.java:254)
... 1 more
Press any key to continue . . .

Let me know if there's a way for me to restore the DB without having to reconfigure my server.

angeloo ·

Hi Robin,

Would like to add, I tried to open the .h2 file to see if I can fi the issue, unfortunately, it seems that the data became corrupted...
Error is as follows:

Unique index or primary key violation: "PRIMARY KEY ON """".PAGE_INDEX"; SQL statement:
ALTER TABLE PUBLIC.QB_AUTHORIZATION ADD CONSTRAINT PUBLIC.FK_AUTH_CONFIG FOREIGN KEY(QB_CONFIGURATION_ID) REFERENCES PUBLIC.QB_CONFIGURATION(QB_ID) NOCHECK [23505-200] 23505/23505 (Help)
org.h2.jdbc.JdbcSQLIntegrityConstraintViolationException: Unique index or primary key violation: "PRIMARY KEY ON """".PAGE_INDEX"; SQL statement:
ALTER TABLE PUBLIC.QB_AUTHORIZATION ADD CONSTRAINT PUBLIC.FK_AUTH_CONFIG FOREIGN KEY(QB_CONFIGURATION_ID) REFERENCES PUBLIC.QB_CONFIGURATION(QB_ID) NOCHECK [23505-200]
at org.h2.message.DbException.getJdbcSQLException(DbException.java:459)
at org.h2.message.DbException.getJdbcSQLException(DbException.java:429)
at org.h2.message.DbException.get(DbException.java:205)
at org.h2.message.DbException.get(DbException.java:181)
at org.h2.pagestore.db.PageDataIndex.add(PageDataIndex.java:125)
at org.h2.pagestore.PageStore.addMeta(PageStore.java:1804)
at org.h2.pagestore.db.PageBtreeIndex. (PageBtreeIndex.java:65)
at org.h2.pagestore.db.PageStoreTable.addIndex(PageStoreTable.java:183)
at org.h2.command.ddl.AlterTableAddConstraint.createIndex(AlterTableAddConstraint.java:298)
at org.h2.command.ddl.AlterTableAddConstraint.tryUpdate(AlterTableAddConstraint.java:223)
at org.h2.command.ddl.AlterTableAddConstraint.update(AlterTableAddConstraint.java:78)
at org.h2.engine.MetaRecord.execute(MetaRecord.java:60)
at org.h2.engine.Database.open(Database.java:759)
at org.h2.engine.Database.openDatabase(Database.java:307)
at org.h2.engine.Database. (Database.java:301)
at org.h2.engine.Engine.openSession(Engine.java:74)
at org.h2.engine.Engine.openSession(Engine.java:192)
at org.h2.engine.Engine.createSessionAndValidate(Engine.java:171)
at org.h2.engine.Engine.createSession(Engine.java:166)
at org.h2.engine.Engine.createSession(Engine.java:29)
at org.h2.engine.SessionRemote.connectEmbeddedOrServer(SessionRemote.java:340)
at org.h2.jdbc.JdbcConnection. (JdbcConnection.java:173)
at org.h2.jdbc.JdbcConnection. (JdbcConnection.java:152)
at org.h2.Driver.connect(Driver.java:69)
at org.h2.util.JdbcUtils.getConnection(JdbcUtils.java:309)
at org.h2.util.JdbcUtils.getConnection(JdbcUtils.java:289)
at org.h2.server.web.WebServer.getConnection(WebServer.java:785)
at org.h2.server.web.WebApp.login(WebApp.java:1008)
at org.h2.server.web.WebApp.process(WebApp.java:223)
at org.h2.server.web.WebApp.processRequest(WebApp.java:173)
at org.h2.server.web.WebThread.process(WebThread.java:139)
at org.h2.server.web.WebThread.run(WebThread.java:94)
at java.lang.Thread.run(Unknown Source)

Let me know about your thoughts.
TIA.

robinshen ADMIN ·

Is the path "C:\Quickbuild\dbbackup~2020-06-13_09-28-46" a directory? If yes, please check what contents is inside the directory. As to h2 database corruption, you may try h2 recovery tool to see if it helps:

angeloo ·

Hi Robin,

We weren't able to recover, so we're trying to restore from our old DB back-up to reconfigure our system.

With that being said, we hooked up the DB connection to a local DB connection on the same machine, and we ran into a bit of issue.

Here is the error:

java version "12.0.2" 2019-07-16
Java(TM) SE Runtime Environment (build 12.0.2+10)
Java HotSpot(TM) 64-Bit Server VM (build 12.0.2+10, mixed mode, sharing)

2021-10-26 10:42:11,822 INFO Cleaning cached plugin libraries...
2021-10-26 10:42:16,502 INFO Cleaning temp directory...
2021-10-26 10:42:19,415 INFO Extracting backup file...
2021-10-26 10:42:19,650 INFO Booting QuickBuild from 'C:\Quickbuild_Upgrade\quickbuild-10.0.17\Quickbuild~2020-06-13_09-28-19'...
2021-10-26 10:42:19,650 INFO Starting framework...
2021-10-26 10:42:30,775 INFO Caching plugin libraries...
2021-10-26 10:42:57,071 INFO Starting QuickBuild server...
2021-10-26 10:42:57,080 INFO Migrating data in directory 'C:\Quickbuild_Upgrade\quickbuild-10.0.17\Quickbuild~2020-06-13_09-28-19\restore'...
2021-10-26 10:42:57,602 INFO Importing data from 'C:\Quickbuild_Upgrade\quickbuild-10.0.17\Quickbuild~2020-06-13_09-28-19\restore'...
2021-10-26 10:42:58,399 INFO Stopping QuickBuild server...
2021-10-26 10:42:58,415 INFO Stopping plugins...
2021-10-26 10:42:58,430 INFO Stopping task scheduler...
2021-10-26 10:42:58,462 INFO QuickBuild server stopped.
Exception in thread "main" java.lang.ExceptionInInitializerError
at com.pmease.quickbuild.Quickbuild.importData(Quickbuild.java:1085)
at com.pmease.quickbuild.bootstrap.Restore$1.execute(Restore.java:51)
at com.pmease.quickbuild.Quickbuild$3.run(Quickbuild.java:798)
at java.base/java.lang.Thread.run(Thread.java:835)
Caused by: com.google.inject.ProvisionException: Guice provision errors:

  1. Error in custom provider, java.lang.RuntimeException: java.lang.ClassNotFoundException: com.microsoft.sqlserver.jdbc.sqlserverdriver
    while locating com.pmease.quickbuild.persistence.SessionFactoryProvider
    at com.pmease.quickbuild.QuickbuildModule.configure(QuickbuildModule.java:36)
    while locating org.hibernate.SessionFactory
    for field at com.pmease.quickbuild.entitymanager.impl.DefaultDataManager.sessionFactory(DefaultDataManager.java:134)
    at com.pmease.quickbuild.entitymanager.impl.DefaultDataManager.class(DefaultDataManager.java:134)
    while locating com.pmease.quickbuild.entitymanager.impl.DefaultDataManager
    while locating com.pmease.quickbuild.entitymanager.DataManager

1 error
at com.google.inject.internal.InjectorImpl$4.get(InjectorImpl.java:987)
at com.google.inject.internal.InjectorImpl.getInstance(InjectorImpl.java:1013)
at com.pmease.quickbuild.Quickbuild.getInstance(Quickbuild.java:986)
at com.pmease.quickbuild.entitymanager.DataManager. (DataManager.java:67)
... 4 more
Caused by: java.lang.RuntimeException: java.lang.ClassNotFoundException: com.microsoft.sqlserver.jdbc.sqlserverdriver
at com.pmease.quickbuild.bootstrap.BootstrapUtils.wrapAsUnchecked(BootstrapUtils.java:56)
at com.pmease.quickbuild.util.ExceptionUtils.wrapAsUnchecked(ExceptionUtils.java:82)
at com.pmease.quickbuild.util.DbUtils.getConnection(DbUtils.java:107)
at com.pmease.quickbuild.util.DbUtils.getDataVersion(DbUtils.java:135)
at com.pmease.quickbuild.persistence.SessionFactoryProvider.get(SessionFactoryProvider.java:80)
at com.pmease.quickbuild.persistence.SessionFactoryProvider.get(SessionFactoryProvider.java:36)
at com.google.inject.internal.BoundProviderFactory.get(BoundProviderFactory.java:55)
at com.google.inject.internal.ProviderToInternalFactoryAdapter$1.call(ProviderToInternalFactoryAdapter.java:46)
at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1031)
at com.google.inject.internal.ProviderToInternalFactoryAdapter.get(ProviderToInternalFactoryAdapter.java:40)
at com.google.inject.Scopes$1$1.get(Scopes.java:65)
at com.google.inject.internal.InternalFactoryToProviderAdapter.get(InternalFactoryToProviderAdapter.java:40)
at com.google.inject.internal.SingleFieldInjector.inject(SingleFieldInjector.java:53)
at com.google.inject.internal.MembersInjectorImpl.injectMembers(MembersInjectorImpl.java:110)
at com.google.inject.internal.ConstructorInjector.construct(ConstructorInjector.java:94)
at com.google.inject.internal.ConstructorBindingImpl$Factory.get(ConstructorBindingImpl.java:254)
at com.google.inject.internal.ProviderToInternalFactoryAdapter$1.call(ProviderToInternalFactoryAdapter.java:46)
at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1031)
at com.google.inject.internal.ProviderToInternalFactoryAdapter.get(ProviderToInternalFactoryAdapter.java:40)
at com.google.inject.Scopes$1$1.get(Scopes.java:65)
at com.google.inject.internal.InternalFactoryToProviderAdapter.get(InternalFactoryToProviderAdapter.java:40)
at com.google.inject.internal.InjectorImpl$3.get(InjectorImpl.java:737)
at com.google.inject.internal.InjectorImpl$4$1.call(InjectorImpl.java:978)
at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1024)
at com.google.inject.internal.InjectorImpl$4.get(InjectorImpl.java:974)
... 7 more
Caused by: java.lang.ClassNotFoundException: com.microsoft.sqlserver.jdbc.sqlserverdriver
at java.base/java.net.URLClassLoader.findClass(URLClassLoader.java:436)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:588)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521)
at java.base/java.lang.Class.forName0(Native Method)
at java.base/java.lang.Class.forName(Class.java:332)
at com.pmease.quickbuild.util.DbUtils.getConnection(DbUtils.java:100)
... 29 more

We declared an environment variable called CLASSPATH to the path of the required to the installed path: C:\Program Files (x86)\SQLJDBC_9.4\enu\mssql-jdbc-9.4.0.jre11.jar

I've also stored the JAR file's under the plugins/com.pmease.quickbuild.libs. Obviously instead of just the JAR file, we have the SQLJDBC_9,4\enu.... files under the path.

Let me know if I misunderstood the connectivity requirements.

robinshen ADMIN ·

Please place file "mssql-jdbc-9.4.0.jre11.jar" into directory /plugins/site
Also it is odd that your sql server driver class is "com.microsoft.sqlserver.jdbc.sqlserverdriver". It should be "com.microsoft.sqlserver.jdbc.SQLServerDriver" instead. Please check "conf/hibernate.properties" to make sure

angeloo ·

Hi Robin,

Stored it .JAR file under /plugins/site and modified conf/hibernate.properties to the proper setting.
Still running into an error:

java version "12.0.2" 2019-07-16
Java(TM) SE Runtime Environment (build 12.0.2+10)
Java HotSpot(TM) 64-Bit Server VM (build 12.0.2+10, mixed mode, sharing)

2021-10-26 16:06:58,065 INFO Cleaning cached plugin libraries...
2021-10-26 16:06:59,018 INFO Cleaning temp directory...
2021-10-26 16:07:01,190 INFO Extracting backup file...
2021-10-26 16:07:01,377 INFO Booting QuickBuild from 'C:\Quickbuild_Upgrade\quickbuild-10.0.17\Quickbuild~2020-06-13_09-28-19'...
2021-10-26 16:07:01,377 INFO Starting framework...
2021-10-26 16:07:01,643 INFO Caching plugin libraries...
Exception in thread "main" java.lang.reflect.InvocationTargetException
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:567)
at com.pmease.quickbuild.bootstrap.Bootstrap.boot(Bootstrap.java:647)
at com.pmease.quickbuild.bootstrap.Restore.main(Restore.java:42)
Caused by: java.lang.RuntimeException: java.lang.reflect.InvocationTargetException
at com.pmease.quickbuild.bootstrap.BootstrapUtils.wrapAsUnchecked(BootstrapUtils.java:56)
at com.pmease.quickbuild.equinoxadapter.EquinoxAdapter.startup(EquinoxAdapter.java:61)
... 6 more
Caused by: java.lang.reflect.InvocationTargetException
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:567)
at com.pmease.quickbuild.equinoxadapter.EquinoxAdapter.startup(EquinoxAdapter.java:59)
... 6 more
Caused by: java.lang.IncompatibleClassChangeError: class com.microsoft.sqlserver.jdbc.osgi.Activator can not implement org.osgi.framework.BundleActivator, because it is not an interface (org.osgi.framework.BundleActivator is in unnamed module of loader java.net.URLClassLoader @4b2c5e02)
at java.base/java.lang.ClassLoader.defineClass1(Native Method)
at java.base/java.lang.ClassLoader.defineClass(ClassLoader.java:1016)
at java.base/java.security.SecureClassLoader.defineClass(SecureClassLoader.java:151)
at java.base/java.net.URLClassLoader.defineClass(URLClassLoader.java:515)
at java.base/java.net.URLClassLoader$1.run(URLClassLoader.java:423)
at java.base/java.net.URLClassLoader$1.run(URLClassLoader.java:417)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:689)
at java.base/java.net.URLClassLoader.findClass(URLClassLoader.java:416)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:588)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521)
at com.pmease.quickbuild.Quickbuild.loadPluginModules(Quickbuild.java:595)
at com.pmease.quickbuild.Quickbuild.start(Quickbuild.java:318)
... 11 more

Removing the .JAR File produces the cannot find class of com.microsoft.sqlserver.jdbc.SqlServerDriver.
Do we need to unpack the .JAR files ourselves under the plugin library? Seems like there are issues with just providing the .JAR file inside plugins/site.
In addition to this: do the .JAR files require to be matching JDK? i.e. JDK 12 equates to JDBC Driver 7.4?

angeloo ·

Hi Robin,

Weird, after waiting a day, and storing and unpacking the .JAR file under the plugins/com.pmease.quickbuild.libs path and also including the .JAR file here, it now finds the SQLServerDriver.

We are running into this error though:
C:\Quickbuild\bin>server.bat console
wrapper | --> Wrapper Started as Console
wrapper | Java Service Wrapper Standard Edition 64-bit 3.5.43
wrapper | Copyright (C) 1999-2020 Tanuki Software, Ltd. All Rights Reserved.
wrapper | http://wrapper.tanukisoftware.com
wrapper | Licensed to Robin Shen for QuickBuild
wrapper |
wrapper | Launching a JVM...
jvm 1 | WrapperManager: Initializing...
jvm 1 | 2021-10-27 12:21:41,915 INFO Cleaning cached plugin libraries...
jvm 1 | 2021-10-27 12:21:42,852 INFO Cleaning temp directory...
jvm 1 | 2021-10-27 12:21:42,852 INFO Benchmarking...
jvm 1 | 2021-10-27 12:21:44,024 INFO Booting QuickBuild from 'C:\Quickbuild'...
jvm 1 | 2021-10-27 12:21:44,024 INFO Starting framework...
jvm 1 | 2021-10-27 12:21:44,274 INFO Caching plugin libraries...
jvm 1 | 2021-10-27 12:21:50,149 INFO Starting QuickBuild server...
jvm 1 | 2021-10-27 12:21:50,149 INFO Initializing velocity...
jvm 1 | 2021-10-27 12:21:50,664 INFO Checking data version...
jvm 1 | 2021-10-27 12:21:51,086 INFO QuickBuild version table found. Catalog: Quickbuild, Schema: dbo, Name: QB_SETTING, Type: TABLE
jvm 1 | WrapperStartStopApp:
jvm 1 | WrapperStartStopApp Error: Encountered an error running start main: java.lang.reflect.InvocationTargetException
jvm 1 | WrapperStartStopApp Error: java.lang.reflect.InvocationTargetException
jvm 1 | WrapperStartStopApp Error: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
jvm 1 | WrapperStartStopApp Error: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
jvm 1 | WrapperStartStopApp Error: at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
jvm 1 | WrapperStartStopApp Error: at java.base/java.lang.reflect.Method.invoke(Method.java:567)
jvm 1 | WrapperStartStopApp Error: at com.pmease.quickbuild.bootstrap.Bootstrap.boot(Bootstrap.java:655)
jvm 1 | WrapperStartStopApp Error: at com.pmease.quickbuild.bootstrap.Bootstrap.main(Bootstrap.java:126)
jvm 1 | WrapperStartStopApp Error: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
jvm 1 | WrapperStartStopApp Error: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
jvm 1 | WrapperStartStopApp Error: at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
jvm 1 | WrapperStartStopApp Error: at java.base/java.lang.reflect.Method.invoke(Method.java:567)
jvm 1 | WrapperStartStopApp Error: at org.tanukisoftware.wrapper.WrapperStartStopApp.run(WrapperStartStopApp.java:429)
jvm 1 | WrapperStartStopApp Error: at java.base/java.lang.Thread.run(Thread.java:835)
jvm 1 | WrapperStartStopApp Error: Caused by: java.lang.RuntimeException: java.lang.reflect.InvocationTargetException
jvm 1 | WrapperStartStopApp Error: at com.pmease.quickbuild.bootstrap.BootstrapUtils.wrapAsUnchecked(BootstrapUtils.java:56)
jvm 1 | WrapperStartStopApp Error: at com.pmease.quickbuild.equinoxadapter.EquinoxAdapter.startup(EquinoxAdapter.java:61)
jvm 1 | WrapperStartStopApp Error: ... 12 more
jvm 1 | WrapperStartStopApp Error: Caused by: java.lang.reflect.InvocationTargetException
jvm 1 | WrapperStartStopApp Error: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
jvm 1 | WrapperStartStopApp Error: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
jvm 1 | WrapperStartStopApp Error: at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
jvm 1 | WrapperStartStopApp Error: at java.base/java.lang.reflect.Method.invoke(Method.java:567)
jvm 1 | WrapperStartStopApp Error: at com.pmease.quickbuild.equinoxadapter.EquinoxAdapter.startup(EquinoxAdapter.java:59)
jvm 1 | WrapperStartStopApp Error: ... 12 more
jvm 1 | WrapperStartStopApp Error: Caused by: com.pmease.quickbuild.QuickbuildException: No data version found in database.
jvm 1 | WrapperStartStopApp Error: at com.pmease.quickbuild.util.DbUtils.getDataVersion(DbUtils.java:158)
jvm 1 | WrapperStartStopApp Error: at com.pmease.quickbuild.Quickbuild.startServer(Quickbuild.java:803)
jvm 1 | WrapperStartStopApp Error: at com.pmease.quickbuild.Quickbuild.start(Quickbuild.java:293)
jvm 1 | WrapperStartStopApp Error: ... 17 more
jvm 1 | 2021-10-27 12:21:52,086 INFO Stopping QuickBuild server...
jvm 1 | 2021-10-27 12:21:52,102 INFO Stopping plugins...
jvm 1 | 2021-10-27 12:21:52,102 INFO Stopping task scheduler...
jvm 1 | 2021-10-27 12:21:53,133 INFO QuickBuild server stopped.
wrapper | <-- Wrapper Stopped
Press any key to continue . . .

Please do note, that when I use H2 Database (default), it allows the restore to work, but when trying to restore with the external DB, it throws this error...
Another thing as well, it seems like the QB_ID table has same inputs of name for one of the connectivity, and this is failing to insert it into the table properly. Due to this, I actually edited the value of 'Name' inside the .xml then zipped it back up to restore. Let me know if this isn't how I should handle this.

Let me know what I can do to fix.

robinshen ADMIN ·

There is an issue working with this version of jdbc driver. This has been fixed in 10.0.36:

Please go with below procedure:

  1. Download and unpack 10.0.36
  2. Copy file "mssql-jdbc-9.4.0.jre11.jar" into directory "<QB 10.0.36 dir>/plugins/site"
  3. Edit "<QB 10.0.36 dir>/conf/hibernate.properties" to point to your SQLServer database
  4. Clean your existing SQLServer database by deleting it and creating a new one with same name
  5. Start QB to make sure it can starts with SQLServer
  6. Stop QB, and run restore command to restore from your existing backup
angeloo ·

Hi Robin, still the same failure if I put the .jar file inside: plugins/site of:

Caused by: java.lang.IncompatibleClassChangeError: class com.microsoft.sqlserver.jdbc.osgi.Activator can not implement org.osgi.framework.BundleActivator, because it is not an interface (org.osgi.framework.BundleActivator is in unnamed module of loader java.net.URLClassLoader @4b2c5e02)

If I move it inside plugin\com.pmease.quickbuild.libs and unpack it using jar xf mssql-jdbc-9.4.0.jre11.jar, and then try to launch my QB, no issues occur.

For now, I will keep it inside plugin\com.pmease.quickbuild.libs. Also, since it seems like QB has a duplicate key inside QB_ID (same value of 'name' inside ID's.xml) it will not load the restore in properly. The only fix I have is to manually edit the .xml to remove the duplicate key and put in a dummy one.

After that, it now interacts with the server. Any clue as to why it's like this and not working like how your suggestion is? Btw, I updated my QB to 11.0 (latest one).

robinshen ADMIN ·

Sorry I am wrong, the jdbc driver file should be placed into "plugins/com.pmease.quickbuild.libs". No need to unpack it, just place the jar file will be fine. As to name collision, this is because database field is case sensitive in embedded h2 database, while sql server is case insensitive by default.