Showing posts with label MQ. Show all posts
Showing posts with label MQ. Show all posts

Monday, January 9, 2017

MQ as a Service in IIB


IBM introdued MQ or Database as SOA service in IIB.This is available in earlier versions of WMB as supportpac.
This includes two things :
·         An IRI Specification defining addresses for referencing WebSphere MQ queues and topics in a way similar to URL Web addresses.
·         A WSDL Binding Specification defining extensions for WSDL that describe WebSphere MQ applications, including its connections, the queues or topics it uses, its message exchange pattern (request-response or one-way) and the quality of service and message formats it uses.
Why MQ or Database services can be used as SOA services?Whats the benefit?
·         Architects can catalogue MQ/DB  applications in a standard way as they are specified in WSDL
·         MQ/DB applications can be extended to Webservice stack. These specifications will enable them to write a WMQ/DB service implementation that will interoperate with other WMQ/DB service implementations.
·         Use the Service Definitions to aid the development, management and monitoring of WebSphere MQ/DB applications, particularly where tools exist that take advantage of these specifications
·         Helps in dynamic invocation

Now,lets create a MQ service and use it in a message flow,

1)Select MQ Service in File->New





2)After creating MQ service,a screen open for MQ service to fill in all the details
3)Provide MQ details to test the connectivity with MQ QueueManager

4)Next step is to choose,whether we are going for One-way or Req-Res modal ,and what are the queues we are selecting
5)Next is to choose ,MQ header information as below,
If we are selecting only one-way,then only Request MQ headers are sufficient to be fillied up
6) Now,we can choose the messagetypes for input messages by first having the messageset in the MQ service folder itself so that it gets referred in the Input (Use XML schema elements àOpen file)

7)Now drag and drop the newly created MQService to the MQInput node.We can now see that all the properties defined in MQ Service gets reflected in the MQInput node’s properties.

Wednesday, October 26, 2016

MQ Linux Commands

The majority of these commands are run as the mqm (or equivalent) user. By default these commands are in /opt/mqm/bin which I would advise adding to the mqm users PATH.

Create a Queue Manager

$ crtmqm REPLACE_QMGR_NAME

Delete a Queue Manager

$ dltmqm REPLACE_QMGR_NAME

Start Queue Manager

$ strmqm REPLACE_QMGR_NAME

Stopping Queue Manager

Wait for queue manager to shutdown
$ endmqm -w REPLACE_QMGR_NAME

End Immediately
$ endmqm -i REPLACE_QMGR_NAME

Start Queue Manager (Init Script)

By default Websphere MQ does not ship with an init script, you can add this functionality via a support pac (MSL1) provided by IBM.
$ service ibm.com-WebSphere_MQ start

Stopping Queue Manager (Init Script)

$ service ibm.com-WebSphere_MQ stop

Start MQ Listener

$ echo "start LISTENER(SYSTEM.DEFAULT.LISTENER.TCP)" | runmqsc REPLACE_QMGR_NAME

Stop MQ Listener

$ echo "stop LISTENER(SYSTEM.DEFAULT.LISTENER.TCP)" | runmqsc REPLACE_QMGR_NAME

Display Queue Managers & Status

$ dspmq

Set MQ Privileges

In order for a Unix user to start utilizing MQ they must have the appropriate privileges. You can find the available privileges in IBM's Documentation.
Set MQ Privileges By User
$ setmqaut -m REPLACE_QMGR_NAME -t qmgr -p REPLACE_USER REPLACE_PLUS_OR_MINUS_PRIVILEGE

Set MQ Privileges By Groups
$ setmqaut -m REPLACE_QMGR_NAME -t qmgr -g REPLACE_GROUP REPLACE_PLUS_OR_MINUS_PRIVILEGE

Display MQ Privileges

Display MQ Privileges By Users
$ dspmqaut -m REPLACE_QMGR_NAME -t qmgr -p REPLACE_USER

Display MQ Privileges By Groups
$ dspmqaut -m REPLACE_QMGR_NAME -t qmgr -g REPLACE_GROUP

Lookup MQ Error Numbers

$ mqrc REPLACE_ERROR_NUM

MQ Sample Scripts

Within the MQ release by IBM there is a package that contains sample scripts for MQ. There are about 3 of these sample scripts that I have found pretty useful.
Pop (GET) Messages off a queue
$ amqsget REPLACE_Q_NAME REPLACE_QMGR_NAME

This command will remove messages from the queue, only use this if you no longer want the messages in the queue.
Browse Messages in a queue
$ amqsbcg REPLACE_Q_NAME REPLACE_QMGR_NAME

Open a Queue for writing
$ amqsput REPLACE_Q_NAME REPLACE_QMGR_NAME

When you find yourself with a system that is connected to a repository but doesn't see new messages you can try opening the queue for writing with amqsput to "refresh" the connectivity. You do not have to write anything to the queue. Simply open the queue and press ctrl+d without typing any additional characters.

Open Websphere MQ CLI

$ runmqsc REPLACE_QMGR_NAME

Websphere MQ CLI Commands

The following commands are to be run directly from the MQ command line interface.

Start MQ Listener

start LISTENER(SYSTEM.DEFAULT.LISTENER.TCP)

Stop MQ Listener

stop LISTENER(SYSTEM.DEFAULT.LISTENER.TCP)

Disable Channel Authentication

alter qmgr chlauth(disabled)

Channel Authentication is new as of MQ 7.0. If your systems don't use it you can simply turn it off.

Display Queues

All Queues
display queue(*)

Specific Queues
display queue(REPLACE_Q_NAME)

Short hand
dis q(REPLACE_Q_NAME)

Display Local Queues only

All Queues
display qlocal(*)

Specific Queue
display qlocal(REPLACE_Q_NAME)

Short hand
dis ql(REPLACE_Q_NAME)

Display Alias Queues only

All Queues
display qalias(*)

Specific Queue
display qalias(REPLACE_Q_NAME)

Short hand
dis qa(REPLACE_Q_NAME)

Display Cluster Queues only

All Queues
display qcluster(*)

Specific Queue
display qcluster(REPLACE_Q_NAME)

Short hand
dis qc(REPLACE_Q_NAME)

Display Channels

All Channels
display channel(*)

Specific Channel
display channel(REPLACE_CHANNEL_NAME)

Short hand
dis channel(REPLACE_CHANNEL_NAME)

Display Channel Status

All Channels
display chstatus(*)

Specific Channel
display chstatus(REPLACE_CHANNEL_NAME)

Short hand
dis chstatus(REPLACE_CHANNEL_NAME)

Display Local Queue Manager Information

display qmgr

Display Cluster Queue Manager Information

display clusqmgr(REPLACE_CLUSQMGR_NAME)

Show number of INPUT and OUTPUT threads open

display qstatus(REPLACE_Q_NAME) IPPROCS OPPROCS

Find Process ID of Processes Accessing Queue

display qstatus(REPLACE_Q_NAME) TYPE(HANDLE) ALL

Refresh Cluster Queue Manager

refresh cluster(REPLACE_CLUSQMGR_NAME)

Start Channel

start channel(REPLACE_CHANNEL_NAME)

What's Clustering and how to create it


What is clustering?


Clustering is a way to logically group WebSphere MQ queue managers so that you have: – reduced system administration due to fewer channel, remote queue, and transmission queue definitions. – increased availability and workload balancing due to the ability to define instances of the same queue on multiple queue managers in the cluster and distribute messages to those queues.
How do you create a cluster?
go to servers -> clusters-> new ->give cluster_name->define first member->define other members->finish
How do you add a new cluster member?
go to servers -> clusters->cluster_name ->cluster members ->new ->give name/node/others->apply->ok->save
one of the cluster member (jvm) is having issues. To troubleshoot the issue, you decided to take it out of the cluster. How do you do that?
Make its runtime weight to 0
In a complex environment, there are 10 machines. Machine A is having 8GB RAM and machine B having 2GB of RAM. The administrator decided to send twice as many request as machineB to machineA. How can he achive it?
give machineA twice the weight as machineB
After making some changes on a cluster, it is required to recycle/restart all the cluster JVMs. The lead admin told you to make sure that there should not be any downtime during this recycle. Which option do you use to achieve it?
Ripplestart
A large application which has 5web modules has been deployed on to a cluster. After some months, the developer asked you to update on of the 5web modules. How do you do it?
Rollout
What is a backup cluster?
can you change the cluster name, once it was created
No

