SAP / cf-java-logging-support

The Java Logging Support for Cloud Foundry supports the creation of structured log messages and the collection of request metrics
Apache License 2.0
76 stars 46 forks source link

Add a new servlet logging module supporting jakarta.* packages. #153

Closed mofterdinger closed 1 year ago

mofterdinger commented 1 year ago

The latest version 3.6.3 of cf-java-logging-support-servlet is not compatible with the Jakarta Servlet API. The Jakarta Servlet API is also used by the new Spring Framework 6. This PR adds a new module cf-java-logging-support-servlet-jakarta which supports the jakarta servlet API. This PR copies the source and test-source code of module cf-java-logging-support-servlet to the new module. Then it replaces the packages javax.* with jakarta.* and performs the tests.

cla-assistant[bot] commented 1 year ago

CLA assistant check
All committers have signed the CLA.

mofterdinger commented 1 year ago

I'm not able to sign the CLA, I get this error:

Error
There is no CLA to sign for SAP/cf-java-logging-support
(Bad credentials)
KarstenSchnitter commented 1 year ago

Thanks, for providing this change. I will clarify, what the problem with the CLA is. Members of the SAP Github organisation should have the CLA signed that way.

Mazhar0910 commented 1 year ago

@KarstenSchnitter @mofterdinger , Thanks for considering the support for jakarta.* packages. I am in a process to migrate our app to Spring 3.x, however we make use of cf java logging libraries.

May be i would like to know by when we can expect this change to be available into SAP Internal Artifactory ?

Regards, Mazhar

KarstenSchnitter commented 1 year ago

@Mazhar0910 I am currently clarifying the usage of the additional Maven plugin. This is a prerequisite for a merge of this change. It would be very beneficial if the first Maven build after checkout was succeeded, as well. The build issue I could work-around for now, though. I still have to check, what kind of artefacts will be uploaded to Maven Central. Still, I do not think, these issues will take to long to clarify or mitigate. I estimate a new library version containing this change in early March.

KarstenSchnitter commented 1 year ago

Currently mvn test -Dtest=CustomFilterTest is failing, when executed in the new module. I think, it does not pick up the logging configuration in logback-test.xml. The log output does not match the output from the original test in cf-java-logging-support. Since the test validates this output, the test currently fails.

aamotharald commented 1 year ago

Hi colleagues, Hi @mofterdinger ,

please consider my PR: https://github.com/mofterdinger/cf-java-logging-support/pull/1

It is using a plugin that needs no extra license checking. Also the wrong logback-test.xml file location got fixed. Tests execute green on my machine ..

mofterdinger commented 1 year ago

@aamotharald Thanks for your PR, with your changes the test no longer fail :-). From my point of view it looks good.

KarstenSchnitter commented 1 year ago

Once more, thanks for the contribution. I will go over the dependencies of the entire project and create a new release afterwards.