views:

3358

answers:

14

What is the best OS for Java development? People from Sun are pushing the Solaris, yes Solaris have some extra features included in itself such as (dTrace, possibility for Performance tuning the JVM, etc.. ). Some friends of mine, had port their application on solaris, and they said to me that the performances was brilliant. I'm not happy with switching my OS, and use Solaris instead.

What were your experiences?

A: 

I have had success before doing Java development in Windows with Eclipse. Sounds like you are also asking about deployment/hosting. Whichever OS is best to run your application on should not really predicate what OS you use to develop the application.

Peter M
There is not talking about the deployment/hosting, maybe the context does not match what I was mean, but my friend are port their application on Solaris just for testing.
vaske
what's the software? Give some more context. Migrating an application to a specific OS to test seems odd, since most of the tools are platform independent.
Egwor
some how the swing application are faster on Solaris
vaske
Ok, if your GUI apps are faster on Solaris this could be for a few reasons. Are your users always using Solaris? If not, then is it worthwhile working out why it is faster on Solaris? Do you have some users on Solaris, and some on some other OS?
Egwor
+1  A: 

Personally, I would not bother. I would use the platform that best supports the development tools and target platform that you use.

Why do you need to tune the JVM? This is a very unusual thing to want to do. Would you be better writing in a lower level language like C++?

Dtrace is available for OS X, there is a linux port too. Solaris has historically had a reputation for being slow (hence the Slowaris nickname). I'm not sure if this is still true.

Dave Hillier
Sparc is what made Solaris a lil slower compared to the faster Pentium + processors. Now that Solaris runs as good on intel processors, Solaris is as fast/slow as any other OS. YMMV.
anjanb
+5  A: 

"development" ?

I believe you should stick to the OS you are the most comfortable with, or which is the most available to a large group (of developers), like for instance a set of PCs on Windows.

It is rare to need to do in-depth tuning on development platform.

You would reserve all those dtrace and other performance tuning to assembly platform (for example in Linux), for daily deployments where everything is recompiled and unit-tested.

And then you could set up a special JVM (like IBM JRockit instead of Sun JRE) to do some analysis on your integration platform, where all your system can be tested from front to back, with stress and non-regression test

And finally, make all UAT (User Acceptance Tests) on a pre-production platform (which can be an expensive F15K or SunFire880 or V490 or...), with the target JRE used there.

My point is: there is so many parameters to take into account between development and release into production that switching OS at such an early stage may prove unnecessary.

VonC
UNLESS you're writing a GUI, in which case you want to be on the OS that your users use.
Egwor
True, but, in the context of this question... Solaris ? If you have hundreds of user, I doubt they will all have a Solaris box ;-)
VonC
+5  A: 

Develop on what you're happy with, and test on what you deploy on.

I get to develop Java on my Mac, and deploy on Solaris and Linux. The truth is that for the bulk of tasks, Java can be developed in an OS independent manner. This is especially true for server side development.

I like developing on a Unix in general over a Windows box, but that's me.

Will Hartung
A: 

Windows and Eclipse works well, as pmiller suggested. I can also recommend OS X with either Eclipse or IntelliJ IDEA (the latter also works on Windows, too).

I've only ever done the most basic Java development on Solaris (basic data structures' programming practice at University), so I can't offer any real comparison, I'm afraid. I did find it quite painful on Solaris, though, due to a lack of proper tools (I think I was restricted to nedit or something).

alastairs
+8  A: 

Develop on whatever you like. As a java programmer you might want to avoid Mac OS X, primarily because new features seem to have been significantly delayed, and also because you can find you've no longer got a machine that supports the new versions of Java. Having said that I imagine developing on Mac OS X must be very nice (command line interface, dtrace, nice OS).

I develop on windows with IntelliJ 7. It's ok, but needs some hefty hardware. I then deploy onto solaris/linux. Unless you're writing GUI's or integrating with C++ code, you should be fine choosing whatever takes your fancy.

Egwor
What about the write-once, run everywhere-metaphor?Our clients mostly use windows, and some use mac os x, so our application tries to look like a native one on either os...
dhiller
Sure, for servers that's fine. But for GUI's, it might look native, but there are subtleties that impact how they actually perform. For example focus.
Egwor
A: 

One thing you have to take into account is whether you are going to be developing an application that could be run on a mac. I love OS X, but good old steve made sure that we're always many JDK versions behind. We just barely got Java 6. Developing on a mac may at least insure you are working under the lowest possible JDK version.

Uri
+2  A: 

I'd say Mac OS X.

Java development built in. All the unix command line tools you want. Out of the box. Ant and maven are there. Not the latest versions, but that's easy enough to upgrade.

Yes, you might not have the very latest version of the JDK, but really, unless you have a need to develop for the latest and greatest JDK, it's not going to be an issue.

tunaranch
+1  A: 

