Posts

Showing posts from September, 2015

Latest Jython using in Thin Client WebSphere 8.5 on Vagrant Ubuntu box

How to use the latest Jython for wsadmin Today my experiment on renovating wsadmin Jython version. How to check the current Jython version? It is very simple you can try with sys module attribute version and one more thing your jdk that used for wsadmin runs on which version you can know by sys.platform. wsadmin>print sys.version 2.1 wsadmin>print sys.platform java1.6.0 Installing Jython in Thin Client Home Executing the Jython jar command in the ThinClt/lib directory : vagrant@ubuntu-was8:~/ThinClt/lib$ java -jar /vagrant/was8_5_install/jython-installer-2.7.0.jar Welcome to Jython ! You are about to install Jython version 2.7.0 (at any time, answer c to cancel the installation) For the installation process, the following languages are available: English, German Please select your language [E/g] >>> E Do you want to read the license agreement now ? [y/N] >>> N Do you accept the license agreement ? [Y/n] >>> Y The following installatio...

Setup WebSphere 8.5 on Ubuntu Vagrant box

Image
I've started working on new adventure being in the WebLogic wold had some basic knowledge on Virtuallization with Vagrant and Oracle VirtualBox begin my experiment for WebSphere installation on Ubuntu box. Prerequisites Download and install Vagrant  for Windows Download and install Oracle VirtualBox Download Installation Manager Lets Start Virtualization for WebSphere 8.5 with Vagrant Initially I started following the steps which are given Pattrick Hueper in the Vagrant Ubuntu WebSphere  8.5. Downloaded the Vagrantfiles folder using git command. git clone https://github.com/phueper/vagrantfiles.git Then followed the read me document in that. Modify the Vagrantfile It stuck saying Ubuntu box is not available so I have changed the Vagrant file  with the following line:     config.vm.box = "bento/ubuntu-14.04" and I faced issue with the private network then I modified that with the following line:     config.vm.network "private...

Jython Multi Threading in wsadmin

What is the Multi threading? Multi threading is similar to how multiple programs runs on your computer system, moreover which run at same time. When you are running multiple tasks in parallel on same CPU[machine]. More cores parallel processing allowed by your VM. The simple mapping let me tell you that if you have 1 core CPU that links to Multiple threads. Do's and Don'ts in threading Let us talk about does first here: You defined tasks which are independent of each other Physics/collision calculations in on thread, graphics in another All the threads should communicate back with the main thread which actually starts them Don'ts If you don't have clarity on multi threading then whole program would mess up! so be-careful Simple Threading examples on wsadmin The following sample is from tutorial point python examples. import threading import time exitFlag = 0 class LearnThread (threading.Thread): def __init__(self, threadID, name, counter): ...

Jython Date and time formats experiment

Basic date and time formats in Jython This is common requirement in most of our WAS administration tasks. You need the date or time formats in the following tasks: Back of the deployment units such as .war or .ear or .jar files Log file rotations Monitoring report logs with time stamps Update the Logger with time stamp Jython allow us to use time object only from Python module. other two date, datetime objects are not available in Jython. Lets experiments with the time object and its different functions in a simple script: import time timetuple=time.localtime() print "Time tuple:", timetuple print "Time tuple with loop" for t in timetuple: print t # Week of the day print "Today Weekday in short:",time.strftime('%a') print "Today Weekday in full:", time.strftime('%A') # Month of the date print "This month in short:", time.strftime('%b') print "This month in full:", time.strftime('%...