12 Replies Latest reply: Aug 12, 2016 3:45 PM by Ganesh Devarashetty RSS

    Trigger load in QVMC by external event (EDX)

    Knut Erik Thorsen

      Hi all,

       

      I want to trigger a task in QVMC (reload of a QV report) by running a .bat file.

       

      • I have downloaded the QMSEDX.exe and QMSEDA.exe.config
      • I have created the task which is triggered by EDX and the password is 000

       

      My problem:

      I cant seem to get the .bat file to work properly and trigger the reload in QVMC.

       

      My .bat file looks like this:

      "<filepath>QMSEDX.exe -task="Test EDX.qvw" -qms=http://<QVserverName>:4799/QMS/Service -password=000"

      exit

       

      Can anyone give me a "step-by-step" for dummies ?

       

      Thanks in advance

        • Re: Trigger load in QVMC by external event (EDX)
          Peter Cammaert

          If you run this command from the DOS command line, what does the QMSEDX program return?

           

          Edit: add -verbosity=5 to your command line to get the largest amount of feedback.

            • Re: Trigger load in QVMC by external event (EDX)
              Knut Erik Thorsen

              It does not return anything. Even without the "Exit" part of the command, the command window only birefly opnes and then it is closed automatically

                • Re: Trigger load in QVMC by external event (EDX)
                  Peter Cammaert

                  This is what you get when you run the bat/cmd file. Instead, open a CMD prompt window and enter your command line (starting with "pathtoprogram\QMSEDX.exe...") and add the -verbosity=5 command line option.

                    • Re: Trigger load in QVMC by external event (EDX)
                      Knut Erik Thorsen

                      the command prompt only returns the message that QMSEDX is not a valid win 32 program.

                        • Re: Trigger load in QVMC by external event (EDX)
                          Peter Cammaert

                          There you have it: your copy of QMSEDX is either broken or not suitable to run on your OS. Can you download the latest copy again (1.0.4 I guess), check the zip for any errors and extract a new copy of QMSEDX?

                           

                          Peter

                            • Re: Trigger load in QVMC by external event (EDX)
                              Knut Erik Thorsen

                              Hi,

                               

                              BTW, thank you so much for your help!

                               

                              Now I got a different error message running the .bat:

                               

                              "D:\QlikView Storage\EDX\QMSEDX.exe" -task="4_Development\Test EDX.qvw" -qms="http://10.120.0.400:4799/QMS/Service.htm" -password="123"

                               

                              I suspect it may be that I do not have the correct  QV server box (ref your post)

                               

                              10.120.0.400 is the server address

                               

                               

                               

                              I have tried to follow the recipie from your post,to find the QV Server box (properties on my computer), but the computer name there does not work either.

                               

                              Any ideas?

                               

                               

                              this is the error message

                               

                              Failed to create a client to the specified Uri.
                              There was no endpoint listening at http://10.120.0.400:4799/QMS/Service.htm that
                              could accept the message. This is often caused by an incorrect address or SOAP
                              action. See InnerException, if present, for more details.

                              Unhandled Exception: System.ServiceModel.EndpointNotFoundException: There was no
                              endpoint listening at http://10.120.0.400:4799/QMS/Service.htm that could accep
                              t the message. This is often caused by an incorrect address or SOAP action. See
                              InnerException, if present, for more details. ---> System.Net.WebException: The
                              remote server returned an error: (404) Not Found.
                                 at System.Net.HttpWebRequest.GetResponse()
                                 at System.ServiceModel.Channels.HttpChannelFactory.HttpRequestChannel.HttpCha
                              nnelRequest.WaitForReply(TimeSpan timeout)
                                 --- End of inner exception stack trace ---

                              Server stack trace:
                                 at System.ServiceModel.Channels.HttpChannelUtilities.ProcessGetResponseWebExc
                              eption(WebException webException, HttpWebRequest request, HttpAbortReason abortR
                              eason)
                                 at System.ServiceModel.Channels.HttpChannelFactory.HttpRequestChannel.HttpCha
                              nnelRequest.WaitForReply(TimeSpan timeout)
                                 at System.ServiceModel.Channels.RequestChannel.Request(Message message, TimeS
                              pan timeout)
                                 at System.ServiceModel.Dispatcher.RequestChannelBinder.Request(Message messag
                              e, TimeSpan timeout)
                                 at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean on
                              eway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan tim
                              eout)
                                 at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCall
                              Message methodCall, ProxyOperationRuntime operation)
                                 at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)

                              Exception rethrown at [0]:
                                 at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage req
                              Msg, IMessage retMsg)
                                 at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgDa
                              ta, Int32 type)
                                 at QMSEDX.QMSAPI.IQMS.TriggerEDXTask(Guid qdsID, String taskNameOrID, String
                              password, String variableName, List`1 variableValues)
                                 at QMSEDX.QMSAPI.QMSClient.TriggerEDXTask(Guid qdsID, String taskNameOrID, St
                              ring password, String variableName, List`1 variableValues)
                                 at QMSEDX.Program.TriggerTask(IQMS qms, String task, String password, String
                              variableName, List`1 variableValues)
                                 at QMSEDX.Program.TriggerAndMonitorTask()
                                 at QMSEDX.Program.Main(String[] args)

                                • Re: Trigger load in QVMC by external event (EDX)
                                  Peter Cammaert

                                  I don't think your server software is at fault. However, check the following:

                                   

                                  • 10.120.0.400 is not a valid IP-address. It will never work
                                  • On the QlikView server, is port 4799 (the one you are using) opened?
                                  • Are you running this on the QlikView server itself (in a remote session)? If you are, use localhost as server name. If not, try to open http://serveraddress/qlikview to see whether the AP is showing up  Whenever that works, you can be sure that the serveraddress is correct.

                                   

                                  Best,

                                   

                                  Peter

                                    • Re: Trigger load in QVMC by external event (EDX)
                                      Jerry Svensson

                                      I would also recommend using localhost if you are running this on the server.

                                       

                                      You can verify the address from QMC like this:

                                      System/Setup: Click on Management Service.

                                      In Summary on the right you will see :

                                      "To connect to the API of this Management Service use: https://<server>:4799/QMS/Service "

                                        • Re: Trigger load in QVMC by external event (EDX)
                                          Knut Erik Thorsen

                                          Hi,

                                           

                                          Thank you! You guys are the best!

                                           

                                          Getting close I think

                                           

                                          Now I got this error message:

                                           

                                          Unhandled Exception: System.ServiceModel.FaultException: Authorization failed fo
                                          r user Test/User, required access level is QlikViewEDX

                                          Server stack trace:
                                             at System.ServiceModel.Channels.ServiceChannel.HandleReply(ProxyOperationRunt
                                          ime operation, ProxyRpc& rpc)
                                             at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean on
                                          eway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan tim
                                          eout)
                                             at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCall
                                          Message methodCall, ProxyOperationRuntime operation)
                                             at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)

                                          Exception rethrown at [0]:
                                             at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage req
                                          Msg, IMessage retMsg)
                                             at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgDa
                                          ta, Int32 type)
                                             at QMSEDX.QMSAPI.IQMS.TriggerEDXTask(Guid qdsID, String taskNameOrID, String
                                          password, String variableName, List`1 variableValues)
                                             at QMSEDX.QMSAPI.QMSClient.TriggerEDXTask(Guid qdsID, String taskNameOrID, St
                                          ring password, String variableName, List`1 variableValues)
                                             at QMSEDX.Program.TriggerTask(IQMS qms, String task, String password, String
                                          variableName, List`1 variableValues)
                                             at QMSEDX.Program.TriggerAndMonitorTask()
                                             at QMSEDX.Program.Main(String[] args)

                                            • Re: Trigger load in QVMC by external event (EDX)
                                              Peter Cammaert

                                              The user that is running QMSEDX must be a member of a specific local group on the QlikView Server. Otherwise he/she will not be able to access the EDX interface.

                                               

                                              Normally, membership of local group QlikView Administrators is enough to access the Management API. But not for EDX. To trigger tasks by way of EDX, your user must be member of local group "QlikView EDX". Create that local group on the QlikView Server if it doesn't exist, and make the user that tries to run QMSEDX a member of this group.

                                               

                                              All technical information about EDX in v11 is available here: Using EDX in QlikView 11

                                               

                                              Best,

                                               

                                              Peter

                                                • Re: Trigger load in QVMC by external event (EDX)
                                                  Ganesh Devarashetty

                                                  Hi Thorsen, I think creating the Qlikview EDX group and adding the user to that group will fix your issue.

                                                   

                                                  All, I have a similar issue, I opened another thread but noticed this one. I think mine is not working because my HTTP and HTTPS both pointing to 4799..Here is my thread EDX Command Line trigger not working and I am also pasting my issue below...Can someone give some guidance or how to change HTTP to use a different port while HTTPS looks like using 4799.

                                                   

                                                  I am using command line EDX run. did the following.

                                                   

                                                  1. Created a QMC Task with EDX trigger and password

                                                  2. Copied the EDX command program onto a machine (even on server).

                                                  3. executing below in cmd (admin mode)

                                                     qmsedx -task="ABC.qvw" -qms="http://PUB:4799/QMS/Service"  -password=Password123 -verbosity=3

                                                  4. Get below error message followed by an exception trace:

                                                   

                                                  Failed to create a client to the specified Uri.

                                                  The request channel timed out while waiting for a reply after 00:00:59.8979898.

                                                  Increase the timeout value passed to the call to Request or increase the SendTim

                                                  eout value on the Binding. The time allotted to this operation may have been a p

                                                  ortion of a longer timeout.

                                                   

                                                  5. If I give https://PUB:4799/QMS/Service  (https instead of http), the following error comes up

                                                  Failed to create a client to the specified Uri.
                                                  The provided URI scheme 'https' is invalid; expected 'http'.
                                                  Parameter name: via

                                                  Unhandled Exception: System.ArgumentException: The provided URI scheme 'https' i
                                                  s invalid; expected 'http'.

                                                   

                                                  6. If enter http://PUB:4799/QMS/Service URL in browser, there is no response (timeout). If I enter https://PUB:4799/QMS/Service  URL in browser, a certificate message shows up but webpage opens up.

                                                   

                                                  Just checking if anyone? One thing I am thinking is the QMS port number is the same for both HTTP and HTTPS. Is that an issue? Is that the reason that HTTPS works but HTTP does not?

                              • Re: Trigger load in QVMC by external event (EDX)
                                Peter Cammaert

                                A step-by-step guide can be found here: Trigger QV  Task using command line arguments

                                 

                                Searching for a specific term like "QMSEDX" with just type "Documents" marked, will always return useful information from the extensive resource library in this community.