spring cloud dataflow compatibilty with base cloud foundry versions - spring

I am reading this release announcement for Spring Cloud dataflow.
https://spring.io/blog/2017/02/22/spring-cloud-data-flow-for-cloud-foundry-1-1-1-maintenance-release-available
I am wondering if we need a minimum version of cloud foundry for successfully running spring cloud data applications.. Given that this stream of work is actually targeted for cloud based environments, i think they should also mention the minimum base Cloud Foundry versions that can support them.
Does this require an inter-process communication that's being made available in latest cloud foundry versions
https://www.cloudfoundry.org/meet-new-container-networking-stack-cloud-foundry/
https://content.pivotal.io/blog/building-spring-microservices-with-cloud-foundrys-new-container-networking-stack
I do see the mention of PCF version compatibility for Spring Cloud Tasks
http://docs.spring.io/spring-cloud-dataflow-server-cloudfoundry/docs/current-SNAPSHOT/reference/htmlsingle/#_version_compatibility
But i haven't been able to find the Base cloud foundry version that supports the features of Spring Cloud Data Flow in general or per feature compatibility breakdown with Cloud foundry versions. We are running IBM Bluemix in our company and are upgrading to the cf version that supports Deigo architecture (vs the current DEA) - don't know the exact version of CF will that be.
If we know the Spring Cloud Data flow feature compatibility with specific Cloud Foundry versions we can decide our adoption strategy accordingly.

Please refer to PCF vs. OSS CF compatibility matrix from the project site.
This matrix captures the baseline OSS CF release required to run SCDF on the particular PCF versions. You could further dive into respective PCF release-notes to double check other OSS components (eg., CAPI) for more granular compatibility measurements.
Tasks in SCDF, in particular, is GA'd with PCF 1.9; so if you're planning to use it, you'd have to be at least on OSS CF 246 release.

Related

Can we deploy spring micro services on AWS Lambda?

Is it recommended to deploy spring micro services on Lambda. I have recently deployed a sample spring boot app returning a sample data from AWS RDS Oracle DB on Lambda, Just analyzing the possibility if we could deploy two micro services in different Lambda functions and configure them using API gateway.
I am entirely new to it and trying to understand if Lambda can really support micro services patterns like Service discovery/Circuit breaker or Saga patterns if I deploy two or more services on different lambda functions. Would Lambda be used for such scenarios in Real Time ?
Can anyone help me if there would be limitations other than package/payload size limit or timeout limitations ?
Thanks in Advance
If you use java for serverless application like AWS lambdas I would recommend for looking a framework which supports Ahead-of-Time compilation which will boost a lot your application start. If your application is not bit it will be very easy to be rewritten with Micronaut (very similar to Spring boot development)
For instance have a look at Micronaut, Quarkus using with Graalvm. Spring Boot is not the best option using with directly with AWS lambdas, it is big package size + really a lot of initial time, not good for API services.
Target of max package sizes of 25 MB for small cold start with adjustable memory starting from 256MB, with spring boot this is not doable.
In case you are referring to Spring Boot Cloud Functions that's exactly they were made for.
Google Cloud Functions already have an Alpha product for running Java functions.
AWS Lambda seems to have support for this as well.
In case you simply wrote a Spring Boot app with embedded Tomcat that you packaged in a Docker container which you're spinning up on demand, beware that cold start can be an issue, especially with the overhead of the Tomcat.

How do people host Spring Boot apps with WebFlux on Reactor Netty in production?

I know it's a vague question but that's because I am not clear enough on what people are doing to ask anything more specific. I currently run my own apps with the embedded reactor netty server for development and basically push the embedded server inside a jar to cloud foundry to run the embedded server in production.
What are the other ways out there to set up a production environment for reactive reactor netty apps that people are using, or any documentation you might have seen?
I'm no sure that there is any difference between hosting the reactive spring-webflux application and regular applications.
Spring boot creates a jar with everything bundled inside (netty or more old-school tomcat) - it doesn't matter.
Then you can take this and run it "as is" on your server (on-premise, cloud ec2 style whatever you have, this really depends on your organization) directly with java -jar app.jar
Or, if you have more advanced needs/setup:
"Containerize" the application and create a docker (usually, although there are alternatives) image that runs the spring boot application. and then deploy it on kubernetes cluster, for example. At this point you should really consult with your DevOps people so that they'll tell you what is the way of deployment in your organization.
Besides kubernetes cluster there are many other alternatives:
- cloud provider specific solutions, like ECS or Fargate in amazon AWS
- Docker Swarm to name a few
All these solutions are pretty advanced, allow auto-scaling, advanced liveness monitoring and so forth. As an organization you usually pick the one that meets your needs

Running Apache Ignite Cluster on Pivotal Cloud Foundry environment

