Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ace+tao newcomer problem 1

Status
Not open for further replies.

franklane

Programmer
Oct 5, 2004
12
0
0
US
Hello,

I'm new to ACE+TAO (version 5.4 & 1.4) and trying to run the simple examples. My client and server are on the same machine, my home x86 XP box. Whenever I try to do anything with clients I get the following messages, on different examples ..\tests\hello and ..\examples\simple\echo respectively:

(1460|2384) EXCEPTION, Exception caught:
system exception, ID 'IDL:eek:mg.org/CORBA/INV_OBJREF:1.0'
TAO exception, minor code = 0 (all protocols failed to parse the IOR; unspecified errno), completed = NO

or, the closest to working yet:

(3100|1544) EXCEPTION,
Exception in RMI
system exception, ID 'IDL:eek:mg.org/CORBA/TRANSIENT:1.0'
OMG minor code (2), described as 'No usable profile in IOR.', completed = NO

I'm sure it's something I'm doing wrong, maybe a bogus environment setup, maybe my windows firewall is doing this?

Please help if you can/will.

I thought I had accomplished something when I got the IDL compiler to work under visual studio.

Thanks,
Frank
 
try each time you launch an application to update the .ior file on the client side if the server generates one.

Ion Filipski
1c.bmp
 
Thank you IonFilipski,

I'm really really new here and don't know how to update an IOR from the client side. Would you please tell me how to do this? Because you were right, the server does generate one. It appears the server generates one due to the use of some virtually undocumented command line switches.

It also appears there was a problem with the DNS setup, even though everything is on the same machine. I've been sinking hours into this and found a checkbox in the network options that says something to the effect of "advertise this DNS suffix".

Thanks again,
Frank
 
1. launch the server. It generates an ior file.
2. copy the ior file in the place where client is situated.
3. change the directory to the directory where client is situated
4. launch the client

or
1. put the client and the server in the same directory
2. set the current directory to location there programs are
3. launch the server
4. launch the client

Also you should take a look at the client sources.
it could look like this:
Code:
...
main()
  try
  {
    ifstream inp_file(".\\MyORef.ior");
    char str[1024] = "";
    inp_file>> str;
    inp_file.close();
    CORBA::ORB_var orb = CORBA::ORB_init(__argc, __argv);
    CORBA::Object_var obj = orb->string_to_object(str);
    MyObject_var oRef = MyObject::_narrow(obj);
    oRef->function();
    MessageBox(0, str, "hello received from", 0);
  }catch(...)
  {
    MessageBox(0, "error", "corba error", 0);
  }

see where it searches the ior file(MyORef.ior). Launch the server, put the generated ior in the directory where client searches it and launch the client.

Ion Filipski
1c.bmp
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top