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

Groovy 4 / Spring Boot 3 branch #13334

Open
codeconsole opened this issue Jan 4, 2024 · 14 comments
Open

Groovy 4 / Spring Boot 3 branch #13334

codeconsole opened this issue Jan 4, 2024 · 14 comments

Comments

@codeconsole
Copy link
Contributor

Feature description

Any chance you can create a Groovy 4 / Spring Boot 3 branch?

It is long overdue and it is better to have broken branch that can be worked on and contributed to.

Please merge the work you already did somewhere:
#12491

Otherwise it is just going to keep diverging with more and more conflicts otherwise.

Spring Boot 3 was released November 24, 2022.

If there are no plans to upgrade Grails to support it, please let us know and provide some sort of realistic guidance if/when it will occur.

@tubbynl
Copy link

tubbynl commented Jan 12, 2024

these are different things; updating to Spring-Boot 3 will raise the minimal Java version to 17 (and probably break stuff), the Groovy update doesn't have that.

both probably only make sense for a major version increment

@codeconsole
Copy link
Contributor Author

@tubbynl that was the point of requesting a branch. Both these things are long overdue as well as upgrading to JDK 17 (which was implied).

@rainboyan
Copy link
Contributor

We've waited too long, and maybe they've done their best. I have spent a lot of time last year going to the upgrade on my own, and after more than six months of hard work, it was all done.
Now that GoBoots has been renamed to Grace Framework and is publicly available on GitHub, I think it's time for it to be accessible to anyone who loves Grails.

@ndruet
Copy link

ndruet commented Jan 17, 2024

The most worrying points are :

@codeconsole
Copy link
Contributor Author

yeah, end of open source support for 2.x was 11/23/23 so we are running on fumes and it's been a major stress point for me.

I've been willing to help out, but there is no branch to commit to. @rainboyan what's the process to switching over to what you got?

@rainboyan
Copy link
Contributor

@codeconsole
Please follow me on Twitter/X: rainboyan, I will release a version later, v2022.0.0 is just the beginning, 2023.0.0 version will support Spring Boot 3, all the features are already done.

@codeconsole
Copy link
Contributor Author

@rainboyan were you able to get rid of all the micronaut dependencies since they are all old, don't really do anything and just make the jar file larger?

@rainboyan
Copy link
Contributor

Yes, I make Micronaut dependencies optional for the Grails application, if we do not need Micronaut as the parent application context.
Micronaut Spring has already supports more options to integrate with Spring and Spring Boot, we can choose it when we want.

@codeconsole
Copy link
Contributor Author

codeconsole commented Jan 26, 2024

Exciting 👍
7.0 🥇 https://github.com/grails/grails-core/tree/7.0.x
Groovy 4: #12491
JDK 17: #13352

@boardbloke
Copy link

boardbloke commented Mar 13, 2024

Hi @codeconsole - I seem to remember us having this conversation back in Sept on #12914 :-)

For our part - the lack of any communication of a roadmap beyond "it'll be in Grails 7" - and no comms about tentative dates etc. has made the decision for us. We're actively working on moving off Grails to vanilla Boot for a number of components.

Found this - which is helping to organise the effort - https://medium.com/whozapp/moving-from-grails-to-spring-boot-part-1-the-man-in-the-middle-strategy-8d6a68ccb25f

@rainboyan
Copy link
Contributor

@boardbloke I'm interested in migrating your project from Grails to Spring Boot, how is it going, how long has it taken, and are there any lessons you can share with us?

@boardbloke
Copy link

It's at the planning stage at the moment. Waiting for available resources. But I can probably post more about it when we get into it.

The plan is to attack it like the article above suggests. Do it in stages, replace gorm and config first, then services then controllers. We have very few views so not much to do there. We plan to keep using groovy in boot to avoid significant rewrites of class implementations.

I suspect the hardest part will be unit test translation

@codeconsole
Copy link
Contributor Author

@boardbloke

If you are interested in using gsp, I would take a look at https://github.com/grails/grails-boot
I think gorm should be separable as well

@rainboyan
Copy link
Contributor

@codeconsole
There is also a Grace version used to demonstrate how to use GSP with Spring Boot, https://github.com/grace-guides/gs-spring-boot-gsp

In the Grace version, grace-boot is just a Spring Boot starter which can load any plugins include GSP, Hibernate.
Grails should not create a separate project contains Spring AutoConfiguration for every plugin.

If you only want use Grace plugins in Spring Boot, you can check out the other guide: https://github.com/grace-guides/gs-spring-boot.
In addition to that, Grace 2020.1.0 introduces Dynamic Modules to create modular application and plugins.

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

5 participants