Issue: Upgrade to Deploy 22.0.1 produced error creating bean with name 'upgrader'

Issue

During the upgrade to Deploy 22.0.1, the following error is thrown:

2022-03-16 18:02:03.660 [main] {} INFO com.zaxxer.hikari.HikariDataSource - ReportingPool
- Shutdown initiated...
2022-03-16 18:02:03.757 [main] {} INFO com.zaxxer.hikari.HikariDataSource - ReportingPool
- Shutdown completed.
2022-03-16 18:02:03.759 [main] {} INFO com.zaxxer.hikari.HikariDataSource - MainPool
- Shutdown initiated...
2022-03-16 18:02:03.831 [main] {} INFO com.zaxxer.hikari.HikariDataSource - MainPool
- Shutdown completed.
2022-03-16 18:02:03.847 [main] {} INFO org.eclipse.jetty.server.session - node0 Stopped scavenging
2022-03-16 18:02:03.858 [main] {} INFO o.e.j.s.h.ContextHandler.application - Closing Spring root
WebApplicationContext
2022-03-16 18:02:04.178 [main] {} INFO o.e.j.server.handler.ContextHandler - Stopped o.s.b.w.e.j.
JettyEmbeddedWebAppContext@beb78a6{application,/xldeploy,file:///OPT/xldeploy/xl-deploy-22.0.1
-server/,STOPPED}
2022-03-16 18:02:04.408 [main] {} ERROR o.s.boot.SpringApplication - Application run failed
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'upgrader'
defined in com.xebialabs.deployit.ApplicationBootstrapper: Bean instantiation via factory
method failed; nested exception is org.springframework.beans.BeanInstantiationException:
Failed to instantiate [com.xebialabs.deployit.upgrade.PlatformUpgrade]: Factory method
'upgrader' threw exception; nested exception is com.xebialabs.deployit.server.api.upgrade.
UpgradeException: Could not perform upgrade [ArtifactResolverConfigurationUpgrader] to
upgrade to [central-config 10.2.0]
at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver
.java:658)
at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod
(ConstructorResolver.java:486)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsing
FactoryMethod(AbstractAutowireCapableBeanFactory.java:1352)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance
(AbstractAutowireCapableBeanFactory.java:1195)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean
(AbstractAutowireCapableBeanFactory.java:582)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean
(AbstractAutowireCapableBeanFactory.java:542)
at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(Abstract
BeanFactory.java:335)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(Default
SingletonBeanRegistry.java:234)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory
.java:333)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory
.java:208)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons
(DefaultListableBeanFactory.java:953)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization
(AbstractApplicationContext.java:918)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplication
Context.java:583)
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh
(ServletWebServerApplicationContext.java:144)
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:771)
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:763)
at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:438)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:339)
at com.xebialabs.deployit.ApplicationBootstrapper$.main(ApplicationBootstrapper.scala:43)
at com.xebialabs.deployit.ApplicationBootstrapper.main(ApplicationBootstrapper.scala)
Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.
xebialabs.deployit.upgrade.PlatformUpgrade]: Factory method 'upgrader' threw exception;
nested exception is com.xebialabs.deployit.server.api.upgrade.UpgradeException:
Could not perform upgrade [ArtifactResolverConfigurationUpgrader] to upgrade to [central-config
10.2.0]
at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(Simple
InstantiationStrategy.java:185)
at org.springframework.beans.factory.support.ConstructorResolver.lambda$instantiate$2
(ConstructorResolver.java:648)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at org.springframework.beans.factory.support.ConstructorResolver.instantiate(Constructor
Resolver.java:647)
... 19 common frames omitted
Caused by: com.xebialabs.deployit.server.api.upgrade.UpgradeException: Could not perform
upgrade [ArtifactResolverConfigurationUpgrader] to upgrade to [central-config 10.2.0]

Affected Products & Versions

Deploy 22.x

Cause

The xl-deploy.conf file contains commented-out lines.

Example:

# unmerged value 1 for key "connection-timeout" from xl-deploy.conf @ file:/app_1/xld/conf/
  xl-deploy.conf: 183
# unresolved merge of 2 values follows
# unmerged value 0 for key "connection-timeout" from xl-deploy.conf @ jar:file:/
xldata/lib/xld-config-10.1.0.jar!/xl-deploy.conf:

Duplicate entries for the reporting database configuration.

  • connection-timeout
  • idle-timeout
  • leak-detection-threshold
  • max-life-time
  • minimum-idle

Workaround/Resolution Action

  1. Remove the duplicates from the file xl-deploy.conf
  2. Remove all the "unresolved merge" and "unmerged value" commented out lines from xl-deploy.conf

 

Was this article helpful?
0 out of 0 found this helpful

Comments

0 comments

Please sign in to leave a comment.