Spring Team
Josh Long

Josh Long

Spring Developer Advocate

an aisle seat or San Francisco, CA

Josh Long is the Spring Developer Advocate. Josh is the lead author on Apress’ Spring Recipes, 2nd Edition, the O'Reilly "Pro Spring Roo" book, the Pearson "Livelessons for Spring" and a committer on several Spring projects and the Activiti BPMN framework. When he’s not hacking on code, he can be found at the local Java User Group or at the local coffee shop. Josh likes solutions that push the boundaries of the technologies that enable them. Josh's interests include big-data, mobile, REST, NoSQL and integration. He blogs on the Spring blog and [on his personal blog](http://joshlong.com).
Blog Posts by Josh Long

This Week in Spring - March 24th, 2015

Welcome to another installment of This Week in Spring! This week, I’m in São Paulo, Brazil, where I presented a workshop on building cloud-native applications - specifically microservices - with Spring Boot, Spring Cloud and Cloud Foundry (via Pivotal Web Services).

Read more...

Using Google Protocol Buffers with Spring MVC-based REST Services

This week I’m in São Paulo, Brazil presenting at QCon SP. I had an interesting discussion with someone who loves Spring’s REST stack, but wondered if there was something more efficient than plain-ol’ JSON. Indeed, there is! I often get asked about Spring’s support for high-speed binary based encoding of messages. Spring’s long supported RPC encoding with the likes of Hessian, Burlap, etc., and Spring Framework 4.1 introduced support for Google Protocol Buffers which can be used with REST services as well.

Read more...

This Week in Spring - March 17th, 2015

Welcome to another installment of This Week in Spring! This week I’ve been busily preparin for a workshop I’ll be giving at QCon São Paulo next week. If you’re at the show, I hope you’ll come out to say hi, ask questions and we’ll talk Spring and Cloud Foundry. Obrigado!

  1. The replay on my humble webinar introducing Spring Session is online, check it out!
  2. Janne Valkealahti has just announced the latest release of Spring Security Kerberos 1.0.0.RC1, packed with new features and now - at long last!! - near GA! Go Janne and team, go!
  3. Spring and Groovy & Grails Tool Suite lead Martin Lippert just announced STS and GGTS 3.6.4.
  4. I put together a post on getting started with Spring Data Couchbase
  5. Spring XD ninjas Marius Bogoevici and Dr. Mark Pollack are going to be giving a webinar on April 28th that introduces using Spring XD and Apache Kafka to create reactive data-pipelines.
  6. I’ll be giving a webinar on April 21st that introduces how to make smart service-to-service calls with Spring Cloud.
  7. This Week’s SpringOne2GX 2014 replays are out! Check out Asychronous design with Spring and RTI: 1M events per second, Building a Recommendation Engine with Spring and Hadoop, and author Peter Harrington’s Become a data-driven Organization with Machine Learning.
  8. Curious about the why Pivotal considers iteself at the nexus of Apps, Data and Cloud? Check out Matt Stine’s SpringOne2GX replay for the answer.
  9. the Vaadin web framework now has official support for Spring and Spring Boot. This support is the official stamping of the code that Peter Holmst and I started, so I couldn’t be more excited to see how far it’s come and to see it finally graduate to an officially supported module.
  10. Intellij 14.1 is packed with all sorts of amazing Spring Boot goodness! Check out this post from JetBrain’s Yann Cébron on some of the amazing new features and be sure to register for this March webinar in March with our own Stéphane Nicoll and Yann covering some of these amazing features!
  11. Heroku have put together a nice writeup on using Spring Cloud to build cloud native applications on Heroku
  12. Check out this video of Spring framework lead Juergen Hoeller recorded from Voxxed Days Austria
  13. Alex Williams put together a nice post on using Apache Brooklyn - an application blueprint and management system which supports a wide range of software and services in the cloud - to automate Cloud Foundry with their custom service broker. The idea is simple: a Cloud Foundry service broker talks to backend services (it’s what drives the flow from cf services and cf create-service). Apache Brooklyn exposed as a service broker in this way is powerful; you only need one broker to expose the catalog of Brooklyn blueprints.
  14. Our pal Matt Stine just published a free e-book for O’Reilly on building cloud-native architectures.
  15. There are a few case studies on the Pivotal blog today. First, Jarrod Vawdrey’s post on using data-science to predict TV viewer behavior and formulate a hit TV show is awesome
  16. Dwayne Forde has put together a nice case study on How Pivotal Performs Continuous Delivery of Mobile Services.
Read more...

Getting Started with Couchbase and Spring Data Couchbase

This blog was inspired by a talk that Laurent Doguin, a developer advocate over at Couchbase, and I gave at Couchbase Connect last year. Merci Laurent!

This is a demo of the Spring Data Couchbase integration. From the project page, Spring Data Couchbase is:

The Spring Data Couchbase project provides integration with the Couchbase Server database. Key functional areas of Spring Data Couchbase are a POJO centric model for interacting with Couchbase Buckets and easily writing a Repository style data access layer.

Read more...

This Week in Spring - March 10, 2015

Welcome to another installment of This Week in Spring! This week I am at DevNexus in Atlanta, GA along with a handful of Spring team members and Spring community luminaries. I’ll be presenting a talk on getting started with Spring Boot and I hope you’ll join me, or one of the many other talks on Spring team:

Read more...

Getting started with Activiti and Spring Boot

This post is a guest post by Activiti co-founder and community member Joram Barrez (@jbarrez) who works for Alfresco. Thanks Joram! I’d like to see more of these community guest posts, so - as usual - don’t hesitate to ping me (@starbuxman) with ideas and contributions! -Josh


Introduction

Activiti is an Apache-licensed business process management (BPM) engine. Such an engine has as core goal to take a process definition comprised of human tasks and service calls and execute those in a certain order, while exposing various API’s to start, manage and query data about process instances for that definition. Contrary to many of its competitors, Activiti is lightweight and integrates easily with any Java technology or project. All that, and it works at any scale - from just a few dozen to many thousands or even millions of process executions.

Read more...

This Week in Spring - March 3, 2015

Welcome to another installment of This Week in Spring! This week I’m in Kansas City, Kansas, hanging out with my pal and Spring Security lead Rob Winch. This week, I’m speaking at the local User Group and the Spring User Group, and I’ll be talking to Cerner and a few other large businesses about Spring, Spring Boot and Spring Cloud.

As usual, we’ve got a lot of great stuff to talk about, so let’s go to it!

  1. Spring Boot co-lead Phil Webb just announced Spring Boot 1.2.2 and Spring Boot 1.1.11. Both releases are recommended upgrades, and Spring Boot 1.2.2 even includes new support for the Mustache templating library. Nice!
  2. Check out John Hann’s SpringOne2GX 2014 talk, introducing Rave.js, which brings Spring Boot-concepts to JavaScript
  3. I put together a blog on building applications that use the Servlet HTTP session in a scalable manner and in a portable way - from application server, web server, and cloud - with ease.
  4. Chris Beams’s SpringOne2GX 2014 talk, The Revolution will not be Centralized is now available online.
  5. Want to learn more about caching in Spring? Check out this replay of Michael Plod’s SpringOne2GX 2014 talk introducing advanced caching improvements in Spring framework
  6. Brian Clozel and Rossen Stoyanchev’s SpringOne2GX 2014 talk introducing resource handling in Spring MVC 4.1 is awesome check it out!
  7. Spring Security lead Rob Winch just announced Spring Security 4.0 RC2 which includes, among other things, support for websockets! Check it out and try the bits out now!
  8. Rob Winch also just announced Spring Security 3.2.6 which improves the Java configuratino and Spring Boot integration, so check it out!
  9. This isn’t specific to Spring, or any tech, per se, but it’s inspiring an inspiring at how machine learning used to predict clinical response to anti-cancer drugs
  10. Speaking of Rob Winch, and education ninja Ken Kreuger, check out their SpringOne2GX 2014 talk on integration testing, now available on InfoQ.
  11. Alex Zhitnitsky put together a nice comparison of Spring Boot and Dropwizard
  12. Check out these Spring Cloud PaaS connectors for IBM’s Bluemix, which is based on Cloud Foundry
  13. Rahman Usta put together an amazing cool demo of a web-based SSH client (with Spring Boot in the backend)
  14. This video demonstrates how to use Codeenvy and Spring Boot
Read more...

The Portable, Cloud-Ready HTTP Session

A Framework for all Seasons (and Architectures)

Spring walks an interesting line. It provides a lot of value no matter where you run it, and - because it’s built on dependency injection layer - it offers a natural piece of indirection between the underlying layer and the applications that run on top of it. This indirection promotes code portability through decoupling: your application code is ignorant of where the javax.sql.DataSource (or whatever) handle it’s using comes from, be it a JNDI lookup, environment variables, or a simple new’d-up bean provided by Spring. This decoupling and the rich toolbox of features on top of Spring supporting all manner of use cases - batch processing, integration, stream processing, web services, microservices, operations, web applications, security, etc. - have made Spring a logical choice for developers deploying to (sometimes-embedded) web containers like Apache Tomcat or Eclipse Jetty, to application servers like WebSphere and WildFly, and to cloud runtimes like Google App Engine, Heroku, OpenShift, and (my personal favorite these days) Cloud Foundry. This portability is also what makes it easy to forklift most (reasonably-written!) applications from the application servers into lighter web containers and, ultimately, into the cloud.

Read more...

This Week in Spring - February 24th, 2015

Welcome to another installment of This Week in Spring! We’ve got a lot to cover so let’s get to it!

  1. Our pal Adam Koblentz (from ZeroTurnaround) put up this great post introducing building a websocket application with Spring Boot and JRebel. Check it out!
  2. Check out this replay of Mark Fisher, Dr. Mark Pollack, and Sabby Anandan’s webinar introducing Spring XD - A Platform for data at scale and developer productivity
  3. A huge part of the Pivotal Data Suite, of course, is Spring XD. Last week I surfaced some of the amazing Spring XD wiki content on the new stream processing supports in Spring XD 1.1. Check out the Wiki page for a more detailed look by Spring XD ninja Ilayaperumal Gopinathan.
  4. Spring Cloud co-lead Spencer Gibb has been improving the Spring Cloud Netflix integration. Check out this example demonstrating using RxJava’s Observable<T> return-values from Spring MVC. Here are the changes.
  5. March Webinars are here, and it’s packed with Javascript, Spring Boot and Spring Cloud.
    This killer lineup starts with Dr. Dave Syer’s epic VII part blog series on Angular - lightweight API gateway - Spring Security - made into a webinar on March 10th. Then Scott Deeg will examine the same thing, except with Google’s Polymer on the frontend, on a webinar March 24th. Lastly, Julien Dubois will introduce the AngularJS+Boot application generator, JHipster on March 17th, 2015.
  6. Alvin Reyes’s posts introducing how to configure Apache Tomcat’s server.xml and users.xml are wonderful resources.
  7. Reactor project-lead Jon Brisbin has just announced Reactor RC1!
  8. Spring ninja Stéphane Nicoll has just announced the Spring framework maintenance release, 4.1.5
  9. Last week, we at Pivotal announced some big changes; we’ve open-sourced our Pivotal Data Suite! Check out this InfoQ post on the subject
  10. Spring IO Platform lead Andy Wilkinson has just released improved support for Maven Bill-of-Material dependency management using Gradle
  11. Eclipse foundation member John Arthorne and Spring Tool Suite lead Martin Lippert’s talk, Eclipse IDE to the Cloud-Based Era of Developer Tooling from JavaOne 2014 is available online and well worth a watch!
  12. The SD Times article on the open-sourcing of the Pivotal Data Suite is worth a read, too.
  13. Not related but still awesome: HTTP2 is now a thing!
  14. Check out Rick Hightower’s post on using the QBit framework with Spring Boot. Interesting..
  15. Hubert Klein Ikkink put together a quick look at using Spring Boot’s OutputCapture JUnit @Rule in a Spock test.
  16. Our pal Eugen Paraschiv put together a great look at using the venerable JdbcTemplate
  17. Disid’s Enrique Ruiz put together a nice post on using Spring Roo from STS.
  18. Check out this week’s SpringOne2GX 2014 replays:
    SpringOne2GX 2014 Replay: Panel Session: Real World Boot-up sequences
    SpringOne2GX 2014 Replay: Spring Data REST - Data Meets Hypermedia
    SpringOne2GX Replay: Spring Batch Performance Tuning
    SpringOne2GX 2014 Replay: Artistic Spring Data Neo4j 3.x with Spring Boot
Read more...

Stream Processing in Spring XD 1.1

This tip is drawn heavily from this Wiki-page on Spring XD’s streaming support by various Spring XD team-members, and particularly the amazing Ilayaperumal Gopinathan

Spring XD 1.1 is here and is packed with lots of new features. One theme for this release is rich stream processing support. Spring XD 1.1 provides integration with Project Reactor Streams, RxJava Observables, and Spark’s streaming.

Let’s look specifically at using Reactor, though the concepts are similar across all of the supported streaming APIs.

Read more...