Jasperreports 7.5 SRC Keystore troubles

0

Hi,

I'm building a clean 7.5 instance in a Tomcat 9.0 server; I'm always getting the same starting error trace:

2020-02-21T08:48:11,330 ERROR ContextLoader,main:350 - Context initialization failed org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'themeSource' defined in ServletContext resource [/WEB-INF/applicationContext-themes.xml]: Cannot resolve reference to bean 'themeCache' while setting bean property 'themeCache'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'themeCache' defined in ServletContext resource [/WEB-INF/applicationContext-themes.xml]: Cannot resolve reference to bean 'unsecureRepositoryService' while setting bean property 'repositoryService'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'hibernateRepositoryService' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Cannot resolve reference to bean 'hibernateRepositoryListeners' while setting bean property 'repositoryListeners'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'hibernateRepositoryListeners' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Cannot resolve reference to bean 'schedulingReportDeleteListener' while setting constructor argument with key [0]; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'schedulingReportDeleteListener' defined in ServletContext resource [/WEB-INF/applicationContext-report-scheduling.xml]: Cannot resolve reference to bean 'reportSchedulingService' while setting bean property 'schedulingService'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'reportSchedulingService' defined in ServletContext resource [/WEB-INF/applicationContext-report-scheduling.xml]: Cannot resolve reference to bean 'securedReportJobsPersistenceService' while setting bean property 'persistenceService'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'securedReportJobsPersistenceService': FactoryBean threw exception on object creation; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'reportJobSecurity' defined in ServletContext resource [/WEB-INF/applicationContext-report-scheduling.xml]: Cannot resolve reference to bean 'authenticationManager' while setting bean property 'authenticationManager'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'authenticationManager' defined in ServletContext resource [/WEB-INF/applicationContext-security.xml]: Cannot resolve reference to bean 'daoAuthenticationProvider' while setting constructor argument with key [0]; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'daoAuthenticationProvider' defined in ServletContext resource [/WEB-INF/applicationContext-security.xml]: Cannot resolve reference to bean 'passwordEncoder' while setting bean property 'passwordEncoder'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'passwordEncoder': Unsatisfied dependency expressed through field 'keystoreManager'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'keystoreManager': Invocation of init method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.jaspersoft.jasperserver.crypto.KeystoreManager]: Please make sure that `create-keystore` was executed; nested exception is java.lang.RuntimeException: KeystoreManager was never initialized or there are errors while instantiating the instance.

2020-02-21T08:48:11,367 ERROR JNDIResourceProvider,main:75 - error closing context javax.naming.OperationNotSupportedException: Context is read only.

I have a Java 1.8 VM for the Tomcat Server, and I have also deployed a 7.2 server in the same way as I'm doing this one, working completely fine.

What I'm missing here? Thank you

jbarrenada's picture
Joined: Jun 2 2016 - 10:13pm
Last seen: 1 month 1 week ago

I have advanced a little bit; I have 2 versions of Java, the first one and main from system is Amazon Corretto's 11 (OpenJDK); then, I also have Java 8 installed.

I found out that if I use installed tomcat's service, it doesnt work, but if i start server from catalina or tomcat9 exe, it works like a charm. I'm assuring when I install the service it uses my Java 8:

Installing the service 'Tomcat9' ...
Using CATALINA_HOME:    "C:\Program Files\Apache Software Foundation\Tomcat 9.0"
Using CATALINA_BASE:    "C:\Program Files\Apache Software Foundation\Tomcat 9.0"
Using JAVA_HOME:        "C:\Program Files\Java\jdk1.8.0_221"
Using JRE_HOME:         "C:\Program Files\Java\jre1.8.0_221"
C:\Program Files\Java\jre1.8.0_221\bin\server\jvm.dll
Using JVM:              "C:\Program Files\Java\jre1.8.0_221\bin\server\jvm.dll"
"C:\Program Files\Apache Software Foundation\Tomcat 9.0\bin\Tomcat9.exe" //IS//Tomcat9
        --Description "Apache Tomcat 9.0.30 Server - https://tomcat.apache.org/"
        --DisplayName "Apache Tomcat 9.0 Tomcat9"
        --Install "C:\Program Files\Apache Software Foundation\Tomcat 9.0\bin\Tomcat9.exe"
        --LogPath "C:\Program Files\Apache Software Foundation\Tomcat 9.0\logs"
        --StdOutput auto
        --StdError auto
        --Classpath "C:\Program Files\Apache Software Foundation\Tomcat 9.0\bin\bootstrap.jar;C:\Program Files\Apache Software Foundation\Tomcat 9.0\bin\tomcat-juli.jar"
        --Jvm "C:\Program Files\Java\jre1.8.0_221\bin\server\jvm.dll"
        --StartMode jvm
        --StopMode jvm
        --StartPath "C:\Program Files\Apache Software Foundation\Tomcat 9.0"
        --StopPath "C:\Program Files\Apache Software Foundation\Tomcat 9.0"
        --JvmOptions "-Dcatalina.home=C:\Program Files\Apache Software Foundation\Tomcat 9.0;-Dcatalina.base=C:\Program Files\Apache Software Foundation\Tomcat 9.0;-Dignore.endorsed.dirs=C:\Program Files\Apache Software Foundation\Tomcat 9.0\endorsed;-Djava.io.tmpdir=C:\Program Files\Apache Software Foundation\Tomcat 9.0\temp;-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager;-Djava.util.logging.config.file=C:\Program Files\Apache Software Foundation\Tomcat 9.0\conf\logging.properties;"
        --JvmOptions9 "--add-opens=java.base/java.lang=ALL-UNNAMED#--add-opens=java.base/java.io=ALL-UNNAMED#--add-opens=java.rmi/sun.rmi.transport=ALL-UNNAMED"
        --Startup "manual"
        --JvmMs "128"
        --JvmMx "256"
The service 'Tomcat9' has been installed.

jbarrenada - 1 month 1 week ago

0 Answers:

No answers yet
Feedback