6 Replies Latest reply on Aug 25, 2017 3:41 PM by khayes RSS
    khayes Apprentice

    Dynamically binding to an entity for services issue

    Hi,

     

    I have a mashup that has the name of a thing as a mashup parameter which I use as the EntityName parameter for some dynamic services.

    The problem I am having is that the binding doesn't appear to be working correctly (i.e. service do not run when called). When I look at the connections in the 'connections' window I see some odd things (see below). The connection appears to be okay for only one of the templated things.

     

     

     

    When called, only the services for the last dynamic thing (LinxRemotePrinterTemplate) run. They used to be fine and all run correctly, but now any time I try to use the first two templates dynamically I get the same binding issue.

    Has anyone seen this before, and have any idea how i might fix this?

    Thx.

      • Re: Dynamically binding to an entity for services issue
        polinao Ninja

        Not quite sure I understand the scenario fully. Could you please attach an export of related entities for  demonstration? Have you modified any of the templates recently?

          • Re: Dynamically binding to an entity for services issue
            khayes Apprentice

            Hi Polina,

            thanks for the quick reply. Yes I have been modifying the services in the templates (parameters and code) of both of the templates which no longer seem to work. i did wonder if they had been corrupted when trying to save or something.

            I'll try to explain it a little more clearly. i'll just talk about one of the templates, as I think the problem is the same on both.

             

            I have a mashup that calls some dynamic services on things based on a 'Distributor Template'.

            The first service is called when the mashup is loaded.

            The mashup itself has a parameter which is the name of the thing on which I wish to run the service. This is bound to the 'EntityName' parameter (see above) of the dynamic service. When i load the mash up I can see that the service doesn't run (I have a debug statement as the first line of the service which doesn't appear in the logs). When I look at the 'connections' window in the mashup composer where I would normally see a blue arrow from the mashup parameter to the service EntityName all I see is the 'remove binding' button but no blue arrow  (see original post). It's like the binding has been corrupted?

             

            When you say to attach an export do you mean an .xml file of the template in question?

            K

          • Re: Dynamically binding to an entity for services issue
            khayes Apprentice

            Hi,

             

            I have tried a number of things to solve the issue:

            1. removing the services completely saving then adding back but it still persists.
            2. I've also tried creating new mashups using the same template services (dynamic) and the problem is always present.
            3. I can run the services directly via the composer using an instance (of the template) services 'Test' button. They work okay.
            4. I've tried shutting the composer down and restarting it. Issue persists.

             

            I have attached the xml files of the mashup & the template. Thanks again for looking at this, I appreciate it.