0

I have a jdk version updated from jdk 1.7.21 to jdk 1.7.25, build on Solaris 10 and production runs over windows server 2003. I have not updated any java code this time, since build was a success, I would update java code if compile hits an error, e.g on jdk from 1.6.45 to jdk 1.7.xx, I have to update a few files to match jdk 1.7 API changes, then it's running fine, there was a few updates from jdk 1.7.xx to jdk1.7.21, each time updated was fine. But this time, after build jdk 1.7.25 from 1.7.21 source code, compile was ok, but run time the server runs up ok, but client is stuck in the middle - there is a SESSION_ADAPTER build failed, we used OPNORG 1.2 which is over 10 years old, and a 3rd party binary code only. Wondering where is the really problem on jdk 1.7.25?

I used "old school" skills to print out which line was broken, it looks stuck in the function of narrow(orb), got an Exception of "BAD_PARAM":

Here is the java file(It's generated by CORBA IDL, we do not have source of OPNORG):

package DPEM.src.presentation.adaptation.adaptationIfc;

//
// Helper class for : SessionAdapter
//
// @author OpenORB Compiler
//
public class SessionAdapterHelper
{
//
// Insert SessionAdapter into an any
// @param   a an any
// @param   t SessionAdapter value
//
public static void insert( org.omg.CORBA.Any a, DPEM.src.presentation.adaptation.adaptationIfc.SessionAdapter t )
{
    a.insert_Object( t , type() );
}

//
// Extract SessionAdapter from an any
// @param   a an any
// @return the extracted SessionAdapter value
//
public static DPEM.src.presentation.adaptation.adaptationIfc.SessionAdapter extract( org.omg.CORBA.Any a )
{
    if ( !a.type().equal( type() ) )
        throw new org.omg.CORBA.MARSHAL();
    try {
        return DPEM.src.presentation.adaptation.adaptationIfc.SessionAdapterHelper.narrow( a.extract_Object() );
    }
    catch ( org.omg.CORBA.BAD_PARAM ex ) {
        throw new org.omg.CORBA.MARSHAL();
    }
}

//
// Internal TypeCode value
//
private static org.omg.CORBA.TypeCode _tc = null;

//
// Return the SessionAdapter TypeCode
// @return a TypeCode
//
public static org.omg.CORBA.TypeCode type()
{
    if ( _tc == null ) {
        org.omg.CORBA.ORB orb = org.omg.CORBA.ORB.init();
        _tc = orb.create_interface_tc(id(),"SessionAdapter");
    }
    return _tc;
}

//
// Return the SessionAdapter IDL ID
// @return an ID
//
public static String id()
{
    return _id;
}

private final static String _id = "IDL:adaptation.presentation.src.DPEM/adaptationIfc/SessionAdapter:1.0";

//
// Read SessionAdapter from a marshalled stream
// @param   istream the input stream
// @return the readed SessionAdapter value
//
public static DPEM.src.presentation.adaptation.adaptationIfc.SessionAdapter read( org.omg.CORBA.portable.InputStream istream )
{
    return( DPEM.src.presentation.adaptation.adaptationIfc.SessionAdapter )istream.read_Object( DPEM.src.presentation.adaptation.adaptationIfc._SessionAdapterStub.class );
}

//
// Write SessionAdapter into a marshalled stream
// @param   ostream the output stream
// @param   value SessionAdapter value
//
public static void write( org.omg.CORBA.portable.OutputStream ostream, DPEM.src.presentation.adaptation.adaptationIfc.SessionAdapter value )
{
    ostream.write_Object((org.omg.CORBA.portable.ObjectImpl)value);
}

//
// Narrow CORBA::Object to SessionAdapter
// @param   obj the CORBA Object
// @return SessionAdapter Object
//
public static SessionAdapter narrow( org.omg.CORBA.Object obj )
{
    if ( obj == null )
        return null;
    if ( obj instanceof SessionAdapter )
        return ( SessionAdapter)obj;

    if ( obj._is_a( id() ) )
    {
        _SessionAdapterStub stub = new _SessionAdapterStub();
        stub._set_delegate( ((org.omg.CORBA.portable.ObjectImpl)obj)._get_delegate() );
        return stub;
    }

    throw new org.omg.CORBA.BAD_PARAM();
}

//
// Unchecked Narrow CORBA::Object to SessionAdapter
// @param   obj the CORBA Object
// @return SessionAdapter Object
//
public static SessionAdapter unchecked_narrow( org.omg.CORBA.Object obj )
{
    if ( obj == null )
        return null;
    if ( obj instanceof SessionAdapter )
        return ( SessionAdapter)obj;

    _SessionAdapterStub stub = new _SessionAdapterStub();
    stub._set_delegate( ((org.omg.CORBA.portable.ObjectImpl)obj)._get_delegate() );
    return stub;

}

}

I have no idea for the past a 2 weeks, hopefully can borrow a little of java/IDL skills from you gurus.

Thanks, Curtis

Curtis Wu
  • 13
  • 4
  • If you expect to get useful answers, you need to provide useful information. Things like "client is stuck in the middle" and "SESSION_ADAPTER build failed" don't provide useful information. Nor does posting generated code. – kdgregory Sep 12 '13 at 20:26
  • If you're getting an exception, put the *entire* exception, *including stack trace* in your question. If you're getting a build failure, copy the *entire* message into your question. Better still, create a [SSCCE](http://sscce.org/) that demonstrates the problem, and post it. – kdgregory Sep 12 '13 at 20:27
  • Thank you kdgregory for your comments. Here is the exception trace: – Curtis Wu Oct 14 '13 at 12:53
  • org.omg.CORBA.INITIALIZE: Unable to create CDROutputStream class vmcid: 0x0 minor code: 0 completed: No at org.openorb.iiop.CDRCodec.encode_value(CDRCodec.java:147) at org.openorb.iiop.IIOPServerProtocol.create_profile(IIOPServerProtocol.java:258) at org.openorb.net.ServerManagerImpl.construct_ior(ServerManagerImpl.java:697) at org.openorb.adapter.poa.POA.create_reference(POA.java:1602) at org.openorb.adapter.poa.RootPOA$DomainManagerPOA.create_reference(RootPOA.java:162) – Curtis Wu Oct 14 '13 at 12:59
  • at org.openorb.adapter.poa.POA.create_reference_with_id(POA.java:1397) at org.openorb.adapter.poa.RootPOA.create_poa_domain_manager(RootPOA.java:135) at org.openorb.adapter.poa.POA.get_domain_managers(POA.java:848) at org.openorb.adapter.poa.POA.create_reference(POA.java:1593) at org.openorb.adapter.poa.POA.create_reference_with_id(POA.java:1397) at org.openorb.adapter.poa.DelegateImpl.this_object(DelegateImpl.java:121) at org.omg.PortableServer.Servant._this_object(Servant.java:79) at – Curtis Wu Oct 14 '13 at 12:59
  • at org.omg.PortableServer.Servant._this_object(Servant.java:98) at DPEM.src.presentation.adaptation.adaptationIfc.SessionAdapterPOA._this(SessionAdapterPOA.java:18) at DPEM.src.presentation.adaptation.SessionAdapterImpl.(SessionAdapterImpl.java:91) at DPEM.src.presentation.adaptation.SessionAdapterImpl.instance(SessionAdapterImpl.java:164) at DPEM.src.presentation.adaptation.AdapterFactory.getAdapter(AdapterFactory.java:166) at DPEM.src.presentation.adaptation.AdapterFactory.getAdapter(AdapterFactory.java:121) – Curtis Wu Oct 14 '13 at 13:00
  • at DPEM.src.presentation.dialogControl.DialogController.createAdapterReferences(DialogController.java:320) at DPEM.src.presentation.dialogControl.DialogController.(DialogController.java:112) at DPEM.src.presentation.dialogControl.PresentationFactory.getDialogController(PresentationFactory.java:470) at DPEM.src.presentation.dialogControl.ThreadedClient.run(ThreadedClient.java:136) – Curtis Wu Oct 14 '13 at 13:00
  • You should edit your post to include the trace, as this will make the question active again. Using comments like this means that nobody will see the information (at least, nobody that can give you an answer). – kdgregory Oct 27 '13 at 17:30

0 Answers0