github.com/binkynet/BinkyNet@v1.12.1-0.20240421190447-da4e34c20be0/apis/v1/logprovider.proto (about) 1 // Copyright 2020 Ewout Prangsma 2 // 3 // Licensed under the Apache License, Version 2.0 (the "License"); 4 // you may not use this file except in compliance with the License. 5 // You may obtain a copy of the License at 6 // 7 // http://www.apache.org/licenses/LICENSE-2.0 8 // 9 // Unless required by applicable law or agreed to in writing, software 10 // distributed under the License is distributed on an "AS IS" BASIS, 11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 // See the License for the specific language governing permissions and 13 // limitations under the License. 14 // 15 // Author Ewout Prangsma 16 // 17 18 syntax = "proto3"; 19 20 package binkynet.v1; 21 22 option go_package = "github.com/binkynet/BinkyNet/apis/v1"; 23 option csharp_namespace = "BinkyNet.Apis.V1"; 24 25 // LogProviderService is served by all services that provider some form of logging. 26 // Log provider services make themselves available in mDNS under service type "_logprovider._binkynet._tcp". 27 service LogProviderService { 28 // Record a log message. 29 rpc GetLogs(GetLogsRequest) returns (stream LogEntry); 30 } 31 32 message GetLogsRequest { 33 // Empty on purpose 34 } 35 36 // Log levels 37 enum LogLevel { 38 TRACE = 0; 39 DEBUG = 1; 40 INFO = 2; 41 WARNING = 3; 42 ERROR = 4; 43 FATAL = 5; 44 } 45 46 message LogEntry { 47 // Message of the log entry 48 string message = 1; 49 // Log level 50 LogLevel level = 2; 51 }