Details
-
Type: Monitor
-
Status: Closed
-
Priority: Major
-
Resolution: Done
-
Affects Version/s: None
-
Fix Version/s: None
-
Component/s: FIWARE-TECH-HELP
-
Labels:
-
HD-Chapter:Unknown
-
HD-Enabler:Unknown
-
HD-Node:Unknown
Description
Created question in FIWARE Q/A platform on 04-10-2023 at 14:10
Please, ANSWER this question AT https://stackoverflow.com/questions/77230581/how-to-get-the-missing-table-schema-while-using-quantumleap-in-cratedb-using-ori
Question:
How to get the missing table Schema while using quantumleap in cratedb using orion LD context broker though the subscriptions are working?
Description:
{
"cols": [
"schema_name"
],
"rows": [
[
"blob"
],
[
"doc"
],
[
"information_schema"
],
[
"pg_catalog"
],
[
"sys"
]
],
"rowcount": 5,
"duration": 7.289699
}
http://crate/_sql
{"stmt":"SHOW SCHEMAS"}for read schemas. you can see there is no schema formed in "mtmytenant" (my service hearder is mytenant).
now see the below. You can see the subscribtion but there is no table schema. BUt i get all the subscribed sensor values.
{
"cols": [
"table_name"
],
"rows": [
[
"etdummydevice1"
],
[
"etdummydevice2"
],
[
"md_ets_metadata"
]
],
"rowcount": 3,
"duration": 24.486307
}
According to the doc https://ngsi-ld-tutorials.readthedocs.io/en/latest/time-series-data.html ,
Schema names are formed with the mt prefix followed by NGSILD-Tenant header in lower case. The IoT Agent is forwarding measurements from the dummy IoT devices, with the NGSILD-Tenant header openiot. These are being persisted under the mtopeniot schema.
If the mtopeniot does not exist, then the subscription to QuantumLeap has not been set up correctly. Check that the subscription exists, and has been configured to send data to the correct location.
here openiot is the header.
Post with headers NGSILD-Tenant=mytenant, Content-Type=application/ld+json
http://localhost:1026/ngsi-ld/v1/subscriptions/
{
"description": "Notify me of Dummydevice1 changes",
"type": "Subscription",
"entities": [
],
"watchedAttributes": ["pilot_temperature"],
"notification": {
"attributes": ["location", "pilot_temperature"],
"format": "normalized",
"endpoint":
},
"@context": "http://context:3000/data-models/ngsi-context.jsonld"
}
This works perfectly with NSGI v2 I am getting all the table schemas but with NGSI LD it is a bit problem. If anyone solved this. As in the tutorial if I did, still the schema names are not formed, but it does in the tutorials
Activity
- All
- Comments
- History
- Activity
- Transitions