I build a HTTP backend datasource plugin from this documentation that have to send HTTP requests to several servers.
- Get business value from an API
- Get data value from Elasticsearch database
I have a previous HTTP datasource plugin that makes both but it’s now obsolete (HTTP request to Elasticsearch triggers CORS issues).
I added the previous frontend part in the new backend plugin.
I can send HTTP request from the frontend part of the plugin into my business API.
I can send HTTP request from the frontend part into Elasticsearch.
I would like to send those requests into Elasticsearch from the backend part of the plugin.
I can now see data from Elasticsearch with the
datasource.ts file; How can I switch the app to use the
datasource.go file ?
Is it possible to send requests to my business API from the front part and to my Elasticsearch database from the backend part ?
PS : I noticed that the “Save and test” button in the ConfigEditor runs the datasource.ts instead of the datasource.go file.