Closed sfl0r3nz05 closed 2 years ago
[update]
I fixed this error:
{"op":"IoTAgentNGSI.DomainControl","time":"2022-10-08T09:15:31.479Z","lvl":"ERROR","msg":"/opt/iotaul/config.js:55\n ngsiVersion: 'v2'\n ^^^^^^^^^^^\n\nSyntaxError: Unexpected identifier\n at Object.compileFunction (node:vm:360:18)\n at wrapSafe (node:internal/modules/cjs/loader:1055:15)\n at Module._compile (node:internal/modules/cjs/loader:1090:27)\n at Object.Module._extensions..js (node:internal/modules/cjs/loader:1180:10)\n at Module.load (node:internal/modules/cjs/loader:1004:32)\n at Function.Module._load (node:internal/modules/cjs/loader:839:12)\n at Module.require (node:internal/modules/cjs/loader:1028:19)\n at require (node:internal/modules/cjs/helpers:102:18)\n at start (/opt/iotaul/bin/iotagent-ul:41:18)\n at Object.<anonymous> (/opt/iotaul/bin/iotagent-ul:56:1)\n at Module._compile (node:internal/modules/cjs/loader:1126:14)\n at Object.Module._extensions..js (node:internal/modules/cjs/loader:1180:10)\n at Module.load (node:internal/modules/cjs/loader:1004:32)\n at Function.Module._load (node:internal/modules/cjs/loader:839:12)\n at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12)\n at node:internal/main/run_main_module:17:47 {\n domainThrown: true\n}"}
I missed a ,
in configmap.yaml
contextBroker: {
/**
* Host where the Context Broker is located.
*/
host: '{{ .Values.iota.contextBroker.host }}',
/**
* Port where the Context Broker is listening.
*/
port: '{{ .Values.iota.contextBroker.port }}',
/**
* If you want to use NGSI v2.
*/
ngsiVersion: '{{ .Values.iota.contextBroker.ngsiVersion }}'
}
However, the error {"name":"BAD_REQUEST","message":"Request error connecting to the Context Broker: 501"}
persists, with the same log:
time=2022-10-08T09:48:21.184Z | lvl=DEBUG | corr=d11a8a9a-ff9a-4748-9f47-4fce66054360 | trans=d11a8a9a-ff9a-4748-9f47-4fce66054360 | op=IoTAgentNGSI.Request | from=n/a | srv=openiot | subsrv=/ | msg=Response {
"error": "NotImplemented",
"description": "Only NGSIv1-based forwarding supported at the present moment. Set explictely legacyForwarding to true"
}
[Update]
I have updated orion version to 3.7.0 from fiware/orion repository, previously I was using quay.io/fiware/orion-ld repository. The logging error is:
time=2022-10-08T18:17:24.614Z | lvl=ERROR | corr=841d2b61-463e-42ff-acd7-d0f4b867b7b3 | trans=841d2b61-463e-42ff-acd7-d0f4b867b7b3 | op=IoTAgentNGSI.DeviceService | srv=openiot | subsrv=/ | msg=Registration error connecting to the Context Broker: {"code":"400","reasonPhrase":"Bad Request","details":"missing isDomain value for registration attribute"} | comp=IoTAgent
I am trying to solve the issue on SOF (https://stackoverflow.com/questions/74003335/how-to-enable-ngsiv2-in-iotagent-ul-helmchart), so I will close the issue.
Hi, I received
{"name":"BAD_REQUEST","message":"Request error connecting to the Context Broker: 501"}
error when when I send a POST to iotagent-ul deployed via iotagent-ul helm chart.I get the following log via
kubectl logs pod/iotagent-ul-xxxxxx
:Following the iotagent-ul documentation to enable NGSIv2 it must be set
ngsiVersion
in contextBroker:So, I have modified:
However, the new pod status is
CrashLoopBackOff
and the log received viakubectl logs pod/iotagent-ul-xxxx
is:Any suggestions on how to properly configure NGSIv2?