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

[Salesforce] Add pagination support for login_rest and logout_rest data streams #4866

Merged
merged 2 commits into from
Jan 11, 2023

Conversation

kush-elastic
Copy link
Collaborator

@kush-elastic kush-elastic commented Dec 19, 2022

What does this PR do?

In the current Salesforce Integration, we don’t have pagination support for login-rest and logout-rest data streams. So if in any case, we have a response body with more than 2000 records, the next page is never called and the data will not be fetched.

Solution:
You can request the next batch of records using the provided URL with your instance and session information, and repeat until all records have been retrieved. These requests use nextRecordsUrl and don’t include any parameters. The final batch of records doesn’t have a nextRecordsUrl field and return true value for field done

Checklist

  • I have reviewed tips for building integrations and this pull request is aligned with them.
  • I have verified that all data streams collect metrics or logs.
  • I have added an entry to my package's changelog.yml file.
  • I have verified that Kibana version constraints are current according to guidelines.

Related issues

@kush-elastic kush-elastic changed the title [Salesforce] Add pagination support for login_rest and logout_rest [Salesforce] Add pagination support for login_rest and logout_rest data streams Dec 19, 2022
@elasticmachine
Copy link

elasticmachine commented Dec 19, 2022

💚 Build Succeeded

the below badges are clickable and redirect to their specific view in the CI or DOCS
Pipeline View Test View Changes Artifacts preview preview

Expand to view the summary

Build stats

  • Start Time: 2022-12-19T12:43:42.684+0000

  • Duration: 17 min 34 sec

Test stats 🧪

Test Results
Failed 0
Passed 12
Skipped 0
Total 12

🤖 GitHub comments

Expand to view the GitHub comments

To re-run your PR in the CI, just comment with:

  • /test : Re-trigger the build.

@elasticmachine
Copy link

🌐 Coverage report

Name Metrics % (covered/total) Diff
Packages 100.0% (2/2) 💚
Files 100.0% (2/2) 💚 6.667
Classes 100.0% (2/2) 💚 6.667
Methods 100.0% (26/26) 💚 15.0
Lines 96.404% (429/445) 👍 0.382
Conditionals 100.0% (0/0) 💚

@agithomas
Copy link
Contributor

Please complete the internal review. Send me a note once it is done

@harnish-elastic
Copy link
Contributor

Please complete the internal review. Send me a note once it is done

We are not able to provide approval from the Elastic account. It seems like still, some access is missing for the Elastic GitHub integration repo. Hence we are not able to approve. We have raised an IT ticket for the same.

@agithomas
Copy link
Contributor

Please complete the internal review. Send me a note once it is done

We are not able to provide approval from the Elastic account. It seems like still, some access is missing for the Elastic GitHub integration repo. Hence we are not able to approve. We have raised an IT ticket for the same.

You may consider cancelling the IT ticket created for this purpose as it is not needed at the moment . If you decide to proceed, kindly ensure atleast one of the Elastic team member performs the code review.

cc @rameshelastic

@harnish-elastic
Copy link
Contributor

Please complete the internal review. Send me a note once it is done

We are not able to provide approval from the Elastic account. It seems like still, some access is missing for the Elastic GitHub integration repo. Hence we are not able to approve. We have raised an IT ticket for the same.

You may consider cancelling the IT ticket created for this purpose as it is not needed at the moment . If you decide to proceed, kindly ensure atleast one of the Elastic team member performs the code review.

cc @rameshelastic

Currently, only Kush has access, But when he raises the PR, others are not able to review it. So we need at least one more person who has the access to reviewers and approval.

@harnish-elastic
Copy link
Contributor

LGTM! Approved. ✅

Copy link
Contributor

@agithomas agithomas left a comment

Choose a reason for hiding this comment

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

Approved

@elasticmachine
Copy link

Package salesforce - 0.2.1 containing this change is available at https://epr.elastic.co/search?package=salesforce

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.

4 participants