HowTo: Create Data using BPM TaskManager

Quite a lot of our Partners are using BPM Software to automate tasks in the background. Not surprising, because the BPM Server and TaskManager can access the same databases (Microsoft SQL Server and Gupta SQLBase) on a local Instance. If you are not familiar yet with BPM Server and TaskManager, check out their website here: www.bpmsoftware.nl.

Use Webservices for data validation

Now of course you can do all kinds of actions directly in the databases. But that might cause inconsistencies. Fortunately, BPM also offers the possibilities to read and write data using xmlHTTP webservices. More fortunately, each BusinessController you configure for your Essence Portal, automatically exposes itself as a read/write webservice! 

So, basically you have everything in place for a smooth integration. In this post we will show you how to create data using BPM Server and TaskManager.

What your message should look like

To see what the in- or outgoing messages should look like, you can use the test tool as documented on our TrainingCenter. With the Test Tool you can generate the messages, without having extensive knowledge of XML. When you are in the Full, Quick or Menu Editor, you can bring up the ToolBox Navigator using the key combination Alt+T. From the bottom right of the ToolBox Navigator, select the TestTools.

If you want to dive in deeper, you can find the documented scheme in the XML directory of you Essence installation. Just look for the SilverBusinessController.xsd file, which you can explore using a tool like Altova XMLSpy.

Put your credentials in Memory fields

Well, actually this isn't a mandatory step. But it is good practice. One this makes changing your credentials much easier because the are all in one place. Second, you don't expose your credentials in every task. Third, it makes it easier to copy tasks from one BPM server to another. So, having said that this isn't mandatory, here is what you must do. Add Memory Fields for the ConsumerUser, Password, SolutionName and ImpersonateUserName. Or the ConsumerKey (check this post) if you prefer that over the Password.

Post your message from BPM Server

Now in BPM Server, create a new Task. From the available Actions, drag and drop the Web Request: Post onto your Task. You can find that Action under the Internet Actions. Here's what the Post action should look like.

  • URL
    This is the URL as you shown in the Test Tool. Do not forget the /Operate at the end. To check if the Service is up and running, you can use the URL without the /Operate, but to perform a Post action, it is required.
  • Content-type
    This should be application/xml
  • Encoding
    This should be UTF-8

The Message Request goes in the Message field. If you constructed the Message using the Test Tool, this is the time you should remove the credentials and replace them with the Memory Fields. Optionally you can save the Response Message in a Memory Field as well. That way, you can check the results, or log the errors in a next step.