I found my own answer
I was initially thrown by the fact that DSpaceBeanPostProcessor is not
defined anywhere in the source, neither DSpaceConfigurationService nor
BTEBatchImportService - so I was at a loss what to clue in on.
Once I could boil it down to a config problem by running the same code
with one install dir and see it fail, but see it succeed with another
installation directory, I read beyond the class not found complaint. The
error talks about /dspace/config/spring/api/bte.xml which existed in one
install directory and not the other. Removing this and other files under
config/spring did the trick
Now - here my questions:
1) given that we have no local spring related changes in our DSPACE
source and we are doing JSPUI, I assume that I can safely remove all
files under config/spring except for the ones that come with the default
1.8 release. Correct ?
2) how should I approach house cleaning on our production config dir,
which was not maintained under version control for a quite some time and
probably has all sorts of gunk in it - does the following look like a
safe approach - will I miss files that I do want by simply listing what
is in config under the source tree ?
git co remotes/upstream/dspace-1_8_x
cd dspace/config/
find . -type f > FILES_I_WANT
cd install_dir/config
find . -type f > FILES_I_HAVE
and the go over the diff of the two
Monika
On 7/10/14, 4:57 PM, Monika Mevenkamp wrote:
after merging some changes into my production branch
after a successful mvn package and ant update
I get the following mysterious error
when I do dspace/bin/dsapace test-database I get the error
Failed to startup the DSpace Service Manager: failure starting up
spring service manager: Error creating bean with name
'org.dspace.servicemanager.spring.DSpaceBeanPostProcessor#0' defined
in class path resource [spring/spring-dspace-applicationContext.xml]:
Unsatisfied dependency expressed through constructor argument with
index 0 of type
[org.dspace.servicemanager.config.DSpaceConfigurationService]: :
Cannot find class [org.dspace.app.itemimport.BTEBatchImportService]
for bean with name 'org.dspace.app.itemimport.BTEBatchImportService'
defined in file [/dspace/config/spring/api/bte.xml]; nested exception
is java.lang.ClassNotFoundException:
org.dspace.app.itemimport.BTEBatchImportService; nested exception is
org.springframework.beans.factory.CannotLoadBeanClassException: Cannot
find class [org.dspace.app.itemimport.BTEBatchImportService] for bean
with name 'org.dspace.app.itemimport.BTEBatchImportService' defined in
file [/dspace/config/spring/api/bte.xml]; nested exception is
java.lang.ClassNotFoundException:
org.dspace.app.itemimport.BTEBatchImportService
FYI:
find /dspace/ -name applicationContext.xml
/dspace//webapps/jspui/WEB-INF/spring/applicationContext.xml
/dspace//webapps/xmlui/WEB-INF/spring/applicationContext.xml
obviously something did go wrong
how should I go looking ?
Monika
here is the complete nastiness
Failed to startup the DSpace Service Manager: failure starting up
spring service manager: Error creating bean with name
'org.dspace.servicemanager.spring.DSpaceBeanPostProcessor#0' defined
in class path resource [spring/spring-dspace-applicationContext.xml]:
Unsatisfied dependency expressed through constructor argument with
index 0 of type
[org.dspace.servicemanager.config.DSpaceConfigurationService]: :
Cannot find class [org.dspace.app.itemimport.BTEBatchImportService]
for bean with name 'org.dspace.app.itemimport.BTEBatchImportService'
defined in file [/dspace/config/spring/api/bte.xml]; nested exception
is java.lang.ClassNotFoundException:
org.dspace.app.itemimport.BTEBatchImportService; nested exception is
org.springframework.beans.factory.CannotLoadBeanClassException: Cannot
find class [org.dspace.app.itemimport.BTEBatchImportService] for bean
with name 'org.dspace.app.itemimport.BTEBatchImportService' defined in
file [/dspace/config/spring/api/bte.xml]; nested exception is
java.lang.ClassNotFoundException:
org.dspace.app.itemimport.BTEBatchImportService
Failure during filter init: Failed to startup the DSpace Service
Manager: failure starting up spring service manager: Error creating
bean with name
'org.dspace.servicemanager.spring.DSpaceBeanPostProcessor#0' defined
in class path resource [spring/spring-dspace-applicationContext.xml]:
Unsatisfied dependency expressed through constructor argument with
index 0 of type
[org.dspace.servicemanager.config.DSpaceConfigurationService]: :
Cannot find class [org.dspace.app.itemimport.BTEBatchImportService]
for bean with name 'org.dspace.app.itemimport.BTEBatchImportService'
defined in file [/dspace/config/spring/api/bte.xml]; nested exception
is java.lang.ClassNotFoundException:
org.dspace.app.itemimport.BTEBatchImportService; nested exception is
org.springframework.beans.factory.CannotLoadBeanClassException: Cannot
find class [org.dspace.app.itemimport.BTEBatchImportService] for bean
with name 'org.dspace.app.itemimport.BTEBatchImportService' defined in
file [/dspace/config/spring/api/bte.xml]; nested exception is
java.lang.ClassNotFoundException:
org.dspace.app.itemimport.BTEBatchImportService:java.lang.RuntimeException:
Failed to startup the DSpace Service Manager: failure starting up
spring service manager: Error creating bean with name
'org.dspace.servicemanager.spring.DSpaceBeanPostProcessor#0' defined
in class path resource [spring/spring-dspace-applicationContext.xml]:
Unsatisfied dependency expressed through constructor argument with
index 0 of type
[org.dspace.servicemanager.config.DSpaceConfigurationService]: :
Cannot find class [org.dspace.app.itemimport.BTEBatchImportService]
for bean with name 'org.dspace.app.itemimport.BTEBatchImportService'
defined in file [/dspace/config/spring/api/bte.xml]; nested exception
is java.lang.ClassNotFoundException:
org.dspace.app.itemimport.BTEBatchImportService; nested exception is
org.springframework.beans.factory.CannotLoadBeanClassException: Cannot
find class [org.dspace.app.itemimport.BTEBatchImportService] for bean
with name 'org.dspace.app.itemimport.BTEBatchImportService' defined in
file [/dspace/config/spring/api/bte.xml]; nested exception is
java.lang.ClassNotFoundException:
org.dspace.app.itemimport.BTEBatchImportService
Exception in thread "main" java.lang.IllegalStateException: Failure
during filter init: Failed to startup the DSpace Service Manager:
failure starting up spring service manager: Error creating bean with
name 'org.dspace.servicemanager.spring.DSpaceBeanPostProcessor#0'
defined in class path resource
[spring/spring-dspace-applicationContext.xml]: Unsatisfied dependency
expressed through constructor argument with index 0 of type
[org.dspace.servicemanager.config.DSpaceConfigurationService]: :
Cannot find class [org.dspace.app.itemimport.BTEBatchImportService]
for bean with name 'org.dspace.app.itemimport.BTEBatchImportService'
defined in file [/dspace/config/spring/api/bte.xml]; nested exception
is java.lang.ClassNotFoundException:
org.dspace.app.itemimport.BTEBatchImportService; nested exception is
org.springframework.beans.factory.CannotLoadBeanClassException: Cannot
find class [org.dspace.app.itemimport.BTEBatchImportService] for bean
with name 'org.dspace.app.itemimport.BTEBatchImportService' defined in
file [/dspace/config/spring/api/bte.xml]; nested exception is
java.lang.ClassNotFoundException:
org.dspace.app.itemimport.BTEBatchImportService
at org.dspace.app.launcher.ScriptLauncher.main(ScriptLauncher.java:66)
Caused by: java.lang.RuntimeException: Failed to startup the DSpace
Service Manager: failure starting up spring service manager: Error
creating bean with name
'org.dspace.servicemanager.spring.DSpaceBeanPostProcessor#0' defined
in class path resource [spring/spring-dspace-applicationContext.xml]:
Unsatisfied dependency expressed through constructor argument with
index 0 of type
[org.dspace.servicemanager.config.DSpaceConfigurationService]: :
Cannot find class [org.dspace.app.itemimport.BTEBatchImportService]
for bean with name 'org.dspace.app.itemimport.BTEBatchImportService'
defined in file [/dspace/config/spring/api/bte.xml]; nested exception
is java.lang.ClassNotFoundException:
org.dspace.app.itemimport.BTEBatchImportService; nested exception is
org.springframework.beans.factory.CannotLoadBeanClassException: Cannot
find class [org.dspace.app.itemimport.BTEBatchImportService] for bean
with name 'org.dspace.app.itemimport.BTEBatchImportService' defined in
file [/dspace/config/spring/api/bte.xml]; nested exception is
java.lang.ClassNotFoundException:
org.dspace.app.itemimport.BTEBatchImportService
at
org.dspace.servicemanager.DSpaceServiceManager.startup(DSpaceServiceManager.java:224)
at
org.dspace.servicemanager.DSpaceKernelImpl.start(DSpaceKernelImpl.java:150)
at org.dspace.app.launcher.ScriptLauncher.main(ScriptLauncher.java:51)
Caused by: java.lang.IllegalStateException: failure starting up spring
service manager: Error creating bean with name
'org.dspace.servicemanager.spring.DSpaceBeanPostProcessor#0' defined
in class path resource [spring/spring-dspace-applicationContext.xml]:
Unsatisfied dependency expressed through constructor argument with
index 0 of type
[org.dspace.servicemanager.config.DSpaceConfigurationService]: :
Cannot find class [org.dspace.app.itemimport.BTEBatchImportService]
for bean with name 'org.dspace.app.itemimport.BTEBatchImportService'
defined in file [/dspace/config/spring/api/bte.xml]; nested exception
is java.lang.ClassNotFoundException:
org.dspace.app.itemimport.BTEBatchImportService; nested exception is
org.springframework.beans.factory.CannotLoadBeanClassException: Cannot
find class [org.dspace.app.itemimport.BTEBatchImportService] for bean
with name 'org.dspace.app.itemimport.BTEBatchImportService' defined in
file [/dspace/config/spring/api/bte.xml]; nested exception is
java.lang.ClassNotFoundException:
org.dspace.app.itemimport.BTEBatchImportService
at
org.dspace.servicemanager.DSpaceServiceManager.startup(DSpaceServiceManager.java:208)
... 2 more
Caused by:
org.springframework.beans.factory.UnsatisfiedDependencyException:
Error creating bean with name
'org.dspace.servicemanager.spring.DSpaceBeanPostProcessor#0' defined
in class path resource [spring/spring-dspace-applicationContext.xml]:
Unsatisfied dependency expressed through constructor argument with
index 0 of type
[org.dspace.servicemanager.config.DSpaceConfigurationService]: :
Cannot find class [org.dspace.app.itemimport.BTEBatchImportService]
for bean with name 'org.dspace.app.itemimport.BTEBatchImportService'
defined in file [/dspace/config/spring/api/bte.xml]; nested exception
is java.lang.ClassNotFoundException:
org.dspace.app.itemimport.BTEBatchImportService; nested exception is
org.springframework.beans.factory.CannotLoadBeanClassException: Cannot
find class [org.dspace.app.itemimport.BTEBatchImportService] for bean
with name 'org.dspace.app.itemimport.BTEBatchImportService' defined in
file [/dspace/config/spring/api/bte.xml]; nested exception is
java.lang.ClassNotFoundException:
org.dspace.app.itemimport.BTEBatchImportService
at
org.springframework.beans.factory.support.ConstructorResolver.createArgumentArray(ConstructorResolver.java:730)
at
org.springframework.beans.factory.support.ConstructorResolver.autowireConstructor(ConstructorResolver.java:196)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireConstructor(AbstractAutowireCapableBeanFactory.java:1003)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:907)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:485)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)
at
org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:291)
at
org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
at
org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:288)
at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:194)
at
org.springframework.context.support.AbstractApplicationContext.registerBeanPostProcessors(AbstractApplicationContext.java:722)
at
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:410)
at
org.dspace.servicemanager.spring.SpringServiceManager.startup(SpringServiceManager.java:207)
at
org.dspace.servicemanager.DSpaceServiceManager.startup(DSpaceServiceManager.java:205)
... 2 more
Caused by:
org.springframework.beans.factory.CannotLoadBeanClassException: Cannot
find class [org.dspace.app.itemimport.BTEBatchImportService] for bean
with name 'org.dspace.app.itemimport.BTEBatchImportService' defined in
file [/dspace/config/spring/api/bte.xml]; nested exception is
java.lang.ClassNotFoundException:
org.dspace.app.itemimport.BTEBatchImportService
at
org.springframework.beans.factory.support.AbstractBeanFactory.resolveBeanClass(AbstractBeanFactory.java:1250)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.predictBeanType(AbstractAutowireCapableBeanFactory.java:576)
at
org.springframework.beans.factory.support.AbstractBeanFactory.isFactoryBean(AbstractBeanFactory.java:1319)
at
org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeanNamesForType(DefaultListableBeanFactory.java:315)
at
org.springframework.beans.factory.BeanFactoryUtils.beanNamesForTypeIncludingAncestors(BeanFactoryUtils.java:185)
at
org.springframework.beans.factory.support.DefaultListableBeanFactory.findAutowireCandidates(DefaultListableBeanFactory.java:829)
at
org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:786)
at
org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:703)
at
org.springframework.beans.factory.support.ConstructorResolver.resolveAutowiredArgument(ConstructorResolver.java:795)
at
org.springframework.beans.factory.support.ConstructorResolver.createArgumentArray(ConstructorResolver.java:723)
... 15 more
Caused by: java.lang.ClassNotFoundException:
org.dspace.app.itemimport.BTEBatchImportService
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at org.springframework.util.ClassUtils.forName(ClassUtils.java:257)
at
org.springframework.beans.factory.support.AbstractBeanDefinition.resolveBeanClass(AbstractBeanDefinition.java:408)
at
org.springframework.beans.factory.support.AbstractBeanFactory.doResolveBeanClass(AbstractBeanFactory.java:1271)
at
org.springframework.beans.factory.support.AbstractBeanFactory.resolveBeanClass(AbstractBeanFactory.java:1242)
... 24 more
------------------------------------------------------------------------------
Open source business process management suite built on Java and Eclipse
Turn processes into business applications with Bonita BPM Community Edition
Quickly connect people, data, and systems into organized workflows
Winner of BOSSIE, CODIE, OW2 and Gartner awards
http://p.sf.net/sfu/Bonitasoft
_______________________________________________
DSpace-tech mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-tech
List Etiquette: https://wiki.duraspace.org/display/DSPACE/Mailing+List+Etiquette
--
Monika Mevenkamp
phone: 609-258-4161
Lewis Library,Washington Road and Ivy Lane, Princeton University, Princeton, NJ
08544
------------------------------------------------------------------------------
_______________________________________________
DSpace-tech mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-tech
List Etiquette: https://wiki.duraspace.org/display/DSPACE/Mailing+List+Etiquette