Live data from Hacker News

Jodd – The Unbearable Lightness of Java

jodd.org

141–150 of 239 posts

Re: Jodd – The Unbearable Lightness of Java

#141

Earlier quoted context omitted.

> Spring documentation is and has always been poor and the sheer volume of outdated documentation Spring documentation is excellent. I had to learn Spring as a PHP developer, so I put the documentation onto a Kindle and read it. It's also versioned, so you don't need to read out of date versions: https://docs.spring.io/spring-framework/docs/ > This is different to eg DropWizard where you actually boot the app (no dif…

> It's a disservice to persuade businesses to use smaller projects that don't have a comparable level of support, or flexibility. This is why we use Spring. We have confidence that it'll be supported long-term and will continue to have backing from a whole host of companies. It's slightly different in a large enterprise environment where a service might be fairly straighforward - take in input, spit out output to som…

> we'd be doing ourt clients a great disservice to sell them on a microframework with our homespun implementations of security, transactions etc.

One of the benefits of Spring Boot was that Pivotal test and ensure all the components work together, so you can upgrade safely. It made keeping things up-to-date much easier.

There's no business value in trying to knit it all together yourself, if you can pass the work onto somebody else who is paid to do it.

Re: Jodd – The Unbearable Lightness of Java

#142

Looks nice and clean. It does seem to be maintained by a single person (at least the JSON subproject [1]) which will be a major turn off for adoption by an "enterprise" [1] https://github.com/oblac/jodd-json

First thoughts: the JSON subproject seems to be very unprincipled. The documentation documents general usage through a few examples, but it doesn't really give you a good idea of the semantics of the library. It appears to scan your objects using reflection for things that it determines to be fields (what are the criteria?), but for some reason does not serialize collection types by default because "This plays well w…

"just a disaster waiting to happen" - if I was the maintainer, I would appreciate a test that demonstrates the failure scenario.

Re: Jodd – The Unbearable Lightness of Java

#143
post #129

Earlier quoted context omitted.

> Errors are indecipherable being swamped by thousand line framework exception trace Don't you just look at the top lines?

If you're lucky and the exception happens in your code directly. If not you're gonna have about 30 lines of interceptors and generators and whatnot before you get to your class. If you call ClassA::foo from ClassB::bar you'll get about 5 lines of interceptors between foo and bar in your stack trace. Debugging is also a nightmare in IntelliJ as step-into and step-out will go through all those interceptors.

I used Spring Boot and just set debug breakpoints, that way you don't have to step into and out-of, you just press "play" and it moves to the next breakpoint.

Re: Jodd – The Unbearable Lightness of Java

#144

I remember the days, when the Spring framework was advertised as a lightweight alternative to Enterprise java beans (ejb); now Spring outgrew the pretence of being lightweight, don't know when that happened. A year and a half ago, i got back to work with java and spring boot, and i was overwhelmed by the prevalence of annotations in spring boot. To cope with all this, i wrote this little project: https://github.com/M…

IBM WebSphere Application Server took several minutes to start or stop. Deploying war file took another 10-30 seconds. And you had to restart application server sometimes.

Spring Boot application with few controllers starts in 2 seconds on my outdated laptop.

Spring is lightweight, compared to old tech.

Not the most lightweight, that's for sure. Simple Java web server which uses socket API to server requests, starts in few milliseconds. That's the bar.

Re: Jodd – The Unbearable Lightness of Java

#146
post #129

Earlier quoted context omitted.

> Errors are indecipherable being swamped by thousand line framework exception trace Don't you just look at the top lines?

If you're lucky and the exception happens in your code directly. If not you're gonna have about 30 lines of interceptors and generators and whatnot before you get to your class. If you call ClassA::foo from ClassB::bar you'll get about 5 lines of interceptors between foo and bar in your stack trace. Debugging is also a nightmare in IntelliJ as step-into and step-out will go through all those interceptors.

Debugging bothered me too. But in the end I have configured IntelliJ to skip all the interceptor classes while stepping into. Had to add a whole bunch of classes and packages for that though

Re: Jodd – The Unbearable Lightness of Java

#147

I really like the Go-like simplicity of these libraries, without the cursed architecture astronomy from the 2000s. In general it's interesting times for Java. With all of language improvements from Kotlin/Scala, and upcoming Go-like concurrency it really feels like a renaissance for the language.

> it really feels like a renaissance for the language. So is this the 2nd or 3rd Java renaissance?

I'd say that first Java renaissance is Java 5 with generics. Second Java renaissance is Java 8 with lambdas. IMO third Java renaissance will be with re-introduction of green threads.

Re: Jodd – The Unbearable Lightness of Java

#148
post #5

I wonder if someone can recommend a lightweight http server library? I like Javalin but it's based on Jetty which is a fully JavaEE compliant framework and includes support for things like OSGI which I don't need. With the whole Log4j situation, I'm re-evaluating some the libraries I've previously relied on.

https://github.com/NanoHttpd/nanohttpd

A bit outdated and not actively maintained, but it's truly small.

If you like async stuff, take a loot at Helidon.

Re: Jodd – The Unbearable Lightness of Java

#150
post #3

Looks good. Is there a "Getting Started" guide or a list of examples anywhere? I'm on mobile so may have missed them. All I could see were links to the separate component docs.

It seems every project has its own documentation (powered by GitBook), for example https://lagarto.jodd.org/, https://http.jodd.org/ etc.
Post reply on HN