Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changes to infrastructure.cells table #6184

Closed
jc-harrison opened this issue Jun 27, 2023 · 0 comments · Fixed by #6433
Closed

Changes to infrastructure.cells table #6184

jc-harrison opened this issue Jun 27, 2023 · 0 comments · Fixed by #6433
Labels
enhancement New feature or request FlowDB Issues related to FlowDB FlowMachine Issues related to FlowMachine refactoring

Comments

@jc-harrison
Copy link
Member

A few suggested additional columns for the infrastructure.cells table:

  • date_added (might need a better name): date that the cell was added to the cells table (not necessarily the same as the date that the cell was added to the network)
  • date_modified: Sometimes incorrect cell info may get corrected - it would be useful to be able to keep track of when this happens. Not sure whether we'd want to track changes to location separately from other changes.
  • additional_metadata: json field to capture additional information (cell info files from MNOs often include additional fields that don't fit into the existing columns in the cells table, which would be useful to have available in FlowDB)
  • to_exclude (or equivalently to_include): boolean field to record whether CDR events at this cell should be included in mobility analysis. We'd want to change flowmachine's JoinToLocation accordingly, to exclude these cells from the join. This would be useful when we suspect a cell location is incorrect, for example. It would be good to be able keep track of these excluded cells in the cells table (especially when updating the cell info), rather than needing to record them elsewhere.

Alternatively, instead of a date_modified column we could treat the cells table as append-only, and modify a cell record by adding a new row with incremented version and marking the old record as to_exclude. This would have the advantage of keeping a record of the history. We'd perhaps still want a date_excluded column, which would make it possible to reconstruct the contents of the cells table as it was on a previous date.

It would also be good to have an EXCLUDE constraint to ensure no two (non-excluded) rows with the same ID have overlapping date_of_first_service-date_of_last_service ranges. This would be facilitated by replacing the date_of_first_service and date_of_last_service fields with a single date range (or timestamp range) field.

@jc-harrison jc-harrison added enhancement New feature or request FlowMachine Issues related to FlowMachine FlowDB Issues related to FlowDB refactoring labels Jun 27, 2023
@jc-harrison jc-harrison mentioned this issue Jan 10, 2024
8 tasks
@mergify mergify bot closed this as completed in #6433 Jan 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request FlowDB Issues related to FlowDB FlowMachine Issues related to FlowMachine refactoring
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant