No, not Apache Spark. Sparkjava I have found to be the simplest approach to APIs and the one that clicks the most with me, but everyone states that it shouldn't be used for production, but no one has given me a good answer why. Do any of you know any unstableness or security flaws or something else?
Thanks for asking such a good question and I don't suppose there is a simple yes or no answer to it directly. Let me start with we have been using Java Spark for microservice development for quite some time now. The challenges which faced during our run with the framework
There is not a lot of material available on the internet for Java Spark as compared to other frameworks like Spring Boot, restlet. So most of the times if you are stuck you are the one who has to solve the problem.
There is no dependency-injection. We had to use Spring in conjunction with java Spark to get this feature.
There is not enough information available on the internet when you want to integrate your microservice with service discovery tools or API gateway.
Integrating Spark with swagger was a mess. It took us days to figure out how we can do.
- As it is still evolving and has a long way to go we dont prefer an framework like this in prod.
All that said, it is super easy to create a microservice application on spark java. Kudo to them!!!
Please refer to below links for more info:
That's all a matter of choice. Spark is intended to be very simple and minimal dependencies are required to get a web app up and running. Spark allows us to build a web app by using only the JSE8 platform, while most of the other existing technologies would require JEE, what would end up increasing a lot the learning curve for using them.
When it comes to deploying your app, be aware thar most of the cloud servers and hosters doesn't support the lean framework Spark out of the box, so that you'll end up having to implement a deploy strategy by yourself. But you can easily deploy an Apache or a Java EE app on such services, and Spark can be easily wrapped in an Apache or JEE web server as described in the documentation
© 2022 - 2024 — McMap. All rights reserved.