https://kotlinlang.org logo
Title
g

gregopet

06/13/2017, 6:19 AM
I've worked a lot with Spring Boot and Groovy and I chose a more lightweight library for my current Kotlin project (and I really don't miss Spring 🙂 )
👍 3
m

minisu

06/13/2017, 10:29 AM
gregopet: out of curiosity, which framework did you use?
t

thisen

06/13/2017, 11:25 AM
Yeah, I'm curious too 🙂
g

gregopet

06/13/2017, 12:31 PM
It's modelled after Sinatra and developed by guys I know from their previous projects
I know at least some of the guys working on it are also using Kotlin for some projects, even though Groovy is mentioned explicitly in Ratpack's docs
Ah yes, there is Kotlin, under Alternative language implementations, there's an 'official' example here: https://github.com/ratpack/example-ratpack-gradle-kotlin-app
j

janvladimirmostert

06/14/2017, 4:42 PM
I also ditched Spring the day I started using Kotlin. Feels like a lot of the Spring stuff exists to make Java dev easier and it only adds weight to a Kotlin project (that’s my personal opinion) Now I’m using a combination of VertX with my own extension functions, no more 20MB Spring jars
d

dave

06/15/2017, 5:05 AM
@janvladimirmostert don't worry - you're not the only one! After being presented back in the day to fix a spring project containing (really) 275 XML files (with multiple layers of XML "inheritance"), I vowed never again. Now, our services are typically between 10-25meg in size and start up in an instant instead of seconds. (We did fix the project btw, and deleted every single last XML file. 😀)
j

janvladimirmostert

06/15/2017, 5:59 AM
That’s my experience as well, project starts up in 100ms instead of 5 - 10 seconds when spring is doing annotation scanning and who-knows-what.
Spring without XML configuration in my opinion is even more verbose when you have to start stacking countless annotations on top of countless other annotations, some classes had 7 annotations on them in the Spring days. Testing is also a pain since you need to inject the Spring Context which then takes ages before the test can start.
g

gregopet

06/15/2017, 6:40 AM
5-10 seconds? That's not so bad, one of my Spring projects need up to a minute to start 🙂
j

janvladimirmostert

06/15/2017, 7:26 PM
The reason I have a JRebel license is because I have to maintain some legacy Spring3 + Hibernate + Java projects that also takes around 50-60 seconds to start. In Kotlin without Spring, the benefits of JRebel doesn’t seem to justify the cost anymore since it restarts so quickly.