Video Screencast Help
Symantec to Separate Into Two Focused, Industry-Leading Technology Companies. Learn more.

Workflow WebService Component Generator validation error - Remedy ARSystem HelpDesk Interface

Created: 26 Oct 2012 | 21 comments

I am trying to use the Workflow Web Service generator to interface with our Remedy Server. Attached is the WSDL file of the web service I want to consume.

I can create the component OK and it creates all 3 that are listed in the WSDL file OK.

The problem comes when I try to use the HelpDesk_Query_ServiceResponse method. Although only 1 input is required (Other than authentication) the component wont validate. It is failing on the field ‘Status_ReasonOutput’ and it appears that on generation of the web service component the system has got confused with a minOccurs=”0” and nillable=”true” data type. What is strange though is this data type exists in the HelpDesk_QueryList_ServiceResponse method and this validates perfectly , and also does not list the output map.

 

Attached is detailed document as I sent to support (who suggested I post here for extra help), also is the WSDL file, an example session from SoapUI showing the SOAP packet to and from the server, errors from the workflow and the package are also attahced.

 

If anyone has any ideas at all I would be much appreciative

 

As far as I can see Workflow is not coping well with the data types in the WSDL file, also on another component its failing to create an array to read the data back into that comes back from the server.

 

I have had a look at these in Visual Studio c# and it reads the file OK and creates all of the Methods and data types etc

 

 

 

Comments 21 CommentsJump to latest comment

reecardo's picture

In the past few months, we've addressed this issue:

"2743107 When creating a library using the Web Service Caller Generator against a webservice using nillable fields for outputs, those components cannot validate in the designer."

Looks like this one will be fixed for 7.5. Just a minor tweak in the generator's template.

kayos99's picture

Hi Reecardo

 

Thank you for your response.

Im using version 7.1.1460.1974

 

Is there an update I need ot be looking for then ? This soudns promising ... Can probably wait for 7.5 but would really like to show the proof of concept with integrating Workflow and remedy to the rest of our team if possible.

 

reecardo's picture

You can try and update the template for the web service generator. You can find it attached (file needs to be renamed to have a .vm extension). Please note this is from the trunk codebase, but should still work in previous versions.

Also note that I've really never replaced a template for a generator either.

To do this in a multigenerator, right click on the webservice generator and select "Select Templates". Add the template I have attached and set it as the default. Again, I'm uploading our trunk template but it should work. If it doesn't work, you should be able to restore the defualt template.

AttachmentSize
WebServiceCompTemplate.vm_.txt 78.44 KB
kayos99's picture

Hi Reecardo

 

Thats great , thank you :) It does now validate but still there dont appear to be any results available to see the reply from teh server, just the variables for the input mask.

 

Definitely getting somewhere now though.

 

If you have any ideas on why its not reporting the result back from the server or creating anything other than HelpDesk_Query_ServiceComponentResult (WHich doesnt have any other values, ie its not an array)

 

 

reecardo's picture

If you're not getting anything back from a nullable output field, more than likely the result was null. Or maybe I'm not understanding your issue right... do you have screenshots of what you expect to see?

kayos99's picture

I do yes, I use SoapUI, you can see the example session attached to this call (Example Session.docx ) says its Null return but when using the form builder there arent any variables crated that I can drag across onto the form.

 

Also if I fireup WireShark which I tried on the QueryList component as well and you can see the SOAP packet go up to the server and the response come back (Showing that Workflow has contructed the XML well)

 

Maybe Im missing something on adding the result variables to my form ?

 

reecardo's picture

Is the Paramater Usage Type set to Ignored for this output? If you move it to Required/Optional, you should get the output type added to the stream.

kayos99's picture

Hi Reecardo

Hi Reecardo,

 

UI have set the Parameter usage to required for some of the fields but they are either returning 'not found' or the fisrt item in the enumeration value list from the WSDL file.  I know the server is returning value (For example I can see the assignee and the notes fields are populated so have set these).

 

The HelpDesk_Query_ServiceComponentResult is coming back as 'not found' as well.

 

I have tried mapping sinlge values and also just grabbing the value acroos in Form builder ... either empty or not found .

 

I really dont know where to go now to find where the results are.

 

Ive attached the latest test of the workflow in case you want to see what Ive tried, maybe you can see what Im doing wrong.

 

many thanks for your help so far.

 

Kind regards,

 

Tim

 

 

AttachmentSize
ARSystemHPD.zip 1.38 MB
kayos99's picture

Attaching SopaUI example session, showing SOAP packet wioth full Incident-Nujber in

AttachmentSize
SoapUITranscript.zip 480.33 KB
kayos99's picture

Attached are 2 Wireshark captures one showing Query traffic, IE just showing one Incident_Number , the other is QueryList showing all the Incidents assigned to myself. Both of these appear to return values when viewing over the wire, but Workflow shows either 'Not Found' or 'Null'

The Destination server is 10.238.196.129 and the host is 10.34.116.0

AttachmentSize
Wireshark_Captures.zip 17.82 KB
reecardo's picture

