Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

opa build: Containing data inside a Wasm file #6809

Open
shkup opened this issue Mar 28, 2024 · 3 comments
Open

opa build: Containing data inside a Wasm file #6809

shkup opened this issue Mar 28, 2024 · 3 comments

Comments

@shkup
Copy link

shkup commented Mar 28, 2024

When I create a regular bundle I can contain there both data and policy.
I would like to request a similar option when creating a wasm file.
Sometimes the data is a json file that reading it, parsing it and set it by a loadData call is cumbersome and costly in terms of performance.
Also, it will be nice if the build -t wasmcommand will create a wasm directly rather a bundle file that you need to extract the wasm file from (Not the end of the work though but I think makes sense that this is like a "compilation" product).

@shkup shkup changed the title Containing data inside the WASM Containing data inside a WASM Mar 28, 2024
@srenatus
Copy link
Contributor

That's a neat idea. But would setData() overwrite the data or error?

Also, this is a feature request for OPA, I think: it builds the wasm module, after all. It might even be doable without having to change the SDKs (like this one).

I'll transfer the issue 🔄

@srenatus srenatus transferred this issue from open-policy-agent/npm-opa-wasm Jun 11, 2024
@srenatus srenatus changed the title Containing data inside a WASM opa build: Containing data inside a Wasm file Jun 11, 2024
@anderseknert
Copy link
Member

Also, it will be nice if the build -t wasmcommand will create a wasm directly rather a bundle file that you need to extract the wasm file from (Not the end of the work though but I think makes sense that this is like a "compilation" product).

Agreed, same for -t plan. If we can avoid users having to repeat extra steps in these flows, we should.

Copy link

stale bot commented Jul 12, 2024

This issue has been automatically marked as inactive because it has not had any activity in the last 30 days. Although currently inactive, the issue could still be considered and actively worked on in the future. More details about the use-case this issue attempts to address, the value provided by completing it or possible solutions to resolve it would help to prioritize the issue.

@stale stale bot added the inactive label Jul 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants