0 Replies Latest reply on Apr 18, 2017 12:21 PM by Harry Reid

    How to resolve Unable to create an instance of class error in wildfly 10?

    Harry Reid Newbie

      Hi,

           I am trying to use some external jar files provided by SAP BO in my project and I am getting a runtime error while calling the classes off of the Jar files. I have created a Module and added the Module in the dependencies of the Manifest file. When I call the class from my Application which was deployed on Wildfly, I see that the class was called from the external jar located in the Modules folder and at some point its failing with Unable to create an instance of the class error. I am adding part of the stack trace below.  Also the interesting part is I am able to read some of the classes of the jar files and some where its failing.

       

      Can any one suggest if this is the right approach to call external jar files?

       

      2017-04-18 15:33:39,155 DS_Worker-4 ERROR [stderr]at org.quartz.core.JobRunShell.run(JobRunShell.java:203)
      2017-04-18 15:33:39,155 DS_Worker-4 ERROR [stderr]at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:520)

      2017-04-18 15:33:39,155 DS_Worker-4 ERROR [stderr] Caused by: com.businessobjects.sdk.core.CoreException: Unable to create an instance of class 'class com.businessobjects.rebean.wi.internal.WIReportEngine'

      2017-04-18 15:33:39,155 DS_Worker-4 ERROR [stderr]at com.businessobjects.sdk.core.internal.guice.GenericFactory.create(GenericFactory.java:97)
      2017-04-18 15:33:39,156 DS_Worker-4 ERROR [stderr]at com.businessobjects.sdk.core.Core.create(Core.java:460)
      2017-04-18 15:33:39,156 DS_Worker-4 ERROR [stderr]at com.businessobjects.rebean.wi.impl.factory.ReBeanCreationHandler.getInstance(ReBeanCreationHandler.java:21)
      2017-04-18 15:33:39,156 DS_Worker-4 ERROR [stderr]at com.businessobjects.rebean.common.util.wrapper.defaults.DefaultInstanceCreator.getInstance(DefaultInstanceCreator.java:29)
      2017-04-18 15:33:39,156 DS_Worker-4 ERROR [stderr]at com.businessobjects.rebean.common.util.wrapper.defaults.DefaultHandlerKey.createElement(DefaultHandlerKey.java:33)
      2017-04-18 15:33:39,156 DS_Worker-4 ERROR [stderr]at com.businessobjects.rebean.common.util.wrapper.defaults.DefaultHandlerKey.createElement(DefaultHandlerKey.java:13)
      2017-04-18 15:33:39,157 DS_Worker-4 ERROR [stderr]at com.businessobjects.rebean.common.util.wrapper.ObjectWrapperKeyManager.getWrapper(ObjectWrapperKeyManager.java:58)
      2017-04-18 15:33:39,157 DS_Worker-4 ERROR [stderr]at com.businessobjects.rebean.common.util.wrapper.defaults.DefaultObjectWrapperKeyManager.getSimpleWrapper(DefaultObjectWrapperKeyManager.java:78)
      2017-04-18 15:33:39,157 DS_Worker-4 ERROR [stderr]at com.businessobjects.rebean.wi.internal.adapt.Rebean3.getEngine(Rebean3.java:221)
      2017-04-18 15:33:39,157 DS_Worker-4 ERROR [stderr]at com.businessobjects.rebean.wi.internal.ReportEngineFactory.makeOCCA(ReportEngineFactory.java:85)
      2017-04-18 15:33:39,157 DS_Worker-4 ERROR [stderr]at com.businessobjects.rebean.wi.ReportEngines.createReportEngine(ReportEngines.java:281)
      2017-04-18 15:33:39,158 DS_Worker-4 ERROR [stderr]... 216 more

      2017-04-18 15:33:39,158 DS_Worker-4 ERROR [stderr] Caused by: com.google.inject.ConfigurationException: Error at com.businessobjects.rebean.wi.internal.WIReportEngine.serverService(WIReportEngine.java:88) Binding to com.businessobjects.sdk.core.server.IServerService not found. No bindings to that type were found.

      2017-04-18 15:33:39,158 DS_Worker-4 ERROR [stderr]at com.google.inject.BinderImpl$RuntimeErrorHandler.handle(BinderImpl.java:426)
      2017-04-18 15:33:39,158 DS_Worker-4 ERROR [stderr]at com.google.inject.AbstractErrorHandler.handle(AbstractErrorHandler.java:30)
      2017-04-18 15:33:39,159 DS_Worker-4 ERROR [stderr]at com.google.inject.ErrorMessages.handleMissingBinding(ErrorMessages.java:46)
      2017-04-18 15:33:39,159 DS_Worker-4 ERROR [stderr]at com.google.inject.InjectorImpl$MissingDependencyException.handle(InjectorImpl.java:791)
      2017-04-18 15:33:39,159 DS_Worker-4 ERROR [stderr]at com.google.inject.InjectorImpl.addInjectorsForMembers(InjectorImpl.java:389)
      2017-04-18 15:33:39,159 DS_Worker-4 ERROR [stderr]at com.google.inject.InjectorImpl.addSingleInjectorsForFields(InjectorImpl.java:367)
      2017-04-18 15:33:39,159 DS_Worker-4 ERROR [stderr]at com.google.inject.InjectorImpl.addInjectors(InjectorImpl.java:350)
      2017-04-18 15:33:39,160 DS_Worker-4 ERROR [stderr]at com.google.inject.InjectorImpl$4.create(InjectorImpl.java:332)
      2017-04-18 15:33:39,160 DS_Worker-4 ERROR [stderr]at com.google.inject.InjectorImpl$4.create(InjectorImpl.java:329)
      2017-04-18 15:33:39,160 DS_Worker-4 ERROR [stderr]at com.google.inject.util.ReferenceCache.create(ReferenceCache.java:53)
      2017-04-18 15:33:39,160 DS_Worker-4 ERROR [stderr]at com.google.inject.util.AbstractReferenceCache.internalCreate(AbstractReferenceCache.java:59)
      2017-04-18 15:33:39,161 DS_Worker-4 ERROR [stderr]at com.google.inject.util.AbstractReferenceCache.get(AbstractReferenceCache.java:116)
      2017-04-18 15:33:39,161 DS_Worker-4 ERROR [stderr]at com.google.inject.ConstructorInjector.<init>(ConstructorInjector.java:39)
      2017-04-18 15:33:39,161 DS_Worker-4 ERROR [stderr]at com.google.inject.InjectorImpl$7.create(InjectorImpl.java:601)
      2017-04-18 15:33:39,161 DS_Worker-4 ERROR [stderr]at com.google.inject.InjectorImpl$7.create(InjectorImpl.java:594)
      2017-04-18 15:33:39,161 DS_Worker-4 ERROR [stderr]at com.google.inject.util.ReferenceCache.create(ReferenceCache.java:53)
      2017-04-18 15:33:39,162 DS_Worker-4 ERROR [stderr]at com.google.inject.util.AbstractReferenceCache.internalCreate(AbstractReferenceCache.java:59)
      2017-04-18 15:33:39,162 DS_Worker-4 ERROR [stderr]at com.google.inject.util.AbstractReferenceCache.get(AbstractReferenceCache.java:116)
      2017-04-18 15:33:39,162 DS_Worker-4 ERROR [stderr]at com.google.inject.InjectorImpl.getConstructor(InjectorImpl.java:765)
      2017-04-18 15:33:39,162 DS_Worker-4 ERROR [stderr]at com.google.inject.InjectorImpl.getImplicitBinding(InjectorImpl.java:973)
      2017-04-18 15:33:39,163 DS_Worker-4 ERROR [stderr]at com.google.inject.InjectorImpl.getInternalFactory(InjectorImpl.java:308)
      2017-04-18 15:33:39,163 DS_Worker-4 ERROR [stderr]at com.google.inject.InjectorImpl.getProvider(InjectorImpl.java:693)
      2017-04-18 15:33:39,163 DS_Worker-4 ERROR [stderr]at com.google.inject.InjectorImpl.getProvider(InjectorImpl.java:689)
      2017-04-18 15:33:39,163 DS_Worker-4 ERROR [stderr]at com.google.inject.InjectorImpl.getInstance(InjectorImpl.java:728)
      2017-04-18 15:33:39,163 DS_Worker-4 ERROR [stderr]at com.businessobjects.sdk.core.internal.guice.GenericFactory.create(GenericFactory.java:95)
      2017-04-18 15:33:39,164 DS_Worker-4 ERROR [stderr]... 226 more