DX Application Performance Management

 View Only
  • 1.  The MOM is not started

    Posted Feb 19, 2021 07:41 AM
      |   view attached
    Hi everyone:
    When we try to start the MOM we get the following message in the log:

    WARNING: Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanDefinitionStoreException: Invalid bean definition with name 'apmDataSource' defined in class path resource [apm-hibernate-context.xml]: Could not resolve placeholder 'hibernate.connection.password' in string value "${hibernate.connection.password}"; nested exception is java.lang.IllegalArgumentException: Could not resolve placeholder 'hibernate.connection.password' in string value "${hibernate.connection.password}"

    Feb 19, 2021 5:49:49 AM org.springframework.beans.factory.support.DefaultListableBeanFactory destroySingletons

    INFO: Destroying singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@4195105b: defining beans [stringEncryptor,com.ca.wily.jasypt.APMEncryptablePropertyPlaceholderConfigurer#0,messages,databaseForeignKeyViolationErrorCodes,feedbackChannel,apmConfigProperties,apmDataSource,ehCacheManager,cacheManager,dataPruner,tessConfig,apmPrunigScheduler,jobDetailBean,cronTrigger,sessionFactory,threadPoolExecutor,transactionManager,org.springframework.aop.config.internalAutoProxyCreator,daoMethods,org.springframework.aop.support.DefaultBeanFactoryPointcutAdvisor#0,txAdvice,exceptionTracer,org.springframework.context.annotation.internalConfigurationAnnotationProcessor,org.springframework.context.annotation.internalAutowiredAnnotationProcessor,org.springframework.context.annotation.internalRequiredAnnotationProcessor,org.springframework.context.annotation.internalCommonAnnotationProcessor,agentDao,vertexTypeDao,vertexDao,ownerDao,edgeDao,metricPathDao,apmDataService,notificationHandler,entityChangeInterceptor,org.springframework.context.annotation.ConfigurationClassPostProcessor.importAwareProcessor]; root of factory hierarchy

    org.springframework.beans.factory.BeanDefinitionStoreException: Invalid bean definition with name 'apmDataSource' defined in class path resource [apm-hibernate-context.xml]: Could not resolve placeholder 'hibernate.connection.password' in string value "${hibernate.connection.password}"; nested exception is java.lang.IllegalArgumentException: Could not resolve placeholder 'hibernate.connection.password' in string value "${hibernate.connection.password}"

            at org.springframework.beans.factory.config.PlaceholderConfigurerSupport.doProcessProperties(PlaceholderConfigurerSupport.java:209)

            at org.springframework.beans.factory.config.PropertyPlaceholderConfigurer.processProperties(PropertyPlaceholderConfigurer.java:222)

            at org.springframework.beans.factory.config.PropertyResourceConfigurer.postProcessBeanFactory(PropertyResourceConfigurer.java:84)

            at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:699)

            at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:674)

            at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:461)

            at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:139)

            at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:93)

            at com.wily.apm.model.SpringAppContext.init(SpringAppContext.java:53)

            at com.wily.apm.model.SpringAppContext.<init>(SpringAppContext.java:28)

            at com.wily.apm.model.SpringAppContext.<clinit>(SpringAppContext.java:23)

            at com.wily.introscope.server.enterprise.entity.appmap.AppMapEntity.initApmDataService(AppMapEntity.java:230)

            at com.wily.introscope.server.enterprise.entity.appmap.AppMapEntity.<init>(AppMapEntity.java:166)

            at com.wily.introscope.server.enterprise.EnterpriseServer.initialize(EnterpriseServer.java:628)

            at com.wily.introscope.server.enterprise.EnterpriseServer.doStart(EnterpriseServer.java:382)

            at com.wily.util.ALifeCycle.start(ALifeCycle.java:86)

            at com.wily.introscope.server.enterprise.EnterpriseServer.<init>(EnterpriseServer.java:325)

            at com.wily.introscope.server.enterprise.EnterpriseServer.<init>(EnterpriseServer.java:304)

            at com.wily.introscope.server.enterprise.EnterpriseServer.start(EnterpriseServer.java:1598)

            at com.wily.introscope.em.internal.Activator.startEM(Activator.java:119)

            at com.wily.introscope.em.internal.Application.start(Application.java:27)

            at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:193)

            at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)

            at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)

            at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:386)

            at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)

            at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

            at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

            at java.lang.reflect.Method.invoke(Method.java:498)

            at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:549)

            at org.eclipse.equinox.launcher.Main.basicRun(Main.java:504)

            at org.eclipse.equinox.launcher.Main.run(Main.java:1236)

            at org.eclipse.equinox.launcher.Main.main(Main.java:1212)

            at org.eclipse.core.launcher.Main.main(Main.java:30)

            at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

            at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

            at java.lang.reflect.Method.invoke(Method.java:498)

            at com.zerog.lax.LAX.launch(Unknown Source)

            at com.zerog.lax.LAX.main(Unknown Source)

    Caused by: java.lang.IllegalArgumentException: Could not resolve placeholder 'hibernate.connection.password' in string value "${hibernate.connection.password}"

            at org.springframework.util.PropertyPlaceholderHelper.parseStringValue(PropertyPlaceholderHelper.java:173)

            at org.springframework.util.PropertyPlaceholderHelper.replacePlaceholders(PropertyPlaceholderHelper.java:125)

            at org.springframework.beans.factory.config.PropertyPlaceholderConfigurer$PlaceholderResolvingStringValueResolver.resolveStringValue(PropertyPlaceholderConfigurer.java:257)

            at org.springframework.beans.factory.config.BeanDefinitionVisitor.resolveStringValue(BeanDefinitionVisitor.java:282)

            at org.springframework.beans.factory.config.BeanDefinitionVisitor.resolveValue(BeanDefinitionVisitor.java:204)

            at org.springframework.beans.factory.config.BeanDefinitionVisitor.visitPropertyValues(BeanDefinitionVisitor.java:141)

            at org.springframework.beans.factory.config.BeanDefinitionVisitor.visitBeanDefinition(BeanDefinitionVisitor.java:82)

            at org.springframework.beans.factory.config.PlaceholderConfigurerSupport.doProcessProperties(PlaceholderConfigurerSupport.java:206)

            ... 40 more

    log4j:WARN No appenders could be found for logger (com.wily.apm.model.SpringAppContext).

    log4j:WARN Please initialize the log4j system properly.


    They will have some idea of what is happening
    I attach the complete log

    Attachment(s)

    log
    mom.log   62 KB 1 version


  • 2.  RE: The MOM is not started

    Broadcom Employee
    Posted Feb 19, 2021 08:32 AM

    <?xml version="1.0" encoding="UTF-8"?>

    <!DOCTYPE hibernate-configuration PUBLIC

    "-//Hibernate/Hibernate Configuration DTD 3.0//EN"

    "http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">

    <hibernate-configuration>

        <session-factory>

          <property name="em.dbtype">Postgres</property>

          <property name="hibernate.connection.username">admin</property>

          <property name="hibernate.connection.password">ENC(3a.eJCO96245SgatZH3UNRHyA==.xwfRqdJNkaMnrZ5QkVcZhQ==)</property>

          <property name="plainTextPasswords">false</property>

          <property name="hibernate.dialect">org.hibernate.dialect.PostgreSQLDialect</property>

          <property name="hibernate.connection.driver_class">org.postgresql.Driver</property>

          <property name="hibernate.connection.url">jdbc:postgresql://localhost:5432/cemdbcluster</property>

          <property name="hibernate.connection.tcpKeepAlive">true</property>

          <property name="use_sql_comments">false</property>

    </session-factory>

    </hibernate-configuration>

    Hello Carlos,
    Could you please check the tess-db-cfg.xml file in the config folder of the Enterprise Manager,

    this is an example

    <?xml version="1.0" encoding="UTF-8"?>

    <!DOCTYPE hibernate-configuration PUBLIC

    "-//Hibernate/Hibernate Configuration DTD 3.0//EN"

    "http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">

    <hibernate-configuration>

        <session-factory>

          <property name="em.dbtype">Postgres</property>

          <property name="hibernate.connection.username">admin</property>

          <property name="hibernate.connection.password">ENC(3a.eJCO96245SgatZH3UNRHyA==.xwfRqdJNkaMnrZ5QkVcZhQ==)</property>

          <property name="plainTextPasswords">false</property>

          <property name="hibernate.dialect">org.hibernate.dialect.PostgreSQLDialect</property>

          <property name="hibernate.connection.driver_class">org.postgresql.Driver</property>

          <property name="hibernate.connection.url">jdbc:postgresql://localhost:5432/cemdb</property>

          <property name="hibernate.connection.tcpKeepAlive">true</property>

          <property name="use_sql_comments">false</property>

    </session-factory>

    </hibernate-configuration>

    The message suggests an issue with the value for the password:

    hibernate.connection.password


    You might compare the file with the collectors and use a copy of the file from the collectors on the MOM.

    Some background would help if this is a new install, upgrade or if anything else in DB setup may have changed ?

    Many thanks,
    David