opensearch-project / simple-schema

The purpose of this Plugin is to enhance open-search engine with user-domain schema by using GraphQL.
Apache License 2.0
6 stars 6 forks source link

embed graphiQL Console in the query-dashboards-workbench #59

Open YANG-DB opened 1 year ago

YANG-DB commented 1 year ago

In the query workbench plugin (https://github.com/opensearch-project/dashboards-query-workbench) Add a new GraphQL tab in addition to SQL/PPL/GraphQL query workbench which will contain the next open- source component https://github.com/graphql/graphiql console

ps48 commented 1 year ago

As of now, Graphiql provides three high level react components as follows:

The GraphiQLProvider components renders multiple context providers that encapsulate all state management The GraphiQLInterface component renders the UI that makes up GraphiQL The GraphiQL component is a combination of both the above components

To use the GraphiQL component, only requirement is to provide a graphql compatible endpoint. To add this to a Dashboards plugins we can create a pass through via node-hapi to the OpenSearch simple-scema endpoint.

Ref: https://github.com/graphql/graphiql/tree/main/packages/graphiql#usage