To update the third-party registry file: - Make sure that, in Traffic Monitor, there is an already registered plugin with the same value of the
"PLUGIN_ID" field as the new plugin has. You can find the information about all registered plugins in the plugin table of the database. For details on working with a database, see Администрирование базы данных. Create the new version of the manifest file of the plugin. For this, make the necessary changes to the initial manifest file. | Предупреждение |
|---|
| When updating plugin, it is not recommended to change service name, i.e. the value of the "SERVICE_MNEMO" field. Because, in this case, a new event type will be created in Traffic Monitor and the events intercepted by old plugin will not be associated with the plugin, that has a new value of the "SERVICE_MNEMO". If you want to change the event type name that is displayed in the Traffic Monitor web interface, edit the "LOCALE" field. If you change the "SERVICE_MNEMO" field and, at the same time, not change the "LOCALE" field, then, in Traffic Monitor, there will be two event types with the same names. In Traffic Monitor Management Console, they cannot be distinguished from each other. |
- Upload the new plugin to the Traffic Monitor Management Console.
Deletion of duplicating event types If you have added several event types with different service names ("SERVICE_MNEMO") but with same displayed names ("LOCALE") to Traffic Monitor, you can resolve duplication by deletion the information on irrelevant event types from the database. In doing so, you can delete not the entire plugin but only the event type created by it and caused the duplication. | Предупреждение |
|---|
| Perform deletion of information from the database carefully. Deletion information by mistake can cause incorrect work of the System. Before deletion, it is recommended to create backup copies of database and tables. |
| Предупреждение |
|---|
| Deletion of duplicating event type will cause incorrect displaying of events of this event type and security policies using this event type. Results of queries that must contain events of the deleted type will not be displayed. If duplicating event type is used in Traffic Monitor, you can: - Not delete it, but change the displayed name of the new event type by correctly updating plugin.
- Wait for storage period of the events of the duplicating type to expire. Then delete this event type from the database.
|
Let's look at the deletion procedure with the example of the plugin with the "im_my_chat" event type from the Пример файла регистрации стороннего компонента article. To demonstrate, we have incorrectly updated the plugin twice. The "SERVICE_MNEMO" field had "im_my_chat_new" and "im_my_chat_final" values. The "LOCALE" field had the "New service" value in all cases. As a result, the duplication has occurred. For example, when you create a query in the Events section of Traffic Monitor Management Console, you can see three New service event types:  To delete duplicating event types: - In the plugin table of the database, find identifiers (ID) of the plugins that caused duplication. This identifiers are recorded in the plugin_id field.
In our example, there is only one record with such a plugin:
 - Find identifiers of the event types and services created by these plugins. For this:
In the plugin_data table, find all data for these plugins. You can do it using SQL query of the following type: | Блок кода |
|---|
| SELECT * FROM iwtm.plugin_data
WHERE plugin_id in ('4B8038D390396EB6E0540100007F1CA200000001')
ORDER BY plugin_id |
If there are several duplicating plugins, then specify their plugin_id field values in brackets, separated by commas. Result of the query in our example:
 - In the obtained data, for each plugin_id value, find those records where entry_type field value equals
OBJECT_TYPE_OBJECT_TYPE_ID or OBJECT_TYPE_SERVICE_ID. Remember the pairs of the values of these fields. It is identifier of the event type created by duplicating plugin and identifier of the service. In the table from the example, one pair is found. It contains the following values:
OBJECT_TYPE_OBJECT_TYPE_ID = "FAF6B5B261204B31BEED5F67798A477C00000000"
OBJECT_TYPE_SERVICE_ID = "DD6ECB5227DA11E2B507CBDB6088709B00000000"
In the object_type table, find records with the pairs of identificators from the previous step. For this, you can use the following query: | Блок кода |
|---|
| SELECT * FROM iwtm.object_type
WHERE object_type_id = 'FAF6B5B261204B31BEED5F67798A477C00000000'
AND service_id = 'DD6ECB5227DA11E2B507CBDB6088709B00000000' |

- On the mnemo field, determine a pair of identifiers that refers to the relevant plugin.
If there is the only one pair, then go to the 6 step. In our example, found records have "im_my_chat_final" value of the mnemo field. It means that these records refer to the relevant plugin. - For each pair that does not refer to the relevant plugin, perform the following actions:
Make sure that, in the object table, there are no events of the event type from this pair. For this, run the query using the values of the pair of the identifiers – OBJECT_TYPE_ID and SERVICE_ID: | Блок кода |
|---|
| SELECT count(*) FROM object
WHERE object_type_code='<OBJECT_TYPE_ID>'
AND service_code='<SERVICE_ID>' |
If the result of the query equals zero, then there are no events. | Предупреждение |
|---|
| | If, in the object table, there are events of this event type but you want to delete it anyway, it is recommended to delete all events of this type from this table first. |
- From the object_type table, delete records related to this event type. These are the records found in the step 3.
- From the plugin_data table, delete records related to this event type. For instance, these can be:
- event type identifier –
"OBJECT_TYPE_OBJECT_TYPE_ID" - service identifier –
"OBJECT_TYPE_SERVICE_ID" - event type name –
"OBJECT_TYPE_MNEMO"
In the object_type table, find the records related to the duplicating event types. For this, run the following query: | Блок кода |
|---|
| SELECT * FROM iwtm.object_type
WHERE display_name = '<EVENT_TYPE_DISPLAY_NAME>' |
where <EVENT_TYPE_DISPLAY_NAME> – the displayed name of the event type. In our example, the query will be as follows: | Блок кода |
|---|
| SELECT * FROM iwtm.object_type
WHERE display_name = 'New service' |

- On the mnemo field, determine duplicating event types.
In our case, "im_my_chat_final" is an event type of the relevant plugin. It means that "im_my_chat" and "im_my_chat_new" are old duplicating types which we want to delete. - For each duplicating event type:
- Make sure that, in the object table there are no event of this type. Follow a procedure similar to step 5а of this instruction.
In the object_type find and delete all records related to this type. They differ from each other only in localization, i.e. in values of the language and display_name fields. For this, you can use the following query: | Блок кода |
|---|
| SELECT * FROM iwtm.object_type
WHERE mnemo = '<MNEMO>' |
For instance, for the "im_my_chat" event type, the following records will be displayed:

Run the procedure of updating database object list. For this: If you use the PostgreSQL DBMS, run the command: | Блок кода |
|---|
| SELECT sp_populate_configuration('bookworm'); |
If you use the Oracle DBMS, run the command: | Блок кода |
|---|
| begin
sp_populate_configuration('bookworm');
end; |
- Make sure that duplicating event types are absent in Traffic Monitor Management Console.
|