orchestracities / ngsi-timeseries-api

QuantumLeap: a FIWARE Generic Enabler to support the usage of NGSIv2 (and NGSI-LD experimentally) data in time-series databases
https://quantumleap.rtfd.io/
MIT License
38 stars 49 forks source link

pandora box surfacing #639

Open chicco785 opened 2 years ago

chicco785 commented 2 years ago

Proposed changes

@StWiemann found out that upgrade from 0.8.2 generate some issues. for some reason when inserting new data in a old table, instanceId column is not added, generating issues. (this could be actually due to some change in cratedb, we haven't handled properly) this pr surface the issue in bc testing (at least it should). moreover, this pr, by fixing a configuration issue in the backward test script, also evidenced an issue with a PR just merged (#564):

The pr is not yet a fix. It's just to reproduced in a controlled environment the issue.

Types of changes

What types of changes does your code introduce to the project? Put an x in the boxes that apply

Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.

Further comments

N/A

"Martel Open Source Software Individual Contributor License Agreement"
"Contributing to QuantumLeap"
"QuantumLeap Release Notes"
github-actions[bot] commented 2 years ago

CLA Assistant Lite bot All contributors have signed the CLA ✍️

chicco785 commented 2 years ago

actually the change from dynamic to strict was introduced my me here: https://github.com/orchestracities/ngsi-timeseries-api/commit/57f721f74610028bd658eb7b2f45bfbe6d415957

the reason why this is now an issue, is that instanceId it's not tracked in metadata, thus, we don't know if it is missing or not, when adding new data.

c0c0n3 commented 2 years ago

@chicco785 cool, thanks for this! We should keep a lid on the box :-)

Let's merge this PR when we've got a fix for #638. Here's what I have in mind

  1. Fix #638. This should include tests to check instanceid is handled correctly (metadata, etc.) but it can leave out backward compat tests.
  2. Rebase this PR on the fix. Tweak backward compat tests if needed. At this point the currently failing tests should pass.

Thoughts?

chicco785 commented 2 years ago

sure, this pr should be use as a base for the fix, since it reproduces the issue.