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

[APM] Migrate /test/apm_api_integration/tests/inspect/ to be deployment-agnostic API tests #198977

Open
rmyz opened this issue Nov 5, 2024 · 3 comments · May be fixed by #199963
Open

[APM] Migrate /test/apm_api_integration/tests/inspect/ to be deployment-agnostic API tests #198977

rmyz opened this issue Nov 5, 2024 · 3 comments · May be fixed by #199963
Assignees
Labels
Team:obs-ux-infra_services Observability Infrastructure & Services User Experience Team technical debt Improvement of the software architecture and operational architecture

Comments

@rmyz
Copy link
Contributor

rmyz commented Nov 5, 2024

API ESS Serverless Test files
GET /internal/apm/environments ESS./test/apm_api_integration/tests/inspect/inspect.spec.ts
@rmyz rmyz added Team:obs-ux-infra_services Observability Infrastructure & Services User Experience Team technical debt Improvement of the software architecture and operational architecture labels Nov 5, 2024
@iblancof iblancof self-assigned this Nov 12, 2024
@iblancof
Copy link
Contributor

The APM inspect test suite relies on Agent Configuration, which, based on my checks, isn’t available in Serverless. Therefore, we can’t migrate this to be deployment-agnostic.

1)    Serverless Observability - Deployment-agnostic api integration tests
   │       APM
   │         inspect
   │           Inspect feature
   │             "before all" hook in "Inspect feature":
   │
   │      ResponseError: security_exception
   │ 	Root causes:
   │ 		security_exception: action [indices:admin/create] is unauthorized for user [testing-internal] with effective roles [superuser] on restricted indices [.ml-config], this action is granted by the index privileges [create_index,manage,all]
   │       at SniffingTransport._request (node_modules/@elastic/transport/src/Transport.ts:602:17)
   │       at processTicksAndRejections (node:internal/process/task_queues:95:5)
   │       at /Users/ireneblanco/Desktop/Projects/kibana/node_modules/@elastic/transport/src/Transport.ts:708:22
   │       at SniffingTransport.request (node_modules/@elastic/transport/src/Transport.ts:705:14)
   │       at Indices.create (node_modules/@elastic/elasticsearch/src/api/api/indices.ts:290:12)
   │       at attemptToCreate (create_index_stream.ts:162:9)
   │       at handleIndex (create_index_stream.ts:228:5)
   │       at Transform.transform [as _transform] (create_index_stream.ts:238:13)
   │
   │
   │2)    Serverless Observability - Deployment-agnostic api integration tests
   │       APM
   │         inspect
   │           Inspect feature
   │             "after all" hook in "Inspect feature":
   │
   │      ResponseError: security_exception
   │ 	Root causes:
   │ 		security_exception: action [indices:admin/delete] is unauthorized for user [testing-internal] with effective roles [superuser] on restricted indices [.ml-config], this action is granted by the index privileges [delete_index,manage,all]
   │       at SniffingTransport._request (node_modules/@elastic/transport/src/Transport.ts:602:17)
   │       at processTicksAndRejections (node:internal/process/task_queues:95:5)
   │       at /Users/ireneblanco/Desktop/Projects/kibana/node_modules/@elastic/transport/src/Transport.ts:708:22
   │       at SniffingTransport.request (node_modules/@elastic/transport/src/Transport.ts:705:14)
   │       at Indices.delete (node_modules/@elastic/elasticsearch/src/api/api/indices.ts:394:12)
   │       at deleteIndex (delete_index.ts:45:5)
   │       at Transform.transform [as _transform] (delete_index_stream.ts:53:13)
   │
   │

cc: @crespocarlos

@iblancof
Copy link
Contributor

Reopening since we can run the tests with 8.0.0 instead of apm_8.0.0 (as suggested in #199817 (comment)), which includes the .ml-config index and isn’t compatible with serverless.

@iblancof iblancof reopened this Nov 13, 2024
@iblancof
Copy link
Contributor

The APM inspect test suite relies on Agent Configuration, which, based on my checks, isn’t available in Serverless. Therefore, we can’t migrate this to be deployment-agnostic.

I’ll exclude the test using Agent Configuration from the migration; the rest can be migrated using 8.0.0 instead of apm_8.0.0.

@iblancof iblancof linked a pull request Nov 13, 2024 that will close this issue
4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Team:obs-ux-infra_services Observability Infrastructure & Services User Experience Team technical debt Improvement of the software architecture and operational architecture
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants