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 Validation Support #9844

Open
dodgex opened this issue Jul 15, 2023 · 3 comments
Open

Jakarta Validation Support #9844

dodgex opened this issue Jul 15, 2023 · 3 comments

Comments

@dodgex
Copy link
Contributor

dodgex commented Jul 15, 2023

In addition to Jakarta Servlet Support discussed in #9727 and worked on in niloc132#3 I think Jakarta Validation 3.0 should be supported too.

While the main part of validation is deprecated as stated on its documentation there are also some validation related bits in requestfactory where we are especially interested in, as missing Jakarta Support prevents us from upgrading our GWT projects to Spring Boot 3

In the context of the above linked PR I already started some work on this. As of now the changes made so far can be found here. These changes have not yet been tested.

@niloc132 mentioned that there are already 3rd party projects that provide client side validation. He named https://gitlab.com/ManfredTremmel/gwt-bean-validators but with the note that it looks like it also only supports javax.validation, I found that they have a 2.0.x release with jakarta support (related issue and branch)

I have no idea how the deprecation and removal policy in GWT is. But as the code does not mark the API as @Deprecated I assume removing would not be an option.

For now I will continue to test the changes I made so far and apply fixes where necessary. While my initial focuse here might be requestfactory, I am willing to also test the client side validation part too.

@dodgex
Copy link
Contributor Author

dodgex commented Jul 22, 2023

I have created a new branch https://github.com/dodgex/gwt/tree/9844-jakarta-validation-support for this. The branch is based on the work done in PR #9845.

After updating the branch to the changes in that PR, i successfully tested the validation part used by requestfactory in a small test project.

For the test project, currently de.knightsoft-net:gwt-time-dummy in a 2.x version is required as it provides (dummy) emulation classes for java.time.Clock required by jakarta validation 3.0 stuff in com.google.gwt.validation.client.

@niloc132
Copy link
Member

Checking in for any update here - should we proceed with #9845, or do you think you have a proposal ready to discuss?

@dodgex
Copy link
Contributor Author

dodgex commented Nov 14, 2023

After my last comment I put some more work into this but came to the realization, that upgrading the GWT Validation Module to Jakarta is way more complex than i could have expected. There is quiet a lot of javax.validation and hibernate-validator code in the GWT codebase that would need to be upgraded/adapted/replaced with thier jakarta.validation counter parts and a current hibernate-validator version. Unfortunately I do not know hiberbnate-validator internals and gwt's requirements to it good enough.

This, plus the fact that the validation module is considered unmaintained for quiet some time, plus the fact that for the last 1.5-2 month my work priorities where switched to other projects and also the fact that we do not use gwt-validation resulted in delay/stop of the work unfortunately.

Only scince like mid last week I am again working on pushing the upgrade of our dependencies and stuff.


Long Story Short: For now we should proceed with #9845 to provide jakarta-servlet support. regarding validation there has to be a decission if it will be maintained/upgraded for an upcoming release or whatever else happens with it.

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

2 participants