Open topic with navigation

TIBCO BusinessEvents® Enterprise Edition 6.3.1

# Creating the Load Balancer

The startup rule function has to be provided. It creates and returns a load balancer that can be used to send messages to load balanced remote destinations.

Procedure
1. Create the router TCP connection in a startup rule function.

       LoadBalancer.Router.createLoadBalancerTo(adhocConfigName);

2. Send Event to the Receiver .
   Use this rule function as an event preprocessor. It sends an event to a remote receiver. The router agent does not have any destinations. The routing decision is made using the routing key.

       void LoadBalancer.Router.send(Object
       				  loadBalancer , SimpleEvent
       				  event, String
       				  routingKey);

3. Discard the Load Balancer.
   Put this rule function in a shutdown rule function.

       Object loadBalancer = Collections.Map.remove(Collections.Map.getMap(String mapID), Object key);

       Collections.Map.deleteMap(String mapID);

4. This rulefunction discards the Load Balancer.

       void LoadBalancer.Router.discardLoadBalancer(Object loadBalancer);

Did you find this helpful?

YesNo
Great!
Thanks for taking the time to give us some feedback.
Sorry about that

Why wasn't this helpful? (check all that apply)

Could not find what I was looking for
Instructions confusing or unclear
Instructions did not work

Want to tell us more?

Please select at least one option or provide details about the issue!!

Error occurred while submitting feedback.

Error2 occurred while submitting feedback.

TIBCO BusinessEvents® Enterprise Edition

Copyright © 2004-2024. Cloud Software Group, Inc. All Rights Reserved.