We previously aligned that for Spade to Polling spade-proxy on aggregates to pass to SPs, Spade would poll from a S3 bucket where we would write the details for an aggregate. This polling will happen on an agreed timeframe (TBD - @ribasushi is there any recommendation from Spade or based on our previous usage of dagcargo?).
During the given timeframe for polling we can have more than one aggregates ready to go. Therefore, we need to make sure that all of them are ready to be polled. S3 client sadly does not support append to a already existing file, which would make our lives much easier. We are currently writing temporary files keyed as YYYY-MM-DD HH:MM:00 commPcid and have a PR with a cron job that kicks in and merges all these files on a single file keyed as YYYY-MM-DD HH:MM:00 that can be polled. This solution has some potential issues:
- If we kick the cron before the timeframe is over another aggregate can be in the process of being written.
- Spade would need to poll with some delay so that thing is already there
Alternatively, we could allow Spade to perform a Bucket list with prefix YYYY-MM-DD HH:MM:00 once time is ready and then perform a get in each key. This makes Spade job a tiny bit more complex on read, but is less susceptible to weirdness with times. This could also happen via an API call by Spade, where spade-proxy exposes an endpoint and does the merge of available aggregates.
For the content format, we are looking at a JSON file with format and I will create a separate issue to discuss that
Thoughts @ribasushi @alanshaw @xinaxu
We previously aligned that for Spade to Polling spade-proxy on aggregates to pass to SPs, Spade would poll from a S3 bucket where we would write the details for an aggregate. This polling will happen on an agreed timeframe (TBD - @ribasushi is there any recommendation from Spade or based on our previous usage of dagcargo?).
During the given timeframe for polling we can have more than one aggregates ready to go. Therefore, we need to make sure that all of them are ready to be polled. S3 client sadly does not support append to a already existing file, which would make our lives much easier. We are currently writing temporary files keyed as
YYYY-MM-DD HH:MM:00 commPcidand have a PR with a cron job that kicks in and merges all these files on a single file keyed asYYYY-MM-DD HH:MM:00that can be polled. This solution has some potential issues:Alternatively, we could allow Spade to perform a Bucket list with prefix
YYYY-MM-DD HH:MM:00once time is ready and then perform a get in each key. This makes Spade job a tiny bit more complex on read, but is less susceptible to weirdness with times. This could also happen via an API call by Spade, wherespade-proxyexposes an endpoint and does the merge of available aggregates.For the content format, we are looking at a JSON file with format and I will create a separate issue to discuss that
Thoughts @ribasushi @alanshaw @xinaxu