Uploaded image for project: 'Help-Desk'
  1. Help-Desk
  2. HELP-12711

[fiware-askbot] Error at Cygnus when receives a Notification from "Orion context Broker" : 'fiware-servicepath' header value does not match the number of notified context responses

    Details

      Description

      Created question in FIWARE Q/A platform on 31-08-2017 at 12:08
      Please, ANSWER this question AT https://ask.fiware.org/question/825/error-at-cygnus-when-receives-a-notification-from-orion-context-broker-fiware-servicepath-header-value-does-not-match-the-number-of-notified-context/

      Question:
      Error at Cygnus when receives a Notification from "Orion context Broker" : 'fiware-servicepath' header value does not match the number of notified context responses

      Description:
      I have created a Subscription at Orion Context Broker in order to send the data to Cygnus for persist the data in mongodb. When Orion receives and new event value send the notification to Cygnus and I get the following log info at console.

      time=2017-08-31T10:10:56.130Z | lvl=INFO | corr=ad9caef6-8e34-11e7-885a-fa163e0d608a | trans=c08becae-0e14-4859-940c-32558dfec7f3 | srv=default | subsrv=/cygnusservicepath | comp=cygnusagent | op=getEvents | msg=com.telefonica.iot.cygnus.handlers.NGSIRestHandler[286] : [NGSIRestHandler] Starting internal transaction (c08becae-0e14-4859-940c-32558dfec7f3)
      time=2017-08-31T10:10:56.141Z | lvl=INFO | corr=ad9caef6-8e34-11e7-885a-fa163e0d608a | trans=c08becae-0e14-4859-940c-32558dfec7f3 | srv=default | subsrv=/cygnusservicepath | comp=cygnusagent | op=getEvents | msg=com.telefonica.iot.cygnus.handlers.NGSIRestHandler[304] : [NGSIRestHandler] Received data ({"subscriptionId":"xxxxxxxxx","data":[{"id":"id1","type":"type1,....)
      time=2017-08-31T10:10:56.239Z | lvl=WARN | corr=ad9caef6-8e34-11e7-885a-fa163e0d608a | trans=c08becae-0e14-4859-940c-32558dfec7f3 | srv=default | subsrv=/cygnusservicepath | comp=cygnusagent | op=getEvents | msg=com.telefonica.iot.cygnus.handlers.NGSIRestHandler[324] : [NGSIRestHandler] Bad HTTP notification ('fiware-servicepath' header value does not match the number of notified context responses
      time=2017-08-31T10:10:56.240Z | lvl=WARN | corr=ad9caef6-8e34-11e7-885a-fa163e0d608a | trans=c08becae-0e14-4859-940c-32558dfec7f3 | srv=default | subsrv=/cygnusservicepath | comp=cygnusagent | op=doPost | msg=org.apache.flume.source.http.HTTPSource$FlumeHTTPServlet[186] : Received bad request from client.
      org.apache.flume.source.http.HTTPBadRequestException: 'fiware-servicepath' header value does not match the number of notified context responses
      at com.telefonica.iot.cygnus.handlers.NGSIRestHandler.getEvents(NGSIRestHandler.java:327)
      at org.apache.flume.source.http.HTTPSource$FlumeHTTPServlet.doPost(HTTPSource.java:184)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:725)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:814)
      at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
      at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:401)
      at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
      at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:766)
      at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
      at org.mortbay.jetty.Server.handle(Server.java:326)
      at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
      at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:945)
      at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:756)
      at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:218)
      at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
      at org.mortbay.jetty.bio.SocketConnector$Connection.run(SocketConnector.java:228)
      at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)

      The header is sent from Orion Context Broker to Cygnus, show what can I do to solve the problem?

      Maybe something is not properly configured?

      cat /usr/cygnus/conf/agent_mongo.conf
      cygnusagent.sources = http-source
      cygnusagent.sinks = mongo-sink
      cygnusagent.channels = mongo-channel

      cygnusagent.sources.http-source.channels = mongo-channel
      cygnusagent.sources.http-source.type = org.apache.flume.source.http.HTTPSource
      cygnusagent.sources.http-source.port = 5050
      cygnusagent.sources.http-source.handler = com.telefonica.iot.cygnus.handlers.NGSIRestHandler
      cygnusagent.sources.http-source.handler.notificationtarget = /notify
      cygnusagent.sources.http-source.handler.defaultservice = default
      cygnusagent.sources.http-source.handler.defaultservicepath = /cygnusservicepath
      cygnusagent.sources.http-source.handler.eventsttl = 10
      cygnusagent.sources.http-source.interceptors = ts gi
      cygnusagent.sources.http-source.interceptors.ts.type = timestamp
      cygnusagent.sources.http-source.interceptors.gi.type = com.telefonica.iot.cygnus.interceptors.NGSIGroupingInterceptor$Builder
      cygnusagent ... (more)

        Activity

        Transition Time In Source Status Execution Times Last Executer Last Execution Date
        Open Open In Progress In Progress
        397d 11h 1 Backlog Manager 10/Oct/18 4:05 PM
        In Progress In Progress Answered Answered
        59m 58s 1 Backlog Manager 10/Oct/18 5:05 PM
        Answered Answered Closed Closed
        89d 17h 10m 1 Andres Muñoz 08/Jan/19 9:15 AM

          People

          • Assignee:
            andres.munoza Andres Muñoz
            Reporter:
            backlogmanager Backlog Manager
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: