onesaitplatform/onesait-cloud-platform-community-deploy

Error UnsatisfiedDependencyException at MigrationService

UncleDinoso opened this issue · 5 comments

Behavior:
I will start first time on a fresh vm "docker-compose -f docker-compose.initdb.yml up" and ConfigInit show an error:

configinitservice     | ┌──->──┐
configinitservice     | |  migrationService (field com.minsait.onesait.platform.config.services.migration.MigrationService com.minsait.onesait.platform.config.services.migration.MigrationServiceImpl.selfReference)
configinitservice     | └──<-──┘
configinitservice     | Action:
configinitservice     | 
configinitservice     | Relying upon circular references is discouraged and they are prohibited by default. Update your application to remove the dependency cycle between beans. As a last resort, it may be possible to break the cycle automatically by setting spring.main.allow-circular-references to true.

Environment:
.env
MODULE_TAG=5.2.0-ce
docker-compose.initdb.yml

  • UPDATE_MODE_MULTITENANT=false

Expect:
ConfigInit Service is run without errors

Hello @UncleDinoso,

this is a known error in the config-init service, but it does not prevent the tasks of the config-init service to be executed. The configuration must have been loaded into the configDB without problems, despite the error you have shared with us. Check if the tables have been created in the configDB and, if so, you can continue with the deployment of the rest of the modules.

Best Regards,
Onesait Platform Team

Hello @onesaitplatform ,
thanks for your fast reply. The tables have been created properly. When i will start the services under op_modules, i receive an error in controlpanel and the service doesnt work properly:


