How to build Spring Cloud Stream JMS ActiveMQ - spring

I recently discovered that Spring has an alpha version of a spring cloud stream provider that leverages jms (ActiveMQ virtual destinations under the hood). This is absolutely fascinating and I want to test it out. I am having difficulty finding a snapshot of the dependencies I can use or being able to pull and build the correct github projects so I have the dependencies in my local repository. I would appreciate any assistance on this.
http://activemq.apache.org/amqp.html
https://github.com/spring-cloud/spring-cloud-stream-binder-jms
https://github.com/spring-cloud/spring-cloud-stream-binder-jms/tree/master/spring-cloud-stream-binder-jms-activemq

We are in the process of restructuring the repositories for the JMS binder and we don't have the CI processes that build the necessary artifacts yet (should be there in by early next week).
For now, you can try building and installing https://github.com/spring-cloud/spring-cloud-stream-binder-jms (which also contains the ActiveMQ support). We'll decide later if we need a separate repository for ActiveMQ.

Related

GitLab CI: Spring boot dependecy on another project

I have a clustered application architecture, where 3 of my primary services make use of a dependency artifact (lets call it commons) that contains the modal files and other utils used by other 3 services.
Presently, I have all the 3 spring boot applications deployed on k8s through Gitlab CI via artifactory for image management.
Now, each time I make changes to my commons service, I have to change the version of the commons in pom.xml(so that it doesn't conflict with the previous artifactory image) and also change the pom versions of my other 3 services that depend on this new version and push all the 4 (first push commons so that the new build image is available in artifactory, and then the other 3) services.
Is there a better way to manage this. I would have preferred if, my 3 services where able to fetch the latest common version and add it to my pom version
This is currently supported in Reliza Hub (disclaimer: I'm developing the project).
The workflow to get latest release is documented here (see workflow 2.Get Latest Release Of A Project Or Product).
Idea is the following:
you define project for your Shared Library and configure from GitLab CI to automatically stream build metadata to Reliza Hub on every build using Reliza Client.
Automatic versioning can also be maintained via Reliza Hub (meaning that Hub would increment versions for you on every build based on your chosen versioning schema) - you need to use getversion command of Reliza Client for that.
You can then use this automatic version increments to update version in your pom.xml at build time. So this process will be fully automated.
Once that is done, in your CI pipelines for each of the 3 dependent services, you include call to Reliza Hub using getlatestrelease command of Reliza Client for your shared library. This call will return you back all metadata for the latest release of shared library, including its version.
You can then plug this version into pom files of your dependent services.
Hope this helps.

PACT: java-maven

I need few answer for my doubt:
Pact-mock-service Vs pact-jvm-server, is both are same? Pls describe this.
Am implementing the PACT in java-maven
I can able to run this:
https://github.com/anha1/microservices-pact-maven
https://github.com/warmuuh/pactbroker-maven-plugin
Help me to understand this with pact-mock-service and pact-jvm-server
Pact-mock-service is a general mock server built into the pact libraries to support mocking out the other dependency in an integration during a consumer test. If you use any of the consumer test support libraries, you do not need to use it directly.
pact-jvm-server is a controllable server that bundles the Pact-mock-service and allows you to setup and tear down mock servers via HTTP requests. It exists for people who can not,or do not wish to use the consumer test support libraries.
For people using Maven, there is a plugin provided as part of the pact-jvm project that can do provider verification tests and publish to a pact broker. For the consumer tests, they just run as JUnit tests so you don't need any Maven specific plugin.
Of the two links you posted, the first is an example project using a spring-boot application, and the second is a maven plugin that provides publishing to a pact broker only.

Source for hermes JMS

It looks like Hermes JMS is no longer maintained. I was wondering if the source is available anywhere. It appears that only the jar files are available sourceforge. We are planning on using SoapUI to test some XML services exposed through ActiveMQ. We are concerned that we will painting ourselves into a corner if there is neither active maintenance or source. I looked for alternatives to Hermes.
It seems that JMSToolbox may be a long term solution, but the support for SoapUI and ActiveMQ have not matured yet. Any suggestions for other solutions would also be appreciated.
You could use Apache Camel (http://camel.apache.org) to write a test harness. It has good support for testing & ActiveMQ.

Spring XD on YARN: ver 1.2.1 direct binding support for kafka source

Spring XD on YARN: ver 1.2.1 direct binding support for kafka source.
1.I know this is not supported yet(as of ver 1.3.0), any definite date/ver would help our project schedule ?
2.This direct binding for kafka source support is very critical for our project. We are in a situation to totally abandon Spring XD YARN in our project just because of this.
Trying to do
stream create --name directkafkatohdfs --definition "kafka | hdfs"
stream deploy directkafkatohdfs --properties "module.*.count=0"
Hitting the exception "must be a positive number. 0-count kafka sources are not currently supported"
I just want to eliminate the use of message bus/transport(redis/kafka/rabbitMQ) and want to have a direct binding of source(kafka) and sink(sink) in the same YARN container.
1.I know this is not supported yet(as of ver 1.3.0), any definite date/ver would help our project schedule.
2.This direct binding for kafka source support is very critical for our project. We are in a situation to totally abandon Spring XD YARN in our project just because of this.
Thanks
Satish Srinivasan
satsrinister#gmail.com
Thanks for the interest in Spring XD :).
For Spring XD 1.x, we suggest using composition instead of direct binding with the Kafka bus - or, in your case, the Kafka source. However, apart from that, in Spring XD 1.x it is not possible to create an entire stream without at least one hop over the bus (regardless of the type of bus or modules being used).
We are addressing direct binding (including support for entire directly bound streams) as part of Spring Cloud Data Flow (http://cloud.spring.io/spring-cloud-dataflow/) - which is the next evolution of Spring XD. We are intending to support it as a specific configuration option, rather than as a side-effect of zero-count modules. From an end-user perspective, SCDF supports the same DSL as Spring XD (with minor variations) and has the same administration UI, and definitely supports YARN, so it should be a fairly seamless transition. I would suggest starting to take a look at that. The upcoming 1.0.0.M2 release of Spring Cloud Data Flow will not support direct binding via DSL yet, but the intent is to support it in the final release which is currently planned for Q1 2016.

Flink for embedded stream processing in OSGi

I would like to use Apache Flink to process event inside an application.
My tests on a standalone JVM worked reasonably well though flink is a really big dependency.
I also tried to get it running in OSGi but gave up for now because of the many dependencies.
So my question is:
How small can I make Flink. I currently tried with the maven dependency on flink-streaming-java.
Unfortunately this depends on or embeds (only listing the questionable ones):
flink-shaded-hadoop2
kryo
zookeeper
netty
jetty
apache http client
apache http core
scala
akka
jackson
It also looks like several jars embed the same libs again and again. Like some google libs and asm.
So is there some way to get a slimmmer version of flink for local usage that does not depend on so many libs?
Many of the dependencies are required for Apache Flink's primary use-cases namely, distributed stream and batch processing.
Zookeeper for high-availability in case of (process) failures
Netty for data network transfer
Jetty for monitoring via REST API and web dashboard
Akka (and transitively Scala) for coordination of distributed processes
Most of these libraries are tightly coupled with the system and cannot be easily switched off or excluded.
I am sorry, there is no stripped down version for local stream processing.

Resources