diff options
Diffstat (limited to 'TAO/tao/RTCORBA/RT_Invocation_Endpoint_Selectors.cpp')
-rw-r--r-- | TAO/tao/RTCORBA/RT_Invocation_Endpoint_Selectors.cpp | 690 |
1 files changed, 227 insertions, 463 deletions
diff --git a/TAO/tao/RTCORBA/RT_Invocation_Endpoint_Selectors.cpp b/TAO/tao/RTCORBA/RT_Invocation_Endpoint_Selectors.cpp index 34a3236e2d8..ce4264caffa 100644 --- a/TAO/tao/RTCORBA/RT_Invocation_Endpoint_Selectors.cpp +++ b/TAO/tao/RTCORBA/RT_Invocation_Endpoint_Selectors.cpp @@ -20,544 +20,308 @@ ACE_RCSID(tao, RT_Invocation_Endpoint_Selectors, "$Id$") -// **************************************************************** - void -TAO_RT_Default_Endpoint_Selector::select_endpoint (TAO_GIOP_Invocation *invocation - ACE_ENV_ARG_DECL) +TAO_RT_Invocation_Endpoint_Selector::select_endpoint (TAO_GIOP_Invocation *invocation + ACE_ENV_ARG_DECL) { - TAO_RT_Stub *rt_stub = - ACE_dynamic_cast (TAO_RT_Stub *, - invocation->stub ()); + CORBA::Policy_var client_protocol_policy_base = + TAO_RT_Endpoint_Utils::client_protocol_policy (invocation ACE_ENV_ARG_PARAMETER); + ACE_CHECK_RETURN (0); - do + if (client_protocol_policy_base.ptr () == 0) { - invocation->profile (invocation->stub ()->profile_in_use ()); - invocation->endpoint (invocation->profile ()->endpoint ()); - - // If known endpoint, select it. - if (invocation->endpoint () != 0) - { - int status; - if (rt_stub->private_connection ()) - { - TAO_Private_Transport_Descriptor private_desc (invocation->endpoint (), - ACE_reinterpret_cast (long, invocation->stub ())); - - status = invocation->perform_call (private_desc ACE_ENV_ARG_PARAMETER); - ACE_CHECK; - } - else - { - TAO_Base_Transport_Property default_desc (invocation->endpoint ()); - - status = invocation->perform_call (default_desc ACE_ENV_ARG_PARAMETER); - ACE_CHECK; - } - - // Check if the invocation has completed. - if (status == 1) - return; - } + this->TAO_Default_Endpoint_Selector::select_endpoint (invocation + ACE_ENV_ARG_PARAMETER); + ACE_CHECK; } - while (invocation->stub ()->next_profile_retry () != 0); + else + { + RTCORBA::ClientProtocolPolicy_var client_protocol_policy = + RTCORBA::ClientProtocolPolicy::_narrow (client_protocol_policy_base.in () + ACE_ENV_ARG_PARAMETER); + ACE_CHECK; - // If we get here, we completely failed to find an endpoint selector - // that we know how to use, so throw an exception. - ACE_THROW (CORBA::TRANSIENT (TAO_OMG_VMCID | 2, - CORBA::COMPLETED_NO)); -} + /// Cast to TAO_ClientProtocolPolicy + TAO_ClientProtocolPolicy *tao_client_protocol_policy = + ACE_static_cast (TAO_ClientProtocolPolicy *, + client_protocol_policy.in ()); -// **************************************************************** + /// Get the ProtocolList + RTCORBA::ProtocolList &client_protocols = + tao_client_protocol_policy->protocols_rep (); -TAO_Priority_Endpoint_Selector::~TAO_Priority_Endpoint_Selector (void) -{ + this->select_endpoint_based_on_client_protocol_policy (invocation, + client_protocol_policy, + client_protocols + ACE_ENV_ARG_PARAMETER); + ACE_CHECK; + } } void -TAO_Priority_Endpoint_Selector::select_endpoint (TAO_GIOP_Invocation *invocation - ACE_ENV_ARG_DECL) +TAO_RT_Invocation_Endpoint_Selector::select_endpoint_based_on_client_protocol_policy (TAO_GIOP_Invocation *invocation, + RTCORBA::ClientProtocolPolicy_ptr client_protocol_policy, + RTCORBA::ProtocolList &client_protocols + ACE_ENV_ARG_DECL) { - TAO_RT_Stub *rt_stub = ACE_dynamic_cast (TAO_RT_Stub *, - invocation->stub ()); - CORBA::Short client_priority; - - // Get client priority. - TAO_Protocols_Hooks *tph = invocation->orb_core ()->get_protocols_hooks (ACE_ENV_SINGLE_ARG_PARAMETER); - ACE_CHECK; - - if (tph->get_thread_CORBA_priority (client_priority - ACE_ENV_ARG_PARAMETER) - == -1) - ACE_THROW (CORBA::DATA_CONVERSION (1, - CORBA::COMPLETED_NO)); - - do + CORBA::Boolean valid_profile_found = 0; + + // Even though cycling through all the protocols is the correct + // things to do to find a match, starting from the start of the + // profile list is not. In addition, this code is also ignoring the + // forwarded reference (if it exists). This behavior is caused by + // problems with the profile management in TAO which are documented + // in bugzilla bugs 1237, 1238, and 1239. Once the above problems + // are fixed, this behavior should be fixed to do the right thing. + for (CORBA::ULong protocol_index = 0; + protocol_index < client_protocols.length (); + ++protocol_index) { - // Obtain profile. - invocation->profile (invocation->stub ()->profile_in_use ()); - - // Select an endpoint from the profile. - - if (invocation->profile ()->endpoint_count () == 0) - { - // Unknown protocol - move onto the next profile. - continue; - } + // Find the profiles that match the current protocol. + TAO_Profile *profile = 0; + TAO_MProfile &mprofile = invocation->stub ()->base_profiles (); - else if (invocation->profile ()->endpoint_count () == 1) - { - // Profile contains just one endpoint. This happens when: - // a) we are talking to a nonTAO server (which doesn't have - // the concept of multiple endpoints per profile) - // or - // b) we have TAO server with a non-lane threadpool, in which - // case there is only one acceptor - // In both cases we should use the endpoint regardless of its priority. - invocation->endpoint (invocation->profile ()->endpoint ()); - } - else + for (TAO_PHandle i = 0; + i < mprofile.profile_count (); + ++i) { - // Profiles contains more than one endpoint. Find one with the - // right priority. + profile = mprofile.get_profile (i); - TAO_Endpoint *endpoint = 0; - for (TAO_Endpoint *endp = invocation->profile ()->endpoint (); - endp != 0; - endp = endp->next ()) + if (profile->tag () == client_protocols[protocol_index].protocol_type) { - if (endp->priority () == client_priority) - { - endpoint = endp; - break; - } - } + valid_profile_found = 1; - if (endpoint != 0) - { - // Found an Endpoint with correct priority. - invocation->endpoint (endpoint); - } - else - { - // The profile didn't contain an endpoint with matching priority. - // There are two possibilities: - // a) the server is a multi-homed host and this is the - // only reason for profile containing more than 1 - // endpoint, i.e., case a) above. - // b) we have misconfiguration - threadpool with lanes on - // the server, and client priority not matching any of - // the lanes. - if (this->is_multihomed (invocation->profile ()->endpoint ())) - { - // case a - invocation->endpoint (invocation->profile ()->endpoint ()); - } - else - // case b - { - if (invocation->inconsistent_policies ().ptr ()) - { - CORBA::Policy_var priority_model_policy = rt_stub->exposed_priority_model (ACE_ENV_SINGLE_ARG_PARAMETER); - ACE_CHECK; + invocation->profile (profile); + invocation->endpoint (invocation->profile ()->endpoint ()); - invocation->inconsistent_policies ()->length (1); - invocation->inconsistent_policies ()[0u] = - CORBA::Policy::_duplicate (priority_model_policy.in ()); - } - ACE_THROW (CORBA::INV_POLICY ()); - } + int status = + this->endpoint_from_profile (invocation ACE_ENV_ARG_PARAMETER); + ACE_CHECK; + + if (status == 1) + return; + // @@ Else we should check for potential forwarding here. } } + } - // Try to perform the invocation using this endpoint. - int status; - if (rt_stub->private_connection ()) - { - TAO_Private_Transport_Descriptor private_desc (invocation->endpoint (), - ACE_reinterpret_cast (long, invocation->stub ())); - - status = invocation->perform_call (private_desc ACE_ENV_ARG_PARAMETER); - ACE_CHECK; - } - else + // We have tried all the profiles specified in the client protocol + // policy with no success. Throw exception. + if (!valid_profile_found) + { + if (invocation->inconsistent_policies ().ptr ()) { - TAO_Base_Transport_Property default_desc (invocation->endpoint ()); - - status = invocation->perform_call (default_desc ACE_ENV_ARG_PARAMETER); - ACE_CHECK; + invocation->inconsistent_policies ()->length (1); + invocation->inconsistent_policies ()[0u] = + CORBA::Policy::_duplicate (client_protocol_policy); } - - // Check if the invocation has completed. - if (status == 1) - return; + ACE_THROW (CORBA::INV_POLICY ()); } - while (invocation->stub ()->next_profile_retry () != 0); - // If we get here, we completely failed to find an endpoint selector - // that we know how to use, so throw an exception. + // If we get here, we found at least one pertinent profile, but no + // usable endpoints. ACE_THROW (CORBA::TRANSIENT (TAO_OMG_VMCID | 2, CORBA::COMPLETED_NO)); } int -TAO_Priority_Endpoint_Selector::is_multihomed (TAO_Endpoint *endpoint) +TAO_RT_Invocation_Endpoint_Selector::endpoint_from_profile (TAO_GIOP_Invocation *invocation + ACE_ENV_ARG_DECL) { - for (TAO_Endpoint *endp = endpoint; - endp != 0; - endp = endp->next ()) + // Narrow to the RT Stub. + TAO_RT_Stub *rt_stub = + ACE_dynamic_cast (TAO_RT_Stub *, invocation->stub ()); + + if (rt_stub == 0) { - if (endp->next () != 0 - && endp->priority () != endp->next ()->priority ()) - return 0; + ACE_DEBUG ((LM_DEBUG, "Unexpected error narrowing stub to TAO_RT_Stub")); + + ACE_THROW_RETURN (CORBA::INTERNAL ( + CORBA_SystemException::_tao_minor_code ( + TAO_DEFAULT_MINOR_CODE, + EINVAL), + CORBA::COMPLETED_NO), + 0); } - return 1; -} - -// **************************************************************** - -TAO_Bands_Endpoint_Selector::~TAO_Bands_Endpoint_Selector (void) -{ -} -void -TAO_Bands_Endpoint_Selector::select_endpoint (TAO_GIOP_Invocation *invocation - ACE_ENV_ARG_DECL) -{ - TAO_RT_Stub *rt_stub = ACE_dynamic_cast (TAO_RT_Stub *, - invocation->stub ()); - TAO_Protocols_Hooks *protocol_hooks = - invocation->orb_core ()->get_protocols_hooks (ACE_ENV_SINGLE_ARG_PARAMETER); - ACE_CHECK; - - CORBA::Policy_var bands_policy = TAO_RT_Endpoint_Utils::priority_bands_policy (invocation - ACE_ENV_ARG_PARAMETER); - ACE_CHECK; - - // Figure out target priority. + // Get the priority model policy. CORBA::Policy_var priority_model_policy = rt_stub->exposed_priority_model (ACE_ENV_SINGLE_ARG_PARAMETER); - ACE_CHECK; + ACE_CHECK_RETURN (0); - CORBA::Short server_priority = 0; - CORBA::Boolean is_client_propagated = 0; - protocol_hooks->get_selector_hook ( - priority_model_policy.in (), // input - is_client_propagated, // side effect - server_priority); // side effect + // Get the bands policy. + CORBA::Policy_var bands_policy = + TAO_RT_Endpoint_Utils::priority_bands_policy (invocation + ACE_ENV_ARG_PARAMETER); + ACE_CHECK; + int all_endpoints_are_valid = 0; + int match_priority = 0; + int match_bands = 0; + CORBA::Short client_thread_priority = 0; + CORBA::Short min_priority = 0; + CORBA::Short max_priority = 0; - CORBA::Short p; - if (is_client_propagated) + // If the priority model policy is not set. + if (priority_model_policy.ptr () == 0) { - // Get Client priority. - - int status = - protocol_hooks->get_thread_CORBA_priority (p // side effect - ACE_ENV_ARG_PARAMETER); - ACE_CHECK; - if (status == -1) + // Bands without priority model do not make sense. + if (bands_policy.ptr () != 0) { - ACE_THROW (CORBA::DATA_CONVERSION (1, - CORBA::COMPLETED_NO)); + if (invocation->inconsistent_policies ().ptr ()) + { + invocation->inconsistent_policies ()->length (1); + invocation->inconsistent_policies ()[0u] = + CORBA::Policy::_duplicate (bands_policy.in ()); + } + // Indicate error. + ACE_THROW_RETURN (CORBA::INV_POLICY (), 0); } + + // No priority model policy (and no bands policy): all endpoints + // are fair game. + all_endpoints_are_valid = 1; } + // If the priority model policy is set. else - p = server_priority; - - int in_range = 0; - - CORBA::Short min_priority; - CORBA::Short max_priority; - - protocol_hooks->get_selector_bands_policy_hook (bands_policy.in (), - min_priority, - max_priority, - p, - in_range); - - // If priority doesn't fall into any of the bands - if (!in_range) { - if (invocation->inconsistent_policies ().ptr ()) - { - invocation->inconsistent_policies ()->length (2); - invocation->inconsistent_policies ()[0u] = - CORBA::Policy::_duplicate (bands_policy.in ()); - invocation->inconsistent_policies ()[1u] = - CORBA::Policy::_duplicate (priority_model_policy.in ()); - } - ACE_THROW (CORBA::INV_POLICY ()); - } + // Get the protocol hooks. + TAO_Protocols_Hooks *protocol_hooks = + invocation->orb_core ()->get_protocols_hooks (ACE_ENV_SINGLE_ARG_PARAMETER); + ACE_CHECK_RETURN (0); - do - { - // Obtain profile. - invocation->profile (invocation->stub ()->profile_in_use ()); + CORBA::Short server_priority = 0; + CORBA::Boolean is_client_propagated = 0; - // Select an endpoint from the profile. + // Check the priority model policy to see if it is client + // propagated. + protocol_hooks->get_selector_hook (priority_model_policy.in (), + is_client_propagated, + server_priority); - if (invocation->profile ()->endpoint_count () == 0) + if (!is_client_propagated) { - // Unknown protocol - move onto the next profile. - continue; - } - - else if (invocation->profile ()->endpoint_count () == 1) - { - // Profile contains just one endpoint. This happens when: - // a) we are talking to a nonTAO server (which doesn't have - // the concept of multiple endpoints per profile) - // or - // b) we have TAO server with a non-lane threadpool, in which - // case there is only one acceptor - // In both cases we should use the endpoint regardless of its priority. - invocation->endpoint (invocation->profile ()->endpoint ()); + // Server declared: all endpoints are fair game. + all_endpoints_are_valid = 1; } + // Client propagated. else { - // Profiles contains more than one endpoint. Find one with the - // right priority. - - TAO_Endpoint *endpoint = 0; - for (TAO_Endpoint *endp = invocation->profile ()->endpoint (); - endp != 0; - endp = endp->next ()) + // Get client thread priority. + int status = + protocol_hooks->get_thread_CORBA_priority (client_thread_priority // side effect + ACE_ENV_ARG_PARAMETER); + ACE_CHECK; + if (status == -1) { - if (endp->priority () <= max_priority - && endp->priority () >= min_priority) - { - if (TAO_debug_level > 1) - { - ACE_DEBUG ((LM_DEBUG, - "(%P|%t) TAO Endpoint Selection: priority = %d, band = [%d %d], endpoint = %d\n", - p, - min_priority, - max_priority, - endp->priority ())); - } - endpoint = endp; - break; - } - } + ACE_THROW (CORBA::DATA_CONVERSION (1, + CORBA::COMPLETED_NO)); + } - if (endpoint != 0) + // If there are no bands. + if (bands_policy.ptr () == 0) { - // Found an Endpoint with correct priority. - invocation->endpoint (endpoint); + // Match the priority of the client thread with the + // endpoint. + match_priority = 1; } + // There are bands. else { - if (invocation->inconsistent_policies ().ptr ()) + // Get the bands. + RTCORBA::PriorityBandedConnectionPolicy_var bands_policy_ptr = + RTCORBA::PriorityBandedConnectionPolicy::_narrow (bands_policy); + + TAO_PriorityBandedConnectionPolicy *priority_bands_policy = + ACE_static_cast (TAO_PriorityBandedConnectionPolicy *, + bands_policy_ptr.in ()); + + RTCORBA::PriorityBands &bands = + priority_bands_policy->priority_bands_rep (); + + // Check which band range we fall in. + int in_range = 0; + protocol_hooks->get_selector_bands_policy_hook (bands_policy.in (), + client_thread_priority, + min_priority, + max_priority, + in_range); + + // If priority doesn't fall into any of the bands. + if (!in_range) { - invocation->inconsistent_policies ()->length (1); - invocation->inconsistent_policies ()[0u] = - CORBA::Policy::_duplicate (bands_policy.in ()); - } - ACE_THROW (CORBA::INV_POLICY ()); - } - } - - // Try to perform the invocation using this endpoint. - int status; - if (rt_stub->private_connection ()) - { - TAO_Private_Transport_Descriptor private_desc (invocation->endpoint (), - ACE_reinterpret_cast (long, invocation->stub ())); + if (invocation->inconsistent_policies ().ptr ()) + { + invocation->inconsistent_policies ()->length (2); + invocation->inconsistent_policies ()[0u] = + CORBA::Policy::_duplicate (bands_policy.in ()); + invocation->inconsistent_policies ()[1u] = + CORBA::Policy::_duplicate (priority_model_policy.in ()); + } - status = invocation->perform_call (private_desc ACE_ENV_ARG_PARAMETER); - ACE_CHECK; - } - else - { - TAO_Base_Transport_Property default_desc (invocation->endpoint ()); + // Indicate error. + ACE_THROW (CORBA::INV_POLICY ()); + } - status = invocation->perform_call (default_desc ACE_ENV_ARG_PARAMETER); - ACE_CHECK; + // Match the priority of the band with the endpoint. + match_bands = 1; + } } - - // Check if the invocation has completed. - if (status == 1) - return; } - while (invocation->stub ()->next_profile_retry () != 0); - - // If we get here, we completely failed to find an endpoint selector - // that we know how to use, so throw an exception. - ACE_THROW (CORBA::TRANSIENT (TAO_OMG_VMCID | 2, - CORBA::COMPLETED_NO)); - - -} - -// **************************************************************** - -TAO_Protocol_Endpoint_Selector::~TAO_Protocol_Endpoint_Selector (void) -{ -} - -void -TAO_Protocol_Endpoint_Selector::select_endpoint (TAO_GIOP_Invocation - *invocation - ACE_ENV_ARG_DECL) -{ - /// Narrow down to the right policy. - CORBA::Policy_var cp = - TAO_RT_Endpoint_Utils::client_protocol_policy (invocation ACE_ENV_ARG_PARAMETER); - ACE_CHECK; - - RTCORBA::ClientProtocolPolicy_var cp_policy = - RTCORBA::ClientProtocolPolicy::_narrow (cp.in () ACE_ENV_ARG_PARAMETER); - ACE_CHECK; - /// Cast to TAO_ClientProtocolPolicy - TAO_ClientProtocolPolicy *client_protocol_policy = - ACE_static_cast (TAO_ClientProtocolPolicy *, - cp_policy.in ()); - - /// Get the ProtocolList - RTCORBA::ProtocolList & protocols = - client_protocol_policy->protocols_rep (); - - TAO_RT_Stub *rt_stub = ACE_dynamic_cast (TAO_RT_Stub *, - invocation->stub ()); - - CORBA::Boolean valid_endpoint_found = 0; - - for (CORBA::ULong protocol_index = 0; - protocol_index < protocols.length (); - protocol_index++) + while (invocation->endpoint () != 0) { - // Find the profiles that match the current protocol. - TAO_Profile *profile = 0; - TAO_MProfile& mprofile = invocation->stub ()->base_profiles (); - - for (TAO_PHandle i = 0; - i < mprofile.profile_count (); - ++i) + // Get the priority of the endpoint. + CORBA::Short endpoint_priority = + invocation->endpoint ()->priority (); + + // If <all_endpoints_are_valid> or match the priority of the + // client thread or match the priority of the band or + // profile contains just one endpoint. This happens when: + // a) we are talking to a nonTAO server (which doesn't have + // the concept of multiple endpoints per profile) + // or + // b) we have TAO server with a non-lane threadpool, in which + // case there is only one acceptor + // In both cases we should use the endpoint regardless of its priority. + + if (all_endpoints_are_valid || + (match_priority && + client_thread_priority == endpoint_priority) || + (match_bands && + endpoint_priority <= max_priority && + endpoint_priority >= min_priority) || + invocation->profile ()->endpoint_count () == 1 && + endpoint_priority == TAO_INVALID_PRIORITY) { - profile = mprofile.get_profile (i); - if (profile->tag () - == protocols[protocol_index].protocol_type) + int status; + if (rt_stub->private_connection ()) { - // Save away the profile and endpoint that we found in the - // invocation. - invocation->profile (profile); - invocation->endpoint (profile->endpoint()); - valid_endpoint_found = 1; - - // Try to perform the invocation using this endpoint. - int status; - if (rt_stub->private_connection ()) - { - TAO_Private_Transport_Descriptor private_desc (invocation->endpoint (), - ACE_reinterpret_cast (long, invocation->stub ())); - - status = invocation->perform_call (private_desc ACE_ENV_ARG_PARAMETER); - ACE_CHECK; - } - else - { - TAO_Base_Transport_Property default_desc (invocation->endpoint ()); - - status = invocation->perform_call (default_desc ACE_ENV_ARG_PARAMETER); - ACE_CHECK; - } + TAO_Private_Transport_Descriptor private_desc (invocation->endpoint (), + ACE_reinterpret_cast (long, invocation->stub ())); - // Check if the invocation has completed. - if (status == 1) - return; + status = + invocation->perform_call (private_desc ACE_ENV_ARG_PARAMETER); + ACE_CHECK_RETURN (-1); } - } - } + else + { + TAO_Base_Transport_Property default_desc (invocation->endpoint ()); - // We have tried all the protocols specified in the client - // protocol policy with no success. Throw exception. + status = + invocation->perform_call (default_desc ACE_ENV_ARG_PARAMETER); + ACE_CHECK_RETURN (-1); + } - // Figure out proper exception. - if (!valid_endpoint_found) - { - if (invocation->inconsistent_policies ().ptr ()) - { - invocation->inconsistent_policies ()->length (1); - invocation->inconsistent_policies ()[0u] = - CORBA::Policy::_duplicate (client_protocol_policy); + // Check if the invocation has completed. + if (status == 1) + return 1; } - ACE_THROW (CORBA::INV_POLICY ()); - } - - // If we get here, we completely failed to find an endpoint selector - // that we know how to use, so throw an exception. - ACE_THROW (CORBA::TRANSIENT (TAO_OMG_VMCID | 2, - CORBA::COMPLETED_NO)); - -} - -void -TAO_Protocol_Endpoint_Selector::next (TAO_GIOP_Invocation - * - ACE_ENV_ARG_DECL_NOT_USED) -{ - ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("You Are not Suppesed to call: TAO_Protocol_Endpoint_Selector::next!!!\n"))); - // invocation->profile_index ()++; - // If we ran out of profiles to try - this will be detected and - // exception thrown once <endpoint> is called. -} - -void -TAO_Protocol_Endpoint_Selector::forward (TAO_GIOP_Invocation - *invocation, - const TAO_MProfile& /* mprofile */ - ACE_ENV_ARG_DECL) -{ - // Location forwarding is currently not supported when using - // RTCORBA::ClientProtocolPolicy. With the current profile - // management scheme being broken, it would be a pain to support here. - // @@ Add support for location forwarding once profile management is - // redesigned. - - // Currently location forward replies are ignored. When we receive - // a location forward reply, we act as if the profile we used - // didn't work, and we try the next one. Should we throw not - // supported exception instead? - this->next (invocation ACE_ENV_ARG_PARAMETER); -} - -void -TAO_Protocol_Endpoint_Selector::success (TAO_GIOP_Invocation *invocation) -{ - invocation->stub ()->set_valid_profile (); -} - -void -TAO_Protocol_Endpoint_Selector::close_connection (TAO_GIOP_Invocation *) -{ -} - -// **************************************************************** - -TAO_Priority_Protocol_Selector::~TAO_Priority_Protocol_Selector (void) -{ -} - -int -TAO_Priority_Protocol_Selector::is_multihomed (TAO_Endpoint *endpoint) -{ - for (TAO_Endpoint *endp = endpoint; - endp != 0; - endp = endp->next ()) - { - if (endp->next () != 0 - && endp->priority () != endp->next ()->priority ()) - return 0; + // Go to the next endpoint in this profile. + invocation->endpoint (invocation->endpoint()->next()); } - return 1; -} - -// **************************************************************** -TAO_Bands_Protocol_Selector::~TAO_Bands_Protocol_Selector (void) -{ + return 0; } |