|        |   | 
- builtins.object
 - 
- UdpPlugin
  
 
 
 
 
  class UdpPlugin(builtins.object) |  
    
|     | 
UdpPlugin(hostname, port) 
  
UpdPlugin sends monitor points to the java plugin by means  
of UDP sockets. 
  
Using UDP has pros and cons. Take into account that UDP 
is connectionless and as such does now warrant delivery 
neither the delivery order. 
On the other hand it is simple and fast (so fast that 
can saturate the network). 
  
UDP paradigm decouple the python code from the java plugin 
that is consistent with IAS design. 
Also the case of UDPs not delivered to the java plugin is 
consistent with IAS design: a missing monitor point will be marked 
as invalid until its value is refreshed. 
  
The java plugin is supposed to run in a server (hostname) and  
be listening to UDP from the given port. 
  
  
Monitor points and alarm are not sent immediately but 
temporarily stored in a dictionary and sent at periodic 
time intervals. 
In this way if the same value is sent many times in the time interval  
only the last value is effectively sent to the java plugin mitigating 
a misbehaving implementation.   |  
|   | 
Methods defined here: 
- __init__(self, hostname, port)
 - Constructor.
 
  
@param hostname the host name to send data packets to 
@param port the port to send UDP packets to 
@raise exception: if the hostname is not resolved  
- shutdown(self)
 - Shutdown the plugin
  
- start(self)
 - Start the UdpPlugin
  
- submit(self, mPointID, value, valueType, timestamp=datetime.datetime(2025, 1, 10, 15, 8, 19, 803616), operationalMode=None)
 - Submit a monitor point or alarm with the give ID to the java plugin.
 
  
The monitor point is added to the dictionary and will be sent later 
  
@param mPointID: the not None nor empty ID of the monitor point 
@param value: the value of the monitor point 
@param valueType: (IasTye)the IasType of the monitor point 
@param timestamp: (datetime) the timestamp when the value has been 
                  red from the monitored system 
@param operationalMode (OperationalMode) the optional operational mode 
@see: JsonMsg.IAS_SUPPORTED_TYPES  
 
Data descriptors defined here: 
- __dict__
 
- dictionary for instance variables
 
 
- __weakref__
 
- list of weak references to the object
 
 
 
Data and other attributes defined here: 
- SENDING_TIME_INTERVAL = 0.25
  
 |    |