package status
import "github.com/open-policy-agent/opa/plugins/status"
Package status implements status reporting.
Index ¶
- Constants
- type Config
- type Plugin
- func Lookup(manager *plugins.Manager) *Plugin
- func New(parsedConfig *Config, manager *plugins.Manager) *Plugin
- func (p *Plugin) BulkUpdateBundleStatus(status map[string]*bundle.Status)
- func (p *Plugin) Reconfigure(_ context.Context, config interface{})
- func (p *Plugin) Start(ctx context.Context) error
- func (p *Plugin) Stop(ctx context.Context)
- func (p *Plugin) UpdateBundleStatus(status bundle.Status)
- func (p *Plugin) UpdateDiscoveryStatus(status bundle.Status)
- type UpdateRequestV1
Constants ¶
const Name = "status"
Name identifies the plugin on manager.
Types ¶
type Config ¶
type Config struct { Service string `json:"service"` PartitionName string `json:"partition_name,omitempty"` }
Config contains configuration for the plugin.
func ParseConfig ¶
ParseConfig validates the config and injects default values.
type Plugin ¶
type Plugin struct {
// contains filtered or unexported fields
}
Plugin implements status reporting. Updates can be triggered by the caller.
func Lookup ¶
Lookup returns the status plugin registered with the manager.
func New ¶
New returns a new Plugin with the given config.
func (*Plugin) BulkUpdateBundleStatus ¶
BulkUpdateBundleStatus notifies the plugin that the policy bundle was updated.
func (*Plugin) Reconfigure ¶
Reconfigure notifies the plugin with a new configuration.
func (*Plugin) Start ¶
Start starts the plugin.
func (*Plugin) Stop ¶
Stop stops the plugin.
func (*Plugin) UpdateBundleStatus ¶
UpdateBundleStatus notifies the plugin that the policy bundle was updated. Deprecated: Use BulkUpdateBundleStatus instead.
func (*Plugin) UpdateDiscoveryStatus ¶
UpdateDiscoveryStatus notifies the plugin that the discovery bundle was updated.
type UpdateRequestV1 ¶
type UpdateRequestV1 struct { Labels map[string]string `json:"labels"` Bundle *bundle.Status `json:"bundle,omitempty"` // Deprecated: Use bulk `bundles` status updates instead Bundles map[string]*bundle.Status `json:"bundles,omitempty"` Discovery *bundle.Status `json:"discovery,omitempty"` }
UpdateRequestV1 represents the status update message that OPA sends to remote HTTP endpoints.
Source Files ¶
- Version
- v0.13.5
- Published
- Aug 30, 2019
- Platform
- js/wasm
- Imports
- 9 packages
- Last checked
- 2 minutes ago –
Tools for package owners.