Skip to content

Multiple OCKOutcomes are not sent to MongoDB sequentially #12

@shawnpatelbt

Description

@shawnpatelbt

Hi HyperProtect SDK Team,

I'm using a OCKOutcome to store my data to send to the Mongo backend, however, I've been facing a payload too large error. My solution around the problem was to wrap my data in multiple outcomes (it ended up being 8 outcomes with a 50,000 character string each) and to send those. Since CareKit uses a revision record to send the data to Mongo, when I tried adding all my outcomes to an array, I faced the same error. My solution around this was to create my own sequential system for all 8 outcomes. This works without the presence of an error. But when an error occurs in the upload (no internet), the outcome is still saved to CoreData. In this case, all future uploads will fail to work as the revision payload will always be too large (as the CoreData store contains the outcomes that failed to sync with MongoDB). Is there another way around this or is this something the team is working to fix (ideally a fix to the payload limit as I believe this is way lower than Mongo's limit of a 16mb document)?

Thanks,
Shawn

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions