RE: CORBA question





> -----Original Message-----
> From: Andrew Clausen [mailto:clausen@alphalink.com.au]
> Sent: 07 December 1998 20:37
> To: Philip Dawes; gnome-list
> Subject: Re: CORBA question
> 
> 
> Philip Dawes wrote:
> 
> > Or you can have a mutually known server pass the references 
> around. This is
> > how the name server works - both the client and the server 
> know the location
> > of the name server (through some magic - this usually 
> requires looking up
> > the server on a well known port, or passing the stringified 
> IOR to the orb
> > on startup) and they use that to publish and look up 
> references to objects.
> 
> Isn't the name server implemented with CORBA interfaces, not 
> sockets?  The
> orbit-name-server doesn't appear to use sockets.  So you need 
> the IOR of the
> name-server.  I assume you have to do that by using popen on 
> orbit-name-server,
> and reading the stdout for the IOR.  This seems a bit messy.

To be honest I haven't looked at the orbit name-server. The other name
server's I've worked with have used the 'pass the stringified IOR to the orb
as a command line variable' technique, which then allows the client to
retireve the reference to it through the resolve_initial_references()
function. The other method is to pre-know the host and port of the
nameserver before startup (i.e. use some pre-agreed location) and
effectively generate the IOR internally from that.
(Both techniques supply the reference to the client through the
resolve_initial_references method, so the client code itself isn't polluted
with this messyness, only the way you initialise the orb.)


> I noticed CORBA_ORB_resolve_initial_references.  The 
> ORBit/test/test program
> lists all services in this, and the InterfaceRepository is in 
> it.  If a server
> registers itself in the IR, then a client can look it up.  
> Given an objec
> reference to a "Contained" corresponding to the interface, 
> how can you create
> an instance of the interface, or retrieve an existing one?

The IR knows nothing about objects or their location. It is simply a
repository containing information about interfaces. Think of it as a
queryable database of IDL files.

Cheers,

Phil.



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]