DSpace 7.4 IllegalArgumentException: Could not resolve placeholder 'pubmed.url.fetch' in value "${pubmed.url.fetch}"

40 views
Skip to first unread message

Simon Eiberger

unread,
Nov 8, 2022, 8:29:16 AM11/8/22
to DSpace Technical Support
Hello,
during the Upgradeprocess from DSpace 7.2.1 to 7.4, I get the following Exception during the ant update step:

[java] 2022-11-08 13:43:48,967 WARN  org.springframework.context.support.ClassPathXmlApplicationContext @ Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanDefinitionStoreException: Invalid bean definition with name 'pubmedImportService' defined in URL [jar:file:/dspace/sw/dspace-dspace-7.4/dspace/target/dspace-installer/lib/dspace-api-7.4.jar!/spring/spring-dspace-addon-import-services.xml]: Could not resolve placeholder 'pubmed.url.fetch' in value "${pubmed.url.fetch}"; nested exception is java.lang.IllegalArgumentException: Could not resolve placeholder 'pubmed.url.fetch' in value "${pubmed.url.fetch}"
     [java] Failure during kernel init: Invalid bean definition with name 'pubmedImportService' defined in URL [jar:file:/dspace/sw/dspace-dspace-7.4/dspace/target/dspace-installer/lib/dspace-api-7.4.jar!/spring/spring-dspace-addon-import-services.xml]: Could not resolve placeholder 'pubmed.url.fetch' in value "${pubmed.url.fetch}"; nested exception is java.lang.IllegalArgumentException: Could not resolve placeholder 'pubmed.url.fetch' in value "${pubmed.url.fetch}"
     [java] org.springframework.beans.factory.BeanDefinitionStoreException: Invalid bean definition with name 'pubmedImportService' defined in URL [jar:file:/dspace/sw/dspace-dspace-7.4/dspace/target/dspace-installer/lib/dspace-api-7.4.jar!/spring/spring-dspace-addon-import-services.xml]: Could not resolve placeholder 'pubmed.url.fetch' in value "${pubmed.url.fetch}"; nested exception is java.lang.IllegalArgumentException: Could not resolve placeholder 'pubmed.url.fetch' in value "${pubmed.url.fetch}"
     [java]     at org.springframework.beans.factory.config.PlaceholderConfigurerSupport.doProcessProperties(PlaceholderConfigurerSupport.java:230)
     [java]     at org.springframework.context.support.PropertySourcesPlaceholderConfigurer.processProperties(PropertySourcesPlaceholderConfigurer.java:198)
     [java]     at org.springframework.context.support.PropertySourcesPlaceholderConfigurer.postProcessBeanFactory(PropertySourcesPlaceholderConfigurer.java:173)
     [java]     at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:325)
     [java]     at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:183)
     [java]     at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:746)
     [java]     at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:564)
     [java]     at org.dspace.servicemanager.DSpaceServiceManager.startup(DSpaceServiceManager.java:277)
     [java]     at org.dspace.servicemanager.DSpaceKernelImpl.start(DSpaceKernelImpl.java:153)
     [java]     at org.dspace.servicemanager.DSpaceKernelImpl.start(DSpaceKernelImpl.java:128)
     [java]     at org.dspace.app.launcher.ScriptLauncher.main(ScriptLauncher.java:70)
     [java] Caused by: java.lang.IllegalArgumentException: Could not resolve placeholder 'pubmed.url.fetch' in value "${pubmed.url.fetch}"
     [java]     at org.springframework.util.PropertyPlaceholderHelper.parseStringValue(PropertyPlaceholderHelper.java:180)
     [java]     at org.springframework.util.PropertyPlaceholderHelper.replacePlaceholders(PropertyPlaceholderHelper.java:126)
     [java]     at org.springframework.core.env.AbstractPropertyResolver.doResolvePlaceholders(AbstractPropertyResolver.java:239)
     [java]     at org.springframework.core.env.AbstractPropertyResolver.resolveRequiredPlaceholders(AbstractPropertyResolver.java:210)
     [java]     at org.springframework.context.support.PropertySourcesPlaceholderConfigurer.lambda$processProperties$0(PropertySourcesPlaceholderConfigurer.java:191)
     [java]     at org.springframework.beans.factory.config.BeanDefinitionVisitor.resolveStringValue(BeanDefinitionVisitor.java:296)
     [java]     at org.springframework.beans.factory.config.BeanDefinitionVisitor.resolveValue(BeanDefinitionVisitor.java:217)
     [java]     at org.springframework.beans.factory.config.BeanDefinitionVisitor.visitPropertyValues(BeanDefinitionVisitor.java:147)
     [java]     at org.springframework.beans.factory.config.BeanDefinitionVisitor.visitBeanDefinition(BeanDefinitionVisitor.java:85)
     [java]     at org.springframework.beans.factory.config.PlaceholderConfigurerSupport.doProcessProperties(PlaceholderConfigurerSupport.java:227)
     [java]     ... 10 more
     [java] Exception in thread "main" java.lang.IllegalStateException: Failure during kernel init: Invalid bean definition with name 'pubmedImportService' defined in URL [jar:file:/dspace/sw/dspace-dspace-7.4/dspace/target/dspace-installer/lib/dspace-api-7.4.jar!/spring/spring-dspace-addon-import-services.xml]: Could not resolve placeholder 'pubmed.url.fetch' in value "${pubmed.url.fetch}"; nested exception is java.lang.IllegalArgumentException: Could not resolve placeholder 'pubmed.url.fetch' in value "${pubmed.url.fetch}"
     [java]     at org.dspace.app.launcher.ScriptLauncher.main(ScriptLauncher.java:82)
     [java] Caused by: org.springframework.beans.factory.BeanDefinitionStoreException: Invalid bean definition with name 'pubmedImportService' defined in URL [jar:file:/dspace/sw/dspace-dspace-7.4/dspace/target/dspace-installer/lib/dspace-api-7.4.jar!/spring/spring-dspace-addon-import-services.xml]: Could not resolve placeholder 'pubmed.url.fetch' in value "${pubmed.url.fetch}"; nested exception is java.lang.IllegalArgumentException: Could not resolve placeholder 'pubmed.url.fetch' in value "${pubmed.url.fetch}"
     [java]     at org.springframework.beans.factory.config.PlaceholderConfigurerSupport.doProcessProperties(PlaceholderConfigurerSupport.java:230)
     [java]     at org.springframework.context.support.PropertySourcesPlaceholderConfigurer.processProperties(PropertySourcesPlaceholderConfigurer.java:198)
     [java]     at org.springframework.context.support.PropertySourcesPlaceholderConfigurer.postProcessBeanFactory(PropertySourcesPlaceholderConfigurer.java:173)
     [java]     at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:325)
     [java]     at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:183)
     [java]     at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:746)
     [java]     at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:564)
     [java]     at org.dspace.servicemanager.DSpaceServiceManager.startup(DSpaceServiceManager.java:277)
     [java]     at org.dspace.servicemanager.DSpaceKernelImpl.start(DSpaceKernelImpl.java:153)
     [java]     at org.dspace.servicemanager.DSpaceKernelImpl.start(DSpaceKernelImpl.java:128)
     [java]     at org.dspace.app.launcher.ScriptLauncher.main(ScriptLauncher.java:70)
     [java] Caused by: java.lang.IllegalArgumentException: Could not resolve placeholder 'pubmed.url.fetch' in value "${pubmed.url.fetch}"
     [java]     at org.springframework.util.PropertyPlaceholderHelper.parseStringValue(PropertyPlaceholderHelper.java:180)
     [java]     at org.springframework.util.PropertyPlaceholderHelper.replacePlaceholders(PropertyPlaceholderHelper.java:126)
     [java]     at org.springframework.core.env.AbstractPropertyResolver.doResolvePlaceholders(AbstractPropertyResolver.java:239)
     [java]     at org.springframework.core.env.AbstractPropertyResolver.resolveRequiredPlaceholders(AbstractPropertyResolver.java:210)
     [java]     at org.springframework.context.support.PropertySourcesPlaceholderConfigurer.lambda$processProperties$0(PropertySourcesPlaceholderConfigurer.java:191)
     [java]     at org.springframework.beans.factory.config.BeanDefinitionVisitor.resolveStringValue(BeanDefinitionVisitor.java:296)
     [java]     at org.springframework.beans.factory.config.BeanDefinitionVisitor.resolveValue(BeanDefinitionVisitor.java:217)
     [java]     at org.springframework.beans.factory.config.BeanDefinitionVisitor.visitPropertyValues(BeanDefinitionVisitor.java:147)
     [java]     at org.springframework.beans.factory.config.BeanDefinitionVisitor.visitBeanDefinition(BeanDefinitionVisitor.java:85)
     [java]     at org.springframework.beans.factory.config.PlaceholderConfigurerSupport.doProcessProperties(PlaceholderConfigurerSupport.java:227)
     [java]     ... 10 more

BUILD FAILED

Any ideas where this error is coming from and how I can fix it? 

Thanks in advance
Simon

Tim Donohue

unread,
Nov 8, 2022, 10:05:20 AM11/8/22
to Simon Eiberger, DSpace Technical Support
Hi Simon,

That new "pubmed.url.fetch" variable should be in the new "[src]/dspace/config/modules/external-providers.cfg" configuration file.

Maybe that file somehow didn't get copied over into your [dspace]/config/ folder (where DSpace 7.x is installed)?   Or, it's possible that your "dspace.cfg" is missing the new "include" statement which imports the "external-providers.cfg".  See this new line: https://github.com/DSpace/DSpace/blob/main/dspace/config/dspace.cfg#L1684

It's unclear which step of the "ant update" script resulted in this error... but, essentially, it sounds like it isn't finding that "external-providers.cfg", which results in the error you are experiencing.

Hopefully these hints might help give you clues on how to proceed. But, if you need more help, let us know on this list.

Tim

From: dspac...@googlegroups.com <dspac...@googlegroups.com> on behalf of Simon Eiberger <Simon.E...@uni-ulm.de>
Sent: Tuesday, November 8, 2022 7:29 AM
To: DSpace Technical Support <dspac...@googlegroups.com>
Subject: [dspace-tech] DSpace 7.4 IllegalArgumentException: Could not resolve placeholder 'pubmed.url.fetch' in value "${pubmed.url.fetch}"
 
--
All messages to this mailing list should adhere to the Code of Conduct: https://www.lyrasis.org/about/Pages/Code-of-Conduct.aspx
---
You received this message because you are subscribed to the Google Groups "DSpace Technical Support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dspace-tech...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/dspace-tech/716de082-3ac9-43d2-a3c4-39300723741fn%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages