Tibco BusinessEvents FAQ

What are the different Concept Relationships ?

inheritance
contained
reference

What is the difference between a Policy and Rules in BE ?

Policies tend to be global statements about some entity: they are business directives

e.g. customers only have 1 logon session; event X must be processed in y secs.

Rules can be both business directives AND IT constructs.In BE, we map policies and business rules to concept models, state models, (production) rules, rule functions and state models.

How do we represent Policy in BE ?

This will typically depend on the policy. If the policy is that "customers only have 1 logon session" and I am enforcing this via filtering such requests as events in BE, then I might have a single concept property called customer.logonsesion - this cannot hold an array so if I get a request for a new session while this is populated, I can either overwrite it or ignore the new request. Which I do will depend on the associated business rules for implementing this policy (which in turn I may implement as production rules and / or in a state model).

When should we using what model? State model/concept model/rule model etc.

Concept models are for static relationships (eg data relationships that do not change). State models are for entity lifecycle models - what happens to entities over time.
Rulesets (rule models) define inference behaviors - what happens when. Decision models are for specific managed decisions to be taken at specific times during event processing.

What is an Inference agent? What does it do at runtime?

You may want to read the following chapter from BusinessEvents Architect's Guide -> Run-time Inferencing Behavior -> Runtime Architecture and Flow.
Inference Engine is the heart of BE where rules are applied on Events.
1. When an event arrives on a channel, its passed on to preprocessor and from there to inference engine (IE).
2. IE uses pattern matching (RETE algo) and working memory sets (facts created from previous events or loaded from other sources) to create a list of rules which can be applied to this particular event.
3. These rules are ordered according to priority to create rule agenda.
4. The action part of the first rule is applied on the event. This will probably change the knowledgebase or WM.
5. Action exection in step 4 forces another cycle starting from step 2 to recreate the rules agenda(forward chaining)
6. IE completes the cycle ( Run to completion - RTC cycle) once all rules have been executed and the agenda is empty.
7. The event is the consumed and concept asserted/stored into working memory.


Whatis Complex Event Processing?


Complex event processing (CEP) isan emerging network technology that creates actionable, situational knowledgefrom distributed message-based systems, databases and applications in real timeor near real time. CEP can provide an organization with the capability todefine, manage and predict events, situations, exceptional conditions,opportunities and threats in complex, heterogeneous networks.

Whatis the scope and use of Local Destination?

Local channels are used in rulesor rule functions to route events to an appropriate agent running in thesame engine (processing unit). Local channels are useful intwo cases:
• For applications using In Memory object management(generally used onlyfor testing)
• For certain scenarios where an inference agent isco-deployed with a queryagent.Local Destination doesn't have defaultdestination and they can be used in preprocess

Howdo you map Incoming Messages to Non-default Events ?

Two fields in a message header instruct TIBCOBusinessEvents to map the incoming message to a specified event type:
• The field named _ns_ takes a namespace as a value. Thenamespace points to
the event type, for example,www.tibco.com/be/ontology/Events/MyEvent
• The field named _nm_ takes the name of the event, forexample, NewMyEvent


An event was defined with Time to Live equal to 10 minutes.An instance of that event arrived from a JMS destination configured withEXPLICIT_CLIENT_ACKNOWLEDGE mode and was consumed in the preprocessor.
When will the JMS message corresponding to this event beacknowledged?

immediately after the Event.consumeEvent calls


What is the difference between Run To Complete(RTC) and Conflict resolution cycle ?

RTC
  • begins when an external action causes changes to the Rete network.
  • ends when there are no more rule actions to execute as a result of that initial change.
  • One RTC is composed of one or more conflict resolution cycles.
CTC

  • begins when TIBCO BusinessEvents builds (or refreshes) a rule action agenda
  • ends when a rule action is executed (or the agenda is empty)


In an application, where input data is coming frommultiple sources then how to synchronize data?

while receiving an event in event preprocessor wehave to lock the concept instance so that no other source will be able toupdate the same concept instance sometimes it will be difficult toget lock in one shot as some other source is updating the same instance inthat situation that it’s better to put retry logic with moderateinterval and moderate number of attempts.

How can we catch timeout exceptions from BW processesin BE?

Using Advisory events

Is there any way to generate Advisory events?

No

What is the sequence to start BE engines?

First Cache agent the Inference agent and while stoppingfirst Inference agent then Cache engine

There are some pending messages on BE queue (Assume theyare unable to complete RTC) what will happen if BE engine is restarted?

bug in 3.02, that is corrected fromrelease BE 4.0

What is the difference between serializers anddeserializers?

Serializers are used by Business Events to convertevents to messages while deserializers are used by Business Events toconvert messages to events.

Will Preprocessor rule function executed for time events?

No

Will it be possible to update event before it enter intoRETE n/w?

Yes, We can do it in Event pre-processors

Is it possible to release unwanted memory in BE?

Yes, by using Engine.GC() function

Is it possible restrict maximum length of a property BE?

Yes, In CDD file we can restrict

What are database concepts?

Database concepts are Business Events conceptscreated by mapping tables or views from a database. Each row in a tablerepresents one database concept instance, and each column represents theproperties of the database concept. Database concepts are different fromBusiness Events concepts because you can perform database operations suchas query, insert, update and delete.

What is an event preprocessor?

An event preprocessor is a rulefunction with one argument of type simple event. It performs actions afteran incoming message is converted into a simple event but before it isasserted into working
memory. This means that before a rulecan process the simple event,the event preprocessor executes certain tasksfirst.

What is a virtual rule function?

A virtual rulefunction is a rule function that has arguments but no body. Itsimplementation is provided in the Decision Manager Business UserInterface. The implementations are called decision table classesor external classes since they exist outside the Business Eventsengine. Each row in a decision table forms a simple rule and collectivelydefines the body of the virtual rule function.

What is a state modeler?

State modeler is aUnified Modeling Language (UML) compliant application that allows you tomodel the lifecycle of an instance. For each instance of a given concept,you can define which states it can
have and how it will change from state to state based onapplicable rules. A state model begins with a start state and ends withone or more end states. It is similar to a finite state automaton. Inbetween may be simple, composite and concurrent states connected bytransitions. A simple state is a state that has an entry and an exitaction. A composite state is like a group of nested folders that containother states. A concurrent state allows multiple state flows to be passedon.Transitions determine when an instance of a concept passes fromone state to another which is indicated by complex transitions, or froma state to itself which is indicated by self-transitions.

What is the difference between Score card and Concept?

We can create multiple instances of concept butthat is not possible with score card, scorecard is just like staticvariable

What is the difference between Rule and rule function?

Rules can’t return anything where as rule functionscan return any objects

2 comments:

  1. What an informative article you shared! This post on Tibco corporate events great! I never knew some of these things that you mentioned in this article. Thanks a lot for sharing my friend!

    ReplyDelete