daemon: added link option to configure buffer, added support in pygui to allow configuring buffer
This commit is contained in:
parent
d95c2ec05f
commit
a35e91aeba
8 changed files with 68 additions and 5 deletions
|
@ -128,6 +128,7 @@ def add_link_data(
|
|||
options.mer = options_proto.mer
|
||||
options.burst = options_proto.burst
|
||||
options.mburst = options_proto.mburst
|
||||
options.buffer = options_proto.buffer
|
||||
options.unidirectional = options_proto.unidirectional
|
||||
options.key = options_proto.key
|
||||
return iface1_data, iface2_data, options, link_type
|
||||
|
@ -329,6 +330,7 @@ def convert_link_options(options_data: LinkOptions) -> core_pb2.LinkOptions:
|
|||
burst=options_data.burst,
|
||||
delay=options_data.delay,
|
||||
dup=options_data.dup,
|
||||
buffer=options_data.buffer,
|
||||
unidirectional=options_data.unidirectional,
|
||||
)
|
||||
|
||||
|
|
|
@ -972,6 +972,7 @@ class CoreGrpcServer(core_pb2_grpc.CoreApiServicer):
|
|||
mburst=options_proto.mburst,
|
||||
unidirectional=options_proto.unidirectional,
|
||||
key=options_proto.key,
|
||||
buffer=options_proto.buffer,
|
||||
)
|
||||
session.update_link(node1_id, node2_id, iface1_id, iface2_id, options)
|
||||
iface1 = InterfaceData(id=iface1_id)
|
||||
|
|
|
@ -457,6 +457,7 @@ class LinkOptions:
|
|||
delay: int = 0
|
||||
dup: int = 0
|
||||
unidirectional: bool = False
|
||||
buffer: int = 0
|
||||
|
||||
@classmethod
|
||||
def from_proto(cls, proto: core_pb2.LinkOptions) -> "LinkOptions":
|
||||
|
@ -471,6 +472,7 @@ class LinkOptions:
|
|||
delay=proto.delay,
|
||||
dup=proto.dup,
|
||||
unidirectional=proto.unidirectional,
|
||||
buffer=proto.buffer,
|
||||
)
|
||||
|
||||
def to_proto(self) -> core_pb2.LinkOptions:
|
||||
|
@ -485,6 +487,7 @@ class LinkOptions:
|
|||
delay=self.delay,
|
||||
dup=self.dup,
|
||||
unidirectional=self.unidirectional,
|
||||
buffer=self.buffer,
|
||||
)
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue