|Perl Monk, Perl Meditation|
From Perl to Javaby ropey (Hermit)
|on Jul 24, 2008 at 16:01 UTC||Need Help??|
ropey has asked for the
wisdom of the Perl Monks concerning the following question:
When the company I worked for was taken over by a much larger one with Java as their core technology 2 years ago, I knew that the Perl app I have so lovingly developed would one day die a death.
But to my surprise after some initial misgivings the company realised that it was fast, stable and maintainable and could be coupled into the greater Java machine via XML and my world was good
However it has reached the point where new functionality is requested more and more rarely, and when it is the development is done 100 x faster than its Java big brother it is incorporated with
So I find myself with much less work than before, there is still a place for me in my job and there will always be the role of maintainer of the Perl side, however now I also am requested to get involved in the Java side as well
So for better or for worst I am getting involved, I am looking at the code... scratching my heads at times and realising how good Perl is to this beast... but the moral high ground isn't the question here. The question is what advice would anyone here give from moving from one language to another... its like a double whammy inheriting some code you didnt write and working out how it fits together as well as finding out the differences between languages. I find I start by looking at the few unit tests and following them, adding my own debug statements and following the flow of it.
However I always seem to find the differences annoying, for instance what is the equivalent to 'Data::Dumper' ? how do I do I 'split' a string what can do 'map' ?... These questions are Java centric and I am sure I could deep dive into the documentation, but is there some sort of perl - java mapping out there handy ?
Apart from above has anyone else been through this ? I know its going to be a learning curve, but other monks previous journeys may make my own journey that little bit less painful