[ https://jira.fiware.org/browse/HELP-9152?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Fernando Lopez updated HELP-9152: --------------------------------- HD-Chapter: Data Description: Created question in FIWARE Q/A platform on 14-04-2015 at 15:04 {color: red}Please, ANSWER this question AT{color} https://stackoverflow.com/questions/29628587/no-json-object-could-be-decoded-orion-context-broker +Question:+ No JSON object could be decoded- orion context broker +Description:+ I am trying out orion context broker comunication on two CentOS 6.6 machines. On the target machine I did: ./accumulator-server.py 1028 /accumulate mywebpage.lan on And on my local machine I did: [DevF12 at localhost ~]$ (curl mywebpage.lan:1028/v1/updateContext -s -S --header 'Content-Type: application/json' --header 'Accept: application/json' -d @- | python -mjson.tool ) <<EOF > { > "contextElements": [ > { > "type": "Room", > "isPattern": "false", > "id": "Room2", > "attributes": [ > { > "name": "temperature", > "type": "float", > "value": "777" > }, > { > "name": "pressure", > "type": "integer", > "value": "711" > } > ] > } > ], > "updateAction": "APPEND" > } > EOF The result on the target machine is: POST http://mywebpage.lan:1028/v1/updateContext Content-Length: 456 User-Agent: curl/7.19.7 (x86_64-redhat-linux-gnu) libcurl/7.19.7 NSS/3.16.2.3 Basic ECC zlib/1.2.3 libidn/1.18 libssh2/1.4.2 Host: mywebpage.lan:1028 Accept: application/json Content-Type: application/json { "contextElements": [ { "type": "Room", "isPattern": "false", "id": "Room2", "attributes": [ { "name": "temperature", "type": "float", "value": "777" }, { "name": "pressure", "type": "integer", "value": "711" } ] } ], "updateAction": "APPEND"}======================================= 192.168.1.11 - - [14/Apr/2015 15:07:36] "POST /v1/updateContext HTTP/1.1" 200 - And the message I get from the local machine is: No JSON object could be decoded So, what does this all mean? 1. Is the 200 code saying that it is successfully creating Room2? 2. Why am I getting the could not decode JSON then? 3. All of this brings up another question, does this mean that the weather station described in my previous post also has to run on CentOS in order to send context broker messages? was: Created question in FIWARE Q/A platform on 14-04-2015 at 15:04 {color: red}Please, ANSWER this question AT{color} https://stackoverflow.com/questions/29628587/no-json-object-could-be-decoded-orion-context-broker +Question:+ No JSON object could be decoded- orion context broker +Description:+ I am trying out orion context broker comunication on two CentOS 6.6 machines. On the target machine I did: ./accumulator-server.py 1028 /accumulate mywebpage.lan on And on my local machine I did: [DevF12 at localhost ~]$ (curl mywebpage.lan:1028/v1/updateContext -s -S --header 'Content-Type: application/json' --header 'Accept: application/json' -d @- | python -mjson.tool ) <<EOF > { > "contextElements": [ > { > "type": "Room", > "isPattern": "false", > "id": "Room2", > "attributes": [ > { > "name": "temperature", > "type": "float", > "value": "777" > }, > { > "name": "pressure", > "type": "integer", > "value": "711" > } > ] > } > ], > "updateAction": "APPEND" > } > EOF The result on the target machine is: POST http://mywebpage.lan:1028/v1/updateContext Content-Length: 456 User-Agent: curl/7.19.7 (x86_64-redhat-linux-gnu) libcurl/7.19.7 NSS/3.16.2.3 Basic ECC zlib/1.2.3 libidn/1.18 libssh2/1.4.2 Host: mywebpage.lan:1028 Accept: application/json Content-Type: application/json { "contextElements": [ { "type": "Room", "isPattern": "false", "id": "Room2", "attributes": [ { "name": "temperature", "type": "float", "value": "777" }, { "name": "pressure", "type": "integer", "value": "711" } ] } ], "updateAction": "APPEND"}======================================= 192.168.1.11 - - [14/Apr/2015 15:07:36] "POST /v1/updateContext HTTP/1.1" 200 - And the message I get from the local machine is: No JSON object could be decoded So, what does this all mean? 1. Is the 200 code saying that it is successfully creating Room2? 2. Why am I getting the could not decode JSON then? 3. All of this brings up another question, does this mean that the weather station described in my previous post also has to run on CentOS in order to send context broker messages? HD-Enabler: Orion > [fiware-stackoverflow] No JSON object could be decoded- orion context broker > ---------------------------------------------------------------------------- > > Key: HELP-9152 > URL: https://jira.fiware.org/browse/HELP-9152 > Project: Help-Desk > Issue Type: Monitor > Components: FIWARE-TECH-HELP > Reporter: Backlog Manager > Assignee: Fermín Galán > Labels: fiware, fiware-orion > > Created question in FIWARE Q/A platform on 14-04-2015 at 15:04 > {color: red}Please, ANSWER this question AT{color} https://stackoverflow.com/questions/29628587/no-json-object-could-be-decoded-orion-context-broker > +Question:+ > No JSON object could be decoded- orion context broker > +Description:+ > I am trying out orion context broker comunication on two CentOS 6.6 machines. On the target machine I did: > ./accumulator-server.py 1028 /accumulate mywebpage.lan on > And on my local machine I did: > [DevF12 at localhost ~]$ (curl mywebpage.lan:1028/v1/updateContext -s -S --header 'Content-Type: application/json' --header 'Accept: application/json' -d @- | python -mjson.tool ) <<EOF > > { > > "contextElements": [ > > { > > "type": "Room", > > "isPattern": "false", > > "id": "Room2", > > "attributes": [ > > { > > "name": "temperature", > > "type": "float", > > "value": "777" > > }, > > { > > "name": "pressure", > > "type": "integer", > > "value": "711" > > } > > ] > > } > > ], > > "updateAction": "APPEND" > > } > > EOF > The result on the target machine is: > POST http://mywebpage.lan:1028/v1/updateContext > Content-Length: 456 > User-Agent: curl/7.19.7 (x86_64-redhat-linux-gnu) libcurl/7.19.7 NSS/3.16.2.3 Basic ECC zlib/1.2.3 libidn/1.18 libssh2/1.4.2 > Host: mywebpage.lan:1028 > Accept: application/json > Content-Type: application/json > { "contextElements": [ { "type": "Room", "isPattern": "false", "id": "Room2", "attributes": [ { "name": "temperature", "type": "float", "value": "777" }, { "name": "pressure", "type": "integer", "value": "711" } ] } ], "updateAction": "APPEND"}======================================= > 192.168.1.11 - - [14/Apr/2015 15:07:36] "POST /v1/updateContext HTTP/1.1" 200 - > And the message I get from the local machine is: > No JSON object could be decoded > So, what does this all mean? > 1. Is the 200 code saying that it is successfully creating Room2? > 2. Why am I getting the could not decode JSON then? > 3. All of this brings up another question, does this mean that the weather station described in my previous post also has to run on CentOS in order to send context broker messages? -- This message was sent by Atlassian JIRA (v6.4.1#64016)
You can get more information about our cookies and privacy policies clicking on the following links: Privacy policy Cookies policy