Q:

Using Spring Cloud Foundry project with a plain java web project

We have a plain java web project with some servlets, some JPAs and our logic. 
We want to move to Cloud Foundry .  I have learnt that Spring boot comes up with a lot of nice cloud foundry features out of the box like support for CF environment variables parsing, CF service broker API implementation. 
Now i don't want to move to Spring MVC since we already have the application running with plain java web framework. 
Can i still use Spring cloud foundry related projects to take advantage of Cloud Foundry related features like parsing of env variables ? 
Are they internally dependent on Spring core, spring mvc projects ?  Will including the Spring Cloud Foundry project bloat my total deployable war size due to all internal spring dependencies. 
Best Regards,
Saurav

A:

A lot of this depends on exactly which features you want to use.   The awesomeness you get from Spring Boot requires Spring & so it won't transfer to your app unless you embrace & use Spring.   The same goes for Spring Cloud. 
You specifically mentioned parsing service information from environment variables (i.e. VCAP_SERVICES & VCAP_APPLICATION).   This is the one exception that comes to mind.   You can use Spring Cloud Connectors in a limited capacity without Spring.   See this link for details.   It's not as full-featured as what you'd get if you were using Spring & Spring Boot, but it will give you some help. 
If you don't want to use SCC, you can always parse the environment variables yourself and use the data.   It's conceptually very easy.   Both VCAP_APPLICATION & VCAP_SERVICES are environment variables and the value is a JSON blob so all you need to do is parse the JSON and locate the information that you need. 
Hope that helps!