StyraInc / regal

Regal is a linter and language server for Rego, bringing your policy development experience to the next level!

Home Page:https://docs.styra.com/regal

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

POC: embedding compiler state for `regal lint` command

anderseknert opened this issue · comments

And possibly other use cases. The issue this would address is the ~100 ms compilation time the bundle currently requires, and which is needed for all invocations of regal lint. The LSP doesn't suffer from this as it is a continuous process and one where prepared queries will make sure that compilation state is preserved between invocations.

@srenatus suggested taking a look at gob, and pointed to guide on that topic.

We should look into:

  1. If this works
  2. If it saves enough time to justify the added complexity
  3. Decide on whether to do this based on that