Skip to content

Handler Reference

Handlers are used to extend the system's functionality by implementing custom functions. They are Python modules with implemented functions. In the system, they are represented as function pointers, such as noc.main.handlers.default_handlers.empty_handler. The actual functions are registered in the system using the import string as a pointer to the function. For example, there is a default handler in the system located at main/handlers/ When called, it prints the passed arguments.

List of Available Handlers

Config FilterAllow Config FilterConfig scanManaged Object
Config Diff FilterAllow Config Diff FilterConfig scanManaged Object
Config ValidationAllow Config ValidationConfig scanManaged Object
Address ResolverAllow Address ResolverDiscovery scanManaged Object Profile
HousekeeperAllow HousekeepingHK scanManaged Object Profile
DS FilterAllow DS FilterDatastream scanDS Filter
Iface DescriptionAllow Iface DescriptionifDesc scanManaged Object Profile


You can check a handler through ./noc shell:

from noc.core.mongo.connection import connect
from noc.core.handler import get_handler

h = get_handler(<handler_path>)

Dumping Variables

This handler prints the provided arguments.

    def empty_handler(*args, **kwargs):
        print("[empty_handler] Arguments", args, kwargs)