config_statistics

package
v2.0.2+incompatible Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 9, 2020 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ConfigStat              = ConfigStatistics{IntervalClearOutStatisCache: 180, StatisticsInterval: 60}
	NAMED_CONFIG_PATH       = `/replicated/jail/named/etc/named.conf`
	REGEX_PURE_IPV4         = `((\d){1,3}\.){3}(\d){1,3}$`
	REGEX_PURE_IPV4_RANGE   = `((\d){1,3}\.){3}(\d){1,3}\/(\d){1,3}$`
	REGEX_PURE_IP_V6        = `` /* 1904-byte string literal not displayed */
	REGEX_PURE_IP_V6_RANGE  = `` /* 1257-byte string literal not displayed */
	REGEX_VIEW              = `^view.+\".+\"`
	FORMAT_ACL_CLIENTS      = "acl _TrafficStatisticsAgent_Clients"
	FORMAT_ACL_SERVERS      = "acl _TrafficStatisticsAgent_Servers"
	FORMAT_PURE_ACL_CLIENTS = "_TrafficStatisticsAgent_Clients"
	FORMAT_MATCH_CLIENTS    = "match-clients"
	ANY                     = "any"
	PREFIX_ACL              = "acl"
	REGEX_ACL_NAME          = `^acl .+ {`

	RegPureIpv4, _      = regexp.Compile(REGEX_PURE_IPV4)
	RegPureIpv4Range, _ = regexp.Compile(REGEX_PURE_IPV4_RANGE)
	RegPureIpv6, _      = regexp.Compile(REGEX_PURE_IP_V6)
	RegPureIpv6Range, _ = regexp.Compile(REGEX_PURE_IP_V6_RANGE)
	RegAclName, _       = regexp.Compile(REGEX_ACL_NAME)
	ACLMap              = make(map[string][]string, 0)
)

Functions

func CollectMapACL

func CollectMapACL()

func Init

func Init()

func ReadACLInNamedConfig

func ReadACLInNamedConfig() ([]*net.IPNet, []*net.IPNet, []string, []string, map[int]map[string][]string)

Types

type ConfigStatistics

type ConfigStatistics struct {
	StatisticsDestination        string        `json:"statistics_destination"`
	StatisticsInterval           time.Duration `json:"statistics_interval"`
	MaximumClients               int           `json:"maximum_clients"`
	UrlAnnouncementDeployFromBam string        `json:"url_announcement_bam_deploy"`
	IntervalClearOutStatisCache  int           `json:"interval_clear_outstatis_cache"`
}

func LoadConfiguration

func LoadConfiguration(file string) ConfigStatistics

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL