It’s There the BizTalk No Output Producing Endpoint Adapter !!!!

April 29, 2005 / Comments Off on It’s There the BizTalk No Output Producing Endpoint Adapter !!!!

The Problem


Sometimes when you use messaging in BizTalk you want to publish messages in the messagebox. And only if some conditions are met, BizTalk should react to those messages and send it somewhere if those conditions are not met BizTalk should discard the message.


Unfortunately this is not how BizTalk works, BizTalk needs a subscriber to a message. Since there is no subscriber for the unwanted messages we end up with messages in the EventLog.


The Workaraound


Well for sure you could use an orchestration and do some business logic to decide what to do. Unfortunately you will need an orchestration for that. And we started out that we only wanted to use messaging…..so this is not an option….


Another workaround would be to write to a fixed filename. So we overwrite the same file over and over again…. But then what happens if there are two messages beeing send at the same time ?? We probably would get a suspended message in the HAT and an Entry in the eventlog. So this is not an option either…..


The Solution


This is where the BizTalk NOPE Adapter comes in. (No Output Producing EndPoint


Just set the Filter Expression to the receiveport where the messages come from and this adapter will eat every message coming from a specific receiveport.


If you want to react to specific messages having specific properties you can still use that but the messages that you’re not interested in will dissappear without a trace…..


 


This adapter is available on GotDotNet, click here to get it

Never reinstall a BizTalk adapter to a different location

April 25, 2005 / Comments Off on Never reinstall a BizTalk adapter to a different location

Last week I had some problems with a specific BizTalk adapter. I Installed an adapter, then I uninstalled the adapter. And I Reinstalled it to a different location.
From that moment on I had problems with the specific adapter.


It seems that when you uninstall an adapter (but not remove it from the registered adapters) and reinstall it again, the physical location on disk is remembered in the the BizTalkMGMTdb.

The content of the field inboundassemblypath in the table adm_adapter was C:Program FilesLogicaCMGEventlog Adapter InstallerEVTReceiveAdapter.dll


I am not really sure what this means but I think  you should Install adapters always in the same directory on every BizTalk machine. The funny thing here is that all of the “out of the box” adapters don’t have this field. I guess that when you have multiple BizTalk Servers running on one messagebox, all the custom adapters should have the same directroy.


I just thought let’s share this with the community cause it caused me some problems….

BizTalk WMI EventLog Adapter

April 12, 2005 / Comments Off on BizTalk WMI EventLog Adapter

An adapter that will read eventlogs. It is possible to read eventlogs on remote machines with different identities. The adapter uses WMI to query the remote machines.


Although there was already an EventLog adapter on the gotdotnet community I was not completely satisfied with the results. If BizTalk was restarted some entries would be read over and over again. Furthermore you had to create a receive location for every log. ( and it was written in C# ) Now you can create a receive location per machine.


This adapter also shows some nice annotations in the receivelocation.xsd. Click here if you want to know more about how to annotate a send or receive schema.


Go get it here

Why Mygeneration Beats the Competition when it comes to codegeneration

April 12, 2005 / Comments Off on Why Mygeneration Beats the Competition when it comes to codegeneration

The main reason why MyGeneration is an excellent tool (Besides support of the dOOdad architecture) is the ability to add several templates to a project. Below is an example of this.

In this project there are four templates needed. Adding a template is very easy. Jus right click on the Rootnode and add a template instance. You can also just execute the selected template so all code within that template is generated.

Then when the template is added you can set the properties for that template.

First you select an output directory, this is where the generated code will be saved. Then you select a database and the tables you need in your project. In this case I needed all tables (that’s why they are blue). Then you save the project. This input is saved as well so you can generate over and over again without any problems. If a table is added, just select that table as wel in the parameters.

Now all that you need is to select the rootnode and hit the green play button on the project explorer. You should get a screen like the one below.

The only thing left to do is add the resulting code to your project and you are done !. I always generate the code directly into my Visual Studio Project directories. So you get a popup from Visual Studio things have changed, hit the OK button and compile.

Now whenever there is a schema change in the database, just implement the change, hit the generate button and be done with those changes.

Using WMI to query the Eventlog

April 8, 2005 / Comments Off on Using WMI to query the Eventlog

After some testing on various ways to query the eventlog I found that a WMI query is the easiest way to query the Eventlog of any (remote) machine. There is very little information about WMI on the internet so I thought it was nice to post this sample snippet. (If you see anything that should be improved please reply on this post)


Public Function QueryLog(ByVal ServerName As String, ByVal LogNames As String, Optional ByVal UserName As String = “”, Optional ByVal PassWord As String = “”) As Collection


‘Set up the new collection
QueryLog = New Collection


‘Set the WMI scope options
Dim oWMI_Scope As New ManagementScope
oWMI_Scope.Path.Server = ServerName
oWMI_Scope.Path.Path = “\” & ServerName & “rootCIMV2”
oWMI_Scope.Path.NamespacePath = “rootCIMV2”


‘ Use the username and passowrd if they are supplied
If UserName = String.Empty And PassWord = String.Empty Then
   oWMI_Scope.Options.Username = UserName
   oWMI_Scope.Options.Password = PassWord
End If


‘ Set impersonation level
oWMI_Scope.Options.Authentication = AuthenticationLevel.Default
oWMI_Scope.Options.Impersonation = ImpersonationLevel.Impersonate
oWMI_Scope.Options.EnablePrivileges =
True


‘Define the WMI query
Dim oWMI_Query As New ObjectQuery


oWMI_Query.QueryString = “SELECT * FROM Win32_NTLogEvent WHERE ” + GetLogNames(LogNames) + ” AND TimeGenerated > ‘” + LastEventTime + “‘”


‘Create the WMI search engine
Dim oWMI_Results As New ManagementObjectSearcher(oWMI_Scope, oWMI_Query)


‘ Iterate through the resulting collection
Dim oWMI_Object As Object
For Each oWMI_Object In oWMI_Results.Get()
  
‘ Get the Individual EventLog entries
  
Dim MyEventClass As New EventLogEntry(oWMI_Object)
  
‘ Add the Eventlogentry to the collection
  
QueryLog.Add(MyEventClass.ToXML)
  
‘ Check if the Time of the generated event is greater
  
‘ then the last time we executed the query if so update that time
  
If MyEventClass.TimeGenerated > LastEventTime Then
     
LastEventTime = MyEventClass.TimeGenerated
  
End If
   ‘Clean up
  
MyEventClass = Nothing
Next oWMI_Object


‘ Clean up
oWMI_Object = Nothing
oWMI_Scope = Nothing
oWMI_Query = Nothing
oWMI_Results = Nothing


End Function


 


 

A very nice EventLog BizTalk Adapter

April 6, 2005 / Comments Off on A very nice EventLog BizTalk Adapter

Hello all you BizTalkers out there….

Just wanted to let you know there is a EventLog Biztalk adapter out there that works very good. It is available on GotDotNet and you can download it by following this link


This is a receive adapter that monitors local or remote Windows event logs and publishes new events, using a provided schema, to the BizTalk environment. This adapter has been used in combination with the Microsoft EMAB to consolidate application events and exceptions with external events that are written to the Windows event Log.

Can’t we kill those very irritating Spammers….

Right,


I am getting a lot of replies on my articles lately, unfortunately it is all spam….Running as SQL job removing all spam will not be that hard (maybe it’s running already).


The spam is redirecting us to several gambling sites…


Is there nothing we can do against those sites…. Like flood them with bogus requests so those sites will be so busy they can’t conduct business anymore…….. (Like generate random loginnames and passwords to flood their databases etc.)


A kind of SETI against spammers ! And then not against the people who spam but the people they spam for…


 


 

  • Recent Posts
  • Recent Comments
  • Archives
  • Categories
  • Meta