config.pb.go 9.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273
  1. // Code generated by protoc-gen-go. DO NOT EDIT.
  2. // versions:
  3. // protoc-gen-go v1.25.0
  4. // protoc v3.14.0
  5. // source: app/log/config.proto
  6. package log
  7. import (
  8. proto "github.com/golang/protobuf/proto"
  9. log "github.com/xtls/xray-core/common/log"
  10. protoreflect "google.golang.org/protobuf/reflect/protoreflect"
  11. protoimpl "google.golang.org/protobuf/runtime/protoimpl"
  12. reflect "reflect"
  13. sync "sync"
  14. )
  15. const (
  16. // Verify that this generated code is sufficiently up-to-date.
  17. _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
  18. // Verify that runtime/protoimpl is sufficiently up-to-date.
  19. _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
  20. )
  21. // This is a compile-time assertion that a sufficiently up-to-date version
  22. // of the legacy proto package is being used.
  23. const _ = proto.ProtoPackageIsVersion4
  24. type LogType int32
  25. const (
  26. LogType_None LogType = 0
  27. LogType_Console LogType = 1
  28. LogType_File LogType = 2
  29. LogType_Event LogType = 3
  30. )
  31. // Enum value maps for LogType.
  32. var (
  33. LogType_name = map[int32]string{
  34. 0: "None",
  35. 1: "Console",
  36. 2: "File",
  37. 3: "Event",
  38. }
  39. LogType_value = map[string]int32{
  40. "None": 0,
  41. "Console": 1,
  42. "File": 2,
  43. "Event": 3,
  44. }
  45. )
  46. func (x LogType) Enum() *LogType {
  47. p := new(LogType)
  48. *p = x
  49. return p
  50. }
  51. func (x LogType) String() string {
  52. return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
  53. }
  54. func (LogType) Descriptor() protoreflect.EnumDescriptor {
  55. return file_app_log_config_proto_enumTypes[0].Descriptor()
  56. }
  57. func (LogType) Type() protoreflect.EnumType {
  58. return &file_app_log_config_proto_enumTypes[0]
  59. }
  60. func (x LogType) Number() protoreflect.EnumNumber {
  61. return protoreflect.EnumNumber(x)
  62. }
  63. // Deprecated: Use LogType.Descriptor instead.
  64. func (LogType) EnumDescriptor() ([]byte, []int) {
  65. return file_app_log_config_proto_rawDescGZIP(), []int{0}
  66. }
  67. type Config struct {
  68. state protoimpl.MessageState
  69. sizeCache protoimpl.SizeCache
  70. unknownFields protoimpl.UnknownFields
  71. ErrorLogType LogType `protobuf:"varint,1,opt,name=error_log_type,json=errorLogType,proto3,enum=xray.app.log.LogType" json:"error_log_type,omitempty"`
  72. ErrorLogLevel log.Severity `protobuf:"varint,2,opt,name=error_log_level,json=errorLogLevel,proto3,enum=xray.common.log.Severity" json:"error_log_level,omitempty"`
  73. ErrorLogPath string `protobuf:"bytes,3,opt,name=error_log_path,json=errorLogPath,proto3" json:"error_log_path,omitempty"`
  74. AccessLogType LogType `protobuf:"varint,4,opt,name=access_log_type,json=accessLogType,proto3,enum=xray.app.log.LogType" json:"access_log_type,omitempty"`
  75. AccessLogPath string `protobuf:"bytes,5,opt,name=access_log_path,json=accessLogPath,proto3" json:"access_log_path,omitempty"`
  76. EnableDnsLog bool `protobuf:"varint,6,opt,name=enable_dns_log,json=enableDnsLog,proto3" json:"enable_dns_log,omitempty"`
  77. }
  78. func (x *Config) Reset() {
  79. *x = Config{}
  80. if protoimpl.UnsafeEnabled {
  81. mi := &file_app_log_config_proto_msgTypes[0]
  82. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  83. ms.StoreMessageInfo(mi)
  84. }
  85. }
  86. func (x *Config) String() string {
  87. return protoimpl.X.MessageStringOf(x)
  88. }
  89. func (*Config) ProtoMessage() {}
  90. func (x *Config) ProtoReflect() protoreflect.Message {
  91. mi := &file_app_log_config_proto_msgTypes[0]
  92. if protoimpl.UnsafeEnabled && x != nil {
  93. ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
  94. if ms.LoadMessageInfo() == nil {
  95. ms.StoreMessageInfo(mi)
  96. }
  97. return ms
  98. }
  99. return mi.MessageOf(x)
  100. }
  101. // Deprecated: Use Config.ProtoReflect.Descriptor instead.
  102. func (*Config) Descriptor() ([]byte, []int) {
  103. return file_app_log_config_proto_rawDescGZIP(), []int{0}
  104. }
  105. func (x *Config) GetErrorLogType() LogType {
  106. if x != nil {
  107. return x.ErrorLogType
  108. }
  109. return LogType_None
  110. }
  111. func (x *Config) GetErrorLogLevel() log.Severity {
  112. if x != nil {
  113. return x.ErrorLogLevel
  114. }
  115. return log.Severity_Unknown
  116. }
  117. func (x *Config) GetErrorLogPath() string {
  118. if x != nil {
  119. return x.ErrorLogPath
  120. }
  121. return ""
  122. }
  123. func (x *Config) GetAccessLogType() LogType {
  124. if x != nil {
  125. return x.AccessLogType
  126. }
  127. return LogType_None
  128. }
  129. func (x *Config) GetAccessLogPath() string {
  130. if x != nil {
  131. return x.AccessLogPath
  132. }
  133. return ""
  134. }
  135. func (x *Config) GetEnableDnsLog() bool {
  136. if x != nil {
  137. return x.EnableDnsLog
  138. }
  139. return false
  140. }
  141. var File_app_log_config_proto protoreflect.FileDescriptor
  142. var file_app_log_config_proto_rawDesc = []byte{
  143. 0x0a, 0x14, 0x61, 0x70, 0x70, 0x2f, 0x6c, 0x6f, 0x67, 0x2f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67,
  144. 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0c, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x61, 0x70, 0x70,
  145. 0x2e, 0x6c, 0x6f, 0x67, 0x1a, 0x14, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2f, 0x6c, 0x6f, 0x67,
  146. 0x2f, 0x6c, 0x6f, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xbb, 0x02, 0x0a, 0x06, 0x43,
  147. 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x3b, 0x0a, 0x0e, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x5f, 0x6c,
  148. 0x6f, 0x67, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x15, 0x2e,
  149. 0x78, 0x72, 0x61, 0x79, 0x2e, 0x61, 0x70, 0x70, 0x2e, 0x6c, 0x6f, 0x67, 0x2e, 0x4c, 0x6f, 0x67,
  150. 0x54, 0x79, 0x70, 0x65, 0x52, 0x0c, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x4c, 0x6f, 0x67, 0x54, 0x79,
  151. 0x70, 0x65, 0x12, 0x41, 0x0a, 0x0f, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x5f, 0x6c, 0x6f, 0x67, 0x5f,
  152. 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x19, 0x2e, 0x78, 0x72,
  153. 0x61, 0x79, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x6c, 0x6f, 0x67, 0x2e, 0x53, 0x65,
  154. 0x76, 0x65, 0x72, 0x69, 0x74, 0x79, 0x52, 0x0d, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x4c, 0x6f, 0x67,
  155. 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x12, 0x24, 0x0a, 0x0e, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x5f, 0x6c,
  156. 0x6f, 0x67, 0x5f, 0x70, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x65,
  157. 0x72, 0x72, 0x6f, 0x72, 0x4c, 0x6f, 0x67, 0x50, 0x61, 0x74, 0x68, 0x12, 0x3d, 0x0a, 0x0f, 0x61,
  158. 0x63, 0x63, 0x65, 0x73, 0x73, 0x5f, 0x6c, 0x6f, 0x67, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x04,
  159. 0x20, 0x01, 0x28, 0x0e, 0x32, 0x15, 0x2e, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x61, 0x70, 0x70, 0x2e,
  160. 0x6c, 0x6f, 0x67, 0x2e, 0x4c, 0x6f, 0x67, 0x54, 0x79, 0x70, 0x65, 0x52, 0x0d, 0x61, 0x63, 0x63,
  161. 0x65, 0x73, 0x73, 0x4c, 0x6f, 0x67, 0x54, 0x79, 0x70, 0x65, 0x12, 0x26, 0x0a, 0x0f, 0x61, 0x63,
  162. 0x63, 0x65, 0x73, 0x73, 0x5f, 0x6c, 0x6f, 0x67, 0x5f, 0x70, 0x61, 0x74, 0x68, 0x18, 0x05, 0x20,
  163. 0x01, 0x28, 0x09, 0x52, 0x0d, 0x61, 0x63, 0x63, 0x65, 0x73, 0x73, 0x4c, 0x6f, 0x67, 0x50, 0x61,
  164. 0x74, 0x68, 0x12, 0x24, 0x0a, 0x0e, 0x65, 0x6e, 0x61, 0x62, 0x6c, 0x65, 0x5f, 0x64, 0x6e, 0x73,
  165. 0x5f, 0x6c, 0x6f, 0x67, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0c, 0x65, 0x6e, 0x61, 0x62,
  166. 0x6c, 0x65, 0x44, 0x6e, 0x73, 0x4c, 0x6f, 0x67, 0x2a, 0x35, 0x0a, 0x07, 0x4c, 0x6f, 0x67, 0x54,
  167. 0x79, 0x70, 0x65, 0x12, 0x08, 0x0a, 0x04, 0x4e, 0x6f, 0x6e, 0x65, 0x10, 0x00, 0x12, 0x0b, 0x0a,
  168. 0x07, 0x43, 0x6f, 0x6e, 0x73, 0x6f, 0x6c, 0x65, 0x10, 0x01, 0x12, 0x08, 0x0a, 0x04, 0x46, 0x69,
  169. 0x6c, 0x65, 0x10, 0x02, 0x12, 0x09, 0x0a, 0x05, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x10, 0x03, 0x42,
  170. 0x46, 0x0a, 0x10, 0x63, 0x6f, 0x6d, 0x2e, 0x78, 0x72, 0x61, 0x79, 0x2e, 0x61, 0x70, 0x70, 0x2e,
  171. 0x6c, 0x6f, 0x67, 0x50, 0x01, 0x5a, 0x21, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f,
  172. 0x6d, 0x2f, 0x78, 0x74, 0x6c, 0x73, 0x2f, 0x78, 0x72, 0x61, 0x79, 0x2d, 0x63, 0x6f, 0x72, 0x65,
  173. 0x2f, 0x61, 0x70, 0x70, 0x2f, 0x6c, 0x6f, 0x67, 0xaa, 0x02, 0x0c, 0x58, 0x72, 0x61, 0x79, 0x2e,
  174. 0x41, 0x70, 0x70, 0x2e, 0x4c, 0x6f, 0x67, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
  175. }
  176. var (
  177. file_app_log_config_proto_rawDescOnce sync.Once
  178. file_app_log_config_proto_rawDescData = file_app_log_config_proto_rawDesc
  179. )
  180. func file_app_log_config_proto_rawDescGZIP() []byte {
  181. file_app_log_config_proto_rawDescOnce.Do(func() {
  182. file_app_log_config_proto_rawDescData = protoimpl.X.CompressGZIP(file_app_log_config_proto_rawDescData)
  183. })
  184. return file_app_log_config_proto_rawDescData
  185. }
  186. var file_app_log_config_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
  187. var file_app_log_config_proto_msgTypes = make([]protoimpl.MessageInfo, 1)
  188. var file_app_log_config_proto_goTypes = []interface{}{
  189. (LogType)(0), // 0: xray.app.log.LogType
  190. (*Config)(nil), // 1: xray.app.log.Config
  191. (log.Severity)(0), // 2: xray.common.log.Severity
  192. }
  193. var file_app_log_config_proto_depIdxs = []int32{
  194. 0, // 0: xray.app.log.Config.error_log_type:type_name -> xray.app.log.LogType
  195. 2, // 1: xray.app.log.Config.error_log_level:type_name -> xray.common.log.Severity
  196. 0, // 2: xray.app.log.Config.access_log_type:type_name -> xray.app.log.LogType
  197. 3, // [3:3] is the sub-list for method output_type
  198. 3, // [3:3] is the sub-list for method input_type
  199. 3, // [3:3] is the sub-list for extension type_name
  200. 3, // [3:3] is the sub-list for extension extendee
  201. 0, // [0:3] is the sub-list for field type_name
  202. }
  203. func init() { file_app_log_config_proto_init() }
  204. func file_app_log_config_proto_init() {
  205. if File_app_log_config_proto != nil {
  206. return
  207. }
  208. if !protoimpl.UnsafeEnabled {
  209. file_app_log_config_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
  210. switch v := v.(*Config); i {
  211. case 0:
  212. return &v.state
  213. case 1:
  214. return &v.sizeCache
  215. case 2:
  216. return &v.unknownFields
  217. default:
  218. return nil
  219. }
  220. }
  221. }
  222. type x struct{}
  223. out := protoimpl.TypeBuilder{
  224. File: protoimpl.DescBuilder{
  225. GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
  226. RawDescriptor: file_app_log_config_proto_rawDesc,
  227. NumEnums: 1,
  228. NumMessages: 1,
  229. NumExtensions: 0,
  230. NumServices: 0,
  231. },
  232. GoTypes: file_app_log_config_proto_goTypes,
  233. DependencyIndexes: file_app_log_config_proto_depIdxs,
  234. EnumInfos: file_app_log_config_proto_enumTypes,
  235. MessageInfos: file_app_log_config_proto_msgTypes,
  236. }.Build()
  237. File_app_log_config_proto = out.File
  238. file_app_log_config_proto_rawDesc = nil
  239. file_app_log_config_proto_goTypes = nil
  240. file_app_log_config_proto_depIdxs = nil
  241. }