Previous | Table of Contents | Next |
local interface RequestInfo { readonly attribute unsigned long request_id; readonly attribute string operation; readonly attribute
Dynamic::ParameterList arguments; readonly attribute Dynamic::ExceptionList exceptions; readonly attribute Dynamic::ContextList
contexts; readonly attribute Dynamic::RequestContext operation_context; readonly attribute any result; readonly attribute
boolean response_expected; readonly attribute Messaging::SyncScope sync_scope; readonly attribute ReplyStatus reply_status;
readonly attribute Object forward_reference; any get_slot (in SlotId id) raises (InvalidSlot); IOP::ServiceContext get_request_service_context
(
in IOP::ServiceId id); IOP::ServiceContext get_reply_service_context ( in IOP::ServiceId id); };
The details of the attributes and operations on RequestInfo follow. Some of these are not valid at all interception points.
See Table 21-1 on page 21-26 and Table 21-2 on
page 21-29.
21.3.12.1 request_id
This ID uniquely identifies an active request/reply sequence. Once a request/reply sequence is concluded this ID may be reused.
Note that this id is not the same as the GIOP request_id. If GIOP is the transport mechanism used, then these IDs may very
well be the same, but this is not guaranteed nor required.
21.3.12.2 operation
This attribute is the name of the operation being invoked.
21.3.12.3 arguments
This attribute is a Dynamic::ParameterList containing the arguments on the
operation being invoked (see Section 21.9.1, “NVList PIDL Represented by
ParameterList IDL,? on page 21-58). If there are no arguments, this attribute will be a
zero length sequence.
Not all environments provide access to the arguments. With the Java portable bindings, for example, the arguments are not
available. In these environments, when this attribute is accessed, NO_RESOURCES will be raised with a standard minor code
of 1.
21.3.12.4 exceptions
This attribute is a Dynamic::ExceptionList describing the TypeCodes of the user
exceptions that this operation invocation may raise (see Section 21.9.3, “ExceptionList
PIDL Represented by ExceptionList IDL,? on page 21-58). If there are no user
exceptions, this attribute will be a zero length sequence.
Not all environments provide access to the exception list. With the Java portable bindings, for example, the exception list
is not available. In these environments, when this attribute is accessed, NO_RESOURCES will be raised with a standard minor
code of 1.
21.3.12.5 contexts
This attribute is a Dynamic::ContextList describing the contexts that may be passed
on this operation invocation (see Section 21.9.2, “ContextList PIDL Represented by
ContextList IDL,? on page 21-58). If there are no contexts, this attribute will be a zero
length sequence.
Not all environments provide access to the context list. With the Java portable bindings, for example, the context list is
not available. In these environments, when this attribute is accessed, NO_RESOURCES will be raised with a standard minor code
of 1.
21.3.12.6 operation_context
This attribute is a Dynamic::RequestContext containing the contexts being sent on the request (see
Section 21.9.4, “Context PIDL Represented by RequestContext IDL,?
on page 21-58).
Not all environments provide access to the context. With the Java portable bindings, for example, the context is not available.
In these environments, when this attribute is accessed, NO_RESOURCES will be raised with standard minor code of 1.
21.3.12.7 result
This attribute is an any containing the result of the operation invocation.
If the operation return type is void, this attribute will be an any containing a type code with a TCKind value of tk_void
and no value.
Not all environments provide access to the result. With the Java portable bindings, for example, the result is not available.
In these environments, when this attribute is accessed, NO_RESOURCES will be raised with a standard minor code of 1.
21.3.12.8 response_expected
This boolean attribute indicates whether a response is expected.
On the client, a reply is not returned when response_expected is false, so receive_reply cannot be called. receive_other is
called unless an exception occurs, in which case receive_exception is called.
On the client, within send_poll, this attribute is true.
21.3.12.9 sync_scope
This attribute, defined in the Messaging specification, is pertinent only when response_expected is false. If response_expected
is true, the value of sync_scope is undefined. It defines how far the request shall progress before control is returned to
the client. This attribute may have one of the following values:
Messaging::SYNC_NONE Messaging::SYNC_WITH_TRANSPORT Messaging::SYNC_WITH_SERVER Messaging::SYNC_WITH_TARGET
On the server, for all scopes, a reply will be created from the return of the target operation call, but the reply will not
return to the client. Although it does not return to the client, it does occur, so the normal server-side interception points
are followed; that is, receive_request_service_contexts, receive_request, send_reply, or send_exception.
For SYNC_WITH_SERVER and SYNC_WITH_TARGET, the server does send an empty reply back to the client before the target is invoked.
This reply is not intercepted by server-side Interceptors.
21.3.12.10 reply_status
This attribute describes the state of the result of the operation invocation. Its value can be one of the following:
PortableInterceptor::SUCCESSFUL PortableInterceptor::SYSTEM_EXCEPTION PortableInterceptor::USER_EXCEPTION PortableInterceptor::LOCATION_FORWARD
PortableInterceptor::TRANSPORT_RETRY PortableInterceptor::UNKNOWN
On the client:
• Within the receive_reply interception point, this attribute will only be SUCCESSFUL.
• Within the receive_exception interception point, this attribute will be either SYSTEM_EXCEPTION or USER_EXCEPTION.
• Within the send_reply interception point, this attribute will only be SUCCESSFUL.
• Within the send_exception interception point, this attribute will be either SYSTEM_EXCEPTION or USER_EXCEPTION.
• Within the send_other interception point, this attribute will be any of: SUCCESSFUL, LOCATION_FORWARD, or UNKNOWN. SUCCESSFUL means an asynchronous request returned successfully. LOCATION_FORWARD means that a reply came back with LOCATION_FORWARD as its status. UNKNOWN means that the ORB was unable to determine the correct status. This can occur for example in the Java language mapping when the optimized path for a collocated call is used.
• Within the receive_other interception point, this attribute will be any of: SUCCESSFUL, LOCATION_FORWARD, TRANSPORT_RETRY, or UNKNOWN. SUCCESSFUL means an asynchronous request returned successfully. LOCATION_FORWARD means that a reply came back with LOCATION_FORWARD as its status. TRANSPORT_RETRY means that the transport mechanism indicated a retry - a GIOP reply with a status of NEEDS_ADDRESSING_MODE, for instance. UNKNOWN means that the ORB was unable to determine the correct status. This can occur for example in the Java language mapping when the optimized path for a collocated call is used.
On the server:
21.3.12.11 forward_reference
If the reply_status attribute is LOCATION_FORWARD, then this attribute will contain the object to which the request will be
forwarded. It is indeterminate whether a forwarded request will actually occur.
21.3.12.12 get_slot
This operation returns the data from the given slot of the PortableInterceptor::Current that is in the scope of the request.
If the given slot has not been set, then an any containing a type code with a TCKind value of tk_null is returned.
If the ID does not define an allocated slot, InvalidSlot is raised.
See
Section 21.4, “Portable Interceptor Current,? on page 21-33 for an explanation of
slots and the PortableInterceptor::Current.
Parameters
id The SlotId of the slot that is to be returned.
Return Value The slot data, in the form of an any, obtained with the given identifier.
21.3.12.13 get_request_service_context
This operation returns a copy of the service context with the given ID that is associated with the request.
If the request’s service context does not contain an entry for that ID, BAD_PARAM with a standard minor code of 26 is raised.
Parametersid |
|||||
The IOP::ServiceId of the service context that is to be | |||||
returned. |
Return Value The IOP::ServiceContext obtained with the given identifier.
21.3.12.14 get_reply_service_context
This operation returns a copy of the service context with the given ID that is associated with the reply.
If the request’s service context does not contain an entry for that ID, BAD_PARAM with a standard minor code of 26 is raised.
Parameters
id The IOP::ServiceId of the service context that is to be returned.
Return Value The IOP::ServiceContext obtained with the given identifier.