\r
Main process\r
------------\r
- \r
+\r
This is the initial process which does the following.\r
\r
- Download CBS configuration and update the vnf_table_1\r
-------------------\r
\r
If the local configuration file (config/hbproperties.yaml) indicates\r
-that CBS polling is required, then main process would create the CBS \r
+that CBS polling is required, then main process would create the CBS\r
polling process. It does the following.\r
\r
- It takes the CBS polling interval from the configuration file.\r
- Download CBS configuration and process it\r
- Spawns processes\r
- Periodically update hb_common with last accessed time to indicate that active instance is Alive.\r
- \r
+\r
Inactive Instance:\r
- Spawns processes\r
- Constantly check hb_common entry for last accessed time\r
- - If the last accessed time is more than a minute or so, then it assumes the role of active instance \r
- \r
+ - If the last accessed time is more than a minute or so, then it assumes the role of active instance\r
+\r
**HB worker process:** Both active and inactive instance behaves the sames as metnioned in the Design section.\r
\r
**DB Monitoring process:** Both active periodically checks its process ID/hostname with hb_common data to know whether it is an active instance or not. If inactive instance it does nothing. If active instance, it behaves as mentioned in design section.\r
Handling of some of the failure scenarios\r
-----------------------------------------\r
\r
-Failure to download the configuration from CBS – In this case, local\r
+Failure to download the configuration from CBS - In this case, local\r
configuration file etc/config.json is considered as the configuration\r
file and vnf_table_1 is updated accordingly.\r
\r
\r
There are 3 tables maintained.\r
\r
-**Vnf_table_1 table:** \r
+**Vnf_table_1 table:**\r
This is table is indexed by eventName. Each entry\r
has following parameters in it.\r
\r
- closedLoopControlName\r
- version\r
\r
-**Vnf_table_2 table:** \r
-For each sourceName there would be an entry in vnf_table_2. \r
+**Vnf_table_2 table:**\r
+For each sourceName there would be an entry in vnf_table_2.\r
This is indexed by eventName and SourceName. Each entry has\r
below parameters\r
\r
- Control loop event raised flag. 0 indicates not raised, 1 indicates\r
CL event raised\r
\r
-**hb_common table:** \r
+**hb_common table:**\r
This is a single entry table.\r
\r
- The configuration status which would have one of the below.\r
- - **RECONFIGURATION** – indicates CBS configuration processing is in\r
+ - **RECONFIGURATION** - indicates CBS configuration processing is in\r
progress.\r
- - **RUNNING** – CBS configuration is completed and ready to process HB\r
+ - **RUNNING** - CBS configuration is completed and ready to process HB\r
event and send CL event.\r
-- The process ID – This indicates the main process ID of the active HB\r
+- The process ID - This indicates the main process ID of the active HB\r
instance which is responsible to take care of reconfiguration\r
-- The source Name – It has 2 parts, hostname and service name. The\r
+- The source Name - It has 2 parts, hostname and service name. The\r
hostname is the Docker container ID. The service name is the\r
environment variable set for SERVICE_NAME\r
-- The last accessed time – The time last accessed by the main process\r
+- The last accessed time - The time last accessed by the main process\r
having the above process ID.\r