500 error when trying to use longhorn 1.42

106 views
Skip to first unread message

Marc

unread,
Feb 3, 2022, 6:40:42 AM2/3/22
to okapi-users

Dear all,

I just installed the latest okapi longhorn version in our Tomcat 9 server, that runs currently okapi versions from 1.39, 1.40, 1.41 successfully in parallel.

When trying to use it in the way we use the others together with translate5, I receive the following error (tried with a txt and 2 different docx-files, so it should not be file-specific).

Am I doing something wrong, or is this a bug in longhorn?

Thank you very much in advance!

best

Marc

HTTP Status 500 – Internal Server Error


Type Exception Report

Message java.lang.AbstractMethodError: Receiver class org.jboss.resteasy.specimpl.ResponseBuilderImpl does not define or inherit an implementation of the resolved method 'abstract javax.ws.rs.core.Response$ResponseBuilder status(int, java.lang.String)' of abstract class javax.ws.rs.core.Response$ResponseBuilder.

Description The server encountered an unexpected condition that prevented it from fulfilling the request.

Exception

org.jboss.resteasy.spi.UnhandledException: java.lang.AbstractMethodError: Receiver class org.jboss.resteasy.specimpl.ResponseBuilderImpl does not define or inherit an implementation of the resolved method 'abstract javax.ws.rs.core.Response$ResponseBuilder status(int, java.lang.String)' of abstract class javax.ws.rs.core.Response$ResponseBuilder.	org.jboss.resteasy.core.SynchronousDispatcher.handleApplicationException(SynchronousDispatcher.java:365)	org.jboss.resteasy.core.SynchronousDispatcher.handleException(SynchronousDispatcher.java:233)	org.jboss.resteasy.core.SynchronousDispatcher.handleInvokerException(SynchronousDispatcher.java:209)	org.jboss.resteasy.core.SynchronousDispatcher.getResponse(SynchronousDispatcher.java:557)	org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:524)	org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:126)	org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.service(ServletContainerDispatcher.java:208)	org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:55)	org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:50)	javax.servlet.http.HttpServlet.service(HttpServlet.java:741)	org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)

Root Cause

java.lang.AbstractMethodError: Receiver class org.jboss.resteasy.specimpl.ResponseBuilderImpl does not define or inherit an implementation of the resolved method 'abstract javax.ws.rs.core.Response$ResponseBuilder status(int, java.lang.String)' of abstract class javax.ws.rs.core.Response$ResponseBuilder.	javax.ws.rs.core.Response$ResponseBuilder.status(Response.java:896)	javax.ws.rs.core.Response.status(Response.java:567)	javax.ws.rs.core.Response.status(Response.java:578)	javax.ws.rs.core.Response.created(Response.java:690)	net.sf.okapi.applications.longhorn.RESTInterface.createProject(RESTInterface.java:103)	java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)	java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)	java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)	java.base/java.lang.reflect.Method.invoke(Method.java:566)	org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.java:167)	org.jboss.resteasy.core.ResourceMethod.invokeOnTarget(ResourceMethod.java:257)	org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:222)	org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:211)	org.jboss.resteasy.core.SynchronousDispatcher.getResponse(SynchronousDispatcher.java:542)	org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:524)	org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:126)	org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.service(ServletContainerDispatcher.java:208)	org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:55)	org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:50)	javax.servlet.http.HttpServlet.service(HttpServlet.java:741)	org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)

Note The full stack trace of the root cause is available in the server logs.


Apache Tomcat/9.0.16 (Ubuntu)

Marc

unread,
Feb 3, 2022, 6:43:55 AM2/3/22
to okapi-users

same files are working with 1.41, same setup


--
You received this message because you are subscribed to the Google Groups "okapi-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to okapi-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/okapi-users/e40c2ed6-a6f5-2e6c-db0b-fe8a58c08cf6%40marcmittag.de.
-- 
Marc Mittag
MittagQI - Quality Informatics

Service Desk for Requests:
https://jira.translate5.net/servicedesk
Please request a login via mail, if you have none