Tuesday, October 25, 2016

WebSphere Message Broker(IIB) FAQ Interview Questions


1.What are the features of Message Broker?


Ans: Routing, Transformation and Integration.

2.What is the role of configuration manager?
Ans:Connect to the broker and to deploy the message flows onto the broker.

3.How to create Broker from Command prompt?
Ans: Using mqsicreatebroker command.

4.What are the default properties of MQ Input node?
Ans:Message Domain, Message Set, Message Type, Message Format, Topic.

5.Which nodes are used to change the message in the flow?
Ans:Compute Node, Filter Node and ResetContentDescriptor node.

6.Name 6 built-in nodes in MB Toolkit?
Ans: (i) MQInput node
(ii) MQOutput node (iii)
Compute node (iv) Database node
(v) AggregateControl node
(vi)Filter node.

7.How to call the method or function in the ESQL coding?
Ans:Using the “CALL” keyword.

8.What is the Broker Domain?
Ans:Group of brokers that coordinate a single configuration manager constitute a Broker Domain.

9.Name the message formats which MB support?
Ans:XML, TDS, CWF, EDI, SWIFT.

10.What is an Execution Group?
Ans:An execution group is a named grouping of message flows that have been assigned to a broker.

11.Difference between Root and OutputRoot?
Ans:Root is used in the Database content changing and in Filter node. OutputRoot is used in the ESQL code for a Compute node that creates a new output message based on the input message.

12.What is User name Server and where it is defined?
Ans:The User Name Server is an optional runtime component that provides authentication of users and groups performing publish/subscribe operations.

13.How can we see the error log files in broker?
Ans:The Windows Event Viewer is where WebSphere Message Broker writes records to the local system.

14.What are the perspectives there in MB Toolkit? In which perspective we deploy the flow?
Ans:(i) Administration Perspective
(ii) Application Development Perspective
(iii)Debugging Perspective
(iv) Java Perspective .
We deploy flows in Administration Perspective .

15.What are the different ways to give input without using MQInput node?
Ans:SCADAInput, HTTPInput, FileInput, Real-timeInput, JMSInput, Custom Input nodes.

16.What is PARSER? Difference between PARSER and FORMAT?
Ans:A Parser is defined as a program that interprets the bit stream of an incoming message and creates an internal representation of it in a tree structure.     Ex: MRM parser
A Format is a physical representation of a message.     Ex: XML wire format

17.Define Correlation names?
Ans:A correlation name is a field reference that identifies a well-defined starting point in the logical message tree and is used in field references to describe a standard part of the tree format.

18.How will we use a Cobol copybook in MB?
Ans:You can populate your message set with message definitions by importing COBOL copybook files, using either the New Message Definition File wizard or the mqsicreatemsgdefs command line utility.

19. What is SCHEMA of broker?
Ans:A broker schema is a symbol space that defines the scope of uniqueness of the names of resources defined within it. The resources are message flows, ESQL files, and mapping files.

20.How can you interact with Database using Compute node?
Ans:Specify in Data Source the name by which the appropriate database is known on the system on which this message flow is to execute.

21. What exactly do you understand by message broker??
A:        A Message Broker is an intermediary program that helps communicating multiple system to each other by transforming, routing the messages in the way they need.


22.      Why do we require message broker when we have MQ?
A:        Both message broker and mq works as middleware programs, that is to help communicating different systems, but mq has a slight drawback that it cannot transform the messages. It can just send the message to other system.

23.       What is the difference between Message Broker and MQ?
A:        WebSphere MQ facilitates communication between applications by sending and receiving message data via messaging queues. WebSphere MQ provides a secure and reliable layer of transport for moving data unchanged in the form of messages between applications but it is not aware of the content of the messages.

WebSphere Message Broker is built to extend WebSphere MQ, and it is capable of understanding the content of each message that it moves through the Broker. Message Broker can do the following:
Matches and routes communications between services
Converts between different transport protocols
Transforms message formats between requestor and service
Identifies and distributes business events from disparate sources.


24.        What are the advantages of using Websphere message broker?
A:        Websphere message broker provides services, based on message brokers to allow you to:
Route a message to several destinations, using rules that act on the contents of one or more of the fields in the message or message header.
Transform a message, so that applications using different formats can exchange messages in their own formats.
Store a message, or part of a message, in a database.
Retrieve a message, or part of a message, from a database.
Modify the contents of a message; for example, by adding data extracted from a database.


25.         What all are the main components used in Message Broker?
A:        The main components used in Message Broker Name Server are
User Name Server
Configuration Manager
Broker


26.        What do you understand by Broker Domain?
A:        Group of brokers under a single configuration manager constitute a Broker Domain.


27.         What is the significance of nodes in message flows?
A:        A message flow node receives a message, performs a set of actions against the message, passes the original message or the changed message, to the next node in the message flow.


28.        If configuration manager is down, what are the effects on the running brokers?
A:        The running broker will also be down at the moment when configuration manager is down.

29        How can we create broker?
A:        Two ways to create broker:
By using Websphere Message Broker Explorer.
By using command prompt.


30.       What is the command use to create broker?
A:        mqsicreatebroker is the command used to create broker.


31.        What is User name Server?
A:        The User Name Server is an optional runtime component that provides authentication of users and groups and give an administrative control over who can publish and who can subscribe operations.


32.       What is the Role of Username server?
A:        The User Name Server interfaces with operating system facilities to provide information about valid users and groups in a broker domain.


33.      Can a single queue manager have two brokers?
A:        No a single queue mnager cannot have two brokers.

34.        With Which command one can deploy the bar files?
A:        Using the mqsideploy command one can deploy the bar files.


35.       What is the difference between a Root and OuputRoot?
A:        Root is used in the Database content changing and in Filter node.

Output Root is used in the ESQL code for a Compute node that creates a new output message based on the input message


36.      What is the Use of Configmanager?
A:        To Connect to the remote broker or local broker and to deploy the message flows onto the Broker.


37.      Which perspective you used to deploy the flow?
A:        Administrator perspective is used to deploy the flow.


38.       What do you understand by EAI? Name some EAI tools?
A:        Enterprise Application Integration refers to the integration of one or more applications and processes together.
Tools: WBI Message Broker, Tibco, WebMethods and ICS


39.       What are the Features of Message Broker?
A:        WMB has many features, The main features are :
Routing
Transformation and
Integration

40.        What do you mean by an Execution Group?
A:        An execution group is a named grouping of message flows that have been assigned to a broker. The broker enforces a degree of isolation between message flows in distinct execution groups by ensuring that they execute in separate address spaces, or as unique processes.


41.       What is the significance of SCHEMA in message broker?
A:        A broker schema is a symbol space that defines the scope of uniqueness of the names of resources defined within it. The resources are message flows, ESQL files, and mapping files.


42.      What are the perspectives you have mainly used while development in message broker?
A:        The perspectives mainly used while the development in message broker are

Administration Perspective
Application Development Perspective
Debugging Perspective
Java Perspective (MB 6)
43. What is the significance of message flows in message broker?
A:        A message Flow describes the sequence of steps followed in the broker that processes an input message when an input message is received.

44.         What is PARSER?
A:        A Parser is a program that takes the incoming message, interprets its bit stream and creates an internal representation of it in a tree like structure, which can be then understand by message broker assembly.


45.        What is a Format?
A:        Physical Representation of a message is a Format.


46.        What you do to make your services actually run?
A:        Packaging services in a BAR file and deploy the BAR file on the broker.


47.       What is a BAR?
A:        Broker Archive or BAR is a package of message flows, message sets, java utility classes, xslts etc. that are grouped together to be deployed on the broker.


48.       Which command is used to create a BAR?
A:        mqsipackagebar command.


49.      What does mqsiapplybaroverride command do?
A:        The mqsiapplybaroverride command is used to replace configurable values in the broker archive (BAR) with new values that you specify in a properties file.


50.       Which nodes in WMB supports aggregation?
A:
AggregateControl
AggregateRequest
AggregateReply


51.      Is it possible to create multiple instances of a message flow?
A:        Yes. We can create multiple instance of a message flow by deploying the message flows to different execution group.


52.       What is a logical message tree?
A:        Logical message tree is the internal representation of a message.

