J2SE 5.0 CORBA logging

I am running the J2SE 5.0 update 2 CORBA features. Just before a CORBA exception is thrown the logging service logs out the following stack trace. I was wondering if there is a way to disable only this function�s console logging?
Apr 14, 2005 3:03:27 PM com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl <init>
WARNING: "IOP00410201: (COMM_FAILURE) Connection failure: socketType: IIOP_CLEAR_TEXT; hostname: 157.176.13.122; port: 2004"
org.omg.CORBA.COMM_FAILURE:   vmcid: SUN  minor code: 201  completed: No
     at com.sun.corba.se.impl.logging.ORBUtilSystemException.connectFailure(ORBUtilSystemException.java:2172)
     at com.sun.corba.se.impl.logging.ORBUtilSystemException.connectFailure(ORBUtilSystemException.java:2193)
     at com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl.<init>(SocketOrChannelConnectionImpl.java:205)
     at com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl.<init>(SocketOrChannelConnectionImpl.java:218)
     at com.sun.corba.se.impl.transport.SocketOrChannelContactInfoImpl.createConnection(SocketOrChannelContactInfoImpl.java:101)
     at com.sun.corba.se.impl.protocol.CorbaClientRequestDispatcherImpl.beginRequest(CorbaClientRequestDispatcherImpl.java:152)
     at com.sun.corba.se.impl.protocol.CorbaClientDelegateImpl.request(CorbaClientDelegateImpl.java:118)thanks for your help,
greg

I am running the J2SE 5.0 update 2 CORBA features. Just before a CORBA exception is thrown the logging service logs out the following stack trace. I was wondering if there is a way to disable only this function�s console logging?
Apr 14, 2005 3:03:27 PM com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl <init>
WARNING: "IOP00410201: (COMM_FAILURE) Connection failure: socketType: IIOP_CLEAR_TEXT; hostname: 157.176.13.122; port: 2004"
org.omg.CORBA.COMM_FAILURE:   vmcid: SUN  minor code: 201  completed: No
     at com.sun.corba.se.impl.logging.ORBUtilSystemException.connectFailure(ORBUtilSystemException.java:2172)
     at com.sun.corba.se.impl.logging.ORBUtilSystemException.connectFailure(ORBUtilSystemException.java:2193)
     at com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl.<init>(SocketOrChannelConnectionImpl.java:205)
     at com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl.<init>(SocketOrChannelConnectionImpl.java:218)
     at com.sun.corba.se.impl.transport.SocketOrChannelContactInfoImpl.createConnection(SocketOrChannelContactInfoImpl.java:101)
     at com.sun.corba.se.impl.protocol.CorbaClientRequestDispatcherImpl.beginRequest(CorbaClientRequestDispatcherImpl.java:152)
     at com.sun.corba.se.impl.protocol.CorbaClientDelegateImpl.request(CorbaClientDelegateImpl.java:118)thanks for your help,
greg

