Project

General

Profile

Actions

Bug #1384

closed

Annotace needs Tomcat restart after redeploy

Added by Lama Saeeda about 4 years ago. Updated almost 3 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Target version:
2021-IPR - TermIt - 2.9.0
Start date:
10.09.2020
Due date:
% Done:

0%

Estimated time:

Description

  • Reproduce: Redeploy Annotace in Jenkins.
  • The service is down due to exception "java.lang.NoClassDefFoundError: Could not initialize class cz.cuni.mff.ufal.morphodita.morphodita_javaJNI". The full log is in the attachment. The problem is most probably happening because of using JNI under Tomcat. “The important thing to know about using JNI under Tomcat is that one cannot place the native libraries OR their JNI interfaces under the WEB-INF/lib or WEB-INF/classes directories of a web application and expect to be able to reload the webapp without restarting the server.” see this wiki provided by Martin https://cwiki.apache.org/confluence/display/tomcat/HowTo#HowTo-I'mencounteringclassloaderproblemswhenusingJNIunderTomcat.
  • The current solution is to restart Tomcat with every Jenkins redeploy of Annotace. This is not a very nice solution as other services running on Tomcat will be affected.
    - Sol1: Move the problematic files to the $CATALINA_HOME/shared/lib directory.
    - Sol2: Deploy Annotace in a separate instance of Tomcat.

Files

AnnotaceLog (8.14 KB) AnnotaceLog Lama Saeeda, 10.09.2020 16:27
Actions

Also available in: Atom PDF