15 Jan 2010, 07:51
Generic-user-small

Bernie Wang (2 posts)

Hi all,

 I went through dwmj example completely following the steps as described in "Modular Java" book and running it when hitting pax-provision command but got below errors. However,i tried out domain component with compass help under non-OSGi env and worked well. 
 Any one met the same problem, pls help me.Thanks in advance.
 BTW, i used Compass 2.2.0.

 ...
 ectionMethod
    at java.lang.ClassLoader.defineClass1(Native Method)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:466)
    ... 29 more Caused by: java.lang.ClassNotFoundException: org.compass.core.util.reflection.Re flectionMethod
    at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(Bundl eLoader.java:494)
    at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader. java:410)
    at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader. java:398)
    at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(De faultClassLoader.java:105)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
    at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
    ... 32 more [Start Level Event Dispatcher] DEBUG org.compass.core.util.reflection.Reflection Factory - Failed to generate ASM (should have worked...) for method [public java .lang.String dwmj.domain.JarFile.getVersion()] java.lang.NoSuchMethodException: Can't create ASM method reflection helper for [ public java.lang.String dwmj.domain.JarFile.getVersion()]
    at org.compass.core.util.reflection.asm.AsmReflectionMethodGenerator.gen erateMethod(AsmReflectionMethodGenerator.java:89)
    at org.compass.core.util.reflection.asm.AsmReflectionMethodGenerator.gen erateMethod(AsmReflectionMethodGenerator.java:45)
    at org.compass.core.util.reflection.ReflectionFactory.getMethod(Reflecti onFactory.java:50)
    at org.compass.core.accessor.BasicPropertyAccessor.getGetterOrNull(Basic PropertyAccessor.java:235)
    at org.compass.core.accessor.BasicPropertyAccessor.setterMethod(BasicPro pertyAccessor.java:189)
    at org.compass.core.accessor.BasicPropertyAccessor.getSetterOrNull(Basic PropertyAccessor.java:163)
    at org.compass.core.accessor.BasicPropertyAccessor.getSetter(BasicProper tyAccessor.java:155)
    at org.compass.core.config.process.PropertyAccessorMappingProcessor.proc essMapping(PropertyAccessorMappingProcessor.java:94)
    at org.compass.core.config.process.PropertyAccessorMappingProcessor.proc essMapping(PropertyAccessorMappingProcessor.java:99)
    at org.compass.core.config.process.PropertyAccessorMappingProcessor.proc ess(PropertyAccessorMappingProcessor.java:79)
    at org.compass.core.config.CompassMappingProcessor.process(CompassMappin gProcessor.java:62)
    at org.compass.core.config.CompassConfiguration.buildCompass(CompassConf iguration.java:281)
    at dwmj.domain.internal.ExampleActivator.start(ExampleActivator.java:33)

    at org.eclipse.osgi.framework.internal.core.BundleContextImpl$1.run(Bund leContextImpl.java:783)
    at java.security.AccessController.doPrivileged(Native Method)
    at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActiv ator(BundleContextImpl.java:774)
    at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(Bund leContextImpl.java:755)
    at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(Bundl eHost.java:352)
    at org.eclipse.osgi.framework.internal.core.AbstractBundle.resume(Abstra ctBundle.java:370)
    at org.eclipse.osgi.framework.internal.core.Framework.resumeBundle(Frame work.java:1068)
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBund les(StartLevelManager.java:557)
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(St artLevelManager.java:464)
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStart Level(StartLevelManager.java:248)
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEv ent(StartLevelManager.java:445)
    at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventM anager.java:227)
    at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(Even tManager.java:337) Caused by: java.lang.reflect.InvocationTargetException
    at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at org.compass.core.util.reflection.asm.AsmReflectionMethodGenerator.def ineClass(AsmReflectionMethodGenerator.java:249)
    at org.compass.core.util.reflection.asm.AsmReflectionMethodGenerator.gen erateMethod(AsmReflectionMethodGenerator.java:84)
    ... 25 more Caused by: java.lang.NoClassDefFoundError: org/compass/core/util/reflection/Refl ectionMethod
    at java.lang.ClassLoader.defineClass1(Native Method)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:466)
    ... 30 more Caused by: java.lang.ClassNotFoundException: org.compass.core.util.reflection.Re flectionMethod
    at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(Bundl eLoader.java:494)
    at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader. java:410)
    at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader. java:398)
    at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(De faultClassLoader.java:105)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
    at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
    ... 33 more [Start Level Event Dispatcher] DEBUG org.compass.core.util.reflection.Reflection Factory - Failed to generate ASM (should have worked...) for method [public void  dwmj.domain.JarFile.setVersion(java.lang.String)] java.lang.NoSuchMethodException: Can't create ASM method reflection helper for [ public void dwmj.domain.JarFile.setVersion(java.lang.String)]
    at org.compass.core.util.reflection.asm.AsmReflectionMethodGenerator.gen erateMethod(AsmReflectionMethodGenerator.java:89)
    at org.compass.core.util.reflection.asm.AsmReflectionMethodGenerator.gen erateMethod(AsmReflectionMethodGenerator.java:45)
    at org.compass.core.util.reflection.ReflectionFactory.getMethod(Reflecti onFactory.java:50)
    at org.compass.core.accessor.BasicPropertyAccessor.getSetterOrNull(Basic PropertyAccessor.java:170)
    at org.compass.core.accessor.BasicPropertyAccessor.getSetter(BasicProper tyAccessor.java:155)
    at org.compass.core.config.process.PropertyAccessorMappingProcessor.proc essMapping(PropertyAccessorMappingProcessor.java:94)
    at org.compass.core.config.process.PropertyAccessorMappingProcessor.proc essMapping(PropertyAccessorMappingProcessor.java:99)
    at org.compass.core.config.process.PropertyAccessorMappingProcessor.proc ess(PropertyAccessorMappingProcessor.java:79)
    at org.compass.core.config.CompassMappingProcessor.process(CompassMappin gProcessor.java:62)
    at org.compass.core.config.CompassConfiguration.buildCompass(CompassConf iguration.java:281)
    at dwmj.domain.internal.ExampleActivator.start(ExampleActivator.java:33)

    at org.eclipse.osgi.framework.internal.core.BundleContextImpl$1.run(Bund leContextImpl.java:783)
    at java.security.AccessController.doPrivileged(Native Method)
    at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActiv ator(BundleContextImpl.java:774)
    at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(Bund leContextImpl.java:755)
    at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(Bundl eHost.java:352)
    at org.eclipse.osgi.framework.internal.core.AbstractBundle.resume(Abstra ctBundle.java:370)
    at org.eclipse.osgi.framework.internal.core.Framework.resumeBundle(Frame work.java:1068)
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBund les(StartLevelManager.java:557)
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(St artLevelManager.java:464)
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStart Level(StartLevelManager.java:248)
    at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEv ent(StartLevelManager.java:445)
    at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventM anager.java:227)
    at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(Even tManager.java:337) Caused by: java.lang.reflect.InvocationTargetException
    at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at org.compass.core.util.reflection.asm.AsmReflectionMethodGenerator.def ineClass(AsmReflectionMethodGenerator.java:249)
    at org.compass.core.util.reflection.asm.AsmReflectionMethodGenerator.gen erateMethod(AsmReflectionMethodGenerator.java:84)
    ... 23 more Caused by: java.lang.NoClassDefFoundError: org/compass/core/util/reflection/Refl ectionMethod
    at java.lang.ClassLoader.defineClass1(Native Method)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:466)
    ... 28 more Caused by: java.lang.ClassNotFoundException: org.compass.core.util.reflection.Re flectionMethod
    at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(Bundl eLoader.java:494)
    at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader. java:410)
    at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader. java:398)
    at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(De faultClassLoader.java:105)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
    at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
    ... 31 more [Start Level Event Dispatcher] DEBUG org.compass.core.executor.concurrent.Concur rentExecutorManager - Using concurrent executor manager with core size [10], max  size [50], and keep alive time [60000ms] [Start Level Event Dispatcher] DEBUG org.compass.core.executor.concurrent.Concur rentExecutorManager - Using concurrent executor manager scheduler with size [1] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.LuceneSettin gs - Using connection [f:/dudeindex][null] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.LuceneSettin gs - Using alias property [alias] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.LuceneSettin gs - Using extended alias property [extendedAlias] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.LuceneSettin gs - Using default all property [zzz-all] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.LuceneSettin gs - Using all property term vector [no] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.LuceneSettin gs - All property boost support is [true] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.LuceneSettin gs - Using default search property [zzz-all] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.LuceneSettin gs - Using transaction lock timeout [10000ms] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.LuceneSettin gs - Using lock poll interval [100ms] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.LuceneSettin gs - Using cache invalidation interval [5000ms] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.LuceneSettin gs - Wait for cahce invalidation on index operatrion is set to [false] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.LuceneSettin gs - Setting *static* Lucene BooleanQuery maxClauseCount to [1024] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.analyzer.Def aultLuceneAnalyzerFactory - Analyzer [default] uses Lucene analyzer [standard] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.store.Defaul tLuceneSearchEngineStore - Using compound format [true] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.store.Defaul tLuceneSearchEngineStore - Support concurrent operations [true] and concurrent c ommits [true] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.highlighter. DefaultLuceneHighlighterFactory - Highlighter [default] uses formatter [simple] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.highlighter. DefaultLuceneHighlighterFactory - Highlighter [default] uses pre [<b>] and post [</b>] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.highlighter. DefaultLuceneHighlighterFactory - Highlighter [default] uses encoder [default] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.optimizer.Lu ceneSearchEngineOptimizerManager - Using optimizer [org.compass.core.lucene.engi ne.optimizer.DefaultLuceneSearchEngineOptimizer@117f31e] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.queryparser. LuceneQueryParserManager - No default query parser found (under groupd [default] ), registering a default one [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.queryparser. DefaultLuceneQueryParser - Query Parser configured with allowLeadingWildcard [tr ue] and allowConstantScorePrefixQuery [true] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.transaction. async.AsyncTransactionProcessorFactory - Async Transaction Processor will wait f or [10000ms] if backlog is full [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.transaction. async.AsyncTransactionProcessorFactory - Async Transaction Processor blocking ba tch size is [5] with timeout of [100ms] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.transaction. async.AsyncTransactionProcessorFactory - Async Transaction Processor non blockin g batch size is [5] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.transaction. async.AsyncTransactionProcessorFactory - Async Transaction Processor process bef ore close is set to [true] [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.transaction. async.AsyncTransactionProcessorFactory - Async Transaction Processor will use [5 ] concrrent threads to process transactions [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.transaction. async.AsyncTransactionProcessorFactory - Async Transaction Processor uses [UID] based hashing for concurrent processing [Start Level Event Dispatcher] DEBUG org.compass.core.lucene.engine.transaction. async.AsyncTransactionProcessorFactory - Starting Async polling transaction proc essor [Start Level Event Dispatcher] DEBUG org.compass.core.transaction.TransactionFac toryFactory - Using transaction factory [org.compass.core.transaction.LocalTrans actionFactory@14520eb] [Start Level Event Dispatcher] DEBUG org.compass.core.cache.first.FirstLevelCach eFactory - Using first level cache [org.compass.core.cache.first.NullFirstLevelC ache] [Start Level Event Dispatcher] INFO org.compass.core.lucene.engine.optimizer.Luc eneSearchEngineOptimizerManager - Starting scheduled optimizer [class org.compas s.core.lucene.engine.optimizer.DefaultLuceneSearchEngineOptimizer] with period [ 10000ms] [Start Level Event Dispatcher] INFO org.compass.core.lucene.engine.manager.Defau ltLuceneSearchEngineIndexManager - Starting scheduled index manager with period [60000ms] [Start Level Event Dispatcher] INFO org.compass.core.lucene.engine.manager.Index HoldersCache - Starting scheduled refresh cache with period [5000ms] [Start Level Event Dispatcher] DEBUG org.compass.core.impl.DefaultCompass - Regi stering shutdown hook [10040532] REGISTER dwmj.domain.ExampleService [Start Level Event Dispatcher] DEBUG com.dudewheresmyjar.domain - ServiceEvent R EGISTERED [Framework Event Dispatcher] DEBUG com.dudewheresmyjar.domain - BundleEvent STAR TED [Framework Event Dispatcher] DEBUG com.dudewheresmyjar.index - BundleEvent START ED [Framework Event Dispatcher] DEBUG org.eclipse.osgi - BundleEvent STARTED [Framework Event Dispatcher] DEBUG org.eclipse.osgi - FrameworkEvent STARTED [Framework Event Dispatcher] DEBUG org.eclipse.osgi - FrameworkEvent STARTLEVEL CHANGED ss

Framework is launched.

id State Bundle 0 ACTIVE org.eclipse.osgi_3.5.1.R35x_v20090827 1 ACTIVE org.ops4j.pax.logging.pax-logging-api_1.3.0 2 ACTIVE org.ops4j.pax.logging.pax-logging-service_1.3.0 3 ACTIVE org.eclipse.osgi.services_3.2.0.v20090520-1800 4 ACTIVE org.eclipse.osgi.util_3.2.0.v20090520-1800 5 ACTIVE org.compass-project.compass_2.2.0 6 ACTIVE com.dudewheresmyjar.domain_1.0.0.SNAPSHOT 7 ACTIVE com.dudewheresmyjar.index_1.0.0.SNAPSHOT

osgi>

16 Jan 2010, 12:02
Generic-user-small

Ayman Elwany (1 post)

Hi all , I’m also having the same problem both in Felix and Equinox (but in felix it didn’t start the index bundle at all )

and I had also downloaded the source code and pax-provision it and it gave me the same problem ,any help ????

18 Jan 2010, 06:32
Generic-user-small

Bernie Wang (2 posts)

Hey,

Just do as follows:

      CompassConfiguration config = new CompassConfiguration()
            .setSetting(CompassEnvironment.CONNECTION, "f:/dudeindex")
            .setSetting("compass.reflection.type", "plain")
            .addClass(JarFile.class);

those errors will disappear immediately, but still not find actual reason.
18 Apr 2014, 20:04
Me_pragsmall

David Kowis (6 posts)

Thanks for this, it didn’t seem to be listed in the errata :(

  You must be logged in to comment