Tuesday, 6 September 2011

BizTalk Interview Question & Answers




1. What is BizTalk?
         Biztalk is a messaging based integration tool.
         Bonus: It consists of several different pieces including Business Processes (Orchestrations), BAM, Rules Engines, and HAT.
2. In BizTalk 2002, schemas were DTD based and allowed Xml Elements to be in any order inside a record using the <Any> keyword.  How is this different in BizTalk 2004?
         BizTalk 2004 is XSD based.
         BizTalk 2004 Elements default to <Sequence> and <Any> is no longer available.
3. What is a Message Type (i.e. BTS.MessageType) and how is it used in BizTalk?
         Message Type is a BizTalk System property that is promoted inside a Pipeline.  It is made up of Document Name Space # Root Node Name.
4. How do you call a Non-Serializable .Net helper class inside an Expression Shape?
         Add a reference to that class.
         Make sure your Orchestration is Long Running transactional.
         Add an Atomic scope.
         Create an Orchestration variable of that class inside the scope.
         Create an instance on that object inside the scope.
         Call the method.
         Bonus: Mention the class must be strongly signed and in the GAC.
5. What if the class is Serializable?
         No transactional Orchestration or Atomic scope is needed.
6. What does the Value Mapping Functoid do?
         Returns the second parameter if the first parameter is true
7.How do you use Auto Mapping in the BizTalk 2004 mapper?
         Select a top level node, hold down the Shift key, drag the top level node over to the other top level node.
8. What is the default mapping for Auto Mapping?
         The default is by structure.  This can be change to by node name on the map properties. (This default in the auto map messes me up every time.)
9. Step-by-step, how do you set up a basic, pure messaging solution taking in a flat file and send an Xml File out to 5 different places?
         Create a Flat File schema
         Create a Custom Pipeline using the Flat File Disassembler
         Create a Receive Port
         Create 5 Send Ports
         Create a Send Port Group
         Add each Send Port to the Send Port Group
         Create a Filer on the Send Port Group using Bts.ReceivePortName (or something close to this)
         Additional: no map is required but it is ok to mention it
Design (Architecture) Focused Questions
10. What is the difference between a Distinguished field and a Promoted Property?
         Distinguished fields are light weight and can only be used inside an Orchestration.
         Promoted Properties are defined inside a property schema, are tracking in SQL, can be tracked in HAT, and can be used for content based routing.
11. How do you achieve First-In-First-Out message processing of messages received from multiple sources using an Orchestration?
         Use a Sequential Convoy to process the messages in the order they are received into the Message Box. 
         Make sure Ordered Delivery is set to True inside the Orchestration Receive Port.
12. At high level, what do Receive Ports and Orchestration Send Port really do in terms of messaging?  What about Send Ports and Orchestration Receive Ports?
         Receive Ports and Orchestration Send Port are both publishers.
        Send Ports and Orchestration Receive Ports are both subscribers.
13. When working with Schemas, Maps, Pipelines, and Orchestrations how should the projects be structured?
         Schemas and Maps in its own project
         Or Schemas and Maps together in its own project
         Orchestrations in its own project
         Pipelines in it own project
14. What is direct binding?
         Direct binding has three types: direct to message box, self correlating, and partner ports.
         Used to route message between the message box and Orchestrations without using bindings or from one Orchestration to another Orchestration.
15. What is BAM used for?
         BAM is used to monitor business milestones and key metrics in near real-time throughout a process in BizTalk.
16. What is the Rules Engine?
         Rules are used to provide highly efficient, easily changeable business rules evaluation to Business Processes.  This allows rules to be changed without rebuilding and redeploying .net assemblies.  The Business Rules Engine (BRE) can also be called from any .net component through the API’s.
17. What are Persistence Points and what causes them?
         Persistence is when the state of a running Orchestration is stored into SQL.
         It is good enough to know various shape and actions cause persistence.  More specifically, it occurs: end of a transactional scope, at a send shape, at a start Orchestration shape, during dehydration, if the system shuts down expectedly or unexpectedly, or the business process suspends or ends.
18. What group does a user need to belong to in order to submit messages to the message box? 
         The user needs to be a member of the host group or isolated host group (assuming a default installation).
19. What user rights to you need to perform most actions in HAT?
         BizTalk Server Administrator
20. When installing Biztalk in a multi-server configuration with a remote SQL and Analysis Services, what SQL components do you need on the Biztalk Server?
         SQL Analysis Services Client Tools
21. When installing Biztalk and SQL on a Windows XP SP2 Desktop, what pre-requests are required?
         Correct answer: A Lot.  The best answer something like I have a custom written installation document I use or I always referrer to the most current updated installation guide from Microsoft. 
General
22. Does BizTalk 2004/2006 support Synchronous communication?
BizTalk is essentially Asynchronous. It can exhibit some synchronous behavior, if an Orchestration is converted into a web service.
23.   numerate the new functoids added BizTalk 2006?
Please refer to this article New functoids in BizTalk 2006
Schemas
24.   Can a flat file message be processing without a pipeline?
A Pipeline's job is to convert any external format into XML, be it a flat file or EDI or anything else.
25.   Can multiple messages be processed or batched without an envelope schema?
It is possible to process multiple messages, without an envelope.
26.   What is property promotion, why is it required?
When a property is Promoted, it is exposed to the orchestration/send port filters etc.
27.   In which scenarios would use a "promoted property" vs "distinguished fields"?
The rule here is, if you don’t want the schema element to appear in send port filters/debugging information then make it a distinguished field.
28.   In Biztalk, what does a message type consist of?
A message type consists of the TargetNamespace#RootElement name.
29.   What are un-typed messages, how does one create them?
A message created in BizTalk Orchestration is bound to a schema, this is a typed message. In un-typed messages, the message is bound to System.Xml.XmlDocument instead of a schema.
30.   What is the difference between static, dynamic and direct binding?
31.   How does one enable subscriptions in BizTalk?
A filter on the Send Port is          the first step to enable subscriptions in BizTalk.
Orchestrations
32.   How do you prevent occuring of zombies in a Parallel Convoy?
Refer to the article known as "Convoy Deep Drive" on MSDN
33.   What is the difference between a delay shape vs a listen shape?
A 'Delay' is very much similar to a sleep on the current thread. A 'Listen' shape is used to wait for an incoming resource, with a timeout period.
34.   When you use Call Orchestration shape vs Start Orchestration shape?
A Call Orchestration returns the control back to the caller. A Start Ochestration shape starts the orchestration in a non-deterministic way.
35.   What is the difference between a "Message Assignment" shape and an "Expression" shape?
A "Message Assignment" shape is used to create a new message and assign values to it. A Expression shape is used to assign values to variables and also write 'if' conditions.
36.   Does BizTalk Orchestrations support recursion?
An Orchestration does NOT support recursion.
37.   What is the purpose of the property "Activate" in a Receive shape?
It is used to invoke a new instance of an Orchestration.
38.   Can an orchestration Start without an Activatable receive?
A Nested Orchestration can be started without an Activatable receive
39.   Is it necessary for all .NET components being called from an Orchestration be Serializable?
Yes it is necessary. There are cases where a .NET component need not be Serializable.
40.   When do we need set the property "Synchronized" = true for a scope?
This needs to be set, when a variable is shared across the branches of a parallel shape.
41.   What is the difference between an Exception block and a Compensation block? Is it the equivalent of try-catch-finally?
42.   Is it possible to have a exception block for an Atomic scope? if not why?
43.   How does one enable Correlations in BizTalk?
First create a Correlation type and then create an instance of it.
44.   Is it possible to share variables across two branches in a Parallel shape?
45.   Does BizTalk automatically compensate a unsuccessful transaction?
46.   What is the main difference between a Long-Running transaction and an Atomic Transaction in BizTalk context?
Architecture and Design
47.   In an Orchestration design, Orchestration "A" calls another Orchestration "B", and vice versa. Is it possible to implement this design?
It is NOT possible, since it forms a cyclic dependency.
48.   List out the three important things to consider while designing a BizTalk orchestration!
The Incoming data format, The Business process and The Outgoing data format.
49.   Enumerate the steps required to deploy an BizTalk solution from one machine to another machine.
50.  What are the types of transaction in Biztalk?
A. Atomic Transaction and Long-Running Transaction

1. Orchestrations
2. Role Links
3. Send Ports and Send Port Groups
4. Receive Ports
5. Receive Locations
6. Policies
7. Schemas
8. Maps
9. Pipelines
10. Resources
11. BAS Artifacts (Business Activity Services)

52. Q. What is Correlation? Why do we need it?
A. An Orchestration can have more than one instance running simultaneously. Even though each of those multiple instances perform the same action, it does it on different data contained within a message.
Correlation is a process of associating an incoming message with the appropriate instance of an orchestration.
For Example: If your orchestration issues a purchase order, receives an invoice, and sends a payment, the developer must make certain that the invoice message is received by the orchestration instance which corresponds to the orchestration that sent the Purchase Order. Without correlation, it would be possible to send out an invoice for thousands of items even though the purchase order is for one. And each correlation is based on a set of properties known as correlation types.

Dehydration:
When an orchestration has been idle for a while, the orchestration engine will save the state information of the instance and free up memory resources.
Rehydration:
When a message is received, or else when a timeout has expired, the orchestration engine can be automatically triggered to rehydrate the instance – it is at this point that the orchestration engine loads the saved instance of the orchestration into memory, restores the state, and runs it’s from the point it left off
Q 17 What is property promotion, why is it required?
A. Biztalk provides you with a really smart routing feature that allows the engine to decide where to send which message. For example, If you receive a message with the EmployeePaySlip schema, and it has the approved flag to true, it should be redirected to the Finance system Orchestration for making the payments and to the HR system Orchestration for keeping the records. This built in intelligence for the Biztalk engine allows it to route the messages simply based on some content within the messages.
In order to achieve this, the Biztalk engine obviously needs to understand the fields based on which the routing decisions can be taken. To simplify and optimize this working, Biztalk has introduced the notion of "promoted properties". The Biztalk engine can get easy access to the promoted properties without knowing the entire message and hence it can save loads of time and complexity when dealing with routing. To route a message, the Biztalk engine simply reads its promoted properties and does not care about other contents in the message
Q. What is the default mapping for Auto Mapping?
A. The default is Structure

56. Mapping - its just used to transfer values from one XSD to other XSD.
 
Orchestration - Work flow of processes.
 
Schema - Schema(Sample) of the XML files which will be used for processing messages.
 
Adapter.Pipeline - Gateway to receive and send messages.
 
BRE -(Bussiness Rule Engine)Used to Externally configure the values.
 
HAT - (Health and Activity tracking) Used to trace the message.
 
BAM - (Bussiness activity monitoring) Used to generate and Moniter Report's
 
 
When A message is passed through biztalk without being 
processed then it is called Message Routing.
 
When A message is passed based on certain field value of 
schema, it is called content routing.
 
Message Routing:
 When a message is routed by BizTalk based on message Type.
 
Content Routing:
  When a message is routed by BizTalk based on some 
specific values in the message elements.
 
 
57. What are Host and Host Instance? Did you deploy BizTalk 
more than one machine?
 
Host is nothing but the logical container of host instance.
from which we can create host instance
 
A BizTalk Server Host is a logical set of zero or more 
BizTalk Server run-time processes in which you deploy items 
such as adapter handlers, receive locations (including 
pipelines), and orchestrations.
 
A host instance is the process where the message 
processing, receiving, and transmitting occurs You install 
a host instance on each server running BizTalk Server 2006 
that has one or more hosts mapped to that server
Yes we can deploy Biztalk on more than one machine.
                                             
58. How to transfer files without using Orchestration?
Use content Base routing
create receive port and Send Port.
while configuring send port provide filter condition as
BTS.Receiveportname=<receive_portname you created>
yes, with out using orchestration, we can get the message  
it is done in the case of messaging solution.
Messaging solution means it is the biztalk solution with 
out orchestration.
go to biztalk adminstration console and create the receive 
port and create the send port .
in the send port configuration wizard, in the left 
pane,there is tab called filters which is used to provide 
subscription infornation to biztalk msg box, that tells the 
msgbox,"if any information comes on a particular port, 
please send that information to me
there is a filter property is there 
 
bts.receiveportname="ReceivePortName"
 
so when ever the msg is dropped to receive location 
configured with receive port, it comes to biztalk msgbox 
db, msgbox db sends the message to send port based on 
subscription information
 
This is how the message transformation is done without 
using orchesrtation

59. How and why you have to use Active Directory in BizTalk 
development?
its all depends on sort of deployment, in case of single 
box hosting sql and biztalk services then absolutely no 
need of active directory which is mostly happens in 
development environments, but AD importance coming in to 
the picture in enterprise deployments where you have 
biztalk group , sql on separate boxes, more important when 
you want to have cluster for high availability and 
performance scalability. Because the service user accounts 
and service group credentials are used across the network 
and group of computers and which is maintained in common 
repository called AD on windows platform.
 
Active Directory is considered as default directory for Deployment of Application.

60. How to create dynamic ports?
create one port, port type as dynamic.
Drag one expression shape in orchastration.
in that type, Portname(Microsoft.XLANGS.BaseTypes.Addresses)
= Address url.

BIZTALK SERVER dynamic ports .
Create a port and give the port information by using 
expression.It works when the orchestrtion runs being 
dynamic in nature.
Drag a expression shape from the tool bar write code for 
configuration.

The dynamic port property is available only while creating 
a send port. The simplest way to create a dynamic send port 
by is by selecting the "New configured port" option in the 
orchestration designer port window. 
     Select the send port binding property as "Dynamic in 
the configuration wizard. You can also specify the pipeline 
to be used in the port. The Dynamic send port will be 
created as well as a physical port will be automatically 
created once you deploy the application. Bind the 
orchestration logical port and physical send port
 
Create an expresion shape and set the address where the 
files are to be submitted example : 
Microsoft.XLANGs.BaseTypes.Address="FILE://C:\\OUTPUT_FILES\
INVOICE.txt";
 
You can also promote a schema element and assign its value 
in a variable and pass it as address information so that 
the file location can be selected at run time depending on 
the values in the element.


61. What if the class is Serializable?
No transactional Orchestration or Atomic scope is needed.
62. What is the difference between a Document Schema and a Property Schema?A document schema is like any regular schema, whereas a Property schema consists of only child elements under a root node.




1 comment: