I consider myself a pretty bright guy and a good developer. But making sense of Java Web Services is completely frustrating.
It should be simple.
I can’t count the number of times that I’ve tried to find a way to write a webservice and failed. I have spent countless hours digging through documentation and just find myself more confused. There are just too many options. What the hell is an EJB, what is JAXB? What about Spring? J2EE? Apache Axis? or Javax Servlets? There are so many abreviations, and buzzwords, and competing standards that it all becomes meaningless. There is no possible way to find out what is the best way to do something.
All I want to do is take my existing Java applications and libraries, deploy them on Tomcat and expose a couple of methods for users to call. Just one HTTP GET request that takes a single string argument and returns XML.
Java was never meant for this sort of thing. And the hundreds of different approaches are confusing.
This is why PHP is taking off. PHP is simple. Write the code, save it to a file and upload it to just about any standard install of Apache and it works. There’s no restarting the server, refreshing listings, registering services. There are no extra XML files to keep consistent.
It’s all part of a larger problem with Java development in general. Too many pointless abstractions. Large Java projects invariably have so many classes that it becomes difficult to find bugs. The code is spread out so much that one logical task is coded across 10 files. Add in some interfaces and it becomes even more difficult to track back through the code.
Oh, and Swing. I hate swing too. Why are there 10 different layout managers, none of which are any good? Why is it that after a decade of improvements I still have repainting performance issues. As much as I despise using Microsoft products, Visual Basic got it right. GUIs should be designed not coded.
Honestly, I just can’t get past the fact that you have to restart the server to load a library. How can you provided 99% uptime if it has to go down and come back up. We’re constantly expanding our libraries to support new features in the applications we write. So library files change every other day for us. That would mean restarting the server just about every day. How is that a good solution?
Java tries to be everything for everyone which makes it a pain in the ass to use for just about every application when compared to the best solutions out their for their given domain. Yet for some reason people insist on using Java top to bottom.