Key Java API Components for Custom Channel
Using the Java API, you can create your own custom channel according to your requirement.
Refer to the Java API Reference for complete list of Java classes and interfaces for the custom channel. However, few of the key Java classes, interfaces and their key components are mentioned in the following section. You can implement these methods to create your custom channel.
class com.tibco.be.custom.channel.BaseDestination
interface com.tibco.be.custom.channel.Event
You need to implement the Event interface which holds the underlying event related data. An instance of this interface is to be returned through the custom deserializer.
class com.tibco.be.custom.channel.BaseEventSerializer
You need to extend the BaseEventSerializer class. The following methods are used during serialization and deserialization of the custom channel message.
You must specify the fully qualified Java class name of the serializer in the drivers.xml file.
interface com.tibco.be.custom.channel.EventContext
A new instance of this interface is to be returned through the BaseDriver.getDestination().getEventContext method. Implement the following EventContext interface methods.
- reply - This corresponds to the catalog function Event.replyEvent.
- acknowledge - For some messaging systems, this method specifies an indication that this message can be removed from the messaging system. This method is called by BusinessEvents when message processing is completed.
- rollback - For messaging systems that support transactions, rollback is invoked by BusinessEvents when there is an internal failure during the transaction. The implementation handles rollback as applicable to the custom channel.
Copyright © TIBCO Software Inc. All rights reserved.