Open rajrahul opened 3 years ago
The main problem is that CUE's evaluator is not concurrency safe yet. This means you need to lock many of the Go functions so that separate API requests are not processing CUE at the same time.
The intention is to eventually change this.
Other options are:
cue
CLI with os.Exec
, certainly less performant than other options.Generating OpenAPI for validation is a good idea. For scripting there are no alternatives it looks like.
This may indeed be useful.
It would be good to write a proposal for this, with use cases, API etc.
I would like to integrate cue-lang with our java/python services, I created a REST server in golang embedding all cue-lang dependencies to achieve this. We have multiple use cases like transforming JSON documents, validations and possibly policy evaluations.
Can such a REST service be shipped with the standard cue release? It could be run as a sidecar container, and will make it easier for other language developers in getting started without a golang wrapper. I checked OPA and it includes such a docker image.
Any recommended approach to this problem?