MittagQI
Konrad-Lorenz-Weg 10
D-72116 Mössingen
Germany
Tel.:   ++49 (0)7473/220202
Fax:    ++49 (0)7473/220211
mailto: Ma...@MittagQI.com
Web:    www.MittagQI.com

Optionale PGP-Verschlüsselung:
Für jeden Mitarbeiter von MittagQI ist auf 
pool.sks-keyservers.net
ein PGP-Key hinterlegt den Sie zur 
PGP-Verschlüsselung Ihrer Mails an uns
nutzen können.

Mihai Nita

unread,
Feb 3, 2022, 11:29:18 AM2/3/22
to Marc, okapi-users
Does 1.42.0 alone works?

Okapi updates the 3rd party libraries dependencies to the latest version.
Do you also have a way to isolate those versionsdependencies 

Mihai


Mihai Nita

unread,
Feb 3, 2022, 11:32:32 AM2/3/22
to Marc, okapi-users
Sorry. Sent by mistake.
Do you also have a way to isolate those versions dependencies?
Or all versions of Okapi end up using one single version of each dependency.
And sooner or later we will stumble on an incompatibility.
I'm not surprised.

Mihai



Marc

unread,
Feb 3, 2022, 11:40:30 AM2/3/22
to Mihai Nita, Marc, okapi-users

Hi Mihai,

thank you very much for your answer!

On 03.02.22 17:32, Mihai Nita wrote:
Sorry. Sent by mistake.
Do you also have a way to isolate those versions dependencies?
Or all versions of Okapi end up using one single version of each dependency.

What do you mean by version dependencies?

All okapi versions run in a different war container and on a different workfiles folder

version 1.42 has the war-file name okapi-longhorn_142.war inside webapps folder of tomcat. Version 1.41 the name okapi-longhorn_141.war

Unpacked by Tomcat they create a folder /okapi-longhorn_142 etc.

And we read 1.42 under http://localhost:8080/okapi-longhorn_142/ etc.

Work folder for 1.42 is under /var/lib/tomcat9/work/Okapi-Longhorn-Files_M1.42.0 etc.

What dependencies do you mean? I think, the only thing they have in common is, that they are all running as tomcat containers?

BTW: In /var/lib/tomcat9/okapi-longhorn-configuration.xml                            

the following configuration is placed, that makes this setup possible according to Chase:

                                                                                                
<?xml version="1.0" encoding="utf-8"?>
<okapi-longhorn-configuration version="1">
    <working-directory>/var/lib/tomcat9/work/Okapi-Longhorn-Files</working-directory>
    <use-unique-working-directory>True</use-unique-working-directory>
</okapi-longhorn-configuration>

Is there still any further dependency between them?

best

Marc

Chase Tingley

unread,
Feb 3, 2022, 12:14:03 PM2/3/22
to Marc, Mihai Nita, okapi-users
I will have to investigate this, I don't recognize that stack offhand.  It does look like a resteasy-related classloading issue.  I did upgrade the resteasy libraries at some point (possibly in release 42), since the old ones had a million security vulnerabilities.

I've run 42 in conjunction with other builds successfully via Jetty (although not Tomcat).  I wonder if there is some sort of classloading leakage going on.

I would also second Mihai's suggestion of seeing if you can run 1.42 standalone independent of the other versions successfully.

Marc

unread,
Feb 3, 2022, 1:18:40 PM2/3/22
to Chase Tingley, Mihai Nita, okapi-users

I removed all war-files and unpacked war-file-folders from /var/lib/tomcat9/webapps, except the 1.42 one and stopped tomcat and stared it again (no restart, to be sure).

Then tried it again - looks like same error:

HTTP Status 500 – Internal Server Error


Type Exception Report

Message java.lang.AbstractMethodError: Receiver class org.jboss.resteasy.specimpl.ResponseBuilderImpl does not define or inherit an implementation of the resolved method 'abstract javax.ws.rs.core.Response$ResponseBuilder status(int, java.lang.String)' of abstract class javax.ws.rs.core.Response$ResponseBuilder.

Description The server encountered an unexpected condition that prevented it from fulfilling the request.

Exception