I've tried duplicating this with a "baby" web service with "out" paramters and nullable types (all strings in this case) but still can't get this to reproduce. I'm assuming something is wrong with the WSDL of the Remedy service in some way. I'm attaching my test project and the .cs of my test web svc method.

 

AttachmentSize
DecisionProject2.zip 1.4 MB
Service1.asmx_.cs_.txt 1004 bytes
kayos99's picture

Hi Reecardo,

 

I tried loading your workflow but my version of Workflow said it needed to upgrade this and then failed ...

Im thinking this could be a timing issue though. I did some investigation yesterday and discovered that our compnay have a number of cache servers for Remedy applications, Im wondering if this could in anyway affect the way Workflow sees the reply ?

 

Im not really sure where we go now, I really want to try and get Workflow integrated into ITSM7 as this is an important goal in showing we can integrate our Altiriws infrastructure into our Service desk and problem management system.

 

If you can think of anything else I can try or any manula mods we could to to the wsdl file to try and make things easier let me know .

 

For now I will see what else I can do, maybe I can carry on with an intermediate application to handle the web service for Workflow ...

 

I see that there are some perl script components but they only work with Altiris filters, is there a way of running perl just as a script in a component like we can with jscript and c# ?

Kind regards,

 

Tim

reecardo's picture

The flow I previously uploaded required you deploy a web service locally with the .cs I had attached. You can ignore any upgrade warnings (I built this in trunk of the codebase)

The timing issue is interesting, it might be one of the problems.

You can try looking into Task Server on the SMP and see if there's a way of setting up a Perl Script task if it exists. There's a Connect article/video I've done about importing tasks on the SMP and running them on the fly. You can have the tasks pre-existing on the SMP when you run them, however... the concept is the same.

kayos99's picture

Hi Reecardo,

 

i have managed to load your Workflow now, I cant run the .cs file, my version of Visual Studio (2012) doesnt like all the definitions.

 

You only appear to run the web service component though in the workflow, I guess you checked the results returned OK in the debugger ?

 

I will see about task manager for Perl ... not so sure now as I need to load things like SOAP:Lite and I usually use CPAN for that ...

 

I am going to try and consume the web service again in VS2012 to see if I can do anything that might shed some more light on this, like timing ..

 

Kind regards,

 

Tim

toomas's picture

Hey Tim,

You need to be a bit more clear about what information does not get populated. Trying this ourselves is not very easy, as we don't have a Remedy web service around :)

Looking at the Debug logs you have attached, in Workflow a proper request does go out (30/10/2012 08:16:54) and response is received (30/10/2012 08:16:55) containing pretty much the same HelpDesk_Query_ServiceResponse data as your SoapUI screenshot.

What exact pieces of data are you expecting to receive and what is missing?
Can you give us a screenshot of the result in the form?

kayos99's picture

Hi Toomas,

 

Please find attached the screen shots showing that the count variable and the OutputList array never contain data and return back as Null or No Data. So I know from Wireshark taht as you say the data is returned to Workflow, but Workflow never takes the data and populates the values in the arrays for me to use or display.

 

The attachment shows the configuration of the component, the form builder setup the browser final output (showing No data returned), also is the SoapUI for the same query showing that the query is valid and does retun data.

 

Kind regards,

 

Tim

AttachmentSize
Help Desk Query List Screen Shots.zip 1.06 MB
kayos99's picture

Just for info, I have updated one of my machines to latest version fo Workflow (7.1.1500.2051) to see if this made any difference, but Im afraid I still get the same problem.

 

Have you any further ideas or things i can try ? Is there a way I can see what Workflow thinks it is receiving ? I have tried Log All Data from debug but it doesnt appear to give me any clues at all.

kayos99's picture

Hi Toomas

 

I have now tried on Workflow 7.5 and the result is slightly different, one row returns with a status of 'New' ... which is strange and different,

 

Attached are log files and the output screen for info.

 

Kind regards,

 

Tim

AttachmentSize
REMEDY-TEST.zip 81.42 KB
TGiles's picture

This actually appears to be an issue with C# and dealing with blank enumerated data types being returned from a web service. The below link was found on Remedy's site pertaining to the specific web service in question.

https://communities.bmc.com/communities/thread/32323

toomas's picture

This is either remedy webservice or its WSDL that is causing this, response has an unexpected namespace.

I will use the last set of files a few posts back as an example (Connect: REMEDY-TEST.zip from Dec 17):
 

Request:

<soap:Body>
<HelpDesk_QueryList_Service xmlns="urn:HPD_IncidentInterface_WS">
<Qualification>'Assignee' = "Tim KAY"</Qualification>
<startRecord>0</startRecord>
<maxLimit>999</maxLimit>
</HelpDesk_QueryList_Service>
</soap:Body>

Response:

<?xml version="1.0" encoding="utf-8"?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<soapenv:Body><ns0:HelpDesk_QueryList_ServiceResponse xmlns:ns0="HPD_IncidentInterface_WS" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<ns0:getListValues>

Note the bold parts. The component Web Service Caller generator has generated does exactly what it was supposed to and looks for the values in the response and cannot find anything since the namespace is wrong.

After I added the missing "urn:" to response, data did get processed into Workflow.