Recently I had a problem with using sockets from Java on the Nokia 7650/3650. Now here's the problem with this, where should I have gone to for support? Sun makes Java, Nokia made the phone (and the Series 60 UI) and Symbian made the underlying OS. Who's fault is it that the sockets (which aren't officially "supported") don't work the way they should?
I've ranted about the sockets problem before, but I'll recap it briefly. When you open a normal socket using Java (not an HTTP connection), you can write to the socket, but when you do a .read() it will block the stream waiting for data. The problem is that it will also block the socket for WRITING as well. This means if your app is waiting for messages from a server (like a Jabber server), you can't send requests so as to receive the answers and unblock the read() and go on with your program. There doesn't seem to be any way around it.
This is a major problem. First, manufacturers like Nokia aren't used to having developers yet, so their developer resources are limited. There's lots of docs, and a few forums on Nokia's site - and it's admitedly getting better all the time - but still doesn't rank up there with the wealth of information that can be found on traditional software websites like Microsoft's MSDN, Apple's ADC or even Sun's Java portal.
The Nokia problem was actually a special case because it added a third element into the mix which is Symbian. This will continue to be a problem as more and more phones get operating systems. So now the question is, should I go to Sun because it's a Java problem, Nokia because it's their phone or Symbian because it's their underlying sockets that I'm calling?
Now, imagine that I want to target more than one phone? This is a reasonable thing to want to do, no? It's Java, right? It should be Write Once Run Anywhere... (hahahaha. *snort*). So now, I'm having trouble with the same app on the SonyEricsson P800. Now I have to check out their site. Or maybe Symbian again? What about the Siemens' phones and Sharps and Motorola's, etc. etc. The problem is that there are too many manufacturers using Java and too many problems that can be encountered.
And that's my beef with Sun on this one. They aren't doing anything to ease the chaos. Java is THEIR technology. They're promoting it and educating the developers on it, but always from a generic J2ME Wireless Toolket level. Once you get to the real devices, you're on your own.
Sun needs to be a CLEARINGHOUSE for these issues. Licensees should be able to have a common Java forum for developers where they can hash out the capabilities for each phone. If I go to Nokia with a Java problem, I should be redirected to Sun's site - even if it was rebranded. Sun should be organizing, collecting, resolving and publishing all of the different issues that come up with any licensee using their technology.
If they were smart, they'd do that, in order to push better apps out to the end users and more adoption of Java phones. It's just in their best interest (and mine as a developer). But instead, Sun is just letting everything go their own seperate ways and chaos is the result. Though it does seem like a great business opportunity for someone to step in and help developers, without Sun's backing it just isn't the same.