Object - jms : Session

Represents the JMS session.

createTextMessage

(string content)

returns Message | error

Creates a JMS message, which holds the text content.

Parameters

  • content string
  • The text content that is used to initialize the message.

  • Return Type

    (Message | error)
  • Returns a text message or an error upon the occurrence of an error.

createMapMessage

(map content)

returns Message | error

Creates a JMS message, which holds the Map content.

Parameters

  • content map
  • The Map content that is used to initialize the message.

  • Return Type

    (Message | error)
  • Returns a map message or an error upon the occurrence of an error.

unsubscribe

(string subscriptionId)

returns error?

Unsubscribes a durable subscription that has been created by a client. It is erroneous for a client to delete a durable subscription while there is an active (not closed) consumer for the subscription, or while a consumed message being part of a pending transaction or has not been acknowledged in the session.

Parameters

  • subscriptionId string
  • The name, which is used to identify the subscription.

  • Return Type

    (error?)
  • Cancels the subscription.

createTemporaryQueue

()

returns Destination | error

Creates a JMS Queue, which can be used as temporary response destination.

  • Return Type

    (Destination | error)
  • Returns the JMS destination for a temporary queue or an error if it fails.

createTemporaryTopic

()

returns Destination | error

Creates a JMS Topic, which can be used as a temporary response destination.

  • Return Type

    (Destination | error)
  • Returns the JMS destination for a temporary topic or an error if it fails.

createQueue

(string queueName)

returns Destination | error

Creates a JMS Queue, which can be used with a message producer.

Parameters

  • queueName string
  • The name of the Queue.

  • Return Type

    (Destination | error)
  • Returns the JMS destination for a queue or an error if it fails.

createTopic

(string topicName)

returns Destination | error

Creates a JMS Topic, which can be used with a message producer.

Parameters

  • topicName string
  • The name of the Topic.

  • Return Type

    (Destination | error)
  • Returns the JMS destination for a topic or an error if it fails.