opensearch-project / OpenSearch

🔎 Open source distributed and RESTful search engine.
https://opensearch.org/docs/latest/opensearch/index/
Apache License 2.0
9.61k stars 1.76k forks source link

Opensearch serverless image #10001

Open gondalez opened 1 year ago

gondalez commented 1 year ago

Is your feature request related to a problem? Please describe

It is handy to use the Opensearch docker image for local testing during development to get quick feedback if features will work against AWS Opensearch.

AWS Opensearch serverless recently became available. It has a restricted set of api operations and plugins when compared to regular opensearch.

Using the (non-serverless) Opensearch docker image will not flush out usages of unsupported operations while in dev.

Describe the solution you'd like

A docker image that has the same limitations as AWS Opensearch Serverless, similar to Dynamo DB Local.

Describe alternatives you've considered

I looked around to see if AWS provide a docker image for serverless, but could not find one.

Apologies if this request doesn't really belong here (since it is not directly affiliated with AWS). But still, any advice would be appreciated 🙏 :)

Additional context

-

dblock commented 1 year ago

I think an in image that only includes Serverless-compatible APIs is not a bad idea, however it might be tricky to implement. Serverless, for example, doesn't have the concept of nodes, or has SigV4. I would open a feature request with AWS support either way.

gaiksaya commented 1 year ago

I think an in image that only includes Serverless-compatible APIs is not a bad idea, however it might be tricky to implement. Serverless, for example, doesn't have the concept of nodes, or has SigV4. I would open a feature request with AWS support either way.

Right! Restricting specific APIs should come from underlying software. Docker is one of the distribution created using the product (tarball today). In order to create such image basic requirement would be to have a opensearch-serverless as a separate product. Moving this request to OpenSearch repository to see if they have any future plans for this. Thanks!

cc: @peterzhuamazon @bbarani @CEHENKLE

gkamat commented 1 year ago

The most appropriate solution for this would be for the Serverless team to implement a proxy that emulates their service's restrictions: for instance it would trap unsupported calls, require SigV4, limit plugins, etc. These restrictions might change over time for the service, hence that team would be the best arbiter in this regard.

The proxy method would work with both standard OpenSearch clusters as well as OpenSearch running within Docker.

gondalez commented 1 year ago

@gkamat that is what I had imagined, more of a simulator to be used for development and test workflows. Much like Dynamo DB Local.

dblock commented 1 year ago

@gkamat that is what I had imagined, more of a simulator to be used for development and test workflows. Much like Dynamo DB Local.

+1 to this. I've been using OpenSearch open-source as that simulator though and just living with having to find out the limitations by running my integration tests against an actual serverless environment ;)