Sync service #34
Labels
No labels
Agent/Chrome-Android
Agent/Chrome-Desktop
Agent/Chrome-iOS
Agent/Firefox-Android
Agent/Firefox-Desktop
Agent/Firefox-iOS
Agent/Safari-Desktop
Agent/Safari-iOS
Code/Backend
Code/DevOps
Code/Frontend
Compat/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Security
Kind/Testing
Priority
Critical
Priority
High
Priority
Low
Priority
Medium
Reviewed
Confirmed
Reviewed
Duplicate
Reviewed
Invalid
Reviewed
Won't Fix
Status
Abandoned
Status
Blocked
Status
Need More Info
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
overdrives/chambersbr#34
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Food for thought:
i) Use in-memory cache(redis, memcached) for user's favorites.
ii) Use a caching layer -> on a dedicated service retrieve projects, authors and related data from the API as JSON files*, transform and store them as my own entity with the properties as I need them(aggregate information scattered across requests into one entity) to my DB and fetch from there. Depending how fresh the data needs to be, retrieve from the API accordingly.
*their website claims they would provide JSON files updated daily with whole tables. I could use those files instead of making requests timed by a cronjob which could overload their system unnecessarily.
Originally posted by @aniram in aniram/cidadon#6 (comment)
Check out #24 on how I could verify when to update the cache.
Cache systemto Cache service@aniram wrote in aniram/cidadon#34 (comment):
Nevermind, the HEAD request does not return X-Total-Count.
The structure between the CSV and JSON files differ.
For example in the JSON file "ultimoStatus" is an object while in the CSV it has been flattened out to single keys like "ultimoStatus_dataHora" and "ultimoStatus_despacho". Another difference is that the CSV contains "ultimoStatus_idOrgao" while this key inside the JSON file is a key called "codOrgao" on the "ultimoStatus" object.
Also the The CSV is separated by semicolons so in order to read it with sqlite the mode must be set to CSV AND the separator must be set to semicolon like so
.separator ;Cache serviceto Sync serviceThe offline API does not return data on the history of propositions.
TODO
The CSV files are not typed, everything is a string so I'll go with the JSON files.
aniram referenced this issue2026-05-10 19:38:45 +00:00
TODO
Currently the sync service works but has a few quirks that have to be addressed later: