Environment
- Weblogic 10
- Sun Java
- HP UX
Goal
Restart all managed instances with all clusters in a rolling restart fashion. Would like the different clusters to restart concurrently
Question
Is there a way to use Jython's threading module to do multiple WLST actions at the same time?
Attempted Approach
In one script I have classes for both cluster and server instance. A cluster has a list of server instances. There is a method on the cluster object to loop through its list of servers and restart them one by one if the cluster is healthy. I have tried passing this method into a thread like so:
Thread(target=lambda: cluster.managedRestart()).start()
But I receive an error
TypeError: can't set arbitrary attribute in java instance: target
Ideas
Break out the managed restart code into a seperate file and use execfile()
to call it from within a thread