[LaunchedURLClassLoader@64c009b8] abort trouble in: 
class org.springframework.boot.jdbc.DataSourceBuilder$ComboPooledDataSourceProperties extends org.springframework.boot.jdbc.DataSourceBuilder$MappedDataSourceProperties:
  void <init>():
                    ALOAD_0     // Lorg/springframework/boot/jdbc/DataSourceBuilder$ComboPooledDataSourceProperties; this   (line 662)
                    INVOKESPECIAL org.springframework.boot.jdbc.DataSourceBuilder$MappedDataSourceProperties.<init> ()V
    constructor-execution(void org.springframework.boot.jdbc.DataSourceBuilder$ComboPooledDataSourceProperties.<init>())
    |               ALOAD_0     // Lorg/springframework/boot/jdbc/DataSourceBuilder$ComboPooledDataSourceProperties; this   (line 663)
    | field-get(org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty.URL)
    | |             GETSTATIC org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty.URL Lorg/springframework/boot/jdbc/DataSourceBuilder$DataSourceProperty;
    | field-get(org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty.URL)
    |               INVOKEDYNAMIC #0.get ()Lorg/springframework/boot/jdbc/DataSourceBuilder$Getter;
    |               INVOKEDYNAMIC #1.set ()Lorg/springframework/boot/jdbc/DataSourceBuilder$Setter;
    |               INVOKEVIRTUAL org.springframework.boot.jdbc.DataSourceBuilder$ComboPooledDataSourceProperties.add (Lorg/springframework/boot/jdbc/DataSourceBuilder$DataSourceProperty;Lorg/springframework/boot/jdbc/DataSourceBuilder$Getter;Lorg/springframework/boot/jdbc/DataSourceBuilder$Setter;)V
    |               ALOAD_0     // Lorg/springframework/boot/jdbc/DataSourceBuilder$ComboPooledDataSourceProperties; this   (line 664)
    | field-get(org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty.DRIVER_CLASS_NAME)
    | |             GETSTATIC org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty.DRIVER_CLASS_NAME Lorg/springframework/boot/jdbc/DataSourceBuilder$DataSourceProperty;
    | field-get(org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty.DRIVER_CLASS_NAME)
    |               INVOKEDYNAMIC #2.get ()Lorg/springframework/boot/jdbc/DataSourceBuilder$Getter;
    |               ALOAD_0     // Lorg/springframework/boot/jdbc/DataSourceBuilder$ComboPooledDataSourceProperties; this
    |               INVOKEDYNAMIC #3.set (Lorg/springframework/boot/jdbc/DataSourceBuilder$ComboPooledDataSourceProperties;)Lorg/springframework/boot/jdbc/DataSourceBuilder$Setter;
    |               INVOKEVIRTUAL org.springframework.boot.jdbc.DataSourceBuilder$ComboPooledDataSourceProperties.add (Lorg/springframework/boot/jdbc/DataSourceBuilder$DataSourceProperty;Lorg/springframework/boot/jdbc/DataSourceBuilder$Getter;Lorg/springframework/boot/jdbc/DataSourceBuilder$Setter;)V
    |               ALOAD_0     // Lorg/springframework/boot/jdbc/DataSourceBuilder$ComboPooledDataSourceProperties; this   (line 665)
    | field-get(org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty.USERNAME)
    | |             GETSTATIC org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty.USERNAME Lorg/springframework/boot/jdbc/DataSourceBuilder$DataSourceProperty;
    | field-get(org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty.USERNAME)
    |               INVOKEDYNAMIC #4.get ()Lorg/springframework/boot/jdbc/DataSourceBuilder$Getter;
    |               INVOKEDYNAMIC #5.set ()Lorg/springframework/boot/jdbc/DataSourceBuilder$Setter;
    |               INVOKEVIRTUAL org.springframework.boot.jdbc.DataSourceBuilder$ComboPooledDataSourceProperties.add (Lorg/springframework/boot/jdbc/DataSourceBuilder$DataSourceProperty;Lorg/springframework/boot/jdbc/DataSourceBuilder$Getter;Lorg/springframework/boot/jdbc/DataSourceBuilder$Setter;)V
    |               ALOAD_0     // Lorg/springframework/boot/jdbc/DataSourceBuilder$ComboPooledDataSourceProperties; this   (line 666)
    | field-get(org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty.PASSWORD)
    | |             GETSTATIC org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty.PASSWORD Lorg/springframework/boot/jdbc/DataSourceBuilder$DataSourceProperty;
    | field-get(org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty org.springframework.boot.jdbc.DataSourceBuilder$DataSourceProperty.PASSWORD)
    |               INVOKEDYNAMIC #6.get ()Lorg/springframework/boot/jdbc/DataSourceBuilder$Getter;
    |               INVOKEDYNAMIC #7.set ()Lorg/springframework/boot/jdbc/DataSourceBuilder$Setter;
    |               INVOKEVIRTUAL org.springframework.boot.jdbc.DataSourceBuilder$ComboPooledDataSourceProperties.add (Lorg/springframework/boot/jdbc/DataSourceBuilder$DataSourceProperty;Lorg/springframework/boot/jdbc/DataSourceBuilder$Getter;Lorg/springframework/boot/jdbc/DataSourceBuilder$Setter;)V
    |               RETURN   (line 667)
    constructor-execution(void org.springframework.boot.jdbc.DataSourceBuilder$ComboPooledDataSourceProperties.<init>())
  end void <init>()

  private void setDriverClass(com.mchange.v2.c3p0.ComboPooledDataSource, String):
    method-execution(void org.springframework.boot.jdbc.DataSourceBuilder$ComboPooledDataSourceProperties.setDriverClass(com.mchange.v2.c3p0.ComboPooledDataSource, java.lang.String))
    | catch java.beans.PropertyVetoException -> E0
    | |             ALOAD_1     // Lcom/mchange/v2/c3p0/ComboPooledDataSource; dataSource   (line 671)
    | |             ALOAD_2     // Ljava/lang/String; driverClass
    | |             INVOKEVIRTUAL com.mchange.v2.c3p0.ComboPooledDataSource.setDriverClass (Ljava/lang/String;)V
    | catch java.beans.PropertyVetoException -> E0
    |               GOTO L0   (line 675)
    |           E0: ASTORE_3   (line 673)
    |               NEW java.lang.IllegalArgumentException   (line 674)
    |               DUP
    |               ALOAD_3     // Ljava/beans/PropertyVetoException; ex
    |               INVOKESPECIAL java.lang.IllegalArgumentException.<init> (Ljava/lang/Throwable;)V
    |               ATHROW
    |           L0: RETURN   (line 676)
    method-execution(void org.springframework.boot.jdbc.DataSourceBuilder$ComboPooledDataSourceProperties.setDriverClass(com.mchange.v2.c3p0.ComboPooledDataSource, java.lang.String))
  end private void setDriverClass(com.mchange.v2.c3p0.ComboPooledDataSource, String)

