New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Embedding and Liferay: org.slf4j.helpers.MessageFormatter cannot be cast to org.orbeon.private.apache.http.HttpRequestInterceptor #3154

Closed
ebruchez opened this Issue Mar 17, 2017 · 6 comments

Comments

Projects
1 participant
@ebruchez
Collaborator

ebruchez commented Mar 17, 2017

This was reported by some users. We haven't managed to reproduce it yet.

@ebruchez ebruchez self-assigned this Mar 17, 2017

@ebruchez

This comment has been minimized.

Show comment
Hide comment
@ebruchez

ebruchez Mar 17, 2017

Collaborator

orbeon-embedding.jar contains these classes from slf4j-api-1.7.21.jar:

org/slf4j/ILoggerFactory.class
org/slf4j/Logger.class
org/slf4j/LoggerFactory.class
org/slf4j/event/EventRecodingLogger.class
org/slf4j/event/Level.class
org/slf4j/event/LoggingEvent.class
org/slf4j/event/SubstituteLoggingEvent.class
org/slf4j/helpers/FormattingTuple.class
org/slf4j/helpers/MarkerIgnoringBase.class
org/slf4j/helpers/MessageFormatter.class
org/slf4j/helpers/NOPLogger.class
org/slf4j/helpers/NOPLoggerFactory.class
org/slf4j/helpers/NamedLoggerBase.class
org/slf4j/helpers/SubstituteLogger.class
org/slf4j/helpers/SubstituteLoggerFactory.class
org/slf4j/helpers/Util.class
org/slf4j/spi/LocationAwareLogger.class

and these classes from slf4j-log4j12-1.7.21.jar:

org/slf4j/impl/Log4jLoggerAdapter.class
org/slf4j/impl/Log4jLoggerFactory.class
org/slf4j/impl/StaticLoggerBinder.class
Collaborator

ebruchez commented Mar 17, 2017

orbeon-embedding.jar contains these classes from slf4j-api-1.7.21.jar:

org/slf4j/ILoggerFactory.class
org/slf4j/Logger.class
org/slf4j/LoggerFactory.class
org/slf4j/event/EventRecodingLogger.class
org/slf4j/event/Level.class
org/slf4j/event/LoggingEvent.class
org/slf4j/event/SubstituteLoggingEvent.class
org/slf4j/helpers/FormattingTuple.class
org/slf4j/helpers/MarkerIgnoringBase.class
org/slf4j/helpers/MessageFormatter.class
org/slf4j/helpers/NOPLogger.class
org/slf4j/helpers/NOPLoggerFactory.class
org/slf4j/helpers/NamedLoggerBase.class
org/slf4j/helpers/SubstituteLogger.class
org/slf4j/helpers/SubstituteLoggerFactory.class
org/slf4j/helpers/Util.class
org/slf4j/spi/LocationAwareLogger.class

and these classes from slf4j-log4j12-1.7.21.jar:

org/slf4j/impl/Log4jLoggerAdapter.class
org/slf4j/impl/Log4jLoggerFactory.class
org/slf4j/impl/StaticLoggerBinder.class
@ebruchez

This comment has been minimized.

Show comment
Hide comment
@ebruchez

ebruchez Mar 17, 2017

Collaborator

Curiously, MessageFormatter is not one of them, but there is clearly potential for clashes. I think that classes from slf4j-api-1.7.21.jar should not be included in orbeon-embedding.jar.

The build already specifies:

-libraryjars orbeon-war/target/webapp/WEB-INF/lib/slf4j-api-1.7.21.jar

But that doesn't appear to work.

Collaborator

ebruchez commented Mar 17, 2017

Curiously, MessageFormatter is not one of them, but there is clearly potential for clashes. I think that classes from slf4j-api-1.7.21.jar should not be included in orbeon-embedding.jar.

The build already specifies:

-libraryjars orbeon-war/target/webapp/WEB-INF/lib/slf4j-api-1.7.21.jar

But that doesn't appear to work.

@ebruchez

This comment has been minimized.

Show comment
Hide comment
@ebruchez

ebruchez Mar 17, 2017

Collaborator

This incantation excludes the slf4j classes:

-injars      orbeon-war/target/webapp/WEB-INF/lib/(!slf4j-api-1.7.21.jar,**.jar;)
Collaborator

ebruchez commented Mar 17, 2017

This incantation excludes the slf4j classes:

-injars      orbeon-war/target/webapp/WEB-INF/lib/(!slf4j-api-1.7.21.jar,**.jar;)

@ebruchez ebruchez added this to the 2017.1 milestone Mar 18, 2017

@ebruchez

This comment has been minimized.

Show comment
Hide comment
@ebruchez

ebruchez Mar 20, 2017

Collaborator

Wondering whether we need to include slf4j-api-1.7.21.jar at all: couldn't we package/reroot that (and the other logging JARs for the proxy portlet) into the Proguarded Orbeon JAR?

Collaborator

ebruchez commented Mar 20, 2017

Wondering whether we need to include slf4j-api-1.7.21.jar at all: couldn't we package/reroot that (and the other logging JARs for the proxy portlet) into the Proguarded Orbeon JAR?

ebruchez added a commit that referenced this issue Mar 21, 2017

@ebruchez

This comment has been minimized.

Show comment
Hide comment
@ebruchez
Collaborator

ebruchez commented Apr 19, 2017

@ebruchez

This comment has been minimized.

Show comment
Hide comment
@ebruchez

ebruchez Apr 19, 2017

Collaborator

Customer above confirms the fix works for them.

Collaborator

ebruchez commented Apr 19, 2017

Customer above confirms the fix works for them.

@ebruchez ebruchez closed this Apr 24, 2017

@ebruchez ebruchez added this to Done in Orbeon Forms 2017.1 Apr 27, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment