Skip to main content
Skip table of contents

23.12 Topics

This section explains the creation of Topic objects:

  1. Creating the Admin Service

MQ Admin Service creates topics on the FioranoMQ server. The instance of admin service can be obtained from the admin connection.

CODE
acf = (MQAdminConnectionFactory) ic.lookup ("primaryACF");
ac = acf.createMQAdminConnection ("admin", "passwd");
adminService = ac.getMQAdminService();

2. Topic Metadata

Create a Topic metadata, specifying the name, description and the storage type. The storage type of the destination can be RDBMS_BASED_DATABASE or FILE_BASED_DATABASE

CODE
TopicMetaData metadata = new TopicMetaData ();
metadata.setName ("mytopic");
// For RDBMS based storage type
metadata.setStorageType(IFioranoConstants.RDBMS_BASED_DATABASE);

or

CODE
// For file based storage type
metadata.setStorageType(IFioranoConstants.FILE_BASED_DATABASE);

3. Create the Topic

Create the Topic object using the adminService and the topic metadata.

CODE
adminService.createTopic(metadata);
JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.