5 ms·
My takeaway from this is "I should probably bite the bullet and learn about Spring Boot." I started writing server-side Kotlin about a year ago and find the JVM
by avolcano 6y ago
My takeaway from this is "I should probably bite the bullet and learn about Spring Boot." I started writing server-side Kotlin about a year ago and find the JVM ecosystem mostly really nice (leagues better than the Node/TypeScript world I escaped from - as much I still like writing TS on the frontend, server-side TS is still too immature to recommend), but I could not wrap my head around Spring/Boot. My understanding is that Spring Boot wraps a bunch of the same libraries used in Spring MVC into an easier to comprehend package, but it still seemed like a very intimidating ecosystem.
I went ahead and used Javalin, which I'm a little bummed to not see represented on the survey - it's meant as a successor to Spark (which I haven't used), and I really like it. It uses similar patterns to Koa/Express in Node, which made it easy to understand. The big downside of not using an integrated ecosystem like Spring Boot, of course, is more glue code, but I actually haven't found it _that_ bad.
- murukesh_s 6y ago>TS is still too immature to recommend care to explain? I don't think TS is immature, but whether it's true or not, Java is still used by 90% of the enterprises. I am amazed why Node.js (TS in server) could not yet challenge Java, especially in large enterprise systems.
- mxschumacher 6y agobecause enterprises run huge and old systems performing critical functions, these systems get modified around the edges (small extensions, bugfixes, performance tuning), not completely re-written. To justify switching the stack (at gigantic expense in training and engineering), a vastly superior technology would have to present itself. I don't think switching from Java to Node would make a big difference for the bottom line.
- anon73044 6y ago>because enterprises run huge and old systems performing critical functions, these systems get modified around the edges (small extensions, bugfixes, performance tuning), not completely re-written. Not every enterprise runs a single huge monolithic app or codebase.
- fendy3002 6y agoAs a daily typescript developer coming from C#, I don't think TS will replace Java / C# even with it's typing system. For daily CRUD simple system, sure. For more complex operation I still vouch for C#. I don't know why, just feel like that, maybe stricter typing system and more verbose language is giving me more confidence.
- murukesh_s 6y agoit's baffling that at least even after a decade, no major adoption of Node.js ecosystem happened in enterprise. At least we expected new projects to migrate to Node.js but it did not happen yet. I believe the Node.js is yet to have large backing that Java had in it's early days which made things like JDBC and JMS and associated drivers from almost all vendors. Node.js feels like a not so solid, light-weight, scripting language in comparison.
- avolcano 6y agoI wrote a comment about this a couple months ago: https://news.ycombinator.com/item?id=23355513 https://news.ycombinator.com/item?id=23355513 I'm still planning to write a longer blog post about it with more details. I think in terms of enterprise usage, there is no equivalent to a batteries-included framework like Spring Boot - especially not one with paid support available for big companies.
- jillesvangurp 6y agoKotlin + Spring Boot is pretty nice and going to get nicer as the Spring people roll out more Kotlin friendly features and DSLs. The trick with Spring Boot is to keep things simple and avoid some of the stuff that is there for legacy code bases. Also, there is a lot of complexity lurking in using stuff like JPA (which I tend to avoid), spring data (like wise), spring-batcg and a few other things that IMHO are not so great. But the core of spring's dependency injection and e.g. MVC with kotlin's co-routines is pretty nice. If you want graphql, there's a great spring library for that from expedia that makes this super easy to setup. The reason javalin and other frameworks are not mentioned is because it's part of an enormous long tail of stuff. A quarter of a century of Java means that there are a lot of things out there that are still being maintained and actively developed. Technically, Spring MVC and Spring Boot are the actually the same thing pretty much. Spring Boot basically just packages up Spring 5.x with a lot of convenient things. I've actually migrated a few old spring projects to spring boot at some point.
- andor 6y agoSpring MVC and Boot are not the same thing. Spring Boot is a "convention over configuration" framework for modern 12-factor apps. It integrates the other Spring libraries (like MVC) by providing "starters" that come with a basic configuration. For instance, adding the Spring Security starter package automatically configures Basic Authentication for all endpoints. Spring MVC is the Servlet-based web library, it includes functionality for serving HTTP endpoints as well as an HTTP client. This is in contrast to Spring Webflux which is the new reactive web library. It also includes server and client functionality. Neither are required in a Spring Boot app though.
- ptx 6y agoOne extremely useful part of Spring Boot is spring-boot-starter-parent, which specifies a compatible set of versions for all the various dependencies you're likely to pull in, which is otherwise tricky and tedious.
- jillesvangurp 6y agoI wasn't equating them just merely stating that MVC, Flux, and lots of other things are part of Spring 5.x. Spring Boot technically is basically a lot of auto configuration around a large amount of spring libraries and third party components. You could replicate pretty much all of what it does by adding those dependencies manually and manually configuring them. That's pretty much how Spring used to work before Spring Boot became a thing (been there done that). It's actually not that hard if you keep it simple.
- x87678r 6y agoSpring Boot brings magic, my like RoR. I can see its super productive, I'm deeply uncomfortable with the magic still, waiting for problems that will be hard to debug, but actually haven't had any.
- johnyzee 6y agoBoot is just an embedded Tomcat/Jetty included with all the different Spring libraries. That makes for an easily bundled application (single executeable jar which launches the web server including all the application code). There are a lot of Spring libraries to learn about, but only a couple are actually required in a Spring boot app.
- Tsarbomb 6y agoSpring Boot makes working with Spring Framework and managing your IoC/DI much nicer.
- jcadam 6y agoI'm doing server-side Kotlin as well, with Spring Boot. I initially was against the idea of Spring Boot, because I had memories of using the old bloated Spring Framework from 10+ years ago with giant XML files full of bean definitions and coding-in-XML horribleness with Apache Ivy and Ant. Oh, yea, I also was using all of the above with OSGi as well (Never use OSGi. Ever). But, Spring Boot is much more modular and I'm impressed with compile and startup speeds. No more XML - unless you want to, but not on my project :) It also supports automagic docker image building using build packs, which keeps the size of images down (not as small as a service built using Go or node, but not as horribly big as you'd expect from Java). I still have a preference for Clojure and integrating small libraries, but on larger projects where you're working with other devs and need to get moving quickly, Kotlin + Spring Boot is a powerful combo that's hard to argue against :)
- phist_mcgee 6y agoSpringboot still has not solved the issue with bad dependencies at runtime being an easy debuggable experience. I still struggle after several years pinpointing where exactly my springboot app crashed, because stack traces are perhaps several hundred lines long in some cases.