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

[exporter/elasticsearch] Add reliability tests #31848

Merged
merged 13 commits into from
Apr 15, 2024

Conversation

lahsivjar
Copy link
Contributor

Description: Adds integration tests for the elasticsearch exporter.

Link to tracking Issue: N/A

Testing: N/A

Documentation: N/A

I have not added a changelog because the contributing guidelines indicated that we might not require any for the changes in this PR.

return rCancel
}

func sendLogs(t *testing.T, target, uid string, logs, agents int) {
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 Reviewers] I wanted to use telemetrygen here instead of writing something new but it is only exposed as a command. Does it make sense to refactor telemetrygen as a follow-up and make it a bit easier to use as a package?

Copy link
Contributor

@ycombinator ycombinator left a comment

Choose a reason for hiding this comment

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

Left a few minor suggestions. Tests themselves LGTM - it's really nice to have these in place!

Copy link
Contributor

@axw axw left a comment

Choose a reason for hiding this comment

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

Looks good, just a couple of minor comments.

Copy link
Contributor

@ycombinator ycombinator left a comment

Choose a reason for hiding this comment

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

LGTM.

I know you're trying to change the ES mock to count the number of bulk requests and try to change the response status based on that. If that works out without too much complexity, 👍. Otherwise, I'm OK with the current implementation.

@lahsivjar
Copy link
Contributor Author

@JaredTan95 Can you help with a review on the PR when you get the chance?

Copy link
Contributor

@carsonip carsonip left a comment

Choose a reason for hiding this comment

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

koanf dep not dropped after latest commit. go mod tidy maybe? Otherwise lgtm

@lahsivjar
Copy link
Contributor Author

lahsivjar commented Apr 4, 2024

@JaredTan95 @bryan-aguilar 👋 folks, any chance I could get this one reviewed?

@ycombinator
Copy link
Contributor

Also pinging @open-telemetry/collector-contrib-approvers in case someone is available to review this PR and move it forward. Thank you!

@bryan-aguilar
Copy link
Contributor

bryan-aguilar commented Apr 4, 2024

You'll probably need to do a rebase. Some changes have been made on main to update the go versions that are causing go vuln check to fail.

I don't think this would be a blocker but did you consider integrating with the Collector testbed instead? It has a lot of the scaffolding already to create a collector instance and custom data generators and validators.

@bryan-aguilar bryan-aguilar added the Skip Changelog PRs that do not require a CHANGELOG.md entry label Apr 4, 2024
Copy link
Contributor

@ycombinator ycombinator 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 incorporating the testbed. Just left a nit, otherwise LGTM once @bryan-aguilar's comments are addressed.

@lahsivjar
Copy link
Contributor Author

@bryan-aguilar @ycombinator Addressed the review comments.

@bryan-aguilar
Copy link
Contributor

Porto links are out of date, please run "make goporto" and commit the changes in this PR.

@lahsivjar
Copy link
Contributor Author

@bryan-aguilar Fixed all the lints I could find. Hope all should be green now, requires your approval to build the other workflows 🙏

@lahsivjar
Copy link
Contributor Author

Apologies for so much noise here, I have now run make checks which should hopefully cover all bases.

@bryan-aguilar
Copy link
Contributor

Looks like it needs another tidy

go: updates to go.mod needed; to update it:
	go mod tidy
go: updates to go.mod needed; to update it:
	go mod tidy
/home/runner/work/opentelemetry-collector-contrib/opentelemetry-collector-contrib/.tools/govulncheck ./...
govulncheck: loading packages: err: exit status 1: stderr: go: updates to go.mod needed; to update it:
	go mod tidy

@lahsivjar
Copy link
Contributor Author

Looks like it needs another tidy

Some version changes were merged and the branch got outdated. I have updated with main and ran another tidy.

@bryan-aguilar bryan-aguilar added the ready to merge Code review completed; ready to merge by maintainers label Apr 12, 2024
@mx-psi mx-psi merged commit 03a96a4 into open-telemetry:main Apr 15, 2024
175 checks passed
@github-actions github-actions bot added this to the next release milestone Apr 15, 2024
@lahsivjar lahsivjar deleted the integration-tests branch April 15, 2024 09:52
rimitchell pushed a commit to rimitchell/opentelemetry-collector-contrib that referenced this pull request May 8, 2024
…ry#32171)

**Description:** 

This PR proposes adding @ycombinator as a codeowner for the
`elasticsearch` exporter component, being an [employee of
Elastic](https://www.linkedin.com/company/elastic-co/people/?keywords=shaunak)
and also meeting the codeowner
[requirements](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/main/CONTRIBUTING.md#requirements):

1. [Be a member of the OpenTelemetry
organization.](https://github.com/open-telemetry/community/blob/main/community-membership.md#member)
   * https://github.com/orgs/open-telemetry/people?query=ycombinator
2. (Code Owner Discretion) It is best to have resolved an issue related
to the component, contributed directly to the component, and/or review
component PRs. How much interaction with the component is required
before becoming a Code Owner is up to any existing Code Owners.
* Resolved
open-telemetry#26647
via
open-telemetry#29619
* Reviewed
open-telemetry#31553
* Contributed
open-telemetry#31694
as follow up to
open-telemetry#31553
* Reviewed
open-telemetry#31848
rimitchell pushed a commit to rimitchell/opentelemetry-collector-contrib that referenced this pull request May 8, 2024
**Description:** Adds integration tests for the elasticsearch exporter.

**Link to tracking Issue:** N/A

**Testing:** N/A

**Documentation:** N/A

I have not added a changelog because the contributing guidelines
indicated that we might not require any for the changes in this PR.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
exporter/elasticsearch ready to merge Code review completed; ready to merge by maintainers Skip Changelog PRs that do not require a CHANGELOG.md entry
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

8 participants