Documentation ¶
Overview ¶
* Copyright 2019-present Ciena Corporation * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License.
* Copyright 2019-present Ciena Corporation * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License.
* Copyright 2019-present Ciena Corporation * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License.
* Copyright 2019-present Ciena Corporation * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License.
* Copyright 2021-present Ciena Corporation * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License.
* Copyright 2019-present Ciena Corporation * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License.
Index ¶
- Variables
- func GetEnumString(msg *dynamic.Message, name string, value int32) (string, error)
- func GetEnumValue(val *dynamic.Message, name string) (string, error)
- func SetEnumValue(msg *dynamic.Message, name string, value string) error
- type AdapterInstance
- type ComponentInstance
- type Flow
- type FlowFieldFlag
- type LogFeature
- type LogLevel
- type OnuEthernetFrameExtendedPm
- type OnuStats
Constants ¶
This section is empty.
Variables ¶
var ( // Provide an array of all flags that can be used for iteration AllFlowFieldFlags = []FlowFieldFlag{ FLOW_FIELD_UNSUPPORTED_MATCH, FLOW_FIELD_UNSUPPORTED_INSTRUCTION, FLOW_FIELD_UNSUPPORTED_ACTION, FLOW_FIELD_UNSUPPORTED_SET_FIELD, FLOW_FIELD_ID, FLOW_FIELD_TABLE_ID, FLOW_FIELD_DURATION_SEC, FLOW_FIELD_DURATION_NSEC, FLOW_FIELD_IDLE_TIMEOUT, FLOW_FIELD_HARD_TIMEOUT, FLOW_FIELD_PACKET_COUNT, FLOW_FIELD_BYTE_COUNT, FLOW_FIELD_PRIORITY, FLOW_FIELD_COOKIE, FLOW_FIELD_IN_PORT, FLOW_FIELD_ETH_TYPE, FLOW_FIELD_VLAN_ID, FLOW_FIELD_IP_PROTO, FLOW_FIELD_UDP_SRC, FLOW_FIELD_UDP_DST, FLOW_FIELD_METADATA, FLOW_FIELD_SET_VLAN_ID, FLOW_FIELD_POP_VLAN, FLOW_FIELD_PUSH_VLAN_ID, FLOW_FIELD_OUTPUT, FLOW_FIELD_GOTO_TABLE, FLOW_FIELD_WRITE_METADATA, FLOW_FIELD_CLEAR_ACTIONS, FLOW_FIELD_METER, FLOW_FIELD_TUNNEL_ID, FLOW_FIELD_VLAN_PCP, } )
Functions ¶
func GetEnumString ¶ added in v1.0.3
Types ¶
type AdapterInstance ¶ added in v1.7.0
type AdapterInstance struct { Id string `json:"id"` Vendor string `json:"vendor"` Type string `json:"type"` Version string `json:"version"` Endpoint string `json:"endpoint"` CurrentReplica int32 `json:"currentreplica"` TotalReplicas int32 `json:"totalreplicas"` LastCommunication time.Time `json:"lastcommunication"` }
func (*AdapterInstance) PopulateFrom ¶ added in v1.7.0
func (a *AdapterInstance) PopulateFrom(val *voltha.Adapter)
type ComponentInstance ¶
type ComponentInstance struct { Id string `json:"id"` Namespace string `json:"namespace"` Name string `json:"name"` Ready string `json:"ready"` Status string `json:"status"` Restarts int `json:"restarts"` Component string `json:"component"` Version string `json:"version"` StartTime string `json:"starttime"` Age string `json:"age"` }
func (*ComponentInstance) PopulateFrom ¶
func (c *ComponentInstance) PopulateFrom(val corev1.Pod)
type Flow ¶
type Flow struct { Id string `json:"id"` TableId uint32 `json:"tableid"` DurationSec uint32 `json:"durationsec"` DurationNsec uint32 `json:"durationnsec"` IdleTimeout uint32 `json:"idletimeout"` HardTimeout uint32 `json:"hardtimeout"` PacketCount uint64 `json:"packetcount"` ByteCount uint64 `json:"bytecount"` Priority uint32 `json:"priority"` Cookie string `json:"cookie"` UnsupportedMatch string `json:"unsupportedmatch,omitempty"` InPort string `json:"inport,omitempty"` EthType string `json:"ethtype,omitempty"` VlanId string `json:"vlanid,omitempty"` IpProto string `json:"ipproto,omitempty"` UdpSrc string `json:"udpsrc,omitempty"` UdpDst string `json:"dstsrc,omitempty"` Metadata string `json:"metadata,omitempty"` UnsupportedInstruction string `json:"unsupportedinstruction,omitempty"` UnsupportedAction string `json:"unsupportedaction,omitempty"` UnsupportedSetField string `json:"unsupportedsetfield,omitempty"` SetVlanId string `json:"setvlanid,omitempty"` PopVlan string `json:"popvlan,omitempty"` PushVlanId string `json:"pushvlanid,omitempty"` Output string `json:"output,omitempty"` GotoTable string `json:"gototable,omitempty"` WriteMetadata string `json:"writemetadata,omitempty"` ClearActions string `json:"clear,omitempty"` MeterId string `json:"meter,omitempty"` TunnelId string `json:"tunnelid,omitempty"` VlanPcp string `json:"vlanpcp,omitempty"` // contains filtered or unexported fields }
* This is a partial list of OF match/action values. This list will be * expanded as new fields are needed within VOLTHA * * Strings are used in the output structure so that on output the table * can be "sparsely" populated with "empty" cells as opposed to 0 (zeros) * all over the place.
func (*Flow) Clear ¶
func (f *Flow) Clear(flag FlowFieldFlag)
func (*Flow) IsSet ¶
func (f *Flow) IsSet(flag FlowFieldFlag) bool
func (*Flow) PopulateFromProto ¶ added in v1.1.4
func (f *Flow) PopulateFromProto(flow *openflow_13.OfpFlowStats, hexId bool)
func (*Flow) Populated ¶
func (f *Flow) Populated() FlowFieldFlag
func (*Flow) Set ¶
func (f *Flow) Set(flag FlowFieldFlag)
type FlowFieldFlag ¶
type FlowFieldFlag uint64
const ( // Define bit flags for flow fields to determine what is set and // what is not FLOW_FIELD_UNSUPPORTED_MATCH FlowFieldFlag = 1 << iota FLOW_FIELD_UNSUPPORTED_INSTRUCTION FLOW_FIELD_UNSUPPORTED_ACTION FLOW_FIELD_UNSUPPORTED_SET_FIELD FLOW_FIELD_ID FLOW_FIELD_TABLE_ID FLOW_FIELD_DURATION_SEC FLOW_FIELD_DURATION_NSEC FLOW_FIELD_IDLE_TIMEOUT FLOW_FIELD_HARD_TIMEOUT FLOW_FIELD_PACKET_COUNT FLOW_FIELD_BYTE_COUNT FLOW_FIELD_PRIORITY FLOW_FIELD_COOKIE FLOW_FIELD_IN_PORT FLOW_FIELD_ETH_TYPE FLOW_FIELD_VLAN_ID FLOW_FIELD_IP_PROTO FLOW_FIELD_UDP_SRC FLOW_FIELD_UDP_DST FLOW_FIELD_METADATA FLOW_FIELD_SET_VLAN_ID FLOW_FIELD_POP_VLAN FLOW_FIELD_PUSH_VLAN_ID FLOW_FIELD_OUTPUT FLOW_FIELD_GOTO_TABLE FLOW_FIELD_WRITE_METADATA FLOW_FIELD_CLEAR_ACTIONS FLOW_FIELD_METER FLOW_FIELD_TUNNEL_ID FLOW_FIELD_VLAN_PCP FLOW_FIELD_HEADER = FLOW_FIELD_ID | FLOW_FIELD_TABLE_ID | FLOW_FIELD_PRIORITY | FLOW_FIELD_COOKIE FLOW_FIELD_STATS = FLOW_FIELD_DURATION_SEC | FLOW_FIELD_DURATION_NSEC | FLOW_FIELD_IDLE_TIMEOUT | FLOW_FIELD_HARD_TIMEOUT | FLOW_FIELD_PACKET_COUNT | FLOW_FIELD_BYTE_COUNT //ReservedVlan Transparent Vlan (Masked Vlan, VLAN_ANY in ONOS Flows) ReservedTransparentVlan = 4096 )
func (*FlowFieldFlag) Clear ¶
func (f *FlowFieldFlag) Clear(flag FlowFieldFlag)
func (*FlowFieldFlag) Count ¶
func (f *FlowFieldFlag) Count() int
func (*FlowFieldFlag) IsSet ¶
func (f *FlowFieldFlag) IsSet(flag FlowFieldFlag) bool
func (*FlowFieldFlag) Reset ¶
func (f *FlowFieldFlag) Reset()
func (*FlowFieldFlag) Set ¶
func (f *FlowFieldFlag) Set(flag FlowFieldFlag)
func (FlowFieldFlag) String ¶
func (f FlowFieldFlag) String() string
type LogFeature ¶ added in v1.2.0
func (*LogFeature) PopulateFrom ¶ added in v1.2.0
func (logFeature *LogFeature) PopulateFrom(componentName, status string)
type LogLevel ¶
func (*LogLevel) PopulateFrom ¶
type OnuEthernetFrameExtendedPm ¶ added in v1.6.9
type OnuEthernetFrameExtendedPm struct { PmFormat string `json:"pm_format"` UDropEvents *uint64 `json:"upstream_drop_events,omitempty"` UOctets *uint64 `json:"upstream_octets,omitempty"` UFrames *uint64 `json:"upstream_frames,omitempty"` UBroadcastFrames *uint64 `json:"upstream_broadcast_frames,omitempty"` UMulticastFrames *uint64 `json:"upstream_multicast_frames,omitempty"` UCrcErroredFrames *uint64 `json:"upstream_crc_errored_frames,omitempty"` UUndersizeFrames *uint64 `json:"upstream_undersize_frames,omitempty"` UOversizeFrames *uint64 `json:"upstream_oversize_frames,omitempty"` UFrames_64Octets *uint64 `json:"upstream_frames_64_octets,omitempty"` UFrames_65To_127Octets *uint64 `json:"upstream_frames_65_to_127_octets,omitempty"` UFrames_128To_255Octets *uint64 `json:"upstream_frames_128_to_255_octets,omitempty"` UFrames_256To_511Octets *uint64 `json:"upstream_frames_256_to_511_octets,omitempty"` UFrames_512To_1023Octets *uint64 `json:"upstream_frames_512_to_1023_octets,omitempty"` UFrames_1024To_1518Octets *uint64 `json:"upstream_frames_1024_to_1518_octets,omitempty"` DDropEvents *uint64 `json:"downstream_drop_events,omitempty"` DOctets *uint64 `json:"downstream_octets,omitempty"` DFrames *uint64 `json:"downstream_frames,omitempty"` DBroadcastFrames *uint64 `json:"downstream_broadcast_frames,omitempty"` DMulticastFrames *uint64 `json:"downstream_multicast_frames,omitempty"` DCrcErroredFrames *uint64 `json:"downstream_crc_errored_frames,omitempty"` DUndersizeFrames *uint64 `json:"downstream_undersize_frames,omitempty"` DOversizeFrames *uint64 `json:"downstream_oversize_frames,omitempty"` DFrames_64Octets *uint64 `json:"downstream_frames_64_octets,omitempty"` DFrames_65To_127Octets *uint64 `json:"downstream_frames_65_to_127_octets,omitempty"` DFrames_128To_255Octets *uint64 `json:"downstream_frames_128_to_255_octets,omitempty"` DFrames_256To_511Octets *uint64 `json:"downstream_frames_256_to_511_octets,omitempty"` DFrames_512To_1023Octets *uint64 `json:"downstream_frames_512_to_1023_octets,omitempty"` DFrames_1024To_1518Octets *uint64 `json:"downstream_frames_1024_to_1518_octets,omitempty"` }
type OnuStats ¶ added in v1.6.4
type OnuStats struct { IntfId *uint32 `json:"intfid,omitempty"` OnuId *uint32 `json:"onuid,omitempty"` PositiveDrift *uint64 `json:"positivedrift,omitempty"` NegativeDrift *uint64 `json:"negativedrift,omitempty"` DelimiterMissDetection *uint64 `json:"delimitermissdetection,omitempty"` BipErrors *uint64 `json:"biperrors,omitempty"` BipUnits *uint64 `json:"bipunits,omitempty"` FecCorrectedSymbols *uint64 `json:"feccorrectedsymbols,omitempty"` FecCodewordsCorrected *uint64 `json:"feccodewordscorrected,omitempty"` FecCodewordsUncorrectable *uint64 `json:"feccodewordsuncorrectable,omitempty"` FecCodewords *uint64 `json:"feccodewords,omitempty"` FecCorrectedUnits *uint64 `json:"feccorrectedunits,omitempty"` XgemKeyErrors *uint64 `json:"xgemkeyerrors,omitempty"` XgemLoss *uint64 `json:"xgemloss,omitempty"` RxPloamsError *uint64 `json:"rxploamserror,omitempty"` RxPloamsNonIdle *uint64 `json:"rxploamsnonidle,omitempty"` RxOmci *uint64 `json:"rxomci,omitempty"` TxOmci *uint64 `json:"txomci,omitempty"` RxOmciPacketsCrcError *uint64 `json:"rxomcipacketscrcerror,omitempty"` RxBytes *uint64 `json:"rxbytes,omitempty"` RxPackets *uint64 `json:"rxpackets,omitempty"` TxBytes *uint64 `json:"txbytes,omitempty"` TxPackets *uint64 `json:"txpackets,omitempty"` BerReported *uint64 `json:"berreported,omitempty"` LcdgErrors *uint64 `json:"lcdgerrors,omitempty"` RdiErrors *uint64 `json:"rdierrors,omitempty"` // reported timestamp in seconds since epoch Timestamp *uint32 `json:"timestamp,omitempty"` }