org.jboss.resteasy.spi.UnhandledException: java.lang.AbstractMethodError: Receiver class org.jboss.resteasy.specimpl.ResponseBuilderImpl does not define or inherit an implementation of the resolved method 'abstract javax.ws.rs.core.Response$ResponseBuilder status(int, java.lang.String)' of abstract class javax.ws.rs.core.Response$ResponseBuilder.	org.jboss.resteasy.core.SynchronousDispatcher.handleApplicationException(SynchronousDispatcher.java:365)	org.jboss.resteasy.core.SynchronousDispatcher.handleException(SynchronousDispatcher.java:233)	org.jboss.resteasy.core.SynchronousDispatcher.handleInvokerException(SynchronousDispatcher.java:209)	org.jboss.resteasy.core.SynchronousDispatcher.getResponse(SynchronousDispatcher.java:557)	org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:524)	org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:126)	org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.service(ServletContainerDispatcher.java:208)	org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:55)	org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:50)	javax.servlet.http.HttpServlet.service(HttpServlet.java:741)	org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)

Root Cause

java.lang.AbstractMethodError: Receiver class org.jboss.resteasy.specimpl.ResponseBuilderImpl does not define or inherit an implementation of the resolved method 'abstract javax.ws.rs.core.Response$ResponseBuilder status(int, java.lang.String)' of abstract class javax.ws.rs.core.Response$ResponseBuilder.	javax.ws.rs.core.Response$ResponseBuilder.status(Response.java:896)	javax.ws.rs.core.Response.status(Response.java:567)	javax.ws.rs.core.Response.status(Response.java:578)	javax.ws.rs.core.Response.created(Response.java:690)	net.sf.okapi.applications.longhorn.RESTInterface.createProject(RESTInterface.java:103)	java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)	java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)	java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)	java.base/java.lang.reflect.Method.invoke(Method.java:566)	org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.java:167)	org.jboss.resteasy.core.ResourceMethod.invokeOnTarget(ResourceMethod.java:257)	org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:222)	org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:211)	org.jboss.resteasy.core.SynchronousDispatcher.getResponse(SynchronousDispatcher.java:542)	org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:524)	org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:126)	org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.service(ServletContainerDispatcher.java:208)	org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:55)	org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:50)	javax.servlet.http.HttpServlet.service(HttpServlet.java:741)	org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)

Note The full stack trace of the root cause is available in the server logs.


Apache Tomcat/9.0.16 (Ubuntu)

Marc

unread,
Feb 3, 2022, 1:24:49 PM2/3/22
to Chase Tingley, Mihai Nita, okapi-users
BTW:

If system environment might be relevant:

/usr/share/tomcat9/bin# ./version.sh
Using CATALINA_BASE:   /usr/share/tomcat9
Using CATALINA_HOME:   /usr/share/tomcat9
Using CATALINA_TMPDIR: /usr/share/tomcat9/temp
Using JRE_HOME:        /usr
Using CLASSPATH:       /usr/share/tomcat9/bin/bootstrap.jar:/usr/share/tomcat9/bin/tomcat-juli.jar
NOTE: Picked up JDK_JAVA_OPTIONS:  --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
Server version: Apache Tomcat/9.0.16 (Ubuntu)
Server built:   Sep 11 2019 19:47:51 UTC
Server number:  9.0.16.0
OS Name:        Linux
OS Version:     4.15.0-166-generic
Architecture:   amd64
JVM Version:    11.0.13+8-Ubuntu-0ubuntu1.18.04
JVM Vendor:     Ubuntu

Marc

unread,
Mar 26, 2022, 6:55:10 AM3/26/22
to okapi-users
Hi there,

is there anyone out there, that runs Okapi longhorn 1.42 sucessfully on Tomcat? If yes, what version of Tomcat?
We would like to upgrade, but can not because of the error outlined above.

Thank you very much for your answer in advance!

best
Marc

Marc

unread,
Apr 12, 2022, 5:51:57 AM4/12/22
to okapi-users

Dear all,

just tried 1.43, and it is working again on our tomcat9, in a parallel install with versions 1.39, 1.40 and 1.41 and something even older.

Just for your info and thank you for anyone who might have fixed the problem with 1.42!  :-)

best
Marc
Reply all
Reply to author
Forward
0 new messages