Live data from Hacker News

Ask HN: Why not Java?

news.ycombinator.com

11–20 of 112 posts

Re: Ask HN: Why not Java?

#11
Java is good, make no mistakes about it. It offers you find grained control in almost every aspect of programming (e.g. concurrency). However it is the same freedom that allows developers to make mistakes. For example -

One can write concurrent systems in Java without understanding concurrency. Languages like Scala and Clojure will give you some freedom but will also enforce certain design principles which will save you.

Similarly for web development, there are scores of frameworks in the Java world, and you can mess it up easily. Rails / Django on the other hand will provide one good, solid way to do web programming.

Finally, Java is showing it's age. The need to write large files of XML to configure things and the lack of ability to treat functions as objects put developers off. Some things are being addressed by Oracle but will take time.

Re: Ask HN: Why not Java?

#12
post #3

It's perfectly fine to use Java for this kind of software. The hate against Java comes from using Java for application development: this is largely due to the kinds of applications that are typically written in Java (line of business software) and (this is the most important reason) accidental complexity and low quality of APIs like Spring or J2EE. Recipe for programming happyness is to use the right tool for the job…

Can you give us some evidence why Spring is "unequivocal and absolute garbage"?

Re: Ask HN: Why not Java?

#13
post #3

It's perfectly fine to use Java for this kind of software. The hate against Java comes from using Java for application development: this is largely due to the kinds of applications that are typically written in Java (line of business software) and (this is the most important reason) accidental complexity and low quality of APIs like Spring or J2EE. Recipe for programming happyness is to use the right tool for the job…

Can you give us some evidence why Spring is "unequivocal and absolute garbage"?

I haven't used it for a few years, but I always found it funny that a project that was supposed to make Java application development easier and more agile than J2EE ended up being just as large, if not larger. Core Spring did a lot for dependency injection, which was a big shift in thought. However, for dependency management, I'd go with something like Guice today.

Re: Ask HN: Why not Java?

#14
post #3

It's perfectly fine to use Java for this kind of software. The hate against Java comes from using Java for application development: this is largely due to the kinds of applications that are typically written in Java (line of business software) and (this is the most important reason) accidental complexity and low quality of APIs like Spring or J2EE. Recipe for programming happyness is to use the right tool for the job…

Can you give us some evidence why Spring is "unequivocal and absolute garbage"?

Spring was innovative in 2008. Now, Spring is overbloat, buggy (look at request-mapper) and have old, sensless integration to others modules, see spring-data for NoSQL, or try integrate last version of Velocity with last version of Spring.

And additionaly, all, what you can do with Spring, you can do with JEE.

Re: Ask HN: Why not Java?

#15
post #3

It's perfectly fine to use Java for this kind of software. The hate against Java comes from using Java for application development: this is largely due to the kinds of applications that are typically written in Java (line of business software) and (this is the most important reason) accidental complexity and low quality of APIs like Spring or J2EE. Recipe for programming happyness is to use the right tool for the job…

Spring is not garbage.

Re: Ask HN: Why not Java?

#16
post #3

It's perfectly fine to use Java for this kind of software. The hate against Java comes from using Java for application development: this is largely due to the kinds of applications that are typically written in Java (line of business software) and (this is the most important reason) accidental complexity and low quality of APIs like Spring or J2EE. Recipe for programming happyness is to use the right tool for the job…

Can you give us some evidence why Spring is "unequivocal and absolute garbage"?

Well, for starters the whole idea of programming in XML. That and gems such as http://static.springsource.org/spring/docs/2.5.x/api/org/spr... or http://static.springsource.org/spring/docs/2.5.x/api/org/spr...

Of course I can't a priori prove that Spring is garbage, much like I can't a priori prove that it's better to be healthy and rich than to be poor and sick. It is a judgement call, but a judgement call that I believe I'm qualified to make, having worked with a large Spring codebase for 2.5 years.

Re: Ask HN: Why not Java?

#17
post #8
post #3

It's perfectly fine to use Java for this kind of software. The hate against Java comes from using Java for application development: this is largely due to the kinds of applications that are typically written in Java (line of business software) and (this is the most important reason) accidental complexity and low quality of APIs like Spring or J2EE. Recipe for programming happyness is to use the right tool for the job…

What does "userland" mean?

Code that isn't part of the OS kernel.

http://en.wikipedia.org/wiki/User_space

Re: Ask HN: Why not Java?

#19
post #8
post #3

It's perfectly fine to use Java for this kind of software. The hate against Java comes from using Java for application development: this is largely due to the kinds of applications that are typically written in Java (line of business software) and (this is the most important reason) accidental complexity and low quality of APIs like Spring or J2EE. Recipe for programming happyness is to use the right tool for the job…

What does "userland" mean?

That's what normal applications are referred to as opposed to kernel-level code. So anything user-facing that does not need low-level system access.

Re: Ask HN: Why not Java?

#20
I am curious about what, specifically, you find easier to do in Java syntax than Python syntax.

Seriously, there is a fairly direct translation from any Java you might want to write to completely equivalent Python. Sure, Python offers more complex techniques such as list comprehensions and iterators. But you don't need to use them. You can just write Java-like Python.

Post reply on HN