Documentation
¶
Index ¶
- Variables
- type Config
- func (*Config) Descriptor() ([]byte, []int)
- func (m *Config) GetCommunity() string
- func (m *Config) GetDynamicRepititions() bool
- func (m *Config) GetMaxIterations() int32
- func (m *Config) GetMaxRepetitions() int32
- func (m *Config) GetNonRepeaters() int32
- func (m *Config) GetPort() uint64
- func (m *Config) GetRetries() int32
- func (m *Config) GetTimeout() *duration.Duration
- func (m *Config) GetVersion() SnmpVersion
- func (*Config) ProtoMessage()
- func (m *Config) Reset()
- func (m *Config) String() string
- func (m *Config) XXX_DiscardUnknown()
- func (m *Config) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Config) XXX_Merge(src proto.Message)
- func (m *Config) XXX_Size() int
- func (m *Config) XXX_Unmarshal(b []byte) error
- type Oid
- func (*Oid) Descriptor() ([]byte, []int)
- func (m *Oid) GetDynamic() bool
- func (m *Oid) GetHelp() string
- func (m *Oid) GetLookup() string
- func (m *Oid) GetName() string
- func (m *Oid) GetNumber() int64
- func (m *Oid) GetOid() string
- func (m *Oid) GetRepeater() bool
- func (m *Oid) GetReps() isOid_Reps
- func (m *Oid) GetType() metric.MetricType
- func (*Oid) ProtoMessage()
- func (m *Oid) Reset()
- func (m *Oid) String() string
- func (m *Oid) XXX_DiscardUnknown()
- func (m *Oid) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Oid) XXX_Merge(src proto.Message)
- func (*Oid) XXX_OneofWrappers() []interface{}
- func (m *Oid) XXX_Size() int
- func (m *Oid) XXX_Unmarshal(b []byte) error
- type Oid_Dynamic
- type Oid_Number
- type SnmpVersion
- type Task
- func (*Task) Descriptor() ([]byte, []int)
- func (m *Task) GetCompleted() *timestamp.Timestamp
- func (m *Task) GetConfig() *Config
- func (m *Task) GetCreated() *timestamp.Timestamp
- func (m *Task) GetExecutionTime() *duration.Duration
- func (m *Task) GetId() string
- func (m *Task) GetMetrics() []*metric.Metric
- func (m *Task) GetOids() []*Oid
- func (m *Task) GetStarted() *timestamp.Timestamp
- func (m *Task) GetStatus() shared.Status
- func (m *Task) GetTags() map[string]*any.Any
- func (m *Task) GetType() Type
- func (*Task) ProtoMessage()
- func (m *Task) Reset()
- func (m *Task) String() string
- func (m *Task) XXX_DiscardUnknown()
- func (m *Task) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Task) XXX_Merge(src proto.Message)
- func (m *Task) XXX_Size() int
- func (m *Task) XXX_Unmarshal(b []byte) error
- type Type
Constants ¶
This section is empty.
Variables ¶
View Source
var SnmpVersion_name = map[int32]string{
0: "ZERO",
1: "VERSION1",
2: "VERSION2c",
3: "VERSION3",
}
View Source
var SnmpVersion_value = map[string]int32{
"ZERO": 0,
"VERSION1": 1,
"VERSION2c": 2,
"VERSION3": 3,
}
View Source
var Type_name = map[int32]string{
0: "GET",
1: "SET",
2: "BULKGET",
3: "WALK",
}
View Source
var Type_value = map[string]int32{
"GET": 0,
"SET": 1,
"BULKGET": 2,
"WALK": 3,
}
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Community string `protobuf:"bytes,1,opt,name=community,proto3" json:"community,omitempty"` Version SnmpVersion `protobuf:"varint,2,opt,name=version,proto3,enum=dnc.snmpc.SnmpVersion" json:"version,omitempty"` Port uint64 `protobuf:"varint,3,opt,name=port,proto3" json:"port,omitempty"` Timeout *duration.Duration `protobuf:"bytes,4,opt,name=timeout,proto3" json:"timeout,omitempty"` Retries int32 `protobuf:"varint,5,opt,name=retries,proto3" json:"retries,omitempty"` MaxIterations int32 `protobuf:"varint,6,opt,name=max_iterations,json=maxIterations,proto3" json:"max_iterations,omitempty"` MaxRepetitions int32 `protobuf:"varint,7,opt,name=max_repetitions,json=maxRepetitions,proto3" json:"max_repetitions,omitempty"` NonRepeaters int32 `protobuf:"varint,8,opt,name=non_repeaters,json=nonRepeaters,proto3" json:"non_repeaters,omitempty"` DynamicRepititions bool `protobuf:"varint,9,opt,name=dynamic_repititions,json=dynamicRepititions,proto3" json:"dynamic_repititions,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*Config) Descriptor ¶
func (*Config) GetCommunity ¶
func (*Config) GetDynamicRepititions ¶
func (*Config) GetMaxIterations ¶
func (*Config) GetMaxRepetitions ¶
func (*Config) GetNonRepeaters ¶
func (*Config) GetRetries ¶
func (*Config) GetTimeout ¶
func (*Config) GetVersion ¶
func (m *Config) GetVersion() SnmpVersion
func (*Config) ProtoMessage ¶
func (*Config) ProtoMessage()
func (*Config) XXX_DiscardUnknown ¶
func (m *Config) XXX_DiscardUnknown()
func (*Config) XXX_Marshal ¶
func (*Config) XXX_Unmarshal ¶
type Oid ¶
type Oid struct { // Name of the Oid, SysDescr or something else, No translation is being done. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // The actual OID, 1.2.3.4.5.6.6.6.33 Oid string `protobuf:"bytes,2,opt,name=oid,proto3" json:"oid,omitempty"` // What kind of data is expected: string, int, bits, mac, ip... Type metric.MetricType `protobuf:"varint,3,opt,name=type,proto3,enum=dnc.metric.MetricType" json:"type,omitempty"` // Description of what is expected of the parser Help string `protobuf:"bytes,4,opt,name=help,proto3" json:"help,omitempty"` // Search the data and parse it, Regexp Lookup string `protobuf:"bytes,5,opt,name=lookup,proto3" json:"lookup,omitempty"` // the next two might be dropped. this is set in the config // True if the oid should be looked up with a repeater Repeater bool `protobuf:"varint,6,opt,name=repeater,proto3" json:"repeater,omitempty"` // reps is determined by this. If dyanmic a dynamic lookup is used // this dyanamic is done on ifIndex so it's not going to work for // some other OID group. // // Types that are valid to be assigned to Reps: // *Oid_Dynamic // *Oid_Number Reps isOid_Reps `protobuf_oneof:"reps"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
Oid is item thack can be fetched through SNMP
func (*Oid) Descriptor ¶
func (*Oid) GetDynamic ¶
func (*Oid) GetRepeater ¶
func (*Oid) GetType ¶
func (m *Oid) GetType() metric.MetricType
func (*Oid) ProtoMessage ¶
func (*Oid) ProtoMessage()
func (*Oid) XXX_DiscardUnknown ¶
func (m *Oid) XXX_DiscardUnknown()
func (*Oid) XXX_OneofWrappers ¶
func (*Oid) XXX_OneofWrappers() []interface{}
XXX_OneofWrappers is for the internal use of the proto package.
func (*Oid) XXX_Unmarshal ¶
type Oid_Dynamic ¶
type Oid_Dynamic struct {
Dynamic bool `protobuf:"varint,7,opt,name=dynamic,proto3,oneof"`
}
type Oid_Number ¶
type Oid_Number struct {
Number int64 `protobuf:"varint,8,opt,name=number,proto3,oneof"`
}
type SnmpVersion ¶
type SnmpVersion int32
const ( // First must be zero in proto3 // not a valid option for SNMPC SnmpVersion_ZERO SnmpVersion = 0 // Enum begins here. SnmpVersion_VERSION1 SnmpVersion = 1 SnmpVersion_VERSION2c SnmpVersion = 2 SnmpVersion_VERSION3 SnmpVersion = 3 )
func (SnmpVersion) EnumDescriptor ¶
func (SnmpVersion) EnumDescriptor() ([]byte, []int)
func (SnmpVersion) String ¶
func (x SnmpVersion) String() string
type Task ¶
type Task struct { // Unique ID of the task Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // Track the status of the Task Status shared.Status `protobuf:"varint,2,opt,name=status,proto3,enum=dnc.shared.Status" json:"status,omitempty"` // if type is BulkGet all oids will be fetched bulked in one request Type Type `protobuf:"varint,3,opt,name=type,proto3,enum=dnc.snmpc.Type" json:"type,omitempty"` // Oids to fetch and process Oids []*Oid `protobuf:"bytes,4,rep,name=oids,proto3" json:"oids,omitempty"` // When fetched the Oids becomes metrics Metrics []*metric.Metric `protobuf:"bytes,5,rep,name=metrics,proto3" json:"metrics,omitempty"` // Configuration for SNMP-Client Config *Config `protobuf:"bytes,6,opt,name=config,proto3" json:"config,omitempty"` Tags map[string]*any.Any `` /* 149-byte string literal not displayed */ // Set when the Task is created Created *timestamp.Timestamp `protobuf:"bytes,8,opt,name=created,proto3" json:"created,omitempty"` // Set when the progress of fetching it starts Started *timestamp.Timestamp `protobuf:"bytes,9,opt,name=started,proto3" json:"started,omitempty"` // Sets when DNC has fetched and parsed the data Completed *timestamp.Timestamp `protobuf:"bytes,10,opt,name=completed,proto3" json:"completed,omitempty"` // A difference between started and completed in MS ExecutionTime *duration.Duration `protobuf:"bytes,11,opt,name=execution_time,json=executionTime,proto3" json:"execution_time,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*Task) Descriptor ¶
func (*Task) GetCompleted ¶
func (*Task) GetCreated ¶
func (*Task) GetExecutionTime ¶
func (*Task) GetMetrics ¶
func (*Task) GetStarted ¶
func (*Task) ProtoMessage ¶
func (*Task) ProtoMessage()
func (*Task) XXX_DiscardUnknown ¶
func (m *Task) XXX_DiscardUnknown()
func (*Task) XXX_Unmarshal ¶
Click to show internal directories.
Click to hide internal directories.