Class UsagePolicyImportService

java.lang.Object
com.axelor.ai.governance.usage.UsagePolicyImportService

public class UsagePolicyImportService extends Object
Usage policies from YAML, one file each, keyed by name.

A file holds a description, active, whether it is global, the roles it applies to by name, the groups and users by code, and its tokenQuotaMonthly and rateLimit. Usage policies seed after the roles they name.

Overwriting replaces the policy's content with the file's, keeping the record. A file naming anything that is none, or a key that is none, is refused whole.