blob: 0678c0c2549f47cc6c6e2ff5cf6f6f57c206b1cd [file] [log] [blame]
Holger Hildebrandt0f9b88d2020-04-20 13:33:25 +00001/*
2 * Copyright 2020-present Open Networking Foundation
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17//Package adaptercoreonu provides the utility for onu devices, flows and statistics
18package adaptercoreonu
19
20import (
21 "errors"
22 //"github.com/opencord/voltha-lib-go/v3/pkg/log"
23)
24
25/*
26OpenOmciAgentDefaults = {
27 'mib-synchronizer': {
28 'state-machine': MibSynchronizer, # Implements the MIB synchronization state machine
29 'database': MibDbVolatileDict, # Implements volatile ME MIB database
30 # 'database': MibDbExternal, # Implements persistent ME MIB database
31 'advertise-events': True, # Advertise events on OpenOMCI event bus
32 'audit-delay': 60, # Time to wait between MIB audits. 0 to disable audits.
33 'tasks': {
34 'mib-upload': MibUploadTask,
35 'mib-template': MibTemplateTask,
36 'get-mds': GetMdsTask,
37 'mib-audit': GetMdsTask,
38 'mib-resync': MibResyncTask,
39 'mib-reconcile': MibReconcileTask
40 }
41 },
42 'omci-capabilities': {
43 'state-machine': OnuOmciCapabilities, # Implements OMCI capabilities state machine
44 'advertise-events': False, # Advertise events on OpenOMCI event bus
45 'tasks': {
46 'get-capabilities': OnuCapabilitiesTask # Get supported ME and Commands
47 }
48 },
49 'performance-intervals': {
50 'state-machine': PerformanceIntervals, # Implements PM Intervals State machine
51 'advertise-events': False, # Advertise events on OpenOMCI event bus
52 'tasks': {
53 'sync-time': SyncTimeTask,
54 'collect-data': IntervalDataTask,
55 'create-pm': OmciCreatePMRequest,
56 'delete-pm': OmciDeletePMRequest,
57 },
58 },
59 'alarm-synchronizer': {
60 'state-machine': AlarmSynchronizer, # Implements the Alarm sync state machine
61 'database': AlarmDbExternal, # For any State storage needs
62 'advertise-events': True, # Advertise events on OpenOMCI event bus
63 'tasks': {
64 'alarm-resync': AlarmResyncTask
65 }
66 },
67 'image_downloader': {
68 'state-machine': ImageDownloadeSTM,
69 'advertise-event': True,
70 'tasks': {
71 'download-file': FileDownloadTask
72 }
73 },
74 'image_upgrader': {
75 'state-machine': OmciSoftwareImageDownloadSTM,
76 'advertise-event': True,
77 'tasks': {
78 'omci_upgrade_task': OmciSwImageUpgradeTask
79 }
80 }
81 # 'image_activator': {
82 # 'state-machine': OmciSoftwareImageActivateSTM,
83 # 'advertise-event': True,
84 # }
85}
86*/
87
88// do not use MibAudit
89const cMibAuditDelayImpl = 0
90
91//suppose global methods per adapter ...
92func MibDbVolatileDictImpl() error {
93 logger.Debug("MibVolatileDict-called")
94 return errors.New("not_implemented")
95}
96
97func AlarmDbDictImpl() error {
98 logger.Debug("AlarmDb-called")
99 return errors.New("not_implemented")
100}