Skip to Content
As I described in a previous blog  (Guided Procedures Explorations: Thoughts on Service Level Agreement Metrics – Active Measures), there is an ever-increasing focus on the quality of process implementation.  It is no longer enough that a process meets the associated user requirements. The process must also often meet quality metrics that are based on Service Level Agreements (SLA). In a corporate setting, customers require proof that a certain service has met the related Key performance indicators (KPI)  (http://en.wikipedia.org/wiki/Key_performance_indicators).    This blog will examine one aspect of process SLAs from the perspective of a service provider who must provide customers with quality measures – usually in the form of daily, weekly or monthly reports.  Although a theoretical discussion of the quality metrics associated with the service provision for processes is interesting, it is the topic for other blogs.  This blog focuses on measures which lists process instances are that overdue.   h2. Initial Web-service    Through the use of a Web DynPro web-service, Guided Procedure (GP) process instances that are running can be examined and the details on the lateness of the process instances can be returned.   The web-service is based on two parameters: name of the user that was the administrator of the process (overseer or owner could have been used as well) and a negative number that reflects how many days (minutes or hours could also have used) the process instances are over-due. For example, “-2” would return those processes that are at least 2 days overdue.  We had some trouble with the constant for the SearchRolesInformation but with a handy Java decompiler, everything is possible.   A Caveat:  This web-service is, of course, relatively simple. However, it demonstrates the basic concept to get the SLA information that is necessary. Based on actual user requirements, it could be improved to deal with other monitoring interfaces. Currently, the web-service returns all processes for a particular user. Thismay not be desired in a production environment where there are many process and processes instances. Related performances considerations were also not examined and would have to be examined more closely for productive usage.   The web-service in action (in a Visual Composer application) shows what the results look like: 
To report this post you need to login first.

4 Comments

You must be Logged on to comment or reply to a post.

  1. Padmarajan KN
    Hi,
    I am trying to create a GP Runtime dashboard and I am using your blog as a reference.
    Could you please tell me how did you resolve the the below imports
    com.sap.caf.eu.gp.model.process.info.impl.SearchRolesInformation
    com.sap.caf.eu.gp.process.api.ISearchRolesInformation

    -Thanks in advance,
    KN.

    (0) 
    1. Claudiu Tatulea
      Hi

      We resolved this import by creating a class ourselves which implements the interface ISearchRolesInformation. The values were taken by decompiling a class, but I cannot remember exactly how this was done. Anyway I used this class and it worked just fine.

      Hope this helps you.

      The code is:

      package com.sap.caf.eu.gp.model.process.info.impl;

      import com.sap.caf.eu.gp.process.api.ISearchRolesInformation;

      public class SearchRolesInformation implements ISearchRolesInformation {

           SearchRolesInformation() {

           }

           public static com.sap.caf.eu.gp.process.api.ISearchRolesInformation getSearchRoleInformation() {

                /* 21*/
                return new SearchRolesInformation();

           }

           public int getSearchRoleAdministrator() {

                /* 30*/
                return 0;

           }

           public int getSearchRoleOverseer() {

                /* 39*/
                return 2;

           }

           public int getSearchRoleOwner() {

                /* 48*/
                return 1;

           }

      }

      (0) 
      1. Padmarajan KN
        Hi,
        I was able to resolve the SearchRolesInformation. Thank you. I have some more doubts on GP API. Please see below:

        1. How do I find out the roles assigned to each task with in the Process?
        2. How do I pull out the output parameters of the process? For this I tried out the following code which is not pulling out the expected result.

        IGPStructureInfo struct = actionInstance.getTemplate().getOutputParameters();
        Collection collection = struct.getAttributes();
                            wdComponentAPI.getMessageManager().reportSuccess(“collection size: “+collection.size());
             Iterator iterator = collection.iterator();
             while(iterator.hasNext()){
                                           IGPAttributeInfo test = (IGPAttributeInfo)iterator.next();
                                                               wdComponentAPI.getMessageManager().reportSuccess(“test.getnamesapce”+test.getNamespace());
             wdComponentAPI.getMessageManager().reportSuccess(“test.label.name”+test.getLabel().getName());
        }

        Could you please provide inputs to the above. I have been posting threads on forum but was not able to get them through. I guess you can be of great help here.

        -Thanks in advance
        KN.

        (0) 
        1. Claudiu Tatulea
          Hello
          I’m sorry but this time I don’t think I’ll be of significant help with both questions. But I’ll try.

          1.
          I didn’t work with roles. But as a hint you can look into the API documentation of IGPModifiableBlock. Methods like getRole or getRoleMap. Or in general in classes starting with IPGModifiable….. not much more I can say

          Also, this blog can be of help:
          https://www.sdn.sap.com/irj/sdn/thread?threadID=188130

          or the link:
          http://help.sap.com/saphelp_nw04s/helpdata/en/44/7b9798e1da6572e10000000a11466f/frameset.htm

          2.
          Supposing that you want the result content of a process instance, not the output structure, I have to tell you:
          I’m sorry, but I ran into the same problem and couldn’t solve it.
          You see, I also tried the line
          actionInstance.getTemplate().getOutputParameters(),
          but this method only retrieves the structure of the output parameters, not the content of the output. We tried also to retrieve the input params of the process instance, but…. same thing.

          If you are inside a callable object for an action inside the process the following methods – getInputStructureInfo and getOutputStructure(). – return the content of input and, of course, the output – since inside the callable object the output is constructed. But I really couldn’t find a method to access this input/output data outside the callable object.

          Here are only a few classes I looked into:
          IGPContextManager
          GPRTContentFactory
          IGPExecutionContext – this would be accessible only in the callable object, since it is only called by the framework

          Finally….
          I searched on SDN and looked in and out the GP API, but all I could get is that I managed to create runtime views which are accessible from the browser interface.
          I mean – in the runtime view, if you visualize a completed process, or running process with some completed steps, you can view the steps and output values of the callable objects (deliverables).

          I couldn’t make anything of the class IGPRTView which, supposedly would have been an API representation of the runtime view….

          So, this is all what I can tell you about getting runtime input/output values of a process instance…. as little as it is, hope it helps in some way.

          Regards
          Claudiu

          (0) 

Leave a Reply