Posts

BizMock using it for orchestration unit testing

Image
BizMock is a tool that allows for testing BizTalk artifacts without having to deploy artifacts. This is done by a private BizMock adapter that receives the messages. BizMock generates a class based on an XML configuration file where the mapping to schemas, sample files, maps, orchestrations, mapping from logical to (virtual) physical ports are defined (all in your head ). Advantages : The generated code to perform the test is simple, powerful and compact. Disadvantages : It uses T4 templates; errors in the XML file are very difficult to debug and resolve. There is little documentation available and sample code does not show all possibilities. Note: According to the developer a DSL tool is on the way providing an easy mechanism to manufacture the Xml file! In the segments below are some code snippets that shows the usage of BizMock; Application The figure below is a sample project with two schemas, a map and an orchestration. The sample orchestration receives a me...

Command shell – shortcuts

I’ve visited the Daydays and there was mentioned that Scott Hanselman was superior in his knowledge of tools and shortcuts. I was particularly interested in the shortcuts he used in the command shell…. Finally today I decided to look it up and found 2 I will regularly use; ALT+SPACE+E+K <-- for copy . and ALT+SPACE+E+P <-- for paste.   Hth, Sander

MSMQ Dynamics Sendport – TimeToReachQueue not Infinite

Image
When using a Dynamics MSMQ SendPort, be aware to set the TimeToReachQueue to a higher value then 0! I had created an Itinerary and could not see any messages…It turns out that the TimeToReachQueue interval is somehow ignored when using Dynamic MSMQ send ports. If the interval specified by the TimeToReachQueue property expires before the message reaches its destination, Message Queuing discards the message in one of two ways. If the message's UseDeadLetterQueue property is true, the message is sent to the dead-letter queue. If UseDeadLetterQueue is false, the message is ignored. In my case the solution was to set the interval to a higher value than 0, otherwise the message has to be submitted to the queue very quickly! (I noticed this only during bulk/stress-testing so I might slip you attention!) http://msdn.microsoft.com/en- us/library/system.messaging.message.timetoreachqueue.aspx http://www.44342.com/BizTalk-f20-t14495-p1.htm Cheers, Sander   Tags van Technorat...

Configuring ESB Portal resubmit

When setting up the ESB Portal we didn’t see the receive ports. After some digging around it seems that the content type is not correctly set resulting in not showing up the available receive locations. A minor change in the SP solves this problem… Modify the Stored Procedure: EsbExceptionDb. usp_insert_Message   IF (@ContentType = 'text/plain' AND LEFT (@MessageData,1) = '<' ) BEGIN SET @ContentType = 'text/xml' END   See the very useful post on the BizTalk forum   HTH, Sander Nefs

MSMQ with ‘Authenticate’ enabled for communicating with Dynamics AX

Image
Hereby my findings on how to communicate with a remote MSMQ with the ‘Authenticate’ property set (required for Dynamics AX MSMQ inbound Channels). There are 2 ways how MSMQ (4+) works, either in workgroup mode (when you only install MSMQ) or in active directory mode (when you choose 'Directory Integration'). The Logon Info only works when you work in workgroup mode. When you set the 'Authenticate' flag on the Queue the Logon Info is useless...implicitly you are using personal user certificates that are installed when you logon to the machine. So my issue was resolved once i got it working with the certificates, although i would expect that the Logon Info should work hereby my resolution: - Logon to the client machine where the Send port is defined using the Host instance account - Open Features\MSMQ\Properties - Go to the tab 'User Security' - Click on 'Register' to Register the public part of the certificate in the active directory (...

BizTalk ESB Dynamic port – 3 filter properties

Image
This is a quick post for you (and me!) to remember….whenever you want to use the ESB Toolkit and are wondering which filters you need to set to be able to get the send port to send a message…. SET THESE 3 FILTERS: Microsoft.Practices.ESB.Itinerary.Schemas.ServiceName Make sure that the name of this filter matches the Dynamic Send port that you have chosen in you itinerary!! Microsoft.Practices.ESB.Itinerary.Schemas.ServiceState To ensure that the process continues and that the itinerary is continued…set the state to ‘Pending’. The Toolkit will worry on the actual states. Microsoft.Practices.ESB.Itinerary.Schemas.ServiceType Depending on the scenario you can set the ‘ServiceType’ to ‘Messaging’ for a messaging based subscriber or to ‘Orchestration’ for an Orchestration based subscriber. Note: the IsRequestResponse property might be useful for solicit response port.   HTH, Sander   Tags van Technorati: BizTalk , ESB , ESB Toolkit

ESB Portal – powershell error on 64-bit machine

Image
Yesterday I was having an issue when trying to install the ESB management portal. Although I opened the gates security wise I still got PowerShell errors… I could not figure out what the problem was….then my colleague Tomasso Groenendijk asked….”is it a 64-bit machine? Good luck with that!” It was so simple, kuch, (if you would think of it)….configure this for 32-bit AND 64-bit. a) Start PowerShell 32-bit Right click and choose ‘Run as Administrator’) Execute the following command: Set-ExecutionPolicy RemoteSigned a) Start PowerShell 64-bit Right click and choose ‘Run as Administrator’) Execute the following command: Set-ExecutionPolicy RemoteSigned   Hope this helps someone….   Sander Tags van Technorati: BizTalk , BizTalk ESB , PowerShell

.Net 4.0 is cool

Since I wasn’t doing a lot of .Net development and when I did it was for developing pipeline components, mapper helpers or other stuff the whole .Net language improvements didn’t got my attention. Since I’m doing some adjustments to the BizUnit steps to enable BizTalk testing I was able to use some new .Net features. I’m probably to last to join the club, but from now on my code has this style; // create new entity and assign the instance variable Name the value ‘TestOrch’ var inputTestCase = new TestCase() { Name = "TestOrch" };  

BizTalk 360 – sharing my experience

Image
Tags van Technorati: BizTalk , BizTalk 360 , BTS Today i was notified about an excellent tool to view the stuff you can see in the administration console in a web based silverlight / pimped GUI. Here some quick notes on my first experience as well as some pros- and cons. Installation As described on the documentation you have to perform some steps to get it working. BizTalk 360 is an IIS web application that is installed when you run the setup, additionally it will install a windows service that will monitor your environment. 1) Register and run the setup 2) Configure security a) Application pool user should be a member of BizTalk Server Administrators / IIS_IUSRS / SSO Administrators b) Is mixed authentication is disabled make sure you change the web.config to use integrated security c) Add some grants on the db (suggestion, only do this when you run into problems) GRANT SELECT ON dbo.adm_OtherDatabases TO BTS_ADMIN_USERS GRANT SELECT ON dbo.adm_Server2...

ESB Toolkit 2.1 No itinerary designer

