Flexibility and control are the key words

Meet Spincast – A flexible Java web framework

Eirini-Eleni Papadopoulou
© Shutterstock / Sky Motion  

Every day we see fancy tools coming out, featuring all the buzzwords in their descriptions! But sometimes, all you need is a simple tool that gets the job done. Spincast was created exactly for that! Let’s have a closer look at this framework.

Java developers certainly have a plethora of fancy tools to chose from. But what if you just want a simple tool that will get the job done for you?

This was the motivation behind Spincast‘s creation, a flexible and open source Java web framework.

Three years after its initial commit, Spincast reaches its first milestone release 1.0 and it is time to have a look at what it has to offer.

How it works

To start things off, it is important to talk about Java support. Despite the fact that the Spincast team wanted to migrate Spincast to Java 11 before tagging it 1.0.0, they felt the Java ecosystem is still not perfect in regard to the new JPMS/Jigsaw module system added in Java 9. After encountering numerous errors using the popular IDEs trying to migrate, it was decided to stabilize on Java 8 first. It is planned, however, for Spincast 2.X.X will be based on Java 11.

Now, let’s have a look at what makes Spincast special.

Built from the ground upon Guice – If you already know Guice, Spincast will be really easy to grasp for you. If you know another dependency injection library, like Spring, it can also help but you’ll probably have to learn a few new things.

Suitable for building REST web services or microservices – You can build REST web services or microservices, without any user interface, since it “talks” JSON and XML natively.

Modular architecture – Composed of a core plugin and a set of default plugins. The core plugin is responsible for validating that an implementation for all the components required in a Spincast application has been bound by other plugins. The default plugins provide such default implementations. You use the Bootstrapper to initialize your application. This bootstrapper will automatically bind the core plugin and the default plugins, but will also let you install extra plugin and custom modules for the components specific to your application.

Request handling using an embedded HTTP Server Head over to the official documentation to find detailed information on how Spincast handles requests.

Main components – The main components are those without which a Spincast application can’t even run. Any class, any plugin, can assume those components are available, so they can inject them and use them. Since Spincast is very modular and you can replace any plugin, even the default one. But, when you do this, you are responsible for providing any required components this plugin was binding.

Transitive dependencies – The spincast-core Maven artifact only has two direct dependencies which are external to Spincast:

  • Guice: which itself pulls some transitive dependencies, such as “Guava” and “jsr305“.
  • SLF4J : the logging facade.

Find out more information on Spincast’s architecture and features here.

SEE ALSO: Next-level Kubernetes native Java framework – Quarkus brings Java on a subatomic level!

Getting started

If you want to give Spincast a try, you can find a helpful set of tutorials and demos here.

You can also find the ‘download guide’ here for all the information on how to get started.

Eirini-Eleni Papadopoulou
Eirini-Eleni Papadopoulou was the editor for Coming from an academic background in East Asian Studies, she decided that it was time to go back to her high-school hobby that was computer science and she dived into the development world. Other hobbies include esports and League of Legends, although she never managed to escape elo hell (yet), and she is a guest writer/analyst for competitive LoL at TGH.

Inline Feedbacks
View all comments