Similar Messages

  • J2SE 1.4 Logging facility

    Hi,
    Can anyone provide me with links to examples of using J2SE 1.4's Logging API?
    Thanks,
    Amit
    [email protected]

    Hi,
    Here's a couple of classes:
    The first is simple logging facility I've written using the logging API (not a complete class - just the relevant method), the second is a generic error class to capture some consistent data across my application.
    Drop me an e-mail if you're still stuck.
    Regards
    Peter.
    public void logError(ClientError error)
    FileHandler fh = null;
    try
    String logDirectoryPath = System.getProperty("user.home")
    + "/Pisces/Log/";
    String filePath = logDirectoryPath + "Error_log.xml";
    File logDirectory = new File(logDirectoryPath);
    if (logDirectory.exists())
    File logFile = new File(filePath);
    else
    logDirectory.mkdir();
    fh = new FileHandler(filePath,true);
    errorLog.addHandler(fh);
    errorLog.logp(Level.SEVERE,
    error.getClassName(),
    error.getMethodName(),
    error.getStackTrace());
    catch (IOException e) { e.printStackTrace(System.out);}
    finally { fh.close(); }
    public class ClientError {
    private String className;
    private String methodName;
    private Date errorTime;
    private String errorMessage;
    private String stackTrace;
    public ClientError() { }
    public void setClassName(String className)
    this.className = className;
    public String getClassName()
    return className;
    public void setMethodName(String methodName)
    this.methodName = methodName;
    public String getMethodName()
    return methodName;
    /* In case we want to set the time where the error occurred. */
    public void setErrorTime(Date errorTime)
    this.errorTime = errorTime;
    /* Sets the date to the current time */
    public void setErrorTime()
    errorTime = new Date();
    public Date getErrorTime()
    return errorTime;
    public void setErrorMessage(String errorMessage)
    this.errorMessage = errorMessage;
    public String getErrorMessage()
    return errorMessage;
    public void setStackTrace(String stackTrace)
    this.stackTrace = stackTrace;
    public String getStackTrace()
    return stackTrace;

  • Installation of JRE-1_4_2-linux-i586.rpm: Linux RH9

    I am kinda of a noob at this so this might be a really simple questions. I just recently installed jre 1.4.2, after following all the processes on the installion page it said this:
    Preparing packages for installation...
    j2re-1.4.2-fcs
    [root@localhost backgrounds]#
    The first question is do I need to take this further?
    The reason for this question is I am installing LimeWireLinux and I got an error message like this:
    [root@localhost backgrounds]# ./LimeWireLinux.bin
    Preparing to install...
    Extracting the installation resources from the installer archive...
    Configuring the installer for this system's environment...
    No Java virtual machine could be found from your PATH
    environment variable. You must install a VM prior to
    running this program.
    [root@localhost backgrounds]#
    So now it won't let me install LimeWire.
    Thank you for your help.

    I decided to answer my reply, since who knows maybe someone else need the same thing. This is thanks to Kevin from the olive.
    This is for the newbies...
    Ok, download limewire from the link above, make sure you have a java vm installed (j2re ...goto http://java.sun.com/j2se/1.3/jre/)
    Log in as root.
    Install J2, then find its path and version (try: ls /usr/java/j2*)
    Before installing Limewire. vi (or however you create files) a file called java.sh :.Click on "more"
    [root@localhost kevin]# vi /etc/profile.d/java.sh
    enter the following:
    JAVA_HOME=/usr/java/j2re...yourversion
    export JAVA_HOME
    PATH=$PATH:$JAVA_HOME/bin
    export PATH
    So my java.sh file looks like this:
    JAVA_HOME=/usr/java/j2re1.4.1_02
    export JAVA_HOME
    PATH=$PATH:$JAVA_HOME/bin
    export PATH
    (note my ls /usr/java/j2* matches the first line in the above file)
    Also change permisions to java.sh:
    chmod +x /etc/profile.d/java.sh
    Now log in as your user, and install Lime wire.
    Once this new file is saved, you will need to type the above 4 lines you put in the java.sh file (again....do this as user, not root) into your command line or reboot. The reason is that this file is read during boot up, since you haven't done thatyet, your OS is not aware of java.sh . Here is the before and after so you see what I am getting at:
    -----------------begin--------------------------
    [kevin@localhost kevin]$ sh LimeWireLinux.bin
    Preparing to install...
    Extracting the installation resources from the installer archive...
    Configuring the installer for this system's environment...
    No Java virtual machine could be found from your PATH
    environment variable. You must install a VM prior to
    running this program.
    [kevin@localhost kevin]$
    [kevin@localhost kevin]$JAVA_HOME=/usr/java/j2re1.4.1_02
    [kevin@localhost kevin]$ export JAVA_HOME
    [kevin@localhost kevin]$ PATH=$PATH:$JAVA_HOME/bin
    [kevin@localhost kevin]$ export PATH
    [kevin@localhost kevin]$ sh LimeWireLinux.bin
    Preparing to install...
    Extracting the installation resources from the installer archive...
    Configuring the installer for this system's environment...
    Launching installer...
    ---------------------end-----------------------------------------
    At this point a box pops up and the rest is point n click. Once installed you will notice in your home directory an new file called "runLimeWire"
    [kevin@localhost kevin]$ ls runLimeWire
    runLimeWire
    So to run LimeWire type:
    [kevin@localhost kevin]$ ./runLimeWire
    ...you will get a box pop up and your off and running......
    Posted by Kevin at June 17, 2003 10:20 PM | TrackBack

  • Siebel exception - SSCASVBC.dll could not be loaded

    We have many CORBA servers written in C++ running on SOlaris box. They connect to Siebel Corba Object Manager running on windows server and fetch the business components.
    I am getting error Siebel exception 4096 "SSCASVBC.dll could not be loaded sometimes when trying to get a business component or sometimes when invoking a business method. If I bounce all the servers the error disappears for 3-4 days and after that again the problem starts. What can be wrong. I do not know much of Siebel. I do not even know where to look for logs and how to enable Siebel logs or CORBA logs. I guess currently no logs are getting generated. Can someone help me please?
    siebel version is 6.3 and we are using visibroker orb for CORBA

    q1: is there a way to tell visual studio 2005 not to produce a .net dll?That's not a Java question. It is a Visual Studio 2005 question. Ask the vendor.
    q2: i tried compiling the code in vc++ 6.0 but got a bunch of "files not found" errors.Then you need to fix them. Again this is not a Java question.
    i don't think the sdk is even compatible with vc++ 6.0. is there an alternative?Once again that question should be directed to the vendor.
    MSDN is probably your friend here.
    has anyone successfully compiled c++ code with gdiplus stuff (graphics, etc...) in vc++ 6.0?Many times.

  • NEED Help in installing SEPA patches - Version 5

    Hi Team,
             Please can you help me with the list of patches for SEPA and its prerequisites.
    We are planning to use SEPA 5.0 Credit Transfer.
    Gone through the metalink note R11i / R12: FAQ for Single European Payments (SEPA) [ID 791226.1] and subsequently further notes from there.
    1) Patch p13510283_11i_GENERIC for SEPA V5
    2) Prequisites are as follows,
    2864765 - TXK Advanced Utilities Rollup A (October 2004)
    3384350 - Patch 11i.SCM_PF.J
    3180816 - Patch 11i.AD.I
    3882116 - REHOST ORACLE 9iR2 JDBC DRIVERS (v9.2.0.5) FOR USE WITH ORACLE APPLICATIONS 11i
    2368042 - Patch 11i.JTA.D (JTA 11.5.7.6)
    3262159 - Patch 11i.FND.H
    3594604 - TXK AUTOCONFIG TEMPLATE ROLLUP PATCH I (October 2004)
    select bug_id, Bug_number from apps.ad_bugs where bug_number in ('2864765','3384350','3180816','3882116','2368042','3262159','3594604')
    "BUG_ID"
    "BUG_NUMBER"
    54056
    "2368042"
    129655
    "2864765"
    126300
    "3262159"
    143919
    "3384350"
    72433
    "3594604"
    111580
    "3882116"
    We are missing 3180816 - Patch 11i.AD.I  patch in our system. This has been superseded by p7429271_11i_SOLARIS.zip.
    We are at the following patch set level,
    Applications DBA
    Shared
    11i.AD.I.5
    Thanks a lot for your support, understanding and time.
    Regards,
    Rajasekaran.

    Hi Hussein,
    1)From the note 246105.1 performed the following and called the URL https://gfs2devweb1.fin.psa:8443/OA_HTML/J2SEtest.jsp
    =============================================================================================
    To create a simple J2SE test page (without logging into the Oracle E-Business Suite database), proceed with the follows:
    Change to the OA_HTML directory on the HTTP server.
    Using a text editor, create a file called J2SEtest.jsp with the following lines:
    The J2SE version is:<%= System.getProperty("java.version") %>
    <p> </p>
    The class path is:<%= System.getProperty("java.class.path") %>
    =============================================================================================
    GOT THE FOLLOWING OUTPUT,
    The J2SE version is:1.4.2_19
    The class path is:/opt/gfsd/gfsdora/iAS/Apache/Jserv/libexec/ApacheJServ.jar:/opt/gfsd/gfsdora/iAS/Apache/Jsdk/lib/jsdk.jar:/opt/gfsd/gfsdora/iAS/jsp/lib/ojsp.jar:/opt/gfsd/gfsdora/iAS/jsp/lib/ojsputil.jar:/opt/gfsd/gfsdora/iAS/lib/servlet.jar:/opt/gfsd/gfsdcomn/java/ojdigsig.zip:/opt/gfsd/gfsdcomn/java/sax2.zip:/opt/gfsd/gfsdcomn/java/xmlparserv2-904.zip:/opt/gfsd/gfsdcomn/java/xdoparser.zip:/opt/gfsd/gfsdora/iAS/sqlj/lib/translator.zip:/opt/gfsd/gfsdcomn/java/jbojdbcpatch.zip:/opt/gfsd/gfsdcomn/java/jdbc14.zip:/opt/gfsd/gfsdcomn/java/nls_charset12.zip:/opt/gfsd/gfsdcomn/java/apps.zip:/opt/gfsd/gfsdcomn/java:/opt/gfsd/gfsdcomn/java/cache.zip:/opt/gfsd/j2sdk1.4.2_19//lib/dt.jar:/opt/gfsd/j2sdk1.4.2_19//lib/tools.jar:/opt/gfsd/j2sdk1.4.2_19//jre/lib/rt.jar:/opt/gfsd/j2sdk1.4.2_19//jre/lib/charsets.jar:/opt/gfsd/gfsdora/iAS/jlib/jssl-1_1.jar:/opt/gfsd/gfsdora/iAS/jlib/javax-ssl-1_1.jar:/opt/gfsd/gfsdora/iAS/rdbms/jlib/aqapi.jar:/opt/gfsd/gfsdora/8.0.6/forms60/java:/opt/gfsd/gfsdora/iAS/rdbms/jlib/jmscommon.jar:/opt/gfsd/gfsdora/iAS/Apache/Jserv/libexec/dms2Server.jar:/opt/gfsd/gfsdora/iAS/lib/oraclexsql.jar:/opt/gfsd/gfsdora/iAS/rdbms/jlib/xsu12.jar:/opt/gfsd/gfsdora/iAS/xdk/lib:/opt/gfsd/gfsdcomn/java/fndoam.zip:/opt/gfsd/gfsdappl/bne/11.5.0/conf:/opt/gfsd/gfsdora/iAS/mp/jlib/opreapi-rt.jar:/opt/gfsd/gfsdora/iAS/mp/jlib/dmtutil.jar:/opt/gfsd/gfsdora/iAS/dm/lib/odmapi.jar:/opt/gfsd/gfsdcomn/java/owa.zip:/opt/gfsd/gfsdora/8.0.6/forms60/java/f60srv.jar:/opt/gfsd/gfsdora/iAS/lib/http_client.jar:/opt/gfsd/gfsdora/iAS/lib/wwcache.jar:/opt/gfsd/gfsdora/iAS/portal30/jpdk/lib/provider.jar:/opt/gfsd/gfsdora/iAS/portal30/jpdk/lib/partnerApp.jar:/opt/gfsd/gfsdora/iAS/mapviewer/lib/sdoapi101.jar:/opt/gfsd/gfsdora/iAS/mapviewer/lib/sdovis.jar:/opt/gfsd/gfsdora/iAS/mapviewer/lib/mapviewer118.jar:/opt/gfsd/gfsdora/8.0.6/vbroker/lib/vbjorb.jar:/opt/gfsd/gfsdora/8.0.6/vbroker/lib/vbjapp.jar:/opt/gfsd/gfsdora/iAS/Apache/Apache/htdocs/disco4iv/disco4res.jar:/opt/gfsd/gfsdora/iAS/soap/webapps/soap/WEB-INF/lib/soap.jar:/opt/gfsd/gfsdora/iAS/Apache/Jserv/servlets
    2) Again calling URL , https://gfs2devweb1.fin.psa:8443/OA_HTML/jsp/fnd/aolj_native_conn_test.jsp
    GOT THE FOLLOWING OUTPUT,
    Connection test results:
    Connect String: jdbc:oracle:thin:apps/*****@gfsmrdev2db1:1551:GFSD
    Successfully obtained a jdbc connection: oracle.jdbc.driver.OracleConnection@51acd5
    Current Database Session ID : 415
    JDBC driver version: 9.2.0.8.0 -- Warning!! You should use at least JDBC Drivers version 9.2.0.5. Please check metalink note#164317.1 for information on how to upgrade your JDBC drivers.
    Testing Result:
    Java Version Number:
    1.4.2_19
    Classpath:
    NOTE: This test gets the classpath from the system variables and analyzes that each entry in it is readable and that it indeed exists. If you have entries in red, that does not mean that the application is broken since the entry might only exist for backwards compatibility and not necesarilly imply an error condition.
    /opt/gfsd/gfsdora/iAS/Apache/Jserv/libexec/ApacheJServ.jar
    /opt/gfsd/gfsdora/iAS/Apache/Jsdk/lib/jsdk.jar
    /opt/gfsd/gfsdora/iAS/jsp/lib/ojsp.jar
    /opt/gfsd/gfsdora/iAS/jsp/lib/ojsputil.jar
    /opt/gfsd/gfsdora/iAS/lib/servlet.jar
    /opt/gfsd/gfsdcomn/java/ojdigsig.zip
    /opt/gfsd/gfsdcomn/java/sax2.zip
    /opt/gfsd/gfsdcomn/java/xmlparserv2-904.zip
    /opt/gfsd/gfsdcomn/java/xdoparser.zip
    /opt/gfsd/gfsdora/iAS/sqlj/lib/translator.zip
    /opt/gfsd/gfsdcomn/java/jbojdbcpatch.zip
    /opt/gfsd/gfsdcomn/java/jdbc14.zip
    /opt/gfsd/gfsdcomn/java/nls_charset12.zip
    NOTE: Below, Apps.zip might be reported in red as missing, but please disregard this message if you already implemented the steps documented in metalink note#220188.1. Only consider this message as valid if apps.zip is missing and you did not implemented the mentioned note or if your applications version is 11.5.9 or above.
    Missing /opt/gfsd/gfsdcomn/java/apps.zip
    /opt/gfsd/gfsdcomn/java
    /opt/gfsd/gfsdcomn/java/cache.zip
    /opt/gfsd/j2sdk1.4.2_19//lib/dt.jar
    /opt/gfsd/j2sdk1.4.2_19//lib/tools.jar
    /opt/gfsd/j2sdk1.4.2_19//jre/lib/rt.jar
    /opt/gfsd/j2sdk1.4.2_19//jre/lib/charsets.jar
    /opt/gfsd/gfsdora/iAS/jlib/jssl-1_1.jar
    /opt/gfsd/gfsdora/iAS/jlib/javax-ssl-1_1.jar
    /opt/gfsd/gfsdora/iAS/rdbms/jlib/aqapi.jar
    /opt/gfsd/gfsdora/8.0.6/forms60/java
    /opt/gfsd/gfsdora/iAS/rdbms/jlib/jmscommon.jar
    /opt/gfsd/gfsdora/iAS/Apache/Jserv/libexec/dms2Server.jar
    /opt/gfsd/gfsdora/iAS/lib/oraclexsql.jar
    /opt/gfsd/gfsdora/iAS/rdbms/jlib/xsu12.jar
    /opt/gfsd/gfsdora/iAS/xdk/lib
    /opt/gfsd/gfsdcomn/java/fndoam.zip
    /opt/gfsd/gfsdappl/bne/11.5.0/conf
    /opt/gfsd/gfsdora/iAS/mp/jlib/opreapi-rt.jar
    /opt/gfsd/gfsdora/iAS/mp/jlib/dmtutil.jar
    /opt/gfsd/gfsdora/iAS/dm/lib/odmapi.jar
    /opt/gfsd/gfsdcomn/java/owa.zip
    /opt/gfsd/gfsdora/8.0.6/forms60/java/f60srv.jar
    /opt/gfsd/gfsdora/iAS/lib/http_client.jar
    /opt/gfsd/gfsdora/iAS/lib/wwcache.jar
    /opt/gfsd/gfsdora/iAS/portal30/jpdk/lib/provider.jar
    Missing /opt/gfsd/gfsdora/iAS/portal30/jpdk/lib/partnerApp.jar
    /opt/gfsd/gfsdora/iAS/mapviewer/lib/sdoapi101.jar
    /opt/gfsd/gfsdora/iAS/mapviewer/lib/sdovis.jar
    /opt/gfsd/gfsdora/iAS/mapviewer/lib/mapviewer118.jar
    /opt/gfsd/gfsdora/8.0.6/vbroker/lib/vbjorb.jar
    /opt/gfsd/gfsdora/8.0.6/vbroker/lib/vbjapp.jar
    /opt/gfsd/gfsdora/iAS/Apache/Apache/htdocs/disco4iv/disco4res.jar
    /opt/gfsd/gfsdora/iAS/soap/webapps/soap/WEB-INF/lib/soap.jar
    /opt/gfsd/gfsdora/iAS/Apache/Jserv/servlets
    =>Try pinging the database with the connection...
    DATABASE_ID gfsmrdev2db1_gfsd
    AOL_VERSION 11.5.0
    SYSDATE 03-JUL-2013 12:21:19
    DATABASE_VERSION Oracle Database 10g Enterprise Edition Release 10.1.0.4.0 - 64bi
    SCHEMA_NAME APPS
    PLEASE HELP TO VALIDATE THE OUTPUT AND CAN WE GO AHEAD WITH THE SEPA PATCHING WITH THIS JDK VERSION.
    Thanks and Regards,
    Rajasekaran.

  • Dealing with J2SE CORBA errors at the WARNING level?

    Sun CORBA Community:
    For several years now (since we upgraded to J2SE 1.5.*) our log files have been filling up with CORBA.COMM_FAILURE errors from the Sun ORB that are thrown at the WARNING level. This has been reported as either a problem or an annoyance by a number of folks in this forum, but there has yet to be a suitable fix or work-around forthcoming.
    An example stack trace is:
    Oct 17, 2008 1:30:54 PM com.sun.corba.se.impl.transport.SocketOrChannelConnectio
    nImpl <init>
    WARNING: "IOP00410201: (COMM_FAILURE) Connection failure: socketType: IIOP_CLEAR
    _TEXT; hostname: 192.168.0.136; port: 58032"
    org.omg.CORBA.COMM_FAILURE: vmcid: SUN minor code: 201 completed: No
    at com.sun.corba.se.impl.logging.ORBUtilSystemException.connectFailure(O
    RBUtilSystemException.java:2172)
    at com.sun.corba.se.impl.logging.ORBUtilSystemException.connectFailure(O
    RBUtilSystemException.java:2193)
    at com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl.<init>(
    SocketOrChannelConnectionImpl.java:205)
    at com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl.<init>(
    SocketOrChannelConnectionImpl.java:218)
    at com.sun.corba.se.impl.transport.SocketOrChannelContactInfoImpl.create
    Connection(SocketOrChannelContactInfoImpl.java:101)
    at com.sun.corba.se.impl.protocol.CorbaClientRequestDispatcherImpl.begin
    Request(CorbaClientRequestDispatcherImpl.java:152)
    at com.sun.corba.se.impl.protocol.CorbaClientDelegateImpl.request(CorbaC
    lientDelegateImpl.java:118)
    at org.omg.CORBA.portable.ObjectImpl._request(ObjectImpl.java:431)
    at org.opencoral.idl.Admin._ClientStub.postedEvent(_ClientStub.java:102)
    at org.opencoral.event.server.EventManagerImpl.postEvent(EventManagerImp
    l.java:284)
    at org.opencoral.idl.Resource.EventManager_Tie.postEvent(EventManager_Ti
    e.java:43)
    at org.opencoral.idl.Resource._EventManagerImplBase._invoke(_EventManage
    rImplBase.java:85)
    at com.sun.corba.se.impl.protocol.CorbaServerRequestDispatcherImpl.dispa
    tchToServant(CorbaServerRequestDispatcherImpl.java:637)
    at com.sun.corba.se.impl.protocol.CorbaServerRequestDispatcherImpl.dispa
    tch(CorbaServerRequestDispatcherImpl.java:189)
    at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleRequest
    Request(CorbaMessageMediatorImpl.java:1680)
    at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleRequest
    (CorbaMessageMediatorImpl.java:1540)
    at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleInput(C
    orbaMessageMediatorImpl.java:922)
    at com.sun.corba.se.impl.protocol.giopmsgheaders.RequestMessage_1_2.call
    back(RequestMessage_1_2.java:181)
    at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleRequest
    (CorbaMessageMediatorImpl.java:694)
    at com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl.dispatc
    h(SocketOrChannelConnectionImpl.java:451)
    at com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl.doWork(
    SocketOrChannelConnectionImpl.java:1189)
    at com.sun.corba.se.impl.orbutil.threadpool.ThreadPoolImpl$WorkerThread.
    run(ThreadPoolImpl.java:417)
    Caused by: java.net.ConnectException: Connection refused
    at sun.nio.ch.Net.connect(Native Method)
    at sun.nio.ch.SocketChannelImpl.connect(SocketChannelImpl.java:464)
    at java.nio.channels.SocketChannel.open(SocketChannel.java:146)
    at com.sun.corba.se.impl.transport.DefaultSocketFactoryImpl.createSocket
    (DefaultSocketFactoryImpl.java:60)
    at com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl.<init>(
    SocketOrChannelConnectionImpl.java:188)
    ... 19 more
    Why does this happen? While I can't speak for others, in our case, I know why it happens and is not something that I want to hear about at the WARNING level. We use CORBA for client/server communications and each client registers with and then receives update information from the server. If someone exits the client properly, by clicking "Exit" in the application, we deregister the client with the server and everything is fine.
    However, if someone simply closes the window to terminate the application, then the next time there is an update, the server tries to send it to a non-existent client and, bingo, we get a CORBA.COMM_FAILURE exception. Of course, getting users to properly exit rather than simply closing the window is a losing battle ....
    While I would argue that this is not a WARNING level problem, that's the way that Sun has chosen to define it in the underlying CORBA stuff.
    So, does anyone have an effective means of dealing with this problem. I thought that I should be able to override the logging level for the appropriate class and change it from WARNING to something lower such as FINE so that our logs listening to INFO level or higher wouldn't see them.
    However, my efforts to do this .... and I don't pretend to be a java.logging wizard ... failed. Maybe I was not resetting the level of the appropriate class. Should the java.logging API let me override a logging level for one of the CORBA classes?
    Any insights or suggestions as to how to better deal with this problem would be greatly appreciated.
    Thanks for your consideration,
    John

    Hi,
    I hope you have carried out the following activities:
    1. Carry out standard cost estimate for the materials involved.
    2. Check KKPAN to see the cost details of the product.
    Need more details on the steps that you have carried out so far.
    Regards,
    SGP.
    P.S - assign points incase the info was useful.

  • How to use j2se 1.4 logging features with j2ee 1.3

    Hi,
    We have developed an EJB that will run in the j2ee 1.3 container of weblogic 5.0
    We would like to use the logging features of j2se 1.4 in our ejb.
    Can this be done ?
    How do I install and use j2se 1.4 a long side of j2ee 1.3 ?
    Is this a recognised configuration ?
    Many Thanks,
    Mark.

    Is it possible to install j2se 1.4 on the same machine
    that is running weblogic with j2ee 1.3 ? Yes.
    If it is.... How do we do it ?Just install it in different directory - the installer will do this for you by default anyway.
    How do we protect our code running in the j2ee 1.3 container from
    mistakenly using the classes provided with j2se 1.4 ?Thats what PATH and CLASSPATH environment variables are for. Read the tutorials on the left there for more information.
    Do we end up with 2 separate VMs one a implementing
    j2ee 1.3 and one a j2se 1.4 ?You end up with as many as you run.
    Every time you run java (java.exe on windows, just plain java on UNIX) you run the version of the VM that's on your PATH.
    It's quite normal to have (on the same machine) a 1.3 VM running Weblogic and a number of 1.4 VM's as clients of that Weblogic installation.
    I think I'm right in saying that 1.4 VM's are (in some cases) regarded by BEA as supported clients of a Weblogic server running in a 1.3 VM, but you'd have to check their e-docs site for exact details.

  • Hello, I'm getting the follwing error in my logs when  trying to use javabeans on a nes 4.0 sp3 with j2se

    JSP compilation error: java.lang.Exception: JSP parse error (line 66) - Incomplete tag ending of /jsp:useBean, stack: java.lang.Exception: JSP parse error (line 66) - Incomplete tag ending of /jsp:useBean

    Use the following steps to fix the problem:
    Add the following line to the JSP:
    <%@ page import = "BeanName" %>
    The BeanName is the name of the bean you would like to use. This name should not include the .class extension.
    Set the classpath for Java in the server so that it includes the directory where the JavaBean is located.
    From the Admin server, click the Servers tab, Manager Servers.
    Select the server instance that you would like to configure.
    Click Manage.
    Click the Servlets tab, Configure JVM Attributes.
    At the end of the classpath field, add the path to the directory where
    your bean is located.
    Note: Remember to separate statements in the classpath by semicolons.
    Click OK.
    When prompted, click Save and Apply.
    Completing the above steps will enable the server to find the JavaBean that
    you are trying to use in a JSP.

  • How to call a CORBA Object in a 3rd Party ORB from a EJB

    Hello
    I found a few articles on the web how to call EJBs for example from C++.
    However, I want to do the inverse. I want to resolve an Object (implemented in C++, using OmniORB) via COS-Naming and invoke it from a EJB. I can write a simple Java Client which does this without a problem. But as soon as I try to do the same in EJB I get the following:
    [#|2004-11-09T10:48:16.848+0100|WARNING|sun-appserver-pe8.0.0_01|javax.enterprise.resource.corba._DEFAULT_.rpc.transport|_ThreadID=12;|"IOP00710209: (INTERNAL) Unable to create listener thread on the specific port"
    org.omg.CORBA.INTERNAL: vmcid: SUN minor code: 209 completed: No
    at com.sun.corba.ee.impl.logging.ORBUtilSystemException.createListenerFailed(ORBUtilSystemException.java:3142)
    at com.sun.corba.ee.impl.logging.ORBUtilSystemException.createListenerFailed(ORBUtilSystemException.java:3160)
    at com.sun.corba.ee.impl.legacy.connection.SocketFactoryAcceptorImpl.initialize(SocketFactoryAcceptorImpl.java:60)
    at com.sun.corba.ee.impl.transport.CorbaTransportManagerImpl.getAcceptors(CorbaTransportManagerImpl.java:190)
    at com.sun.corba.ee.impl.transport.CorbaTransportManagerImpl.addToIORTemplate(CorbaTransportManagerImpl.java:207)
    at com.sun.corba.ee.spi.oa.ObjectAdapterBase.initializeTemplate(ObjectAdapterBase.java:104)
    I think there is somehow a conflict because the SUN Appserver also uses CORBA. My Code looks like this:
    String[] a = null;
    Properties props = new Properties();
    final String CORBA_HOST = "arcos";
    final String ORB_INITIAL_PORT = "2809";
    props.put("org.omg.CORBA.ORBInitialPort", ORB_INITIAL_PORT);
    props.put("org.omg.CORBA.ORBInitialHost", CORBA_HOST);
    org.omg.CORBA.ORB orb = org.omg.CORBA.ORB.init(a, props);
    So I thought this might be because there is already a ORB initialised. So I replaced the last line with
    org.omg.CORBA.ORB orb = org.omg.CORBA.ORB.init();
    Which should give me an ORB instance. However I get the following exception:
    [#|2004-11-09T11:51:59.206+0100|WARNING|sun-appserver-pe8.0.0_01|javax.enterprise.system.stream.err|_ThreadID=15;|
    org.omg.CORBA.NO_IMPLEMENT: vmcid: SUN minor code: 201 completed: No
    at com.sun.corba.ee.impl.logging.ORBUtilSystemException.genericNoImpl(ORBUtilSystemException.java:7085)
    at com.sun.corba.ee.impl.logging.ORBUtilSystemException.genericNoImpl(ORBUtilSystemException.java:7107)
    at com.sun.corba.ee.impl.orb.ORBSingleton.resolve_initial_references(ORBSingleton.java:311)
    at com.ascom.util.CorbaNaming.resolve(CorbaNaming.java:26)
    at com.ascom.fxm.FileManager.<init>(FileManager.java:46)
    at com.ascom.srv.file.web.FileImporterImpl.importFile(FileImporterImpl.java:146)
    Any ideas? Thank you very much in advance.
    Oliver Jaun

    Perhaps you could take a look at the following document and see if it meets your needs:
    http://java.sun.com/j2se/1.4.2/docs/guide/rmi-iiop/interop.html

  • CORBA related issue in JRE 1.4.2_06

    Hi Experts,
    We have an application written in C and Java. Communication is handled by CORBA using ORB form JRE. JRE 1.4.2_06 is used.
    We're currently facing application hanging or crashing. Log files have the following exceptions:
    com.sun.corba.se.internal.iiop.ReaderThread(Thread[JavaIDL Reader for javatech.us.oracle.com:1079,5,ORB ThreadGroup]): Exception thrown while reading request: java.lang.OutOfMemoryError: unable to create new native thread
    java.lang.OutOfMemoryError: unable to create new native thread
    at java.lang.Thread.start(Native Method)
    at com.sun.corba.se.internal.orbutil.ThreadPool.addWork(ThreadPool.java:181)
    at com.sun.corba.se.internal.iiop.MessageMediator.handleInput(MessageMediator.java:221)
    at com.sun.corba.se.internal.iiop.messages.RequestMessage_1_2.callback(RequestMessage_1_2.java:164)
    at com.sun.corba.se.internal.iiop.MessageMediator.processRequest(MessageMediator.java:142)
    at com.sun.corba.se.internal.iiop.IIOPConnection.processInput(IIOPConnection.java:336)
    at com.sun.corba.se.internal.iiop.ReaderThread.run(ReaderThread.java:60)
    Exception 50125 (org.omg.CORBA.COMM_FAILURE: vmcid: SUN minor code: 203 completed: No
    at com.sun.corba.se.internal.iiop.IIOPConnection.sendWithoutLock(IIOPConnection.java:768)
    at com.sun.corba.se.internal.iiop.BufferManagerWriteStream.sendFragment(BufferManagerWriteStream.java:87)
    at com.sun.corba.se.internal.iiop.BufferManagerWriteStream.sendMessage(BufferManagerWriteStream.java:107)
    at com.sun.corba.se.internal.iiop.IIOPOutputStream.finishSendingMessage(IIOPOutputStream.java:159)
    at com.sun.corba.se.internal.iiop.IIOPOutputStream.invoke(IIOPOutputStream.java:117)
    at com.sun.corba.se.internal.iiop.ClientRequestImpl.invoke(ClientRequestImpl.java:76)
    at com.sun.corba.se.internal.corba.ClientDelegate.invoke(ClientDelegate.java:235)
    at com.sun.corba.se.internal.corba.ClientDelegate.invoke(ClientDelegate.java:282)
    at org.omg.CORBA.portable.ObjectImpl._invoke(ObjectImpl.java:457)
    Exception 50125 (org.omg.CORBA.COMM_FAILURE: vmcid: SUN minor code: 208 completed: Maybe
    at com.sun.corba.se.internal.iiop.IIOPConnection.purge_calls(IIOPConnection.java:438)
    at com.sun.corba.se.internal.iiop.ReaderThread.run(ReaderThread.java:70)
    If I use JRE 1.4.2_14, the situation improves.
    Any suggestions on where the problem might be?
    Thanks

    Hello, sorry to jump on this thread, but I am having a similar issue with version 1.4.2_08
    We have a site that checks the current version of java before trying to load an applet, and if the version is not 1.4.2-08 or higher it prompts them to install...
    j2re-1_4_2_08-windows-i586-p.exe
    I am having an issue on a few different computers where even after they install and reboot, it prompts them to install again.
    on the one I am currently working on, they have win98 IE6
    the advanced tab of internet options has selections for MS JIT Compiler, and sun java 1.5 but not 1.4.2_08
    none of these are checked currently...
    This customer had installed 1.4.2_08 from our site, and it dodnt work, so they installed 1.5 from the java website.
    I had them Uninstall everything that said java from add/remove programs (J2SE 5.0 and JRE 1.4.2_08), reboot, and when we came back to the site, it prompted to install again, so we did, only this time the installer prompted to "modify" or "remove"
    We tried Modify first, and rebooted, cand it didnt work, so we tried remove, reboot, and reinstalled again (this time it didnt have the modify option) but the site still wont pass the version check.
    at this point, the internet options still have options for Sun Java 1.5 (which isnt currently installed) and MS JIT Compiler (both unchecked)
    Our diagnostics site reports thier version of java as MS 1.1 (IE isnt even trying to load the Sun Java apparently)
    If this is the same issue, hopefully this will help us both fix our issues, if you dont think this is the same issue, lemme know and ill post in a new topic.
    thanks in advanced for your help.

  • Deploying a Java CORBA application in Web Start

    I am a novice to Java Web Start. I have a sample Client-Server application with CORBA as a middle ware. The front end (Client) is in Java and back end (Server) is in C++. The application is run and tested with jar and batch file. Now I want to deploy that application in Java Web Start and JNLP.
    I have configured the same by creating a JNLP file and signed jars.
    Now as all knows any CORBA application needs a domain file ( .cfg ) and some org.omg classes to communicate with the server by RPC.
    I am stuck with how to specify these domain file name, path, CORBA classes etc in my JNLP. Not even that, I can't understand exactly what configuration will make the CORBA apps work properly in Java Web Start so that it can communicate with the server as well. All the Orbix jars's, IDL Stub jars are present and signed. I am giving my JNLP file as a reference. Actually I have tried adding these domain files and CORBA classes as parameters. But as usual it is not working and after running the JNLP the Java console suddenly gets disappeared.
    CORBADemo.jnlp
    <?xml version="1.0" encoding="UTF-8"?>
    <jnlp spec="1.0+" codebase="http://172.28.1.139:8400/Test_CORBA_App" href="CORBADemo.jnlp">
    <information>
         <title>CORBA Demo</title>
         <vendor>Ushacomm</vendor>
    </information>
    <resources>
         <j2se version="1.6+" href="http://java.sun.com/products/autodl/j2se"/>
         <jar href="lib_6.3-Signed/UI_Fall_Test63.jar" main="true" download="eager" />
         <jar href="lib_6.3-Signed/ConfigurationService.jar" download="eager" />
         <jar href="lib_6.3-Signed/IDLStub.jar" download="eager" />
         <jar href="lib_6.3-Signed/art-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/art.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2_ip-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2_ip.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2_ip_cio-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2_ip_cio.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2_ip_nio-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2_ip_nio.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2_tls-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2_tls.jar" download="eager" />
         <jar href="lib_6.3-Signed/codeset.jar" download="eager" />
         <jar href="lib_6.3-Signed/concurrency-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/concurrency.jar" download="eager" />
         <jar href="lib_6.3-Signed/ifc-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/ifc.jar" download="eager" />
         <jar href="lib_6.3-Signed/iiop.jar" download="eager" />
         <jar href="lib_6.3-Signed/java_management_logging-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/java_mgmt_plugin-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/java_portable_interceptor-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/management-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/management.jar" download="eager" />
         <jar href="lib_6.3-Signed/mgmt.jar" download="eager" />
         <jar href="lib_6.3-Signed/omg-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/omg.jar" download="eager" />
         <jar href="lib_6.3-Signed/perf_logging.jar" download="eager" />
         <jar href="lib_6.3-Signed/portable_interceptor.jar" download="eager" />
         <property name="Dorg.omg.CORBA.ORBClass" value="com.iona.corba.art.artimpl.ORBImpl"/>
         <property name="Dorg.omg.CORBA.ORBSingletonClass" value="com.iona.corba.art.artimpl.ORBSingleton"/>
         <property name="ORBdomain_name" value="VOIAMODOMAINNEW"/>
    </resources>
    <application-desc name="CORBADemo Demo Application" main-class="Launch" width="300" height="300">
    </application-desc>
    <update check="background"/>
    <argument>1</argument>
    <security>
         <all-permissions/>
    </security>
    </jnlp>
    .

    *@ gimbal2 and EJP :*
    The firewall is present and allowed to access apps. When I am running the jar of my application from batch file then everything is running fine. The CORBA Server is a remote RHEL5 (Enterprise Linux 5) machine whose 'IP' and 'Hostname' is specified in *"C:\WINDOWS\system32\drivers\etc\hosts"* file. Server is running fine and after starting the Client the Server side remote method is invoked. Data fetched properly and everything is working like a charm.
    When running from batch (.bat) file using jar My applications folder hierarchy is something like this.
    Test_CORBA_App
    ------+config ( contains resources file and domain file )
    ------+lib_6.3 ( contains all Jars)
    ------+log ( will contaiin the generated log files )
    -------runCORBA_App.bat ( the batch file I am running )
    As depicted above the folder hierarchy, my domain file resides in "config" folder. The contents of the batch file are as follows :
    runCORBA_App.bat
    C:\jdk1.6.0_14\bin\java -Xms64M -Xmx512M -Dorg.omg.CORBA.ORBClass=com.iona.corba.art.artimpl.ORBImpl -Dorg.omg.CORBA.ORBSingletonClass=com.iona.corba.art.artimpl.ORBSingleton -jar lib_6.3\UI_Fall_Test63.jar -ORBdomain_name VOIAMODOMAINNEW 1
    pause
    The following things are specified in the batch file :
    1. JDK path : ( C:\jdk1.6.0_14\bin\java )
    2. Java VM arguments for max and min memory : ( -Xms64M -Xmx512M )
    3. ORB class name: ( -Dorg.omg.CORBA.ORBClass=com.iona.corba.art.artimpl.ORBImpl )
    4. ORB singleton class name : ( -Dorg.omg.CORBA.ORBSingletonClass=com.iona.corba.art.artimpl.ORBSingleton )
    5. Jar file name to run : ( -jar lib_6.3\UI_Fall_Test63.jar )
    6. Domain Name : ( -ORBdomain_name VOIAMODOMAINNEW )
    7. Main function args : ( 1 )
    I am trying to deploy this simple CORBA application in Java Web Start and JNLP. I kept this in my tomcat server web apps. The folder hierarchy is as follows :
    tomcat
    ---+ bin
    ---+ conf
    ---+ ..
    ---+ ..
    ---+ ..
    ---_ webapps
    ----------+ host-manager
    ----------+ manager
    ----------+ ..
    ----------+ ..
    ----------_ Test_CORBA_App
    -------------------+ config
    -------------------+ lib_6.3
    -------------------+ lib_6.3-Signed
    -------------------+ log
    --------------------CORBADemo.jnlp (.jnlp file)
    --------------------index.html (.html file)
    As you can see I maintained the same folder structure as it was when running from batch file. The jars I am using is signed and kept in lib_6.3-Signed folder.
    My updated "CORBADemo.jnlp" is :
    CORBADemo.jnlp
    <?xml version="1.0" encoding="UTF-8"?>
    <jnlp spec="1.0+" codebase="http://172.28.1.139:8400/Test_CORBA_App" href="CORBADemo.jnlp">
    <information>
         <title>CORBA Demo</title>
         <vendor>Ushacomm</vendor>
    </information>
    <resources>
         <j2se version="1.6" href="http://java.sun.com/products/autodl/j2se" java-vm-args="-Xms64M -Xmx512M 1" />
         <jar href="lib_6.3-Signed/UI_Fall_Test63.jar" main="true" download="eager" />
         <jar href="lib_6.3-Signed/ConfigurationService.jar" download="eager" />
         <jar href="lib_6.3-Signed/IDLStub.jar" download="eager" />
         <jar href="lib_6.3-Signed/art-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/art.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2_ip-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2_ip.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2_ip_cio-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2_ip_cio.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2_ip_nio-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2_ip_nio.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2_tls-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/atli2_tls.jar" download="eager" />
         <jar href="lib_6.3-Signed/codeset.jar" download="eager" />
         <jar href="lib_6.3-Signed/concurrency-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/concurrency.jar" download="eager" />
         <jar href="lib_6.3-Signed/ifc-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/ifc.jar" download="eager" />
         <jar href="lib_6.3-Signed/iiop.jar" download="eager" />
         <jar href="lib_6.3-Signed/java_management_logging-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/java_mgmt_plugin-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/java_portable_interceptor-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/management-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/management.jar" download="eager" />
         <jar href="lib_6.3-Signed/mgmt.jar" download="eager" />
         <jar href="lib_6.3-Signed/omg-rt.jar" download="eager" />
         <jar href="lib_6.3-Signed/omg.jar" download="eager" />
         <jar href="lib_6.3-Signed/perf_logging.jar" download="eager" />
         <jar href="lib_6.3-Signed/portable_interceptor.jar" download="eager" />
         <property name="Dorg.omg.CORBA.ORBClass" value="com.iona.corba.art.artimpl.ORBImpl"/>
         <property name="Dorg.omg.CORBA.ORBSingletonClass" value="com.iona.corba.art.artimpl.ORBSingleton"/>
         <property name="ORBdomain_name" value="VOIAMODOMAINNEW"/>
    </resources>
    <application-desc name="CORBADemo Demo Application" main-class="Launch" width="300" height="300">
    </application-desc>
    <update check="background"/>
    <argument>1</argument>
    <security>
         <all-permissions/>
    </security>
    </jnlp>
    N.B
    *1. I am running the Tomcat server in my own machine on port 8400 ( for sure, as I have deployed many .war files using this tomcat and all worked ). And using the URL below running the WebStart application.*
    *2. I am running the JNLP from my own machine.*
    *3. CORBA server is running on a remote RHEL 5 machine as I mentioned before also.*
    URL : http://<My Machine IP>:8400/Test_CORBA_App/
    As desired the Web Start application will make a call to the remote CORBA server on RHEL5 machine by initializing the ORB and resolving the CORBA NamingService. But exception is occurring as I posted in previous post i.e exception while resolving NamingService.
    Now my query is whether the domain file ( DOMAIN.cfg ) is reading/ accessing properly from my machine while running the JNLP or not. Because I presume in Java Web Start special attention is required to read any .cfg file. If everything is fine why the error is occurring.
    *@ EJP :* The ORB is desired to run and running on the CORBA Server remote macine i.e RHEL5 machine, because from batch file it is working fine.
    Is it so that I need to run the Tomcat Web Server and CORBA Server from the same machine.

  • CORBA communication trouble - BAD_PARAM?

    Being into learning how to use CORBA with Java, I'm following the trail through the Java IDL tutorial to be found at
    http://java.sun.com/j2se/1.4.2/docs/guide/idl/GShome.html
    This is what I did so far:
    - an orbd is running at localhost, port 1050.
    - the HelloServer implementation is up and running
    - the HelloClient implementation starts up, gets a server object and tries to call a remote function, which, then, fails:
    server object: IOR:000000000000001749444c3a48656c6c6f4170702f48656c6c6f3a312e300000000000010000000000000082000102000000000a3132372e302e302e3100edca00000031afabcb0000000020c8ea754600000001000000000000000100000008526f6f74504f410000000008000000010000000014000000000000020000000100000020000000000001000100000002050100010001002000010109000000010001010000000026000000020002
    exception: org.omg.CORBA.BAD_PARAM: ----------BEGIN server-side stack trace----------
    org.omg.CORBA.BAD_PARAM: vmcid: SUN minor code: 201 completed: Maybe
         at com.sun.corba.se.impl.logging.ORBUtilSystemException.nullParam(ORBUtilSystemException.java:1099)
         at com.sun.corba.se.impl.logging.ORBUtilSystemException.nullParam(ORBUtilSystemException.java:1113)
         at com.sun.corba.se.impl.encoding.CDROutputStream_1_0.writeString(CDROutputStream_1_0.java:473)
         at com.sun.corba.se.impl.encoding.CDROutputStream_1_0.write_string(CDROutputStream_1_0.java:467)
         at com.sun.corba.se.impl.encoding.CDROutputStream.write_string(CDROutputStream.java:153)
         at HelloApp.HelloPOA._invoke(HelloPOA.java:40)
         at com.sun.corba.se.impl.protocol.CorbaServerRequestDispatcherImpl.dispatchToServant(CorbaServerRequestDispatcherImpl.java:637)
         at com.sun.corba.se.impl.protocol.CorbaServerRequestDispatcherImpl.dispatch(CorbaServerRequestDispatcherImpl.java:189)
         at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleRequestRequest(CorbaMessageMediatorImpl.java:1680)
         at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleRequest(CorbaMessageMediatorImpl.java:1540)
         at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleInput(CorbaMessageMediatorImpl.java:922)
         at com.sun.corba.se.impl.protocol.giopmsgheaders.RequestMessage_1_2.callback(RequestMessage_1_2.java:181)
         at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleRequest(CorbaMessageMediatorImpl.java:694)
         at com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl.dispatch(SocketOrChannelConnectionImpl.java:451)
         at com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl.doWork(SocketOrChannelConnectionImpl.java:1187)
         at com.sun.corba.se.impl.orbutil.threadpool.ThreadPoolImpl$WorkerThread.run(ThreadPoolImpl.java:398)
    ----------END server-side stack trace---------- vmcid: SUN minor code: 201 completed: Maybe
    org.omg.CORBA.BAD_PARAM: ----------BEGIN server-side stack trace----------
    org.omg.CORBA.BAD_PARAM: vmcid: SUN minor code: 201 completed: Maybe
         at com.sun.corba.se.impl.logging.ORBUtilSystemException.nullParam(ORBUtilSystemException.java:1099)
         at com.sun.corba.se.impl.logging.ORBUtilSystemException.nullParam(ORBUtilSystemException.java:1113)
         at com.sun.corba.se.impl.encoding.CDROutputStream_1_0.writeString(CDROutputStream_1_0.java:473)
         at com.sun.corba.se.impl.encoding.CDROutputStream_1_0.write_string(CDROutputStream_1_0.java:467)
         at com.sun.corba.se.impl.encoding.CDROutputStream.write_string(CDROutputStream.java:153)
         at HelloApp.HelloPOA._invoke(HelloPOA.java:40)
         at com.sun.corba.se.impl.protocol.CorbaServerRequestDispatcherImpl.dispatchToServant(CorbaServerRequestDispatcherImpl.java:637)
         at com.sun.corba.se.impl.protocol.CorbaServerRequestDispatcherImpl.dispatch(CorbaServerRequestDispatcherImpl.java:189)
         at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleRequestRequest(CorbaMessageMediatorImpl.java:1680)
         at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleRequest(CorbaMessageMediatorImpl.java:1540)
         at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleInput(CorbaMessageMediatorImpl.java:922)
         at com.sun.corba.se.impl.protocol.giopmsgheaders.RequestMessage_1_2.callback(RequestMessage_1_2.java:181)
         at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleRequest(CorbaMessageMediatorImpl.java:694)
         at com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl.dispatch(SocketOrChannelConnectionImpl.java:451)
         at com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl.doWork(SocketOrChannelConnectionImpl.java:1187)
         at com.sun.corba.se.impl.orbutil.threadpool.ThreadPoolImpl$WorkerThread.run(ThreadPoolImpl.java:398)
    ----------END server-side stack trace---------- vmcid: SUN minor code: 201 completed: Maybe
         at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
         at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
         at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
         at com.sun.corba.se.impl.protocol.giopmsgheaders.MessageBase.getSystemException(MessageBase.java:902)
         at com.sun.corba.se.impl.protocol.giopmsgheaders.ReplyMessage_1_2.getSystemException(ReplyMessage_1_2.java:99)
         at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.getSystemExceptionReply(CorbaMessageMediatorImpl.java:572)
         at com.sun.corba.se.impl.protocol.CorbaClientRequestDispatcherImpl.processResponse(CorbaClientRequestDispatcherImpl.java:430)
         at com.sun.corba.se.impl.protocol.CorbaClientRequestDispatcherImpl.marshalingComplete(CorbaClientRequestDispatcherImpl.java:326)
         at com.sun.corba.se.impl.protocol.CorbaClientDelegateImpl.invoke(CorbaClientDelegateImpl.java:129)
         at org.omg.CORBA.portable.ObjectImpl._invoke(ObjectImpl.java:457)
         at HelloApp._HelloStub.sayHello(_HelloStub.java:19)
         at HelloApp.HelloClient.main(HelloClient.java:23)
    Any ideas what's wrong here? As said, to figure out how to deal with CORBA in Java, I exactly followed the tutorial code using idlj and the SUN orbd from JDK 1.5.0_01. Can someone enlighten me?
    TIA and have a fine sunday,
    Kris

    Being into learning how to use CORBA with Java, I'm following the trail through the Java IDL tutorial to be found at
    http://java.sun.com/j2se/1.4.2/docs/guide/idl/GShome.html
    This is what I did so far:
    - an orbd is running at localhost, port 1050.
    - the HelloServer implementation is up and running
    - the HelloClient implementation starts up, gets a server object and tries to call a remote function, which, then, fails:
    server object: IOR:000000000000001749444c3a48656c6c6f4170702f48656c6c6f3a312e300000000000010000000000000082000102000000000a3132372e302e302e3100edca00000031afabcb0000000020c8ea754600000001000000000000000100000008526f6f74504f410000000008000000010000000014000000000000020000000100000020000000000001000100000002050100010001002000010109000000010001010000000026000000020002
    exception: org.omg.CORBA.BAD_PARAM: ----------BEGIN server-side stack trace----------
    org.omg.CORBA.BAD_PARAM: vmcid: SUN minor code: 201 completed: Maybe
         at com.sun.corba.se.impl.logging.ORBUtilSystemException.nullParam(ORBUtilSystemException.java:1099)
         at com.sun.corba.se.impl.logging.ORBUtilSystemException.nullParam(ORBUtilSystemException.java:1113)
         at com.sun.corba.se.impl.encoding.CDROutputStream_1_0.writeString(CDROutputStream_1_0.java:473)
         at com.sun.corba.se.impl.encoding.CDROutputStream_1_0.write_string(CDROutputStream_1_0.java:467)
         at com.sun.corba.se.impl.encoding.CDROutputStream.write_string(CDROutputStream.java:153)
         at HelloApp.HelloPOA._invoke(HelloPOA.java:40)
         at com.sun.corba.se.impl.protocol.CorbaServerRequestDispatcherImpl.dispatchToServant(CorbaServerRequestDispatcherImpl.java:637)
         at com.sun.corba.se.impl.protocol.CorbaServerRequestDispatcherImpl.dispatch(CorbaServerRequestDispatcherImpl.java:189)
         at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleRequestRequest(CorbaMessageMediatorImpl.java:1680)
         at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleRequest(CorbaMessageMediatorImpl.java:1540)
         at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleInput(CorbaMessageMediatorImpl.java:922)
         at com.sun.corba.se.impl.protocol.giopmsgheaders.RequestMessage_1_2.callback(RequestMessage_1_2.java:181)
         at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleRequest(CorbaMessageMediatorImpl.java:694)
         at com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl.dispatch(SocketOrChannelConnectionImpl.java:451)
         at com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl.doWork(SocketOrChannelConnectionImpl.java:1187)
         at com.sun.corba.se.impl.orbutil.threadpool.ThreadPoolImpl$WorkerThread.run(ThreadPoolImpl.java:398)
    ----------END server-side stack trace---------- vmcid: SUN minor code: 201 completed: Maybe
    org.omg.CORBA.BAD_PARAM: ----------BEGIN server-side stack trace----------
    org.omg.CORBA.BAD_PARAM: vmcid: SUN minor code: 201 completed: Maybe
         at com.sun.corba.se.impl.logging.ORBUtilSystemException.nullParam(ORBUtilSystemException.java:1099)
         at com.sun.corba.se.impl.logging.ORBUtilSystemException.nullParam(ORBUtilSystemException.java:1113)
         at com.sun.corba.se.impl.encoding.CDROutputStream_1_0.writeString(CDROutputStream_1_0.java:473)
         at com.sun.corba.se.impl.encoding.CDROutputStream_1_0.write_string(CDROutputStream_1_0.java:467)
         at com.sun.corba.se.impl.encoding.CDROutputStream.write_string(CDROutputStream.java:153)
         at HelloApp.HelloPOA._invoke(HelloPOA.java:40)
         at com.sun.corba.se.impl.protocol.CorbaServerRequestDispatcherImpl.dispatchToServant(CorbaServerRequestDispatcherImpl.java:637)
         at com.sun.corba.se.impl.protocol.CorbaServerRequestDispatcherImpl.dispatch(CorbaServerRequestDispatcherImpl.java:189)
         at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleRequestRequest(CorbaMessageMediatorImpl.java:1680)
         at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleRequest(CorbaMessageMediatorImpl.java:1540)
         at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleInput(CorbaMessageMediatorImpl.java:922)
         at com.sun.corba.se.impl.protocol.giopmsgheaders.RequestMessage_1_2.callback(RequestMessage_1_2.java:181)
         at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.handleRequest(CorbaMessageMediatorImpl.java:694)
         at com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl.dispatch(SocketOrChannelConnectionImpl.java:451)
         at com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl.doWork(SocketOrChannelConnectionImpl.java:1187)
         at com.sun.corba.se.impl.orbutil.threadpool.ThreadPoolImpl$WorkerThread.run(ThreadPoolImpl.java:398)
    ----------END server-side stack trace---------- vmcid: SUN minor code: 201 completed: Maybe
         at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
         at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
         at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
         at com.sun.corba.se.impl.protocol.giopmsgheaders.MessageBase.getSystemException(MessageBase.java:902)
         at com.sun.corba.se.impl.protocol.giopmsgheaders.ReplyMessage_1_2.getSystemException(ReplyMessage_1_2.java:99)
         at com.sun.corba.se.impl.protocol.CorbaMessageMediatorImpl.getSystemExceptionReply(CorbaMessageMediatorImpl.java:572)
         at com.sun.corba.se.impl.protocol.CorbaClientRequestDispatcherImpl.processResponse(CorbaClientRequestDispatcherImpl.java:430)
         at com.sun.corba.se.impl.protocol.CorbaClientRequestDispatcherImpl.marshalingComplete(CorbaClientRequestDispatcherImpl.java:326)
         at com.sun.corba.se.impl.protocol.CorbaClientDelegateImpl.invoke(CorbaClientDelegateImpl.java:129)
         at org.omg.CORBA.portable.ObjectImpl._invoke(ObjectImpl.java:457)
         at HelloApp._HelloStub.sayHello(_HelloStub.java:19)
         at HelloApp.HelloClient.main(HelloClient.java:23)
    Any ideas what's wrong here? As said, to figure out how to deal with CORBA in Java, I exactly followed the tutorial code using idlj and the SUN orbd from JDK 1.5.0_01. Can someone enlighten me?
    TIA and have a fine sunday,
    Kris

  • Problem using Java Webstart to kick off CORBA Client

    Dear all,
    I am currently having a problem in using the Java Webstart to kick off
    the CORBA Client, I set up the JNLP file jvm properties as following:
    <resources>
    <j2se version="1.4*" java-vm-args="-Xms64m -Xmx256m -verbose -esa
    -Xnoclassgc -client -Dswing.useSystemFontSettings=false ">
         <resources>
         <property name="vbroker.orb.initRef"
    value="NameService=corbaloc::10.35.55.82:20005/NameService"/>
    </resources>
    </j2se>
    </resources>
    The problem I have is that when the webstart starting the client, the
    client just simply dies during the startup and I find the log message
    following:
    org.omg.CORBA.ORBPackage.InvalidName
         at com.inprise.vbroker.orb.ORB.resolve_initial_references(ORB.java:943)
    So it is showing that there is problem with the vbroker.orb.initRef
    setting, know that if I don't use the webstart to start the client and
    simply use the windows batch file, using the jvm properties as:
    java -Dvbroker.orb.initRef=NameService=corbaloc::10.31.51.80:20001/NameService
    It would work perfectly.
    Could you tell if I miss anything when configuing the webstart jnlp
    file on this regard? Currently, I think that the only way I can set
    the JVM properties in the JNLP file is to use its properties tag to
    set the system properties for the application.
    Thanks heaps in advance for any help you can give here !!!
    Victor

    Hi, Andre,
    No, I have tried both of your suggestion and there was no joy. I still have the following error and the client jvm just crashes during starting up:
    org.omg.CORBA.ORBPackage.InvalidName
         at com.inprise.vbroker.orb.ORB.resolve_initial_references(ORB.java:943)
    I believe it is still related to the jvm properties:
    <property name="vbroker.orb.initRef" value="NameService=corbaloc::10.35.55.82:20005/NameService"/>
    And know that when I used "-Dvbroker.orb.initRef=NameService=corbaloc::10.35.55.82:20005/NameService" in the windows batch file, the client runs ok.
    Is this indicating that there is the limitation of using the webstart to invoke CORBA client?
    Any further help would be very appreciated!
    Victor

  • How do I find whatever a "J2SE Installation" is?

    The raptor script (on Fedora Core 4 Linux) asks me to "Type the full pathname of a J2SE installation". I have searched for anything beginning with J2SE or j2se and come up empty.
    I have also installed the Sun JDK and provided the path to tht installation, to which the script replies "Error: Java home /usr/java/jdk1.5.0_06/jre/bin/java is not a J2SE SDK.
    Running Oracle Raptor 1.0 under a JRE is not supported."
    I have Enterprise 10gR2 installed on this host.
    How do I locate this "J2SE Installaion", and if its not installed, where do I get it?
    Thanks

    hi
    I get the same thing with Raptor on Red Hat Linux 9 , i cant start it although I got latest J2SE and latest JDKs
    Oracle SQL Developer 1.0
    Copyright (c) 2005 Oracle Corporation. All Rights Reserved.
    Working directory is /home/oracle/sqldeveloper/jdev/bin
    Exception in thread "main" java.lang.NullPointerException
    at java.util.Hashtable.get(Hashtable.java:333)
    at java.util.logging.LogManager.getLogger(LogManager.java:437)
    at java.util.logging.Logger.getLogger(Logger.java:228)
    at oracle.ide.performance.PerformanceLogger.<init>(PerformanceLogger.java:64)
    at oracle.ide.performance.PerformanceLogger.get(PerformanceLogger.java:94)
    at oracle.ideimpl.Main.main(Main.java:21)
    has anyone got around it?
    have a nice day!!

  • Need help w corba/jdbc class

    hi
    i'm trying to get this class to work right, i don't think i'm coding it the right way, especially the getAllAccounts() and selectAccounts() methods. this code compiles cleanly, but i get runtime exceptions when i try to run my app. my runtime exceptions look like
    ############################ StackTrace ############################
    java.lang.NullPointerException
    at com.kafein.accountServices.AccountServiceImpl.getAllAccounts(AccountS
    erviceImpl.java:218)
    at com.kafein.idl.accountServices.AccountServicePOA._invoke(AccountServi
    cePOA.java:74)
    at org.jacorb.poa.RequestProcessor.invokeOperation(RequestProcessor.java
    :247)
    at org.jacorb.poa.RequestProcessor.process(RequestProcessor.java:477)
    at org.jacorb.poa.RequestProcessor.run(RequestProcessor.java:604)
    and
    Creating 100 Accounts
    org.omg.CORBA.UNKNOWN: This exception was reported by the server, it is only re-
    thrown here. vmcid: 0x0 minor code: 0 completed: No
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Sou
    rce)
    at java.lang.reflect.Constructor.newInstance(Unknown Source)
    at org.jacorb.orb.SystemExceptionHelper.read(SystemExceptionHelper.java:
    157)
    at org.jacorb.orb.connection.ReplyInputStream.checkExceptions(ReplyInput
    Stream.java:117)
    at org.jacorb.orb.Delegate.invoke(Delegate.java:942)
    at org.omg.CORBA.portable.ObjectImpl._invoke(Unknown Source)
    at com.kafein.idl.accountServices._AccountServiceStub.getAllAccounts(_Ac
    countServiceStub.java:134)
    at com.kafein.client.AccountClient.main(AccountClient.java:111)
    org.omg.CORBA.UNKNOWN: This exception was reported by the server, it is only re-
    thrown here. vmcid: 0x0 minor code: 0 completed: No
    ORB shutting down...
    code for this class is below...
    // AccountServiceImpl.java: The AccountService Implementation
    package com.kafein.accountServices;
    import java.util.Hashtable;
    import java.util.Calendar;
    import java.util.GregorianCalendar;
    import junit.framework.TestCase;
    import junit.framework.Test;
    import junit.framework.TestSuite;
    import org.omg.PortableServer.*;
    import com.kafein.idl.accountServices.AccountServicePOA;
    import com.kafein.idl.accountServices.AccountEntryStruct;
    import com.kafein.idl.accountServices.AccountStruct;
    import com.kafein.idl.utilities.DateTimeStruct;
    import com.kafein.idl.exceptions.NotFoundException;
    import com.kafein.idl.exceptions.DataValidationException;
    import com.kafein.idl.errorCodes.DataValidationErrorCodes;
    import com.kafein.utils.ServiceHandler;
    import com.kafein.utils.Log;
    import java.net.URL;
    import java.sql.*;
    import java.util.*;
    * AccountServiceImpl is an implementation of the
    * idl.accountServices.AccountService interface.
    public class AccountServiceImpl extends AccountServicePOA {
      POA poa;
      private Hashtable accounts = new Hashtable(); // collection of Accounts
      private static int nextAccountID = 1; // global account ID
      Connection connection;
      Vector connections;
      Statement statement;
      PreparedStatement preparedStatement;
       * Construct an instance.
      public AccountServiceImpl(POA aPOA, String driver, String url, String user, String password) {
        super();
        poa = aPOA;
        driver = driver;
        url = url;
        user = user;
        password = password;
        connections = new Vector();
        // Connect to Database
        try {
            connect(driver,url,user,password);
        catch(Exception e) {
               e.printStackTrace();       
        // Simple Database Select
        try {
            testSimpleSelect();
        catch(Exception e) {
               e.printStackTrace();       
        // Database Select
        try {
            testSelect();
        catch(Exception e) {
               e.printStackTrace();       
       * Overloaded constructor for unit tests.
      protected AccountServiceImpl() {
        poa = null;
       * createAccount is used by administrator to add a new Account
       * in the system.
       * @param newAccount AccountEntryStruct containing data for new account
       * @return int the new unique Account ID
       * @exception com.kafein.idl.exceptions.DataValidationException
      public int createAccount(AccountEntryStruct newAccount) throws
        DataValidationException {
        validateData (newAccount); // throws DataValidationException;
        int accountID = getNextID();     
        // Create new Account.
        Account anAccount = new Account(accountID,
                            newAccount.userName,
                            newAccount.userEmail,
                            newAccount.creditCardType,
                            newAccount.creditCardNumber,
                            newAccount.creditCardExpirationDate.year,
                            newAccount.creditCardExpirationDate.month,
                            newAccount.userPassword,
                            newAccount.initialBalance);
    // Insert here / call method insertAccount() pass it in an account object
    // or call manager object - accountmanager.put()
        // Insert Account into Database
        try {
            insertAccount(anAccount);
        catch(Exception e) {
               e.printStackTrace();       
        accounts.put(accountID,anAccount);
        return accountID;
       * isAccountValid is used to validate a user logon.
       * @param accountID AccountID
       * @param userPassword String
       * @return boolean true to indicate an existing Account
      public boolean isValidAccount (int accountID, String userPassword) {
        // Get account with key equal to accountID.
        AccountStruct anAccount;
        try {
          anAccount = (AccountStruct) getAccount (accountID);
        catch (NotFoundException e) {
          return false;
        // Verify password.
        return (anAccount.userPassword.equals(userPassword) ? true : false);
       * getAccount is used to retrieve an existing Account in the system
       * @param int AccountID
       * @return AccountStruct containing data for the existing Account
       * @exception com.kafein.idl.exceptions.NotFoundException
      public AccountStruct getAccount(int accountID)throws
        NotFoundException {
        // Verify that accountID is within an appropriate interval.
        if (accountID < 1 || accountID > accounts.size()) {
          throw new NotFoundException(DataValidationErrorCodes.INVALID_ACCOUNT_ID,
                          "Account ID not found");
        // Get Account and convert to AccountStruct (which is returned).
        Account anAccount = (Account) accounts.get(accountID);
        return anAccount.getAccountStruct();
       * getAllAccounts is used to retrieve all existing Accounts in the system
       * @return AccountStruct[] containing all existing Accounts.
       * @fyi returns an empty sequence if no Accounts exist
      // GetAllAcounts method v. 2 - rather than enumerating through the vector
      // call a method that returns a collection of objs in that method where
      // you do select stmts
      public AccountStruct[] getAllAccounts() {
        // Allocate the array of AccountStructs.
        Vector results = new Vector();
        try {
                results = selectAccounts();
        catch(Exception e) {
               e.printStackTrace();       
        //Vector results = selectAccounts();
        int lastKey = results.size();
        //int lastKey = accounts.size();
        AccountStruct[] accountSequence = new AccountStruct[lastKey];
        if (lastKey==0) {
          return accountSequence;
        // Create AccountStructs from Accounts.
        for (int i = 1; i <= lastKey; i++) {
          Account anAccount = (Account) accounts.get(i);
          accountSequence[i-1] = anAccount.getAccountStruct();
        return accountSequence;
       * validateData is used to check new account data.
       * @param newAccount AccountEntryStruct containing data for new account
       * @exception com.kafein.idl.exceptions.DataValidationException
      protected void validateData(AccountEntryStruct newAccount) throws
        DataValidationException {
        // Check all of the member data in newAccount.
        if (newAccount.userName.equals("")) {
          throw new DataValidationException(
              DataValidationErrorCodes.INVALID_USER_NAME,
              "User Name must not be empty");
        if (newAccount.userEmail.equals("")) {
          throw new DataValidationException(
              DataValidationErrorCodes.INVALID_USER_EMAIL,
              "User Email must not be empty");
        if (newAccount.creditCardType.equals("")) {
          throw new DataValidationException(
              DataValidationErrorCodes.INVALID_CREDIT_CARD_TYPE,
              "Credit card type must not be empty");
        if (newAccount.creditCardNumber.equals("")) {
          throw new DataValidationException(
              DataValidationErrorCodes.INVALID_CREDIT_CARD_NUMBER,
              "Credit card number must not be empty");
        // Compare creditCardExpirationDate to current date
        // (we only consider year and month).
        GregorianCalendar now = new GregorianCalendar();
        DateTimeStruct proposed = newAccount.creditCardExpirationDate;
        if (proposed.year < now.get (Calendar.YEAR) ||
         (proposed.year == now.get (Calendar.YEAR) &&
          proposed.month < now.get (Calendar.MONTH) + 1)) {
          throw new DataValidationException(
              DataValidationErrorCodes.INVALID_CREDIT_CARD_EXPIRATION_DATE,
              "Credit card has expired");
        if (newAccount.userPassword.equals("")) {
          throw new DataValidationException(
              DataValidationErrorCodes.INVALID_USER_PASSWORD,
              "Password must not be empty");
        else if (!newAccount.userPassword.equals(newAccount.userPasswordVerification)) {
          throw new DataValidationException(
              DataValidationErrorCodes.INVALID_USER_PASSWORD,
              "Password verification failure");
        if (newAccount.initialBalance < 0.0F) {
          throw new DataValidationException(
              DataValidationErrorCodes.INVALID_BALANCE,
              "Account Balance cannot have a negative balance");
       * getNextID is used to generate a unique ID.
       * Needs a much better implementation that generates a globally unique ID!
       * @return int an Account ID
      protected synchronized int getNextID() {
        nextAccountID++;
        return nextAccountID - 1;
       * override _default_POA to return this servant's POA, not Root POA
      public POA _default_POA() {
        return poa;
       * jdbc related methods
      public void connect(String driver, String url, String user, String password)
                    throws Exception {
            try {
                // Load JDBC driver
                Class.forName(driver);
                System.out.println("Connecting to " + url);
                connection = DriverManager.getConnection(url, user, password);
                connections.add(connection);
                connection.setAutoCommit(false);
            } catch(Exception e) {
                System.err.println("System Exception in connect");
                System.err.println(e);
                throw e;
      public void closeConnection() throws Exception {
            try {
                Enumeration myEnum = connections.elements();
                while ( myEnum.hasMoreElements() ) {
                    System.out.println("Closing connection");
                    ((Connection) myEnum.nextElement()).close();
            } catch (Exception e) {
                System.err.println("System Exception in closeConnection");
                System.err.println(e);
                throw e;
      private void testSimpleSelect() throws Exception {
            try {
                Statement statement = connection.createStatement();
                ResultSet rs = statement.executeQuery("Select 1 from ACCOUNT");
                if (rs != null && rs.next()) {
                   int value = rs.getInt(1);
                   System.out.println("Fetched value " + value);
                connection.commit();
                statement.close();
            } catch(Exception e) {
                System.err.println("System Exception in testSimpleSelect");
                System.err.println(e);
                throw e;
      private void testSelect() throws Exception {
            try {
                Statement statement = connection.createStatement();
                ResultSet rs = statement.executeQuery(
                    "Select ACCT_ID, ACCT_USERNAME, ACCT_USEREMAIL, ACCT_CC_TYPE, ACCT_CC_NUMBER, ACCT_CC_EXPYR, ACCT_CC_EXPMO, ACCT_USERPASSWORD, ACCT_USERBALANCE from ACCOUNT LIMIT 1");
                System.out.println("Account ID   User Name     User Email     CC Type     CC Number     CC Expyr CC Expmo User Password     User Balance");
                while (rs != null && rs.next()) {
                    int acct_id = rs.getInt(1);
                    String acct_username = rs.getString(2);
                    String acct_useremail = rs.getString(3);
                    String acct_cc_type = rs.getString(4);
                    String acct_cc_number = rs.getString(5);
                    int acct_cc_expyr = rs.getInt(6);
                    int acct_cc_expmo = rs.getInt(7);
                    String acct_userpassword = rs.getString(8);
                    float acct_userbalance = rs.getFloat(9);
                    System.out.println(acct_id + "         " +
                                       acct_username + "   " +
                                       acct_useremail + "   " +
                                       acct_cc_type + "   " +
                                       acct_cc_number + "   " +
                                       acct_cc_expyr + "   " +
                                       acct_cc_expmo + "   " +
                                       acct_userpassword + "   " +
                                       acct_userbalance);
                connection.commit();
                statement.close();
            } catch(Exception e) {
                System.err.println("System Exception in testSelect");
                System.err.println(e);
                throw e;
      private void testLoadData() throws Exception {
            int numberOfAccounts = 5;
            String  acct_username    = "<--20 BYTE STRING-->";
            String  acct_useremail = "<--20 BYTE STRING-->";
         String  acct_cc_type = "TEST ";
            String  acct_cc_number = "<--20 BYTE STRING-->";
            int  acct_cc_expyr = 2000;
            int  acct_cc_expmo = 1;
            String  acct_userpassword = "<--20 BYTE STRING-->";
            float     acct_userbalance = 0.0F;
            int     acct_id = 0;
         try {
                System.out.println("Inserting data...");
                connection.setAutoCommit(false);
                // Calculate Start time
                System.out.println("Starting data insertion (" + numberOfAccounts +
                    " rows) into ACCOUNT table..");
                long startTime = System.currentTimeMillis();
                preparedStatement = connection.prepareStatement(
                    "INSERT INTO ACCOUNT (ACCT_ID, ACCT_USERNAME, ACCT_USEREMAIL, ACCT_CC_TYPE, ACCT_CC_NUMBER, " +
                    "ACCT_CC_EXPYR, ACCT_CC_EXPMO, ACCT_USERPASSWORD, ACCT_USERBALANCE) VALUES ( ?, ?, ?, ?, ?, ? , ?, ?, ?)");
                // Insert accounts in ACCOUNT table
                for (int i = 1; i <= numberOfAccounts; i++) {
                    acct_id  = i * 1000;
                    preparedStatement.setInt(1, acct_id);
                    preparedStatement.setString(2, acct_username);
                    preparedStatement.setString(3, acct_useremail);
                    preparedStatement.setString(4, acct_cc_type);
                    preparedStatement.setString(5, acct_cc_number);
                    preparedStatement.setInt(6, acct_cc_expyr);
                    preparedStatement.setInt(7, acct_cc_expmo);
                    preparedStatement.setString(8, acct_userpassword);
                    preparedStatement.setFloat(9, acct_userbalance);
              preparedStatement.executeUpdate();
                    connection.commit();
                System.out.println(numberOfAccounts + " accounts created.");
                preparedStatement.close();
                long stopTime = System.currentTimeMillis();
                System.out.println("Account table load complete.");
                System.out.println("Load time = " +
                                   ((stopTime - startTime)/(1000f)) + " seconds");
                System.out.println("Data insertion complete");
            } catch(Exception e) {
                System.err.println("System Exception in loadData");
                System.err.println(e);
                throw e;
       * insertAccount is used to insert a new Account in the Database
       * @param int AccountID
       * @return AccountStruct containing data for the existing Account
      private void insertAccount(Account anAccount) throws Exception {
              AccountStruct anAccountStruct = anAccount.getAccountStruct();  
         int numberOfAccounts = 1;
         String  acct_username    = anAccountStruct.userName;
            String  acct_useremail = anAccountStruct.userEmail;
         String  acct_cc_type = anAccountStruct.creditCardType;
            String  acct_cc_number = anAccountStruct.creditCardNumber;
         int acct_cc_expyr = anAccountStruct.creditCardExpirationDate.year;
            int acct_cc_expmo = anAccountStruct.creditCardExpirationDate.month;
            String  acct_userpassword = anAccountStruct.userPassword;
            float     acct_userbalance = anAccountStruct.accountBalance;
            int     acct_id = anAccountStruct.accountID;
         try {
                System.out.println("Inserting data...");
                connection.setAutoCommit(false);
    //instead of system.out just log
                // Calculate Start time
                System.out.println("Starting data insertion ( 1" +
                    " row) into ACCOUNT table..");
                long startTime = System.currentTimeMillis();
                preparedStatement = connection.prepareStatement(
                    "INSERT INTO ACCOUNT (ACCT_ID, ACCT_USERNAME, ACCT_USEREMAIL, ACCT_CC_TYPE, ACCT_CC_NUMBER, " +
                    "ACCT_CC_EXPYR, ACCT_CC_EXPMO, ACCT_USERPASSWORD, ACCT_USERBALANCE) VALUES ( ?, ?, ?, ?, ?, ? , ?, ?, ?)");
                    acct_id  = 1000;
                    preparedStatement.setInt(1, acct_id);
                    preparedStatement.setString(2, acct_username);
                    preparedStatement.setString(3, acct_useremail);
                    preparedStatement.setString(4, acct_cc_type);
                    preparedStatement.setString(5, acct_cc_number);
                    preparedStatement.setInt(6, acct_cc_expyr);
                    preparedStatement.setInt(7, acct_cc_expmo);
                    preparedStatement.setString(8, acct_userpassword);
                    preparedStatement.setFloat(9, acct_userbalance);
              preparedStatement.executeUpdate();
                    connection.commit();
                System.out.println("1 account created.");
                preparedStatement.close();
                long stopTime = System.currentTimeMillis();
                System.out.println("Account table load complete.");
                System.out.println("Load time = " +
                                   ((stopTime - startTime)/(1000f)) + " seconds");
                System.out.println("Data insertion complete");
            } catch(Exception e) {
                System.err.println("System Exception in loadData");
                System.err.println(e);
                throw e;
      private Vector selectAccounts() throws Exception {
            try {
                // Create Vector to hold individual Account values
             Vector mainvector = new Vector();
             Vector values = new Vector();
             Statement statement = connection.createStatement();
                ResultSet rs = statement.executeQuery(
                    "Select ACCT_ID, ACCT_USERNAME, ACCT_USEREMAIL, ACCT_CC_TYPE, ACCT_CC_NUMBER, ACCT_CC_EXPYR, ACCT_CC_EXPMO, ACCT_USERPASSWORD, ACCT_USERBALANCE from ACCOUNT");
                System.out.println("Account ID   User Name     User Email     CC Type     CC Number     CC Expyr CC Expmo User Password     User Balance");
             // Iterate through result set
             while (rs != null && rs.next()) {
              // Make sure values is empty
              values.clear();
              int acct_id = rs.getInt(1);
                    String acct_username = rs.getString(2);
                    String acct_useremail = rs.getString(3);
                    String acct_cc_type = rs.getString(4);
                    String acct_cc_number = rs.getString(5);
                    int acct_cc_expyr = rs.getInt(6);
                    int acct_cc_expmo = rs.getInt(7);
                    String acct_userpassword = rs.getString(8);
                    float acct_userbalance = rs.getFloat(9);
              // Populate Vector values
              values.addElement(rs.getObject(1));
              values.addElement(rs.getObject(2));
              values.addElement(rs.getObject(3));
              values.addElement(rs.getObject(4));
              values.addElement(rs.getObject(5));
              values.addElement(rs.getObject(6));
              values.addElement(rs.getObject(7));
              values.addElement(rs.getObject(8));
              values.addElement(rs.getObject(9));
              mainvector.addElement(values);
                    System.out.println(acct_id + "         " +
                                       acct_username + "   " +
                                       acct_useremail + "   " +
                                       acct_cc_type + "   " +
                                       acct_cc_number + "   " +
                                       acct_cc_expyr + "   " +
                                       acct_cc_expmo + "   " +
                                       acct_userpassword + "   " +
                                       acct_userbalance);
                connection.commit();
                statement.close();
             return mainvector;
            } catch(Exception e) {
                System.err.println("System Exception in selectAccounts");
                System.err.println(e);
                throw e;
        }

    line 217 and 218 is
    Account anAccount = (Account) accounts.get(i);
    accountSequence[i-1] = anAccount.getAccountStruct();
    i realized that
    Account anAccount = (Account) accounts.get(i);
    was a typo. what it should have been was
    Account anAccount = (Account) results.get(i);
    so my getAllAccounts() method now looks like
       * getAllAccounts is used to retrieve all existing Accounts in the system
       * @return AccountStruct[] containing all existing Accounts.
       * @fyi returns an empty sequence if no Accounts exist
      // GetAllAcounts method v. 2 - rather than enumerating through the vector
      // call a method that returns a collection of objs in that method where
      // you do select stmts
      public AccountStruct[] getAllAccounts() {
        // Allocate the array of AccountStructs.
        Vector results = new Vector();
        try {
                results = selectAccounts();
        catch(Exception e) {
               e.printStackTrace();       
        //Vector results = selectAccounts();
        int lastKey = results.size();
        //int lastKey = accounts.size();
        AccountStruct[] accountSequence = new AccountStruct[lastKey];
        if (lastKey==0) {
          return accountSequence;
        // Create AccountStructs from Accounts.
        for (int i = 1; i <= lastKey; i++) {
          Account anAccount = (Account) results.get(i);
          accountSequence[i-1] = anAccount.however, i still get the same runtime errors.
    is my selectAccounts() method returning a null?

Maybe you are looking for

  • Installing Fonts on 10gAS 10.1.2.3

    Hello All We have 10gAS R2 (10.1.2.3) running on OEL 5 and I just installed ArialNarrow font and they are working fine but AriallNarrow with Style BOLD, ITALICS, BOLD+ITALICS are NOT coming up in PDF reports on the screen. I have tried mapping using

  • Quicktime  and firefox issues

    when installed, quicktime overwrites flash files, like youtube or any ads that use flash, with the quicktime logo with "?". before, if i uninstalled quicktime, flash would work again. now even with quicktime uninstalled, firefox promts that the "quic

  • Itunes not loading correctly

    Loading the latest version of iTunes has resulted in an absolute disaster. HP Pavillion. Microsoft Windows 7 Home Premium Edition (64-bit), Norton Anti-Virus Since I upgraded to iTunes 11.0.1.12 it has been an unmitigated disaster. I have an iPad, an

  • Page headers in cross tab report

    Hi, I have created addon in SAP B1 2007A PL 46. This includes crystal reports that use .net crystal runtimes. One of the reports is crosstab report. It is required that each result page of report display a header. When I set it in page header section

  • Change position of thekeyb search bar in contacts to just above qwerty keyboards

    Hi  Can we change the position of the search bar just above the qwerty as reaching the search bar with the thumb is too long and painfull when holding the phone in portrait mode.  Regards  Kirti K G Desai