[ Bottom of Page | Previous Page | Next Page | Contents | Index | Library Home |
Legal |
Search ]
Technical Reference: Communications, Volume 1
lb_$lookup_interface Library Routine (NCS)
Purpose
Looks up information about an interface in the Global
Location Broker (GLB) database.
Syntax
void lb_$lookup_interface ( object_interface, lookup_handle)
void lb_$lookup_interface ( max_results, num_results, results, status)
uuid_$t *object_interface;
lb_$lookup_handle_t *lookup_handle;
unsigned long max_results;
unsigned long *num_results;
lb_$entry_t results [ ];
status_$t *status;
Description
The lb_$lookup_interface routine
returns GLB database entries whose fields in the object_interface parameters match the specified interface. It returns information about
all replicas of all objects that can be accessed through that interface.
The lb_$lookup_interface routine
cannot return more than the number of matching entries specified by the max_results parameter at one time. The lookup_handle parameter directs this routine to do sequential lookup
calls to find all matching entries.
Notes:
- The Location Broker does not prevent modification
of the database between lookup calls, which can cause the locations of entries
relative to a lookup_handle value to change. If multiple
calls are made to find all matching results in the database, the returned
information may skip or duplicate entries from the database.
- It is also possible for the results of a single
lookup call to skip or duplicate entries. This can occur if the size of the
results exceeds the size of a remote procedure call (RPC) packet (64KB).
Parameters
Input
object_interface |
Points to the Universal Unique Identifier (UUID) of the interface
being looked up. |
max_results |
Specifies the maximum number of matching entries that can be returned
by a single call. This should be the number of elements in the results parameter array. |
Input/Output
lookup_handle |
Specifies a location in the database. On input, the lookup_handle value indicates the location in the database where the
search begins. An input value of lb_$default_lookup_handle specifies that the search starts at the beginning of the database. |
|
On return, the lookup_handle parameter indicates
the next unsearched part of the database (that is, the point at which the
next search should begin). A return value of lb_$default_lookup_handle indicates that the search reached the end of the database. Any other
value indicates that the search found the number of matching entries specified
by the max_results parameter before it reached the
end of the database. |
Output
num_results |
Points to the number of entries that are returned in the results parameter array. |
results |
Specifies the array that contains the matching GLB database entries,
up to the number specified in the max_results parameter.
If the array contains any entries for servers on the local network, those
entries appear first. |
status |
Points to the completion status. |
Examples
To look up information in the GLB database about a
matrix multiplication interface, enter:
lb_$lookup_interface (&matrix_if_id, &lookup_handle,
results_array_size, &num_results,
&matrix_if_results_array, &status);
Related Information
Remote Procedure Call (RPC)
Runtime Library (NCS) in AIX 5L Version 5.2 Communications Programming Concepts.
[ Top of Page | Previous Page | Next Page | Contents | Index | Library Home |
Legal |
Search ]