summaryrefslogtreecommitdiff
path: root/TAO/docs/locate_request.html
blob: 1978b2f3336064e30187aa18bd4b4926c902ae17 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
<html>
  <!-- $Id $ -->
  <head>
    <title>Implementation of locate requests</title>
  </head>
  
  <BODY text = "#000000"
    link="#0000ff"
    vlink="#cc0000"
    bgcolor="#ffffff">
    
    <body>
      <HR>
	<h1>Locate requests</h1>
	<HR>
	  <h2>Context</h2>
	  The CORBA specification describes locate requests as a way to 
	  find out if an object is available at the other end of the wire
	  or not without invoking an actual method on it.
	  This way expensive marshalling and demarshalling can be prohibited.
	  Locate requests are part of GIOP.

	  <h2>Implementation</h2>
	  The main classes involved in locate requests are the Server_Connection_Handler
	  to do check for the object. This is done by invoking the non standard
	  "non_existent" method on it. If it fails an exception will be thrown,
	  if the exception is not the Forward_Request exception of the POA,
	  the object is not there. If it is this specific exception, the new 
	  forwarded location can be extracted and returned in the locate reply.
	  If the call on "non_existent" succeeds, we know the object is there and
	  return that. 

	  The client part of the locate request is handled int Locate_Request_Invocation.
	  The response is checked on the answer. If there, we go on and invoke the 
	  actual method on the distant object. If not there, we fail and throw the proper
	  exception and if we get forwarded we replace our IIOP profile acordingly.

	  <h2>API</h2>
	  To activate the locate requests, please invoke the non standard method
	  "_use_locate_requests (CORBA::B_TRUE)" on your CORBA::Object or any
	  object which inherits form this object. This will activate the locate
	  request on the first call to the object. The second time and on all 
	  following calls "no" locate request will be used any more. To switch
	  it on again use "_use_locate_requests (CORBA::B_TRUE)" again.
	  You can also switch it of by "_use_locate_requests (CORBA::B_FALSE)".
	  
	  <HR>
	    For more details and questions,
	    <p>
	      <address><a href="mailto:irfan1@cs.wustl.edu">Irfan Pyarali</a></address>
	      <p>
		<address><a href="mailto:mk1@cs.wustl.edu">Michael Kircher</a></address>
		<p>
    </body>
</html>