Image
Tags van Technorati: BizTalk , ESB , ESB Toolkit , ESB 2.1 , ESB Toolkit 2.1 , BizTalk ESB The itinerary design seems to be only installed for the user that was fortunate the install the ESB Toolkit. Symptom – when you open an itinerary you do not see the itinerary DSL but only the Xml (might be good news for the old school notepad coding guys) but having that experience always makes me back shiver. When you go to tools / Extension manager You will not see the ESB Itinerary design What’s wrong – The VS.Net extensions are installed in the folder of the user, somehow the ESB Toolkit installer does not install the extension for all users (you can verify this by looking for the EsbExtensions in the following folder: <DRIVE>\Users\<USERNAME>\AppData\Local\Microsoft\VisualStudio\10.0\ Solution – Close VS.Net (all instances) and go to: ‘Start\Microsoft BizTalk Server 2010 ESB Toolkit\Install Itinerary designer extension’ Open VS and then the itiner...

DevDays – looking forward to day 2

Image
Due to my involvement in a project i will only attend the devdays on day 2. Since I’m doing BizTalk my interests are Azure, WCF, SQL, .Net and the goodies. I’ve figured out how my action packed schedule will look like, hoping to see some current/former colleagues then. 09:15 - 10:30 Speaker: Robert Hartskeerl Summary: SQL Server & Powershell 10:50 - 12:05 Speaker: Clemens Vasters Summary: Windows Azure AppFabric Service Bus: Messaging, Pub/Sub, and Connectivity in and through the Cloud Aaaah finally ….the well deserved break 13:15 - 14:30 Speaker: Vittorio Bertocci Summary: Windows Azure AppFabric Access Control Service: Deep Dive 14:50 - 16:05 Speaker: Christian Weyer Summary: Ubiquitous Communication with the Windows Azure Service Bus 16:15 - 17:30 Speaker: Vittorio Bertocci Summary: Developing SaaS Solutions with the Windows Azure Platform I hope it will be fun, hoping to be able to take some stuff and apply them directly on th...

Passed SQL 70-432

Image
An excuse to post something small, just passed the SQL Exam for database implementation and administration. Next time when I’m the BizTalk Guy and SQL Guy I’m at least certified

Tools – Automatically set the proxy

When you work at customer settings, setting the proxy can be a hassle, you either forget to do it, or forget to turn it off….After trying some codeproject tools that all seem to crash I found another one that works for me (W7 – 64bit): http://blogs.msdn.com/b/irenak/archive/2008/12/16/sysk-366-tool-to-automatically-set-internet-explorer-proxy.aspx This tool detects the environment and sets the proxy accordingly based on a xml config file. Not sure if you can set a password, but for basic usage this is great.   Cheers.

MSI Import error due to HostInstance casing

Just a thing I noticed, when you create a HostInstance and you import a host that slightly differs in casing form the bind host in the binding, you will get an error….thus someone forgot to due an ‘IgnoreCase’ comparison. I had used a tool to create hosts/host instances and made a typo in the casing…had no idea this would be a problem…well easy to solve!   Greetz.

BizTalk Debugging - Breakpoint for thousands instances….ooops

During training I always tell that when you set a breakpoint to an orchestration you have to be careful, since you have to remove the breakpoint on the class. If you would start 100000 orchestrations, you would have a nice job for the weekend when trying to remove all the breakpoints. I was wrong, there is an easier way: Open the ‘Debugger’ - Remove breakpoint on the class - Suspend all the instances in that are dehydrated due to a breakpoint - Resume all the orchestration instances   Voila! Tags van Technorati: BizTalk , BizTalk Debugger , BizTalk Debugging

BizTalk Map test framework

For testing BizTalk solutions the combination of BizUnit and the orchestration profiler are the way to go. Setting it up for a new project can be a hassle, although i appreciate it’s flexibility with the easy of adding custom BizUnit steps. I just came across a new framework that provides some usefull means of testing BizTalk artefacts, namely maps. As you might have noticed the support for testing in BizTalk 2009 / BizTalk 2010 is somewhat limited and it forces you to build your artefacts with additional code for mere testing only (the check ‘Enable Unit Test’ will generate a wrapper around the components such as the TestableMapBase in the example below)….the most you will get out of the standard map testing is a validate instance of your message: Microsoft.BizTalk.TestTools.Mapper.TestableMapBase mapTest = new MapTest.Input2Output(); mapTest.TestMap(     @"Input.xml",   Microsoft.BizTalk.TestTools.Schema.InputInstance...

BizTalk Unit testing – heads up

Image
BizTalk Unit testing was before the release of BizTalk 2009 not an integral part of the product. The community anticipated with awesome frameworks and tools: BizUnit Very stable framework that is a wrapper around NUnit that allows testing using BizUnit steps, complemented with additional steps ( BizUnitExtensions ) and incorperated in the ( BizTalk Software Factory ). This is the framework that suits all your needs by allowing custom BizUnit step development in .Net and uses an Xml based approach. Pipelinetesting framework Very stable framework developed by Tomas Restrepo, very nice and easy to understand. Orchestration profiler Profiler that allows for code coverage by querying the BizTalk database and generating reports on the orchestration shape coverage, allowing insight in the completeness of the test. Present day A new framework has been introduced, that is fitted for one purpose, testing maps using an approach of dynamically reading/manipulating Xml fields by XPath expressions t...

Dynamic SMTP Send Port - Unknown Error Description

The other day I was using the Dynamic SMTP port to send an email message after a technical error had occurred in BizTalk. I used a BRE Policy to configure the Email settings and had set the SMTP.EmailBodyText property. Although there are a lot of things that can go wrong I was convinced it was rooted in my BRE call and result. It took me several dreadful minutes before i stumbled on a post of a fellow BizTalk developer who had faced the same issue. It turns out that when you use the BodyText you MUST set the charset: EmailMessage(SMTP.EmailBodyTextCharset) = "UTF-8";   Cheers.

BizTalk 2010 exam review

Hi there, I just finished providing some feedback for the upcoming BizTalk 2010 exam and I hope the input was valuable. As I am preparing for the SQL Server 70-342 I hope the exam will be finalized early next year so that I can it to my list of exams to take. Cheers.

File Adapter quirks

Image
Since I try to have posts for all the adapters I have encountered it can be that this is a post that it not new for all the people already working with BizTalk for a long time. It just wanted to have it on my blog for the sake of completeness; The FILE adapters requires that the Host Instance account user has FULL Control on the folder it tries to read from. I was giving a course on security in BizTalk and explained the security modal of BizTalk (like BizTalk operator / BizTalk administrator) and the ability to run Host instances under minimal privileges accounts (BizTalk Application Users member) and had a hard time to explain why the file was not picked up when Read only rights were assigned. This answer is: because I said so   Regards.