sql icon indicating copy to clipboard operation
sql copied to clipboard

Enable transport API to accept requests from other plugins while running background jobs

Open zhongnansu opened this issue 2 years ago • 0 comments

Is your feature request related to a problem? Please describe.

Plugins such as Observability depends on PPL to generate metrics and retrieve data for visualization. The requests are from Kibana with auth and uses REST API, which is fine. However there could be use case where observability needs to run background PPL query. At that time, there's no auth info can be attached for REST call.

Describe the solution you'd like Expose transport API, which can be used for transport call from other plugins within background job. It runs as superadmin mode with user context(role, tenant, backend_role, etc)

The following changes need to be made for this feature to work

  • [x] https://github.com/opensearch-project/sql/issues/667
  • [ ] Add SQL Transport interface, and refactor existing Rest Interface to move handler logic to transport handler
  • [ ] request/response model in common-utils
  • [ ] integration from caller plugin

Describe alternatives you've considered A clear and concise description of any alternative solutions or features you've considered.

Additional context Add any other context or screenshots about the feature request here.

zhongnansu avatar Mar 29 '22 23:03 zhongnansu