Contents

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
public void testHierarchicalTopics ()
{
// create the initial context and connect to FioranoMQ 9
Hashtable env = new Hashtable ();
env.put (Context.SECURITY_PRINCIPAL, "anonymous");
env.put (Context.SECURITY_CREDENTIALS, "anonymous");
env.put (Context.PROVIDER_URL, "http://localhost:1856");
env.put Context.INITIAL_CONTEXT_FACTORY,"fiorano.jms.runtime.naming.FioranoInitialContextFactory");
InitialContext ic = new InitialContext (env); 
System.out.println ("Created InitialContext:: " + ic);
MQAdminConnectionFactory acf =
(MQAdminConnectionFactory) ic.lookup ("primaryACF");
MQAdminConnection ac = acf.createMQAdminConnection ("admin", "passwd");
System.out.println ("Created Admin Connection...");
MQAdminService adminService = ac.getMQAdminService ();
System.out.println ("Received handle to Admin services:: " + adminService); 
// Create a topic named primaryTopic.subTopic1
String topicName = "primarytopic.subtopic1";
TopicMetaData tMetaData = new TopicMetaData();
tMetaData.setName (topicName);
adminService.createTopic (tMetaData);
Topic topic = (Topic) ic.lookup (topicName);
System.out.println ("Looked up the Hierarchical Topic ", topic.getName()); 
//create a topic named primarytopic.subtopic2
String topicName = "primarytopic.subtopic2";
TopicMetaData tMetaData = new TopicMetaData ();
tMetaData.setName (topicName);
adminService.createTopic (tMetaData);
topic = (Topic) ic.lookup (topicName);
System.out.println ("Looked up the Hierarchical Topic ", topic.getName());
}

15.1.2

...

eStudio

The User can create Hierarchical Topics with admin Studio. To create hierarchical topics with studioeStudio, follow the steps below:

  1. Launch Fiorano StudioeStudio and connect Studio eStudio to the FioranoMQ Server.
  2. To create a topic, navigate to the Topics sub-node under the Destinations node of the tree
  3. Right-click the Topics node and select Add Topic

...

Adaptavist ThemeBuilder EngineAtlassian Confluence