Saturday, May 29, 2010

WLST development with PyDev in Eclipse

My understanding is that Satya Ghattu has not been working on WLST for quite some time (cmiiaw)
and his blog doesn't say much on this topic.
I really wish Oracle put some development effort in WLST as honestly it's a bit primitive and lacks many features that for a Java Developer are essential (debugging, remote debugging, a proper IDE etc).
When people say "just use notepad" it makes me FURIOUS, it's like saying a surgeon "just use a Swiss Army knife instead of a bisturi"....

So in an attempt to make my WLST life easier...

download Python 2.6.5 here (is Python required? I don't think so)
http://www.python.org/ftp/python/2.6.5/python-2.6.5.msi

and Jython here (Is Jython required? NO! You already have C:\bea11\oracle_common\util\jython\jython.jar !)
http://sourceforge.net/projects/jython/files/jython/jython_installer-2.5.1.jar


install into Eclipse the PyDev plugin by following their instructions:

http://pydev.org/manual_101_install.html

DO NOT declare the system variable PYTHONPATH as c:\Python26, since this will be done automatically by the Intepreter configuration wizard

Configure the Intepreter (Window/Preferences/Pydev/Interpreter Jython...)
specifying C:\Python26\python.exe for Python
http://pydev.org/manual_101_interpreter.html

and accept the path proposed by default.

Configure the Jython Intepreter (WLST IS Jython, so.... who cares about the Python interpreter!)
and specify
C:\bea11\oracle_common\util\jython\jython.jar

and accept the defaults.

mmm it doesn't seem to recognize the WLST commands, like connect and edit... there must be some trick...

ok I give up for lack of time and itnerest, if anyone knows the answer please write a comment.

2 comments:

怡潔 said...

學問好比腸胃裡的食物,裝下多少並不重要,吸收多少才重要。......................................................

Simon said...

You don't need to download python 2.6 Thats CPython (written in C) and has nothing to do with Jython/WLST.

Instead of pydev, try jydt.

http://www.redrobinsoftware.net/jydt/

WLST also includes ANT tasks for easy integration into eclipse.

The interactive interpreter can be spawned at any time by calling org.python.util.InteractiveInterpreter