I am trying to build a Apache Ignite Cluster on Pivotal Cloud Foundry environment as follows.
Created a Spring-Boot app that starts a new Ignite node, Deployed it on on Cloud Foundry ( ex. Ignite-Node1)
Created another Spring-Boot app which will also starts a new Ignite node, Deployed it on on Cloud Foundry ( ex. Ignite-Node2)
Now, even though both the apps are running in a same CloudFoundry Env, they are not forming the Ignite Cluster as they are not able to discover each other.
Apache Ignite documentation provides examle configuration details for AWS, Google cloud , however there are no examples for Pivotal Cloud Foundry.
Can somebody provide me with an example configuration on how to get the Ignite Cluster running on Cloud Foundry environment.
Srini
Container-to-container (app-to-app) networking is not supported on Pivotal Cloud Foundry, although it is possible to enable.
By default all communications must be made 'via the front door' through Cloud Foundry's router, either via HTTP or on a TCP port. One cannot choose which instance of an application to hit. This is due to change with the Container Networking initiative, the progress of which you can check on Pivotal Tracker. There is a detailed design document which is publicly available.
An alternative approach which is more appropriate for data services is to deploy them using BOSH. As a PCF user, you may wish to consider creating a PCF Tile for Apache Ignite.
My company has been helping Hazelcast create a PCF Tile that will create dedicated-VM clusters on-demand. Perhaps you could consider making use of Hazelcast instead?

Reporting statistics in Spring Web Flow

We have an enterprise application using Spring 3.2.8 and Spring Web Flow 2.3.3 deployed on the Websphere 8 server. We wish to report statistics like no. of incomplete flows, the state at which user terminate the flow, time spent at individual states etc. We thought of using Spring Instrumentation. However, could not find instrumentation jar package for Spring 3.2 and Webflow 2.3. Where can I find the complete distribution of Spring 3.2 instrumentation jars? Or which other tool can I use for my purpose with Websphere 8? Please help.
I just did a google search. If I read the webpage correctly, instrumented spring is a paid product.
From http://static.springsource.com/projects/instrumentation/index.html:
Instrumented Spring Framework, Web Services, Web Flow, and Security are available as part of a tc Server Spring Edition 2.x subscription or evaluation, which includes integration with Hyperic HQ. Instrumented Spring products are also available to Spring Enterprise subscribers.

what is Cloud Foundry & spring

I am trying to get the idea of cloud serves but didn't get the point of that.
Dose it can replace a server for the app?
what is the purpose of it?
I have an android app and I what to get info from the server can it be done with Cloud Foundry and what is spring and how it connects to Cloud Foundry.
If you can give me link of how to communicate android app with Cloud Foundry
thanks a lot!
CloudFoundry's an open-source PaaS (github.com/cloudfoundry). It commoditizes the stack - that is, in practical terms, it makes it dead simple to get things like databases (MySQL, PostgreSQL, Redis, MongoDB), messaging (RabbitMQ), and web servers (Tomcat) up and running quickly. Whereas clouds like AWS let you spin up CPUs and hard disks and a stock OS install, a PaaS like CloudFoundry lets you spin up infrastructure, like message brokers, databases, and web servers and routers. So, yes, it replaces a server (or, often more importantly, it can stand in for 1000 servers on-demand). That's the obvious part.
CloudFoundry itself is open source, so unlike other PaaS solutions, by building on top of CF you're not locked into CF. You can later decide to run the cloud locally on your own datacenter, or on some other CloudFoundry provider (CloudFoundry.com is just one provider of the CloudFoundry software. Just as you can easily re-target a git repisotry to have it point to any remote repository using the git command line tool, you can re-target the CloudFoundry 'vmc' command line tool to point to a different CloudFoundry install.
Spring's a development framework in Java. It's not the only way to consume CF, but I personally think it's quite nice. CF exposes a lot of different technologies for the eager technologist and Spring provides the only comprehensive library set that can handle all those options. Learn one Spring library and the others will feel simialar, and so it's more natural to get started with a new API and technology. In the way that APIs designed with idiomatic Python APIs are said to be "Pythonic," Spring's APIs are cohesive and work nicely together. However, if Java's not your cup of tea (punny!), then that's OK too. CloudFoundry supports Ruby on Rails, Scala, Node.js, and other cloudfoundry providers support alternatives (Stacato supports Python, AppFog supports PHP, etc.)
For a quick example demonstrating how to get started with Spring, and the SpringSource Tool Suite, and a development virtual machine for CloudFoundry (so you can develop locally and quickly), check out this blog (and, particularly, the video embedded therein): http://blog.springsource.com/2011/08/24/micro-cloud-foundry-for-spring-developers/
The Springsource team has been doing some interesting work this year integrating a variety of Spring projects with Cloud Foundry.
With the rising popularity of microservices, many of the Spring projects are proving to be useful not only for quickly developing these smaller, lighter weight services, but also for easily incorporating some of the projects from Netflix OSS that implement patterns for making them industrial strength even at web scale.
A few related links:
The latest Cloud Foundry Java buildpacks include support for Spring
Boot and Spring Auto-reconfig (https://github.com/cloudfoundry/java-buildpack/releases).
The CF docs
contain an example on deploying Spring Boot apps to Cloud Foundry or
Heroku
The new Spring Cloud project will "Integrate your application with Pivotal Cloudfoundry. Makes it easy to implement SSO and OAuth2 protected resources, and also to create a Cloudfoundry service broker."
I look forward to seeing more of the results from the collaboration between the Cloud Foundry and Spring teams. One evidence of this is a recent tweet from Pivotal's James Watters "As the Microservices trends take off its pretty amazing to have the world's leading lightwieght #springframework on same team as CF."

Resources