Answer is easiear than you might think: use your favorite OS. For Java, it's the best answer. Not the development itself, but your comfort will help your success, browsing docs etc in your favorite environment.

Szundi
+16  A: 

Of the three I've used (Mac OS X, Linux, Windows), I consider Linux the best place to do Java development.

My primary personal machine is a Mac, and I've done quite a lot of Java development there and been happy with it. Unfortunately, however, Apple lags behind the official JDK releases and you're pretty much limited to the few versions they choose to provide.

My employer-provided machine is an old P4 crate from HP which I use mostly to keep my feet warm. The real work occurs "Oberon", on a 2.6 GHz quad-core running Ubuntu 8.04 in 32-bit mode [1]. The two advantages I notice day-to-day compared with Windows are:

  1. A powerful command line, which helps me automate the boring little stuff.
  2. Far superior file system performance. (I'm currently using EXT3 because I'm becoming conservative in my old age. I used ReiserFS previously, which was even faster for the sorts of operations one typically performs on large workspaces checked out of subversion.)

You can get those advantages from a mac too, but Linux offers another nice bonus:

  • Remote X11: Before my $EMPLOYER provided e-mail and calendar via web, I had to be on the Windows box to read my mail and see my meetings, so I used Cygwin's X11. This allowed my to run the stuff on Linux but display it on my windows desktop.


[1] I used to run Ubuntu in 64-bit mode, but I had no end of trouble. (Mixing 64-bit and 32-bit is something Mac OS X does much better.) 7.04 worked fine running 32-bit applications on the 64-bit kernel. 7.10 broke the linux32 script and the ability to install new 32-bit applications though old ones continued to (mostly) run. 8.04 killed 32-bit java by making it impossible to connect to the network from a 32-bit JVM (no more updates for Eclipse). Running Eclipse 64-bit didn't work reliably. The then current version of oXygen would only run (grudgingly) under the IBM 64-bit VM which would work for about 10 minutes until it stopped getting keyboard events. I finally gave up in frustration and used my Mac for a few months until I had enough slack time to do a 32-bit install of 8.04 on the linux box. Now everything works again and I'm quite happy.

bendin
I would like to add that I'm using ubuntu 8.10, and I find some "bugs" sometimes.. E.g the SystemTray is not supported, it seems to be a known problem. And I had a project at scool where we were going to make a reliable transferring protocol over UDP, and I got some problems with sending packets (segments) that Windows and OSX users didn't get.. :S
Johannes
Ubuntu in particular is really very very good for any kind of development especially if its Java. If you are not towards Microsoft specific technologies, then Ruby, Python, C#, Groovy, Erlang, Perl, D, C/C++ and everything else is available there.
Mohsin Hijazee
And my personal IDE would be Netbeans. Right from J2ME to Servlets etc etc. That's one package dealing all. Even I have been using Netbeans 6.7 for Ruby, C++ (Qt) and for Java.
Mohsin Hijazee
A: 

I've used Linux, Windows and OS X. My big argument in favour of OS X is that it is user friendly operating system (ie. I can run iTunes, most modern browsers, and don't need to allocate 50% of my time maintaining it on a laptop like linux) with a unix foundation. As most my development is for unix systems, this makes life hugely more productive. Also, there is a more and more active development community behind the platform here. These reason also work in reverse for Windows - while cygwin closes some of my requirements for using unix tools - it's nothing like having a real unix system.

James
A: 

Your development environment MUST BE THE SAME AS PRODUCTION.

There is no "best development environment" which is not identical to your production environment. Run what you run in production, in development.

That said, that doesn't mean you can't run your IDE, for example, on another OS, provided you still do development on the same system as production (on another machine, or a VM, for example).

MarkR
A: 

Windows is just fine.

Solaris is a wonderful Java development environment too (I like it better than Windows, but for subjective reasons), but unless you're deploying on it, it might not be worth switching to.

Linux is a little clunky for Java development, but doable.

The only one I can't recommend is Mac because they're always so far behind on the version of Java available (Not provided by Sun, Apple does their own).

Brian Knoblauch
For what reasons is Linux "clunky" for Java dev?
Xepoch
A: 

My best advice is to develop on the platform that you are targeting. That way, when you run it during you development testing and run your unit tests, you know that it will work on the target platform too, without any nasty surprises.

If you are targeting all platforms then you might actually want to develop on a Mac because you will get the most nasty surprises on the Mac. As far as Java goes, on Windows and Unix, "it just works", but not so much on Mac. Sun develops the Java runtime (JRE) for all operating systems except Mac. Apple develops their own JRE.

If you develop on the Mac, you are most likely developing against the least common denominator, so what runs on Mac should run on the others. That has been my experience.

Barring that, I always recommend that you choose the operating system based on whether it runs your software. Pick the OS that runs your IDE and other tools that you use for development and testing. If more than one OS runs the tools that you need, pick the one that runs them the best.

Marcus Adams