Skip to content

feat: support max kB in upload batching #600

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

Merged
merged 1 commit into from
Jul 15, 2022
Merged

feat: support max kB in upload batching #600

merged 1 commit into from
Jul 15, 2022

Conversation

oscb
Copy link
Contributor

@oscb oscb commented Jul 13, 2022

No description provided.

const result: any[] = array.reduce(
(chunks: any[][], item: any, index: number) => {
if (maxKB !== undefined) {
rollingKBSize += sizeOf(item);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

wont this be more accurate to do in plain bytes rather than kb? we wont have to do the / 1024 everytime we add bytes that way

@oscb oscb merged commit 3dc1957 into master Jul 15, 2022
@oscb oscb deleted the user/oscb/batchMax branch July 15, 2022 20:47
oscb pushed a commit that referenced this pull request Jul 15, 2022
## [@segment/analytics-react-native-v2.4.0](https://github.com/segmentio/analytics-react-native/compare/@segment/analytics-react-native-v2.3.2...@segment/analytics-react-native-v2.4.0) (2022-07-15)

### Features

* spin off the queue handling into a reusable plugin ([#502](#502)) ([55d7988](55d7988))
* support max kB in upload batching ([#600](#600)) ([3dc1957](3dc1957))

### Bug Fixes

* add export for SegmentClient ([#606](#606)) ([ff094f5](ff094f5))
* timeline safe processing events for destinations ([#604](#604)) ([78dcd0e](78dcd0e))
* use storePersistor option in QueueFlushingPlugin ([#602](#602)) ([f7be269](f7be269))
@oscb
Copy link
Contributor Author

oscb commented Jul 15, 2022

🎉 This PR is included in version @segment/analytics-react-native-v2.4.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@oscb oscb added the released label Jul 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants