mirror of
https://github.com/azaion/annotations.git
synced 2026-04-22 19:56:31 +00:00
refactor external clients
put model batch size as parameter in config
This commit is contained in:
@@ -11,10 +11,10 @@ public class RemoteCommand(CommandType commandType, byte[]? data = null)
|
||||
[Key("Data")]
|
||||
public byte[]? Data { get; set; } = data;
|
||||
|
||||
public static byte[] Serialize<T>(CommandType commandType, T data) where T : class
|
||||
public static RemoteCommand Create<T>(CommandType commandType, T data) where T : class
|
||||
{
|
||||
var dataBytes = MessagePackSerializer.Serialize(data);
|
||||
return MessagePackSerializer.Serialize(new RemoteCommand(commandType, dataBytes ));
|
||||
return new RemoteCommand(commandType, dataBytes);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user