Closed yujuew closed 4 years ago
This was a bug, introduced during the restructuring when NGSI-LD support was added. I have since corrected the NGSI v2 Query String parameter for the Weather proxy. Please obtain the latest docker images using .services create
and re-try.
Fixed: ef9c08b
Hi,
I'm following the Step-by-Step tutorial and trying out OpenWeatherMap API. I'm testing using docker. (I slightly changed the docker-compose.yml in the tutorial, but the architecture is the same) However, I found for context-provide, the endpoint in the example "/random/weatherConditions" works fine. I tried other endpoints listed in the menu , such as "random/temperature", "/weather/number/cairo%2ceg/temp", and "/weather/weatherConditions", they all returned
{"error":"NotFound","description":"The entity does not have such an attribute"}
in my curl client.If I checked the logs of orion and context provider. I can see that for "/weather/weatherConditions", there's an issue with OpenWeatherMap API
fiware-tutorial | POST /weather/weatherConditions/op/query 400 883.080 ms - 1319 orion_1 | INFO@16:20:36 httpRequestSend.cpp[619]: Notification Successfully Sent to http://host.docker.internal:3000/weather/weatherConditions/op/query orion_1 | WARN@16:20:36 httpRequestSend.cpp[632]: Notification response NOT OK, http code: 400
However, for "random/temperature" or "/weather/number/cairo%2ceg/temp", the logs show that the query operarion goes well. However the response in my curl client is still
{"error":"NotFound","description":"The entity does not have such an attribute"}
...The logs are beloworion_1 | INFO@16:20:35 logMsg.h[1844]: Starting transaction to http://host.docker.internal:3000/random/temperature/op/query orion_1 | INFO@16:20:35 httpRequestSend.cpp[599]: Sending message 55 to HTTP server: sending message of 310 bytes to HTTP server fiware-tutorial | POST /random/temperature/op/query 200 0.899 ms - 34 orion_1 | INFO@16:20:35 httpRequestSend.cpp[619]: Notification Successfully Sent to http://host.docker.internal:3000/random/temperature/op/query orion_1 | INFO@16:20:35 httpRequestSend.cpp[628]: Notification response OK, http code: 200
Since I only change part of the provider url... so I don't know if it's an issue with the context provider or with my settings. Thanks so much for helping in advance!!!!