end class org.springframework.boot.jdbc.DataSourceBuilder$ComboPooledDataSourceProperties
 -- (IllegalStateException) org.aspectj.weaver.MissingResolvedTypeWithKnownSignature) (typeBindings={T=com.mchange.v2.c3p0.ComboPooledDataSource})
org.aspectj.weaver.MissingResolvedTypeWithKnownSignature) (typeBindings={T=com.mchange.v2.c3p0.ComboPooledDataSource})
java.lang.IllegalStateException: org.aspectj.weaver.MissingResolvedTypeWithKnownSignature) (typeBindings={T=com.mchange.v2.c3p0.ComboPooledDataSource})
        at org.aspectj.weaver.BoundedReferenceType.parameterize(BoundedReferenceType.java:112)
        at org.aspectj.weaver.ResolvedType.parameterize(ResolvedType.java:2549)
        at org.aspectj.weaver.ResolvedMemberImpl.parameterize(ResolvedMemberImpl.java:897)
        at org.aspectj.weaver.ResolvedMemberImpl.parameterizedWith(ResolvedMemberImpl.java:789)
        at org.aspectj.weaver.ResolvedMemberImpl.parameterizedWith(ResolvedMemberImpl.java:742)
        at org.aspectj.weaver.ReferenceType.getDeclaredMethods(ReferenceType.java:865)
        at org.aspectj.weaver.ResolvedType$MethodGetterIncludingItds.get(ResolvedType.java:271)
        at org.aspectj.weaver.ResolvedType$MethodGetterIncludingItds.get(ResolvedType.java:268)
        at org.aspectj.weaver.Iterators$4$1.hasNext(Iterators.java:213)
        at org.aspectj.weaver.Iterators$4.hasNext(Iterators.java:230)
        at org.aspectj.weaver.ResolvedType.lookupResolvedMember(ResolvedType.java:642)
        at org.aspectj.weaver.JoinPointSignatureIterator.findSignaturesFromSupertypes(JoinPointSignatureIterator.java:192)
        at org.aspectj.weaver.JoinPointSignatureIterator.hasNext(JoinPointSignatureIterator.java:68)
        at org.aspectj.weaver.patterns.SignaturePattern.matches(SignaturePattern.java:317)
        at org.aspectj.weaver.patterns.KindedPointcut.matchInternal(KindedPointcut.java:202)
        at org.aspectj.weaver.patterns.Pointcut.match(Pointcut.java:137)
        at org.aspectj.weaver.patterns.AndPointcut.matchInternal(AndPointcut.java:56)
        at org.aspectj.weaver.patterns.Pointcut.match(Pointcut.java:137)
        at org.aspectj.weaver.patterns.OrPointcut.matchInternal(OrPointcut.java:60)
        at org.aspectj.weaver.patterns.Pointcut.match(Pointcut.java:137)
        at org.aspectj.weaver.ShadowMunger.match(ShadowMunger.java:113)
        at org.aspectj.weaver.Advice.match(Advice.java:113)
        at org.aspectj.weaver.bcel.BcelAdvice.match(BcelAdvice.java:158)
        at org.aspectj.weaver.bcel.BcelClassWeaver.match(BcelClassWeaver.java:3330)
        at org.aspectj.weaver.bcel.BcelClassWeaver.match(BcelClassWeaver.java:2710)
        at org.aspectj.weaver.bcel.BcelClassWeaver.weave(BcelClassWeaver.java:483)
        at org.aspectj.weaver.bcel.BcelClassWeaver.weave(BcelClassWeaver.java:103)
        at org.aspectj.weaver.bcel.BcelWeaver.weave(BcelWeaver.java:1707)
        at org.aspectj.weaver.bcel.BcelWeaver.weaveWithoutDump(BcelWeaver.java:1651)
        at org.aspectj.weaver.bcel.BcelWeaver.weaveAndNotify(BcelWeaver.java:1418)
        at org.aspectj.weaver.bcel.BcelWeaver.weave(BcelWeaver.java:1192)
        at org.aspectj.weaver.tools.WeavingAdaptor.getWovenBytes(WeavingAdaptor.java:549)
        at org.aspectj.weaver.tools.WeavingAdaptor.weaveClass(WeavingAdaptor.java:385)
        at org.aspectj.weaver.loadtime.Aj.preProcess(Aj.java:115)
        at org.aspectj.weaver.loadtime.ClassPreProcessorAgentAdapter.transform(ClassPreProcessorAgentAdapter.java:51)
        at java.instrument/java.lang.instrument.ClassFileTransformer.transform(ClassFileTransformer.java:244)
        at java.instrument/sun.instrument.TransformerManager.transform(TransformerManager.java:188)
        at java.instrument/sun.instrument.InstrumentationImpl.transform(InstrumentationImpl.java:541)
        at java.base/java.lang.ClassLoader.defineClass1(Native Method)
        at java.base/java.lang.ClassLoader.defineClass(ClassLoader.java:1017)
        at java.base/java.security.SecureClassLoader.defineClass(SecureClassLoader.java:150)
        at java.base/java.net.URLClassLoader.defineClass(URLClassLoader.java:524)
        at java.base/java.net.URLClassLoader$1.run(URLClassLoader.java:427)
        at java.base/java.net.URLClassLoader$1.run(URLClassLoader.java:421)
        at java.base/java.security.AccessController.doPrivileged(AccessController.java:712)
        at java.base/java.net.URLClassLoader.findClass(URLClassLoader.java:420)
        at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:592)
        at org.springframework.boot.loader.LaunchedURLClassLoader.loadClass(LaunchedURLClassLoader.java:151)
        at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:525)
        at org.springframework.boot.jdbc.DataSourceBuilder$MappedDataSourceProperties.lookupPooled(DataSourceBuilder.java:396)
        at org.springframework.boot.jdbc.DataSourceBuilder$MappedDataSourceProperties.forType(DataSourceBuilder.java:378)
        at org.springframework.boot.jdbc.DataSourceBuilder.findType(DataSourceBuilder.java:250)
        at org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration$PooledDataSourceAvailableCondition.getMatchOutcome(DataSourceAutoConfiguration.java:110)
        at org.springframework.boot.autoconfigure.condition.AbstractNestedCondition$MemberOutcomes.getConditionOutcome(AbstractNestedCondition.java:194)
        at org.springframework.boot.autoconfigure.condition.AbstractNestedCondition$MemberOutcomes.<init>(AbstractNestedCondition.java:188)
        at org.springframework.boot.autoconfigure.condition.AbstractNestedCondition$MemberConditions.lambda$getMatchOutcomes$0(AbstractNestedCondition.java:168)
        at java.base/java.util.Map.forEach(Map.java:713)
        at java.base/java.util.Collections$UnmodifiableMap.forEach(Collections.java:1553)
        at org.springframework.boot.autoconfigure.condition.AbstractNestedCondition$MemberConditions.getMatchOutcomes(AbstractNestedCondition.java:168)
        at org.springframework.boot.autoconfigure.condition.AbstractNestedCondition$MemberMatchOutcomes.<init>(AbstractNestedCondition.java:78)
        at org.springframework.boot.autoconfigure.condition.AbstractNestedCondition.getMatchOutcome(AbstractNestedCondition.java:63)
        at org.springframework.boot.autoconfigure.condition.SpringBootCondition.matches(SpringBootCondition.java:47)
        at org.springframework.context.annotation.ConditionEvaluator.shouldSkip(ConditionEvaluator.java:108)
        at org.springframework.context.annotation.ConfigurationClassParser.processConfigurationClass(ConfigurationClassParser.java:225)
        at org.springframework.context.annotation.ConfigurationClassParser.processMemberClasses(ConfigurationClassParser.java:371)
        at org.springframework.context.annotation.ConfigurationClassParser.doProcessConfigurationClass(ConfigurationClassParser.java:271)
        at org.springframework.context.annotation.ConfigurationClassParser.processConfigurationClass(ConfigurationClassParser.java:249)
        at org.springframework.context.annotation.ConfigurationClassParser.processImports(ConfigurationClassParser.java:599)
        at org.springframework.context.annotation.ConfigurationClassParser.access$800(ConfigurationClassParser.java:110)
        at org.springframework.context.annotation.ConfigurationClassParser$DeferredImportSelectorGroupingHandler.lambda$processGroupImports$1(ConfigurationClassParser.java:812)
        at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
        at org.springframework.context.annotation.ConfigurationClassParser$DeferredImportSelectorGroupingHandler.processGroupImports(ConfigurationClassParser.java:809)
        at org.springframework.context.annotation.ConfigurationClassParser$DeferredImportSelectorHandler.process(ConfigurationClassParser.java:780)
        at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:192)
        at org.springframework.context.annotation.ConfigurationClassPostProcessor.processConfigBeanDefinitions(ConfigurationClassPostProcessor.java:331)
        at org.springframework.context.annotation.ConfigurationClassPostProcessor.postProcessBeanDefinitionRegistry(ConfigurationClassPostProcessor.java:247)
        at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:311)
        at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:112)
        at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:748)
        at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:564)
        at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:147)
        at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:731)
        at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:408)
        at org.springframework.boot.SpringApplication.run(SpringApplication.java:307)
        at org.springframework.boot.SpringApplication.run(SpringApplication.java:1303)
        at org.springframework.boot.SpringApplication.run(SpringApplication.java:1292)
        at com.minsait.onesait.platform.controlpanel.ControlPanelWebApplication.main(ControlPanelWebApplication.java:104)
        at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
        at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.base/java.lang.reflect.Method.invoke(Method.java:568)
        at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:49)
        at org.springframework.boot.loader.Launcher.launch(Launcher.java:108)
        at org.springframework.boot.loader.Launcher.launch(Launcher.java:58)
        at org.springframework.boot.loader.PropertiesLauncher.main(PropertiesLauncher.java:467)
        at com.minsait.onesait.platform.controlpanel.ControlPanelWebBootstrapApplication.main(ControlPanelWebBootstrapApplication.java:26)
        at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
        at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.base/java.lang.reflect.Method.invoke(Method.java:568)
        at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:49)
        at org.springframework.boot.loader.Launcher.launch(Launcher.java:108)
        at org.springframework.boot.loader.Launcher.launch(Launcher.java:58)
        at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:88)

[InspectionClassLoader@12aeb97b] info AspectJ Weaver Version 1.9.8 built on Thursday Feb 10, 2022 at 17:30:16 PST
[InspectionClassLoader@12aeb97b] info register classloader org.springframework.data.jpa.repository.config.InspectionClassLoader@12aeb97b
[InspectionClassLoader@12aeb97b] info using configuration file:/app.jar!/BOOT-INF/lib/onesaitplatform-pass-encryptor-5.2.0-ce.jar!/META-INF/aop.xml
[InspectionClassLoader@12aeb97b] info using configuration file:/app.jar!/BOOT-INF/lib/spring-aspects-5.3.29.jar!/META-INF/aop.xml
[InspectionClassLoader@12aeb97b] info register aspect com.minsait.onesait.platform.encryptor.aop.EncryptableAspect
[InspectionClassLoader@12aeb97b] info register aspect org.springframework.beans.factory.aspectj.AnnotationBeanConfigurerAspect
[InspectionClassLoader@12aeb97b] info register aspect org.springframework.scheduling.aspectj.AnnotationAsyncExecutionAspect
[InspectionClassLoader@12aeb97b] info register aspect org.springframework.transaction.aspectj.AnnotationTransactionAspect
[InspectionClassLoader@12aeb97b] info register aspect org.springframework.transaction.aspectj.JtaAnnotationTransactionAspect
[InspectionClassLoader@12aeb97b] info register aspect org.springframework.cache.aspectj.AnnotationCacheAspect
[InspectionClassLoader@12aeb97b] info register aspect org.springframework.cache.aspectj.JCacheCacheAspect
[InspectionClassLoader@12aeb97b] info deactivating aspect 'org.springframework.cache.aspectj.JCacheCacheAspect' as it requires type 'javax.cache.annotation.CacheResult' which cannot be found on the classpath

Hello @UncleDinoso,

this error is not preventing the control panel module to start, because the execution continues correctly (aspectJ Weaver part). The complete logs of the module can be read in /var/log/platform-logs directory of the container. Also, can you check if the tables in configDB have been created?

Best Regards,
Onesait Platform Team

Hello @onesaitplatform,
the tables are created. After a restart of the VM and start up whole environment, the platform is now working. In the logs of the control-panel I encounter an UnknownHost Exception, that the PluginManager can't found, but in the op_modules, there aren't a module for plugin manager so i think, this is an other issue.

This issue can be close. Thank you for your help :-)

Hello @UncleDinoso ,
perfect, the UnknownHost Exception is caused because that module is not available, we have not created the proper configuration for this Community release. We will review these parts and try to change those log traces to WARN in order to make it easy to find the real problems.

You're welcome!

Best Regards,
Onesait Platform Team