Skip to content

Commit

Permalink
default udp frame size const
Browse files Browse the repository at this point in the history
  • Loading branch information
divi255 committed Nov 15, 2021
1 parent fdf2d16 commit bcdcc5d
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions lib/eva/notify.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,8 @@

mqtt_global_topics = ['unit', 'sensor']

DEFAULT_UDP_FRAME_SIZE = 65000


@with_notify_lock
def _get_notifiers_copy():
Expand Down Expand Up @@ -3608,7 +3610,7 @@ def __init__(self,
interval=None,
buf_ttl=0,
fmt='msgpack',
max_frame_size=65000,
max_frame_size=DEFAULT_UDP_FRAME_SIZE,
host=None,
port=None):

Expand Down Expand Up @@ -4346,7 +4348,7 @@ def load_notifier(notifier_id, ncfg=None, test=True, connect=True):
fmt = ncfg.get('fmt')
host = ncfg.get('host')
port = ncfg.get('port')
max_frame_size = ncfg.get('max_frame_size', 65000)
max_frame_size = ncfg.get('max_frame_size', DEFAULT_UDP_FRAME_SIZE)
n = UDPNotifier(notifier_id,
interval=interval,
buf_ttl=buf_ttl,
Expand Down

0 comments on commit bcdcc5d

Please sign in to comment.