Skip to content

Add separate autoreconfiguration for spring-boot with java-cfenv #779

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

Closed
dyroberts opened this issue Feb 10, 2020 · 5 comments
Closed

Add separate autoreconfiguration for spring-boot with java-cfenv #779

dyroberts opened this issue Feb 10, 2020 · 5 comments
Assignees
Labels
dependencies Pull requests that update a dependency file enhancement

Comments

@dyroberts
Copy link

In order to preserve existing behaviour for non-boot spring users, create a separate autoreconfiguration jar, used only for boot apps, that uses java-cfenv in place of spring-cloud-connector. A new framework definition at /lib/java_buildpack/framework/spring_boot_auto_reconfiguration.rb would be added.

Update https://github.com/cloudfoundry/java-buildpack/blob/master/lib/java_buildpack/framework/spring_auto_reconfiguration.rb#L43 to ignore boot apps.

@dyroberts
Copy link
Author

dyroberts commented Feb 10, 2020

@nebhale I'd be happy to take a crack at a contribution here, if this idea actually seems like a good one to you. :)

@nebhale
Copy link
Contributor

nebhale commented Feb 10, 2020

Yeah, why don't you start with a PR to https://github.com/cloudfoundry/java-buildpack-auto-reconfiguration as either another JAR in the project, or a separate branch for the repo, and we'll go from there.

@SeifMostafa
Copy link

Hello, Still available?

@dmikusa
Copy link
Contributor

dmikusa commented Mar 31, 2022

We announced the intended path forward here on Slack recently, sorry, I should have posted it here as well.

The CF JBP has Spring Auto Reconfiguration (SAR). Spring Auto Reconfiguration uses Spring Cloud Connectors (SCC). SCC has been deprecated for a long time.

We also generally recommend explicit configuration, i.e. directly using java-cfenv, as opposed to relying on the SAR. SAR tends to provide good demo flash, but it's not practical in production usage (too much magic, difficult to debug when something goes wrong, etc...).

For these reasons, we are planning to deprecate and over a slow period of time eventually remove SAR and by-proxy SCC. The future recommendation will be explicit configuration in your application either manually or using a tool like java-cfenv.

Please let me know if you @SeifMostafa or anyone else has feedback on this plan. We are not scheduled to implement it quite yet, so there's still time to discuss. Thanks.

@dmikusa
Copy link
Contributor

dmikusa commented May 27, 2022

This deprecation has begun with version 4.49. See the CloudFoundry Docs for usage & migration instructions.

Closing this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file enhancement
Projects
None yet
Development

No branches or pull requests

4 participants