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

Added PIT actions #155

Merged
merged 1 commit into from
Mar 29, 2023
Merged

Added PIT actions #155

merged 1 commit into from
Mar 29, 2023

Conversation

nhtruong
Copy link
Collaborator

Description

Added PIT Actions

Issues Resolved

closes #136

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

harshavamsi
harshavamsi previously approved these changes Mar 13, 2023
Copy link
Collaborator

@harshavamsi harshavamsi left a comment

Choose a reason for hiding this comment

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

@nhtruong this looks good to me. Will you raise a new PR to update the docs?

@nhtruong
Copy link
Collaborator Author

nhtruong commented Mar 14, 2023

@harshavamsi Imma raise a PR to bump the version before release.
Do we have to update the Users Guide for every new API update?

Copy link
Collaborator

@VachaShah VachaShah left a comment

Choose a reason for hiding this comment

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

What about open_point_int_time? Is it still supported?

@VachaShah
Copy link
Collaborator

@harshavamsi Imma raise a PR to bump the version before release. Do we have to update the Users Guide for every new API update?

I think it would be good to add the new API usage to the user guide, I understand the user guide might become increasingly large but maybe we can take those examples and add them to the docs website too?

USER_GUIDE.md Show resolved Hide resolved
Removed Legacy X-Pack Point-In-Time API

Signed-off-by: Theo Truong <[email protected]>
@nhtruong
Copy link
Collaborator Author

@dblock @harshavamsi @VachaShah Would you mind taking another look? All concerns have already been addressed

Copy link
Member

@dblock dblock left a comment

Choose a reason for hiding this comment

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

LGTM, minor nits.

@@ -24,7 +26,8 @@ Import the client:
`require 'opensearch'`

## Sample code

<a name="basic-usage" /></a>
Copy link
Member

Choose a reason for hiding this comment

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

GitHub markdown automatically creates #basic-usage.

index = :movies
client.indices.create(index: 'movies')

# CREATE 3 PITS
Copy link
Member

Choose a reason for hiding this comment

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

DON'T SHOUT :)

def all_pit_segments(arguments = {})
arguments = arguments.clone
headers = arguments.delete(:headers) || {}

Copy link
Member

Choose a reason for hiding this comment

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

Double space, ... we should really add rubocop.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I miss Rubocop. Will incorporate along with generated Ruby Client.

Copy link
Member

Choose a reason for hiding this comment

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

let(:expected_args) do
[
'POST',
'movies,books/_search/point_in_time',
Copy link
Member

@dblock dblock Mar 28, 2023

Choose a reason for hiding this comment

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

wait, this seems wrong! does it support multiple indexes like this?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Copy link
Member

Choose a reason for hiding this comment

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

Fancy!

@VachaShah VachaShah merged commit 2782def into opensearch-project:main Mar 29, 2023
@nhtruong nhtruong deleted the pit branch April 3, 2023 22:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[FEATURE] Point-in-time API endpoints
4 participants