Hi,
I need to get the Weblogic bindAddress during Weblogic
Server Shutdown.
When i start the weblogic using startWeblogic.cmd i
give the bind address of the Weblogic Server as below:
-Dweblogic.system.bindAddr=10.3.10.156
Now how to get back the Bind Address programatically
inside ShutDownIp.java(source code attached).
ShutDownIp.java is executed
automatically when Weblogic Server is Shutdown by
using shutdownWeblogic.cmd
I am not able to get the bindAdress. I am getting
error.
Please reply.
Regards,
Vidyasagar
package com.nec.jp.iopendiosa.shutdown;
import com.nec.jp.iopendiosa.shared.*;
import com.nec.jp.iopendiosa.common.*;
import com.nec.jp.iopendiosa.*;
import com.nec.jp.iopendiosa.log.*;
import java.util.*;
import java.io.*;
import java.net.*;
import weblogic.common.*;
import weblogic.remote.common.*;
import weblogic.workspace.common.*;
/** class ShutDownTraceLog is called when Weblogic is
Shutdown
*
* @see end()
*
*/
public class ShutDownIp extends DefaultShutdown
{
T3ServicesDef services;
Properties myProp = new Properties();
/** Function end is called when Weblogic is Shutdown
* @since JDK1.2
*
*
*/
public ShutDownIp(Properties prop) {
this.myProp = prop;
}
public void end(T3ServicesDef services) throws
IOpenDiosaException {
this.services = services;
SharedSpace iODSharedSpace;
Hashtable hash = new Hashtable();
Vector resultVector = new Vector();
String flag;
try {
/* Lines added for testing */
T3Client t3=null;
System.out.println("Bind Address:1");
t3 = new
T3Client("t3://localhost:7001");
System.out.println("Bind Address:2");
t3.connect();
System.out.println("Bind Address:3");
String getIpAddress
=t3.getT3Services().config().getProperty("weblogic.system.bindAddr");
//t3.services.config().getProperty("weblogic.system.bindAddr");
//t3.getT3Services().config().getProperty("weblogic.system.bindAddr");
System.out.println("WEBLOGIC BIND
ADDRESS::" + getIpAddress);
/* Lines added for testing */
/*Socket client=null;
String getIpAddress =
services.config().getProperty("weblogic.system.bindAddr");
client = new
Socket(getIpAddress,C_IOD_IOPENDIOSA_TRACELOG_PORT);
ObjectOutputStream oout = new
ObjectOutputStream(client.getOutputStream() );
oout.writeObject( hash );
ObjectInputStream oin = new
ObjectInputStream(client.getInputStream() );
flag = (String)oin.readObject();
client.close();*/
}catch(Exception e) {
System.out.println("Inside Exception");
throw new IOpenDiosaException(e);
}
}
}// End of ShutDown Trace Class
__________________________________________________
Do You Yahoo!?
Kick off your party with Yahoo! Invites.
http://invites.yahoo.com/
===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".