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

Initial Commit for Advanced Batching #11544

Merged
merged 9 commits into from
Oct 2, 2020

Conversation

sarangan12
Copy link
Contributor

@sarangan12 sarangan12 commented Sep 29, 2020

@xirzec

This PR is to add fancy batch supporting for the search-documents SDK.

@sarangan12 sarangan12 requested a review from xirzec September 29, 2020 07:21
@ghost ghost added the Search label Sep 29, 2020
Copy link
Member

@xirzec xirzec left a comment

Choose a reason for hiding this comment

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

This looks great! I replied to your comment about how we can achieve hiding the constructor, which I think will be an easy change.

@sarangan12 sarangan12 marked this pull request as ready for review October 1, 2020 05:00
@sarangan12 sarangan12 requested a review from bterlson as a code owner October 1, 2020 05:00
import { createSpan } from "./tracing";
import { CanonicalCode } from "@opentelemetry/api";

const DEFAULT_BATCH_SIZE: number = 1000;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

For this release, we are not allowing the user to modify these values. For next release, we will decide on what is the actual logic to be used. (Batch size vs Threshold Size, Simple Retry Count vs Retry Policy )

* @param options Options to modify batch size, auto flush and flush window.
*
*/
constructor(client: SearchClient<T>, options: SearchIndexingBufferedSenderOptions = {}) {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

For this release, I am keeping the constructor just like Python

Copy link
Member

@xirzec xirzec left a comment

Choose a reason for hiding this comment

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

Thanks for adding the samples! Left some updated feedback.

Copy link
Member

@xirzec xirzec left a comment

Choose a reason for hiding this comment

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

Great work on this! I like the design here and I am looking forward to getting feedback from customers.

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