53.        What are the types of Trees?
A:        Four sub tree of a logical tree created by input node of a message flow:
Message tree
Environment tree
Local Environment tree
Exception List tree.


54.        What is the purpose of a filter node?
A:        The purpose of a filter node is to route a message based on the content dynamically


55.       What are the types of TRACES?
A:
User trace
Service trace.


56.       What are the Types of Queues, one can create in MQ?
A:
Local queue
Remote queue
Transmission queue
Alias queue
Dead letter queue


57.       What are the types of clients in MQ?
A:        There are two types of clients in MQ
  • Fat Clients: Does have a local queue manager.
  • Slim clients: Does not have a local queue manager, whereas the queue manager reside on the server.


58.        With which all nodes one can change message in a message flow?
A:        Compute Node, Message Mapping Node, Filter Node, ResetContentDescriptor Node ca change message in a message flow.


59.       What will happen if we don’t specify queue name in a MQOUTPUT or MQINPUT node?
A:        Message will be backed out and an exception will be thrown with the message no queue name is defined.


60.        What happen if a message is sent to a queue and the queue is filled?
A:        Then the message goes to the relevant dead letter queue.


61.       What is the difference between Environment and Local Environment tree?
A:        The environment tree differs from the local environment tree in that a single instance of it is maintained throughout the message flow. If you include a Compute node, a Mapping node, or a JavaCompute node in your message flow, you do not have to specify whether you want the environment tree to be included in the output message. The environment tree is included automatically, and the entire contents of the input environment tree are retained in the output environment tree. Any changes that you make are available to subsequent nodes in the message flow, and to previous nodes.


62.        In what all cases message goes into DeadLetter Queue?
A:
When the Destination queue is full
When the Destination queue doesn’t exist
When the incoming message too large
When the Sender is not authorized to use the destination queue.


63.        WMB provide supports for what types of messages?
A:        WMB provide support for following type of messages:

MRM
XML
XMLNS
XMLNSC
JMSMap
JMSStream
MIME
BLOB
IDOC
TOP

64.       What do you mean by Correlation names?
A:        A correlation name is a field reference referencing a well-defined starting point in the logical message tree and to describe a standard part of the tree format.


What do you mean by ResetContentDescriptor node?
A:        ResetContentDescriptor node request to parse the message with different parser, leaving the message content unchanged.


65.       What is the difference between an MQGet node nd MQInput node?
A:        The MQGet node reads a message from a specified queue, and establishes the processing environment for the message. Whereas, The MQInput node receives a message from a WebSphere MQ message queue that is defined on the queue manager of the broker.

You can use an MQGet node anywhere in a message flow, unlike an MQInput node, which you can use only as the first node in a message flow.


66.       What is the difference between SOAPRequest node and SOAPAsyncRequest node?
A:        The SOAPAsyncRequest node sends a Web service request, but the node does not wait for the associated Web service response to be received. This asynchronous functionality enables multiple outbound requests to be made almost in parallel because the outbound request is not blocked waiting for the response.

Whereas, The SOAPRequest node is a synchronous request and response node, which blocks processing after sending the request until the response is received.


67.       What is the difference between Mapping node and Compute node transformation?
A:        In Compute node you can transform the message by coding ESQL in the ESQL resource file attached. Whereas, In mapping node you can use graphical maps to transform input message by associating an input message model such as a DFDL or XML schema, or an MRM Message Set and an output message model.

In compute node you can change the entire message even the header assemblies. But, In mapping node you can change the message assembly, message body, and properties.

68.        What is the difference between Input and MQInput node?
A:        Use the Input node as an In terminal for an embedded message flow (a subflow).The MQInput node receives a message from a WebSphere MQ message queue that is defined on the queue manager of the broker. It is the first node of your message flow.


69.        What is the purpose or use of compute node?
A:        The Compute node is used to:

Build a new message using a set of assignment statements
Copy messages between parsers
Convert messages from one code set to another
Transform messages from one format to another

70.         How the interaction with Database does take place using Compute node?
A:        In Data Source specify the name by which the appropriate database is known on the system on which this message flow is to execute.


71.       Difference between try catch node and throw node?
A:        Include a Throw node to force an error path through the message flow if the content of the message contains unexpected data.

If a downstream node (which can be a Throw node) throws an exception, the TryCatch node catches it and routes the original message to its Catch terminal. Connect the Catch terminal to further nodes to provide error processing for the message after an exception.

72.        How will input messages with different – different delimiters between the fields are handled in WMB?
A:        Using MRM domain we can input messages with different – different delimeters between the fields in WMB.

73.       What do you mean by depth of a Queue?
A:        Queue depth, is the number of pending input/output messages in a queue.


74.       How can we know the current depth of a queue?
A:        Using MQSC property CURDEPTH we can know the current depth of a queue.


75.        Message Broker supports what all formats?
A:        Message Broker supports XML, TDS, CSV, CWF, EDIFACT, SWIFT, COBOL formats

76.        What nodes uses ESQL?
A:        ESQL can be used with the Compute, Database, and Filter nodes.


77.       What is ESQL?
A:        Extended Structured Query Language (ESQL) is a programming language based on Structured Query Language (SQL), which is commonly used with relational databases such as DB2. ESQL extends the constructs of the SQL language to provide support for you to work with both message and database content.


78.       What functionality ESQL provides?
A:        Through ESQL you can

Change the message content.
Modify an existing message
Create a new message
Add dynamic terminals
Route a message
Propagate a new request


79.       What are the types of variables in ESQL?
A:        ESQL variables can be described as external variables, normal variables, or shared variables.


80.        What are external variables, normal variables, or shared variables?
A:                 External variables:
Also known as user defined properties.
Exist for entire life time of a message flow and are visible to all messages passed through the flow.
Defined at module or schema level.
You have to assign an initial value at the time of declaring an external variable and then can modify the initial value at deployment time by using the BAR editor.

Normal Variables:
Have lifetime of just one message pass through a node.
Visible to that message only in which it was defined.
To define, omit both EXTERNAL and SHARED keyword.

Shared variable:
Used to implement in-memory cache in the message flow.
Have a long life time and are visible to multiple messages pass through the flow.
Exist for the lifetime of Execution group, lifetime of flow or node, lifetime of node’s ESQL that declares the variable.
Initialized when the first message pass through the node or flow after broker startup.


81.       What are patterns?
A:        A pattern captures a tested solution to a commonly recurring problem, addressing the objectives that you want to achieve.


82.       What are the benefits of using patterns?
A:        Patterns provide the following benefits:

Give you guidance for the implementation of solutions
Increase development efficiency, because resources are generated from a set of predefined templates
Result in higher quality solutions, through reuse of assets and common implementation of programming approaches, such as error handling and logging

83.        How do you ensure that messages do not lose?
A:        For application and internal messages traveling across WebSphere MQ, two techniques protect against message loss:

Message persistence – If a message is persistent, WebSphere MQ ensures that it is not lost when a failure occurs, by copying it to disk.
Sync point control – An application can request that a message is processed in a synchronized unit-of-work .



84.        How to use functions in your esql code?
A:        Use CALL keyword to call functions or methods.


85.       What are the ways in which you can access databases from a message flow?
A:        You can access a database from a message flow in two ways:

You can design a message flow that responds to events generated by the database.
After a flow has already started, you can access the database to read or update information in it. Information from the database can be used to enhance or influence the operation of the message flow.
86. What all nodes can access databases?
A:        We can access a database from a message flow by using the following nodes:

Compute
Database
DatabaseInput
DatabaseRetrieve
DatabaseRoute
Filter
JavaCompute
Mapping


87.       What is Publish/Subscribe?
A:        Publish/subscribe is a style of messaging application in which the providers of information (publishers) are decoupled from the consumers of that information (subscribers).


88.       What are the techniques used in transforming and enriching messages in WMB?
A:        We can transform and enrich messages by using one or more of the following techniques:

Mappings
ESQL
Java
XSL style sheets
PHP
.NET


89.       What are the basic error handling techniques available in message flow?
A:        There are two general approaches to handle errors in a message flow:

Failure checking
Catching Exceptions


90.       What are message models?
A:        Most message formats are not self-defining, and a parser must have access to a predefined model that describes the message, if it is to parse the message correctly. A message model is used by WebSphere Message Broker to model a message format.


91.       What are the advantages of modeling messages?
A:        Even if your messages are self-defining, and do not require modeling, message modeling has the following advantages:

Runtime validation of messages. Without a message model, a parser cannot check whether input and output messages have the correct structure and data values.
Enhanced parsing of XML messages. Although XML is self-defining, all data values are treated as strings if a message model is not used. If a message model is used, the parser is provided with the data type of data values, and can cast the data accordingly.
Improved productivity when writing ESQL. When you are creating ESQL programs for WebSphere Message Broker message flows, the ESQL editor can use message models to provide code completion assistance.
Drag-and-drop operations on message maps. When you are creating message maps for WebSphere Message Broker message flows, the Message Mapping editor uses the message model to populate its source and target views. Without message models, you cannot use the Message Mapping editor.
Reuse of message models, in whole or in part, by creating additional messages that are based on existing messages.
Generation of documentation.
Provision of version control and access control for message models by storing them in a central repository.

92.       What are the ways to create message models?
A:        You can create a message model by using the following methods:

Importing an application message format that is described by an XML Schema, XML DTD, C structure, COBOL structure, SCA import or export, or WSDL definition.
By creating an empty message model file, then creating your message by using the editors provided in the WebSphere Message Broker Toolkit.
By using the Adapter Connection wizard to import EIS metadata.
By creating a populated model file from example message data.


93.       What is the difference between mqsicreatemsgdefs or mqsicreatemsgdefsfromwsdl command-line utilities?
A:        The mqsicreatemsgdefs command has a bulk import capability, but mqsicreatemsgdefsfromwsdl imports only one WSDL definition at a time.

94.       What are message sets?
A:        A message set is a folder in a message set project that contains a logical grouping of your messages and the objects that comprise them (elements, types, groups).

95.       What is a message definition file?
A:        A message definition file contains the messages, elements, types, and groups which make up a message model within a message set. Every message set requires at least one message definition file to describe its messages. Message definition files use the XML Schema language to describe the logical format of one or more messages.


96.       What is a multipart message?
A:
A multipart message contains one or more other messages within its structure. The contained message is sometimes referred to as an embedded message. A multipart message must contain a group, or a complex type, with its Composition property set to Message.


97.       What is Triggering in MQ?
A:        A message is put to a queue defined as Triggering.


98.       What does a PROPAGATE keyword do?
A:        The PROPAGATE statement is used to generate multiple output messages in the Compute node. The output messages may have same or different message content. You can also send output messages to any alternate output terminals of the Compute node.


99.      Why do we use Sequence node?
A:        The Sequence node enables you to receive groups of messages from an input source, and preserve the order in which the messages in each group arrived.

100.      Which command is used to modify broker parameters?
A:        mqsichangebroker command is used to modify broker parameters.

101.      What is the purpose of using mqsichangeproperties command?
A:        mqsichangeproperties command can be used to change properties associated with a broker such as:

that affect the whole broker; for example, an HTTP listener or Service Federation Management
that affect one or more execution groups; for example, the broker registry
that affect a configurable service; for example, a JMS provider.

102. What do you mean by ResetContentDescriptor node?
A:        ResetContentDescriptor node request to parse the message with different parser, leaving the message content unchanged.


103.      What is the difference between an MQGet node nd MQInput node?
A:        The MQGet node reads a message from a specified queue, and establishes the processing environment for the message. Whereas, The MQInput node receives a message from a WebSphere MQ message queue that is defined on the queue manager of the broker.

You can use an MQGet node anywhere in a message flow, unlike an MQInput node, which you can use only as the first node in a message flow.


104.       What is the difference between SOAPRequest node and SOAPAsyncRequest node?
A:        The SOAPAsyncRequest node sends a Web service request, but the node does not wait for the associated Web service response to be received. This asynchronous functionality enables multiple outbound requests to be made almost in parallel because the outbound request is not blocked waiting for the response.

Whereas, The SOAPRequest node is a synchronous request and response node, which blocks processing after sending the request until the response is received.


105.        What is the difference between Mapping node and Compute node transformation?
A:        In Compute node you can transform the message by coding ESQL in the ESQL resource file attached. Whereas, In mapping node you can use graphical maps to transform input message by associating an input message model such as a DFDL or XML schema, or an MRM Message Set and an output message model.

In compute node you can change the entire message even the header assemblies. But, In mapping node you can change the message assembly, message body, and properties.


106.       What is the difference between Input and MQInput node?
A:        Use the Input node as an In terminal for an embedded message flow (a subflow).The MQInput node receives a message from a WebSphere MQ message queue that is defined on the queue manager of the broker. It is the first node of your message flow.


107.       What is the purpose or use of compute node?
A:        The Compute node is used to:

Build a new message using a set of assignment statements
Copy messages between parsers
Convert messages from one code set to another
Transform messages from one format to another


108.        How the interaction with Database does take place using Compute node?
A:        In Data Source specify the name by which the appropriate database is known on the system on which this message flow is to execute.


109.     Difference between try catch node and throw node?
A:        Include a Throw node to force an error path through the message flow if the content of the message contains unexpected data.

If a downstream node (which can be a Throw node) throws an exception, the TryCatch node catches it and routes the original message to its Catch terminal. Connect the Catch terminal to further nodes to provide error processing for the message after an exception.

110.        How will input messages with different – different delimiters between the fields are handled in WMB?
A:        Using MRM domain we can input messages with different – different delimiters between the fields in WMB.


111.       What do you mean by depth of a Queue?
A:        Queue depth, is the number of pending input/output messages in a queue.


112.       How can we know the current depth of a queue?
A:        Using MQSC property CURDEPTH we can know the current depth of a queue.


113.       Message Broker supports what all formats?
A:        Message Broker supports XML, TDS, CSV, CWF, EDIFACT, SWIFT, COBOL formats

114.        What all nodes uses ESQL?
A:        ESQL can be used with the Compute, Database, and Filter nodes.


115.       What is ESQL?
A:        Extended Structured Query Language (ESQL) is a programming language based on Structured Query Language (SQL), which is commonly used with relational databases such as DB2. ESQL extends the constructs of the SQL language to provide support for you to work with both message and database content.

116.        What functionality ESQL provides?
A:        Through ESQL you can

Change the message content.
Modify an existing message
Create a new message
Add dynamic terminals
Route a message
Propagate a new request


117.       What are the types of variables in ESQL?
A:        ESQL variables can be described as external variables, normal variables, or shared variables.


118.       What are external variables, normal variables, or shared variables?
A:                 External variables:
Also known as user defined properties.
Exist for entire life time of a message flow and are visible to all messages passed through the flow.
Defined at module or schema level.
You have to assign an initial value at the time of declaring an external variable and then can modify the initial value at deployment time by using the BAR editor.

Normal Variables:
Have lifetime of just one message pass through a node.
Visible to that message only in which it was defined.
To define, omit both EXTERNAL and SHARED keyword.

Shared variable:
Used to implement in-memory cache in the message flow.
Have a long life time and are visible to multiple messages pass through the flow.
Exist for the lifetime of Execution group, lifetime of flow or node, lifetime of node’s ESQL that declares the variable.
Initialized when the first message pass through the node or flow after broker startup.


119.       What are patterns?
A:        A pattern captures a tested solution to a commonly recurring problem, addressing the objectives that you want to achieve.


120.       What are the benefits of using patterns?
A:        Patterns provide the following benefits:

Give you guidance for the implementation of solutions
Increase development efficiency, because resources are generated from a set of predefined templates
Result in higher quality solutions, through reuse of assets and common implementation of programming approaches, such as error handling and logging

121.        How do you ensure that messages do not lose?
A:        For application and internal messages traveling across WebSphere MQ, two techniques protect against message loss:

Message persistence – If a message is persistent, WebSphere MQ ensures that it is not lost when a failure occurs, by copying it to disk.
Sync point control – An application can request that a message is processed in a synchronized unit-of-work .


122.        How to use functions in your esql code?
A:        Use CALL keyword to call functions or methods.


123.       What are the ways in which you can access databases from a message flow?
A:        You can access a database from a message flow in two ways:

You can design a message flow that responds to events generated by the database.
After a flow has already started, you can access the database to read or update information in it. Information from the database can be used to enhance or influence the operation of the message flow.

Distributed Computing: A Guide to Comparing Data Between Hive Tables Using Spark

In big data, efficient data comparison is essential for ensuring data integrity and validating data migrations. Apache Spark, with its in-me...