Skip to content
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

Jakarta Servlet 5.0 #610

Closed
halset opened this issue Dec 17, 2020 · 10 comments
Closed

Jakarta Servlet 5.0 #610

halset opened this issue Dec 17, 2020 · 10 comments

Comments

@halset
Copy link

halset commented Dec 17, 2020

Looks like servlet-api are moving to jakarta package names. Any plans for upgrading client_java to support it? It will probably take several years before everyone is over, so perhaps we need parallel releases?

https://jakarta.ee/specifications/servlet/5.0/

@brian-brazil
Copy link
Contributor

What would it involve? Is there something in there that would break existing users of it? What would be the benefits? This library supports back to Java 6, so that has to be kept working.

@halset
Copy link
Author

halset commented Dec 17, 2020

There are new package names for the servlet stuff. The new API uses jakarta.servlet instead of javax.servlet.

Perhaps copying over simpleclient_servlet to simpleclient_servlet-servetletapi5 and let the user choose?

Or people can just create their own copy of the MetricsServlet using the new API. Luckily, it is very small.

@brian-brazil
Copy link
Contributor

If it's just a rename then I would presume that there's an adapter out there for it. We already have quite a few different HTTP exposition options, i'd rather not add more if we don't have to.

@halset
Copy link
Author

halset commented Dec 17, 2020

Okay. I do not think it is just a rename, but there are not other changes for MetricsServlet at least. Not fixing this here is fine with me as I can just have my own copy of MetricsServlet with this change locally in each project. This is quite new to me as I just discovered this by reading up on jetty 10 and jetty 11.

@brian-brazil
Copy link
Contributor

I'd recommend against copying, as this code will be changing in the near future to handle OpenMetrics negotiation.

@lfgod
Copy link

lfgod commented Dec 18, 2020

We have a similar situation in our project as we are moving from javax.* (Jetty 9.x ) to jakarta.* (Jetty 11) . We use the simpleclient_servlet jar which use javax.. The quick solution for us would be to copy and refactor the import statements to use jakarta. instead of javax.*. However we would prefer to use a new simpleclient_servlet_jakarta. It would be great if we can have client with jakarta support. Thanks in adavance.

@mmadoo
Copy link

mmadoo commented Apr 2, 2021

I have created the pull request #647 for this.

@jonathanl-telenav
Copy link

Is there any chance we could get this PR merged? Thanks -- Jon

@fstab
Copy link
Member

fstab commented Nov 12, 2022

Isn't it this one? Or am I confusing things? https://github.com/prometheus/client_java/tree/main/simpleclient_servlet_jakarta

@jonathanl-telenav
Copy link

thanks!

@fstab fstab closed this as completed Nov 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants