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

[FEATURE]Show IP2Geo datasource create/update progress percentage #445

Open
heemin32 opened this issue Sep 15, 2023 · 2 comments
Open

[FEATURE]Show IP2Geo datasource create/update progress percentage #445

heemin32 opened this issue Sep 15, 2023 · 2 comments
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@heemin32
Copy link
Collaborator

Is your feature request related to a problem?
Show IP2Geo datasource create/update progress percentage

What solution would you like?
When user call GET API of IP2Geo datasource, it shows how much percentage of the update are done

What alternatives have you considered?
Not showing create/update progress information

Do you have any additional context?

@heemin32 heemin32 added enhancement New feature or request good first issue Good for newcomers labels Sep 15, 2023
@alankar-asthana
Copy link

Hello @heemin32
From where to get started?

Thanks

@heemin32
Copy link
Collaborator Author

Hi @alankar-asthana,

The creation/update is happening in https://github.com/opensearch-project/geospatial/blob/main/src/main/java/org/opensearch/geospatial/ip2geo/jobscheduler/DatasourceUpdateService.java#L63

If we can get the size of file in advance, we can calculate how much of data is processed and store the completed percentage in memory.

In GET API, we can make a call to the node who is creating or updating datasource to get the percentage value and return it in response.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

3 participants