diff --git a/pom.xml b/pom.xml index a67923d..0331404 100644 --- a/pom.xml +++ b/pom.xml @@ -19,7 +19,7 @@ 1.7.4 1.3.2 2.3.0 - 1.46.0 + 1.32.3 1.7.36 1.3.10 2.7.0 @@ -137,6 +137,26 @@ + + scm:git:http://474420502.top/test/dataflow + http://474420502.top/test/dataflow + scm:git:http://474420502.top/test/dataflow + HEAD + + + + + yuandian-nexus + yuandian-snapshots + http://mvn.yuandian.com/repository/maven-snapshots + + + yuandian-nexus + yuandian-releases + http://mvn.yuandian.com/repository/maven-releases + + + yuandian-nexus @@ -208,6 +228,49 @@ + + + org.apache.maven.plugins + maven-release-plugin + 2.5.3 + + v@{project.version} + true + releases + + + + + org.sonatype.plugins + nxrm3-maven-plugin + 1.0.4 + + + default-deploy + deploy + + deploy + + + + + http://mvn.yuandian.com + + yuandian-nexus + + maven-snapshots + + true + + + + + + + + + + \ No newline at end of file diff --git a/src/main/java/com/yuandian/dataflow/grpc/CollectPackets.java b/src/main/java/com/yuandian/dataflow/grpc/CollectPackets.java index 99191d7..2eac689 100644 --- a/src/main/java/com/yuandian/dataflow/grpc/CollectPackets.java +++ b/src/main/java/com/yuandian/dataflow/grpc/CollectPackets.java @@ -24,7 +24,6 @@ import com.yuandian.dataflow.proto.msgtype.ApmBaseDataFlowOuterClass.ApmBaseData import io.grpc.ManagedChannelBuilder; -import io.grpc.netty.shaded.io.netty.handler.codec.compression.CompressionOptions; import io.grpc.stub.StreamObserver; import lombok.extern.slf4j.Slf4j; diff --git a/src/main/java/com/yuandian/dataflow/projo/Doc.java b/src/main/java/com/yuandian/dataflow/projo/Doc.java index 888adfc..8e56325 100644 --- a/src/main/java/com/yuandian/dataflow/projo/Doc.java +++ b/src/main/java/com/yuandian/dataflow/projo/Doc.java @@ -24,8 +24,6 @@ import lombok.Setter; @Setter public final class Doc extends Document { - - @JsonProperty("code") @BsonProperty("code") public int Code ; diff --git a/src/main/java/com/yuandian/dataflow/proto/CollectPacketsServerGrpc.java b/src/main/java/com/yuandian/dataflow/proto/CollectPacketsServerGrpc.java index ded05bf..cd04693 100644 --- a/src/main/java/com/yuandian/dataflow/proto/CollectPacketsServerGrpc.java +++ b/src/main/java/com/yuandian/dataflow/proto/CollectPacketsServerGrpc.java @@ -1,13 +1,25 @@ package com.yuandian.dataflow.proto; import static io.grpc.MethodDescriptor.generateFullMethodName; +import static io.grpc.stub.ClientCalls.asyncBidiStreamingCall; +import static io.grpc.stub.ClientCalls.asyncClientStreamingCall; +import static io.grpc.stub.ClientCalls.asyncServerStreamingCall; +import static io.grpc.stub.ClientCalls.asyncUnaryCall; +import static io.grpc.stub.ClientCalls.blockingServerStreamingCall; +import static io.grpc.stub.ClientCalls.blockingUnaryCall; +import static io.grpc.stub.ClientCalls.futureUnaryCall; +import static io.grpc.stub.ServerCalls.asyncBidiStreamingCall; +import static io.grpc.stub.ServerCalls.asyncClientStreamingCall; +import static io.grpc.stub.ServerCalls.asyncServerStreamingCall; +import static io.grpc.stub.ServerCalls.asyncUnaryCall; +import static io.grpc.stub.ServerCalls.asyncUnimplementedStreamingCall; +import static io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall; /** */ @javax.annotation.Generated( - value = "by gRPC proto compiler (version 1.46.0)", + value = "by gRPC proto compiler (version 1.32.3)", comments = "Source: Base.proto") -@io.grpc.stub.annotations.GrpcGenerated public final class CollectPacketsServerGrpc { private CollectPacketsServerGrpc() {} @@ -98,14 +110,14 @@ public final class CollectPacketsServerGrpc { */ public void getPackets(com.yuandian.dataflow.proto.Base.Request request, io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetPacketsMethod(), responseObserver); + asyncUnimplementedUnaryCall(getGetPacketsMethod(), responseObserver); } @java.lang.Override public final io.grpc.ServerServiceDefinition bindService() { return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) .addMethod( getGetPacketsMethod(), - io.grpc.stub.ServerCalls.asyncServerStreamingCall( + asyncServerStreamingCall( new MethodHandlers< com.yuandian.dataflow.proto.Base.Request, com.yuandian.dataflow.proto.Base.Response>( @@ -132,7 +144,7 @@ public final class CollectPacketsServerGrpc { */ public void getPackets(com.yuandian.dataflow.proto.Base.Request request, io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncServerStreamingCall( + asyncServerStreamingCall( getChannel().newCall(getGetPacketsMethod(), getCallOptions()), request, responseObserver); } } @@ -155,7 +167,7 @@ public final class CollectPacketsServerGrpc { */ public java.util.Iterator getPackets( com.yuandian.dataflow.proto.Base.Request request) { - return io.grpc.stub.ClientCalls.blockingServerStreamingCall( + return blockingServerStreamingCall( getChannel(), getGetPacketsMethod(), getCallOptions(), request); } } diff --git a/src/main/proto/ApmBaseDataFlow.proto b/src/main/proto/ApmBaseDataFlow.proto deleted file mode 100644 index ec8322f..0000000 --- a/src/main/proto/ApmBaseDataFlow.proto +++ /dev/null @@ -1,174 +0,0 @@ -syntax = "proto3"; - -option java_multiple_files = false; -option java_package = "com.yuandian.dataflow.proto.msgtype"; -option go_package = "../grpc-gen;grpcgen"; - - -package dataflow; - - -message ApmBaseDataFlow { - - int32 table_id = 1; - - int32 probe_if = 2; - //四元组 - /** - * 请求端口 - */ - int32 request_port = 3; - /** - * 响应端口 - */ - int32 response_port = 4; - /** - * 请求IP - */ - int32 request_ip = 5; - /** - * 响应ip - */ - int32 response_ip = 6; - - /** - * 源mac - */ - int64 src_mac = 7; - - /** - * 目的mac - */ - int64 dst_mac = 8; - - /** - * 链路编号 - */ - int32 vlan_id = 9; - - int32 tv_sec = 10; - - int32 tv_usec = 11; - - /** - * 开始时间 - */ - int32 start_tm = 12; - - /** - * 总字节数 - */ - int32 total_bytes = 13; - - /** - * 总包数 - */ - int32 total_packets = 14; - /** - * 总丢包数 - */ - int32 total_drop_packets = 15; - /** - * 重传延时 - */ - int32 retran_time_delay = 16; - /** - * 客户端rtt - */ - int32 client_rtt = 17; - - /** - * 服务端Rtt - */ - int32 server_rtt = 18; - - - /** - * 用户响应时间 - */ - int32 user_response_time = 19; - /** - * 服务响应时间 - */ - int32 server_response_time = 20; - - - /** - * tcp回话连接失败数 - */ - int32 con_fail = 21; - - /** - * 会话重置数 - */ - // long reset = 22; - - /** - * 服务端总字节数 - */ - int32 bytes_in = 23; - /** - * 客户端总字节数 - */ - int32 bytes_out = 24; - /** - * 探针推送时间 - */ - int32 time_flag = 25; - - /** - * 结束时间 - */ - int32 end_tm = 26; - - /** - * 结束时间微秒 - */ - int32 end_tm_usec = 27; - - /** - * 总响应数 - */ - int32 respon_num = 28; - /** - * 客户端零窗口数 - */ - int32 cs_window = 29; - /** - * 服务端零窗口数 - */ - int32 sc_window = 30; - /** - * 客户端重置数 - */ - int32 cs_reset = 31; - /** - * 服务端重置数 - */ - int32 sc_reset = 32; - /** - * 客户端重传数 - */ - int32 cs_retran = 33; - /** - * 服务端重传数 - */ - int32 sc_retran = 34; - /** - * 会话建立时间 - */ - int32 conn_setup_tm = 35; - /** - * 新建会话数 - */ - int32 new_session = 36; - - int32 cs_alert = 37; - - int32 sc_alert = 38; - - string protocal = 39; -} - - - diff --git a/src/main/proto/AppFlow.proto b/src/main/proto/AppFlow.proto deleted file mode 100644 index fda72d6..0000000 --- a/src/main/proto/AppFlow.proto +++ /dev/null @@ -1,35 +0,0 @@ -syntax = "proto3"; - -option java_multiple_files = false; -option java_package = "com.yuandian.dataflow.proto.msgtype"; -option go_package = "../grpc-gen;grpcgen"; - - -package dataflow; - -message AppFlow { - int32 table_id = 1; - int32 src_ip = 2; - int32 src_port = 3; - int32 dst_ip = 4; - int32 dst_port = 5; - int32 start_tv_sec = 6; - int32 start_tv_usec = 7; - int32 last_tv_sec = 8; - int32 last_tv_usec = 9; - int32 end_tv_sec = 10; - int32 end_tv_usec = 11; - int32 input_packets = 12; - int32 output_packets = 13; - int32 input_bytes = 14; - int32 output_bytes = 15; - string protocaol = 16; - int32 app_id = 17; - int32 app_group_id = 18; - int32 probe_if = 19; - int32 app_style = 20; - int32 time_flag = 21; - int32 vlan_id = 22; - int32 mpls_lable = 23; - int32 tos = 24; -} \ No newline at end of file diff --git a/src/main/proto/BacktrackingFlow.proto b/src/main/proto/BacktrackingFlow.proto deleted file mode 100644 index 34d0b0c..0000000 --- a/src/main/proto/BacktrackingFlow.proto +++ /dev/null @@ -1,32 +0,0 @@ -syntax = "proto3"; - -option java_multiple_files = false; -option java_package = "com.yuandian.dataflow.proto.msgtype"; -option go_package = "../grpc-gen;grpcgen"; - - -package dataflow; - -message BacktrackingFlow { - - int32 table_id = 1; - int64 mac_src = 2; //源MAC 8 - int64 mac_dst = 3; //目的MAC 8 - int64 ip_src = 4; //源IP 8 - int64 ip_dst = 5; //目的IP 8 - int32 port_src = 6; //源端口,如果没有,为-1 - int32 port_dst = 7; //目标端口,如果没有,为-1 - int32 l3_proto = 8; //第三层协议ID,如果没有,为-1 - int32 l4_proto = 9; //第四层协议ID,如果没有,为-1 - int32 tos = 10; //Tos,如果没有,为-1 - int32 vlan_id = 11; //vlan ID,如果没有,为-1 - - int64 bytes = 12; // 8 字节总数 - int64 packets = 13; // 8 数据包总数 - int64 tcp_sp = 14; // 8 tcp同步包数 - int64 tcp_scpn = 15;// 8 tcp同步确认包数 - int64 tcp_srp = 16; // 8 tcp同步重置包数 - int32 app_id = 17; // 4 appID - int32 app_group_id = 18;// 4 app组ID - int32 mpls_label = 19;// 4 -} \ No newline at end of file diff --git a/src/main/proto/Base.proto b/src/main/proto/Base.proto deleted file mode 100644 index dbda986..0000000 --- a/src/main/proto/Base.proto +++ /dev/null @@ -1,27 +0,0 @@ -syntax = "proto3"; - -import "google/protobuf/any.proto"; - - -option java_multiple_files = false; //不要拆分成多个文件 -option java_package = "com.yuandian.dataflow.proto"; - -option go_package = "../grpc-gen;grpcgen"; - -package dataflow; - -message Response { - int32 code = 1; - string message = 2; - repeated google.protobuf.Any packets = 4; -} - -message Request { - int32 type = 1; // 请求类型. 默认 为 1. 暂无意义 - string version = 2; // 请求版本. 区分版本. 非必要时不使用 - repeated google.protobuf.Any param = 3; -} - -service CollectPacketsServer { - rpc GetPackets (Request) returns (stream Response); -} diff --git a/src/main/proto/BasicTrafficFlow.proto b/src/main/proto/BasicTrafficFlow.proto deleted file mode 100644 index 76ec193..0000000 --- a/src/main/proto/BasicTrafficFlow.proto +++ /dev/null @@ -1,27 +0,0 @@ -syntax = "proto3"; - -option java_multiple_files = false; -option java_package = "com.yuandian.dataflow.proto.msgtype"; -option go_package = "../grpc-gen;grpcgen"; - - -package dataflow; - -message BasicTrafficFlow { - int32 table_id = 1; - int32 cap_port = 2; - int32 request_port = 3; - int32 response_port = 4; - int32 request_ip = 5; - int32 response_ip = 6; - int32 start_time = 7; - int32 total_bytes = 8; - int32 total_packets = 9; - int32 spackets64 = 10; - int32 spackets128 = 11; - int32 spackets256 = 12; - int32 spackets512 = 13; - int32 spackets1024 = 14; - int32 spackets = 15; - int32 send_time = 16; -} \ No newline at end of file diff --git a/src/main/proto/BusinessBodyData.proto b/src/main/proto/BusinessBodyData.proto deleted file mode 100644 index 075bff4..0000000 --- a/src/main/proto/BusinessBodyData.proto +++ /dev/null @@ -1,34 +0,0 @@ -syntax = "proto3"; - -option java_multiple_files = false; -option java_package = "com.yuandian.dataflow.proto.msgtype"; -option go_package = "../grpc-gen;grpcgen"; - - -package dataflow; - -message BusinessBodyData { - int32 table_id = 1; - - string relvance_data_id = 2; - int64 request_ip = 3; - int32 request_port = 4; - int64 response_ip = 5; - int32 response_port = 6; - - int64 start_tv_sec = 7;//开始时间秒 - int64 start_tv_usec = 8;//开始时间毫秒 - int64 end_tv_sec = 9;//结束时间秒 - int64 end_tv_usec = 10;//结束时间微妙 - - string resource_code = 11; - string no_parameter_recognition = 12; - string original_recognition = 13; - string request_cookie = 14; - - string request_body_context = 15; - string response_body_context = 16; - - int32 filter_id = 17; - string business_detail_mesg = 18; -} \ No newline at end of file diff --git a/src/main/proto/BussFlowDb.proto b/src/main/proto/BussFlowDb.proto deleted file mode 100644 index b090f36..0000000 --- a/src/main/proto/BussFlowDb.proto +++ /dev/null @@ -1,77 +0,0 @@ -syntax = "proto3"; - -option java_multiple_files = false; -option java_package = "com.yuandian.dataflow.proto.msgtype"; -option go_package = "../grpc-gen;grpcgen"; - - -package dataflow; - - -message BussFlowDb { - - int32 table_id = 1; - - // redis资源归并,处理服务资源发现是需要设置识别串(正则表达式) - string redisRegex = 2; - - string id = 3; //id - int64 msg_len = 4; //消息长度 - int32 msg_type = 5; //消息类型 - int64 src_mac = 6; - int64 dst_mac = 7; - int32 protocol = 8; //协议名 - string session_serial_number = 9;//会话序列号 - string buss_type = 10;//业务服务资源编码(C_01) - int64 request_ip = 11;//Web客户端IP - int32 request_port = 12;//Web客户端端口 - int64 response_ip = 13;//Web服务器IP - int32 response_port = 14;//Web服务器端口 - int64 start_tv_sec = 15;//Web开始时间秒 - int64 start_tv_usec = 16;//开始时间毫秒 - int64 end_tv_sec = 17;//结束时间秒 - int64 end_tv_usec = 18;//结束时间微妙 - string disc_resource_ident = 19; //web:url mid:apiBody db:sql - string name = 20; //web:操作系统 midd:interfaceName db:db_name - //web midd - string session_id = 21;//sessionid - int32 request_msg_length = 22; //请求报文长度 - string request_msg_detail = 23; //请求报文详情 - int32 response_msg_length = 24; //响应报文长度 - string response_msg_detail = 25; //响应报文详情 - //web段 - string reter_url = 26; - string x_requested_with = 27; - int64 req_method = 28; //请求方式 - string content_type = 29; //请求类型 - string accept = 30; //jieshou - int32 req_cookie_leng = 31;//请求cookie报文长度 - string req_cookie_detail = 32;//请求cookie报文详情 - int64 t_intodb_time = 33; - int32 load_or_step = 34; //0: 页面 1:加载项 2:非web段数据 - string business_detail_mesg = 35; - string bussiness_key_mesg = 36; //关键字 格式:key=val|key=val.... - int32 isUncomplete = 37; //组包是否完全 0:组包完整 1:不完整 - int32 deal_state = 38; // 默认值为1 - int32 server_res_code = 39; - int64 server_response_time = 40; - int64 client_translate_time = 41; - string browser = 42; - int64 server_start_tv_sec = 43; - int64 server_start_tv_usec = 44; - int64 server_end_tv_sec = 45; - int64 server_end_tv_usec = 46; - string probe_ip = 47; - int64 probe_if = 48; - int64 server_translate_time = 49; - int64 time_flag = 50; - string base_code = 51; - string ori_sql = 52; - string reserved = 53; - int64 bytes_in = 54; - int64 bytes_out = 55; - int32 package_in = 56; - int32 package_out = 57; - string data_id = 58; - int32 filter_id = 59; -} \ No newline at end of file diff --git a/src/main/proto/BussFlowExternal.proto b/src/main/proto/BussFlowExternal.proto deleted file mode 100644 index d4135c3..0000000 --- a/src/main/proto/BussFlowExternal.proto +++ /dev/null @@ -1,43 +0,0 @@ -syntax = "proto3"; - -option java_multiple_files = false; -option java_package = "com.yuandian.dataflow.proto.msgtype"; -option go_package = "../grpc-gen;grpcgen"; - - -package dataflow; - -message BussFlowExternal { - int32 table_id = 1; - string id = 2; - int64 probe_if = 3;//接口号 - string channel = 4;//营业厅渠道:前台或者分析服务器给出,渠道标识 - string system_name = 5; //外部系统名称 - string interface_id = 6;// 业务接口编码 - string session_id = 7;//sessionid - string phone_id = 8;//受理手机号码 - string net_type = 9; - string net_segment = 10;//网段标识(客户-web) - int64 request_ip = 11;//Web客户端IP - int64 request_port = 12;//Web客户端端口 - int64 response_ip = 13;//Web服务器IP - int64 response_port = 14;//Web服务器端口 - - int64 start_tv_sec = 15;//Web开始时间秒 - int64 start_tv_usec = 16;//开始时间微秒 - int64 end_tv_sec = 17;//结束时间秒 - int64 end_tv_usec = 18;//结束时间微妙 - - int32 deal_state = 19;//Web操作成功/失败标识1成功0失败 - int64 server_translate_time = 20;//Web服务器传输耗时 - int64 server_response_time = 21;//Web服务器响应时间 - string begin_url = 22;//url - string operating_sytem = 23;//操作系统 - int32 server_res_code = 24; //Web系统返回码 - string browser = 25;//浏览器 - string business_detail_mesg = 26;//要获取的指标 - int64 insert_time = 27;//插入时间? 没有被使用 - string business_involve_msg = 28; //要关联的指标 - int32 is_uncomplete = 29; - int64 time_flag = 30; -} \ No newline at end of file diff --git a/src/main/proto/BussFlowMidd.proto b/src/main/proto/BussFlowMidd.proto deleted file mode 100644 index a7b3bd6..0000000 --- a/src/main/proto/BussFlowMidd.proto +++ /dev/null @@ -1,73 +0,0 @@ -syntax = "proto3"; - -option java_multiple_files = false; -option java_package = "com.yuandian.dataflow.proto.msgtype"; -option go_package = "../grpc-gen;grpcgen"; - - -package dataflow; - -message BussFlowMidd { - int32 table_id = 1; - string id = 2; //id - int64 src_mac = 3; - int64 dst_mac = 4; - int32 msg_len = 5; //消息长度 - int32 msg_type = 6; //消息类型 - int32 protocol = 7; //协议名 - string session_serial_number = 8;//会话序列号 - string buss_type = 9;//业务服务资源编码(C_01) - string net_segment = 10;//网段标识(客户-web) - int64 request_ip = 11;//Web客户端IP - int32 request_port = 12;//Web客户端端口 - int64 response_ip = 13;//Web服务器IP - int32 response_port = 14;//Web服务器端口 - int64 start_tv_sec = 15;//Web开始时间秒 - int64 start_tv_usec = 16;//开始时间毫秒 - int64 end_tv_sec = 17;//结束时间秒 - int64 end_tv_usec = 18;//结束时间微妙 - string disc_resource_ident = 19; //web:url mid:apiBody db:sql - string name = 20; //web:操作系统 midd:interfaceName db:db_name - //web midd - string session_id = 21;//sessionid - int32 request_msg_length = 22; //请求报文长度 - string request_msg_detail = 23; //请求报文详情 - int32 response_msg_length = 24; //响应报文长度 - string response_msg_detail = 25; //响应报文详情 - //web段 - string reter_url = 26; - string x_requested_with = 27; - int64 req_method = 28; //请求方式 - string content_type = 29; //请求类型 - string accept = 30; //jieshou - int32 req_cookie_leng = 31;//请求cookie报文长度 - string req_cookie_detail = 32;//请求cookie报文详情 - int64 t_intodb_time = 33; - int32 load_or_step = 34; //0: 页面 1:加载项 2:非web段数据 - string business_detail_mesg = 35; - string bussiness_key_mesg = 36; //关键字 格式:key=val|key=val.... - int32 is_uncomplete = 37; //组包是否完全 0:组包完整 1:不完整 - int32 deal_state = 38; // 默认值1 - int32 server_res_code = 39; - int64 server_response_time = 40; - int64 client_translate_time = 41; - string browser = 42; - int32 server_start_tv_sec = 43; - int64 server_start_tv_usec = 44; - int32 server_end_tv_sec = 45; - int64 server_end_tv_usec = 46; - string probe_ip = 47; - int32 probe_if = 48; - int64 server_translate_time = 49; - int64 time_flag = 50; - string channel = 51; - string base_code = 52; - string ori_api = 53; - string remain_data = 54; - int64 bytes_in = 55; - int64 bytes_out = 56; - int32 package_in = 57; - int32 package_out = 58; - string data_id = 59; - int32 filter_id = 60; -} \ No newline at end of file diff --git a/src/main/proto/BussFlowOrl.proto b/src/main/proto/BussFlowOrl.proto deleted file mode 100644 index 8135a91..0000000 --- a/src/main/proto/BussFlowOrl.proto +++ /dev/null @@ -1,42 +0,0 @@ -syntax = "proto3"; - -option java_multiple_files = false; -option java_package = "com.yuandian.dataflow.proto.msgtype"; -option go_package = "../grpc-gen;grpcgen"; - - -package dataflow; - -message BussFlowOrl { - int32 table_id = 1; - int32 msg_type = 2; - int32 msg_version = 3; - int32 msg_seq = 4; - int32 msg_len = 5; - int64 request_mac = 6; - int64 response_mac = 7; - int64 request_ip = 8; - int32 request_port = 9; - int64 response_ip = 10; - int32 response_port = 11; - int32 probe_if = 12; - int32 protocol = 13; - int64 start_tv_sec = 14;//Web开始时间秒 - int64 start_tv_usec = 15;//开始时间毫秒 - int64 end_tv_sec = 16;//结束时间秒 - int64 end_tv_usec = 17;//结束时间微妙 - int32 req_len = 18; - int32 res_len = 19; - int32 busi_msg_len = 20; - int32 key_msg_len = 21; - int32 detail_msg_len = 22; - int32 remain_len = 23; - string business_code = 24; - string session_id = 25; - string req_data = 26; - string res_data = 27; - string busi_msg = 28; - string busi_key_msg = 29; - string busi_detail_msg = 30; - string remain_data = 31; -} \ No newline at end of file diff --git a/src/main/proto/BussFlowWeb.proto b/src/main/proto/BussFlowWeb.proto deleted file mode 100644 index dae1bc1..0000000 --- a/src/main/proto/BussFlowWeb.proto +++ /dev/null @@ -1,82 +0,0 @@ -syntax = "proto3"; - -option java_multiple_files = false; -option java_package = "com.yuandian.dataflow.proto.msgtype"; -option go_package = "../grpc-gen;grpcgen"; - - -package dataflow; - -message BussFlowWeb { - int32 table_id = 1; - string id = 2; //id - int32 msg_len = 3; //消息长度 - int32 msg_type = 4; //消息类型 - int64 src_mac = 5; - int64 dst_mac = 6; - int32 protocol = 7; //协议名 - string session_serial_number = 8;//会话序列号 - string buss_type = 9;//业务服务资源编码(C_01) -// string net_segment = 10;//网段标识(客户-web) - int64 request_ip = 11;//Web客户端IP - int32 request_port = 12;//Web客户端端口 - int64 response_ip = 13;//Web服务器IP - int32 response_port = 14;//Web服务器端口 - int64 start_tv_sec = 15;//Web开始时间秒 - int64 start_tv_usec = 16;//开始时间毫秒 - int64 end_tv_sec = 17;//结束时间秒 - int64 end_tv_usec = 18;//结束时间微妙 - string disc_resource_ident = 19; //web:url mid:apiBody db:sql - string operating_system = 20; //web:操作系统 midd:interfaceName db:db_name - //web midd - string session_id = 21;//sessionid - int32 request_msg_length = 22; //请求报文长度 - string request_msg_detail = 23; //请求报文详情 - int32 response_msg_length = 24; //响应报文长度 - string response_msg_detail = 25; //响应报文详情 - //web段 - string reter_url = 26; - string x_requested_with = 27; - int64 req_method = 28; //请求方式 - string content_type = 29; //请求类型 - string accept = 30; //jieshou - int32 req_cookie_leng = 31;//请求cookie报文长度 - string req_cookie_detail = 32;//请求cookie报文详情 - int64 t_intodb_time = 33; - int32 load_or_step = 34; //0: 页面 1:加载项 2:非web段数据 - string business_detail_mesg = 35; - string bussiness_key_mesg = 36; //关键字 格式:key=val|key=val.... - int32 is_uncomplete = 37; //组包是否完全 0:组包完整 1:不完整 - int32 deal_state = 38; // 默认为1 - int32 server_res_code = 39; - int64 server_response_time = 40; - int64 client_translate_time = 41; - string browser = 42; - int32 server_start_tv_sec = 43; - int64 server_start_tv_usec = 44; - int32 server_end_tv_sec = 45; - int64 server_end_tv_usec = 46; - string probe_ip = 47; - int32 probe_if = 48; - int64 server_translate_time = 49; - int64 time_flag = 50; - string channel = 51; - string base_code = 52; - string ori_url = 53; - string remain_data = 54; - int64 bytes_in = 55; - int64 bytes_out = 56; - int32 package_in = 57; - int32 package_out = 58; - - string data_id = 59; - - int32 filter_id = 60; - - string white_character = 61; - - // tokenId - string token_id = 62; - // 判断是否是首端资源( 2 ) - int32 segment_id = 63; -} \ No newline at end of file diff --git a/src/main/proto/DataFlow.proto b/src/main/proto/DataFlow.proto deleted file mode 100644 index ce8677b..0000000 --- a/src/main/proto/DataFlow.proto +++ /dev/null @@ -1,62 +0,0 @@ -syntax = "proto3"; - -option java_multiple_files = false; -option java_package = "com.yuandian.dataflow.proto.msgtype"; -option go_package = "../grpc-gen;grpcgen"; - - -package dataflow; - - -message DataFlow { - int32 table_id = 1; - - string id = 2; - - int32 msg_type = 3; //消息类型 - int32 msg_version = 4; //消息版本 - int32 msg_seq = 5; //序列号 - int32 msg_len = 6; //消息长度 - int32 probe_if = 7; //接口号 - int64 timestamp = 8; //时间戳 - int64 mac_src = 9; //源物理地址 - int64 mac_dst = 10; //目的物理地址 - int32 vlan_id = 11; //vlan_id - int64 l3_proto = 12; //l3层协议 - int64 l4_proto = 13; //l4层协议 - int32 tos = 14; //tos - int32 retran_count = 15; //重传次数 - int32 reset_count = 16; //重置次数 - int32 zerowin_count = 17; //零窗口次数 - int32 protocol = 18; //协议名 - int64 seq = 19; - int64 ack = 20; - int32 recog_status = 21; //识别类型标识 - int64 bytes = 22; //总字节 - int64 packets = 23; //总包数 - int32 start_tv_sec = 24;//Web开始时间秒 - int64 start_tv_usec = 25;//开始时间毫秒 - int32 end_tv_sec = 26;//结束时间秒 - int64 end_tv_usec = 27;//结束时间微妙 - int32 server_start_tv_sec = 28;//服务器响应开始时间秒 - int64 server_start_tv_usec = 29;//服务器响应开始时间毫秒 - int32 server_end_tv_sec = 30;//服务器响应结束时间秒 - int64 server_end_tv_usec = 31;//服务器响应结束时间微妙 - - int64 server_response_time = 32;//Web服务器响应时间 - int64 client_translate_time = 33;//Web客户端传输耗时 - int64 server_translate_time = 34;//Web服务器传输耗时 - - int64 bytes_in = 35; - int64 bytes_out = 36; - int64 packets_in = 37; - int64 packets_out = 38; - int64 ip_src = 39; //源IP - int64 ip_dst = 40; //目的IP - int64 port_src = 41; //源端口 - int64 port_dst = 42; //目的端口 - int64 probeIP = 43; //探针IP - - int64 intodb_time = 44; - int64 count = 45; // 默认为1 -} \ No newline at end of file diff --git a/src/main/proto/QoeFlow.proto b/src/main/proto/QoeFlow.proto deleted file mode 100644 index eb82a59..0000000 --- a/src/main/proto/QoeFlow.proto +++ /dev/null @@ -1,51 +0,0 @@ -syntax = "proto3"; - -option java_multiple_files = false; -option java_package = "com.yuandian.dataflow.proto.msgtype"; -option go_package = "../grpc-gen;grpcgen"; - - -package dataflow; - -message QoeFlow { - int32 table_id = 1; - // 字段类型 字段 原始类型 字节数 说明 - int32 src_ip = 2; //uint32_t 4 源ip地址 - int32 dst_ip = 3; //uint32_t 4 目的ip地址 - int32 stv_sec = 4; //uint32_t 4 开始时间秒 - int32 stv_usec = 5; //uint32_t 4 开始时间微秒 - int32 ltv_sec = 6; //uint32_t 4 最后更新时间秒 - int32 ltv_usec = 7; //uint32_t 4 最后更新时间微秒 - int32 dst2_respon_num = 8; //uint32_t 4 响应总量 - int32 dst2_fast = 9; //uint32_t 4 - int32 dst2_fast_expected = 10; //uint32_t 4 - int32 dst2_expected_degrated = 11; //uint32_t 4 - int32 dst2_degrated_service = 12; //uint32_t 4 - int32 dst2_service_availability = 13; //uint32_t 4 - int32 dst2_respon_timeout = 14; //uint32_t 4 响应超时数 - int32 dst2_respon_success = 15; //uint32_t 4 响应成功数 - int32 dst2_respon_fail = 16; //uint32_t 4 响应失败数 - int32 dst2_respon_peek = 17; //uint32_t 4 峰值响应时间 - int32 dst2_respon_average = 18; //uint32_t 4 响应时间均值 - int32 cs_window = 19; //uint32_t 4 - int32 sc_window = 20; //uint32_t 4 - int32 cs_reset = 21; //uint32_t 4 - int32 sc_reset = 22; //uint32_t 4 - int32 cs_retran = 23; //uint32_t 4 - int32 sc_retran = 24; //uint32_t 4 - int32 app_id = 25; //uint32_t 4 Aphid - int32 app_group_id = 26; //uint32_t 4 app组id - int32 probe_if = 27; //uint32_t 4 探针接口id - int32 app_style = 28; //uint32_t 4 - int32 time_flag = 29; //uint32_t 4 发送时间戳 - int32 conn_setup_tm = 30; //uint32_t 4 链接建立时间 - int32 data_transfer_tm = 31; //uint32_t 4 数据传输时间 - int32 retrans_delay_tm = 32; //uint32_t 4 数据重传时延 - int32 network_inbound = 33; //uint32_t 4 网络响应时间(c->s) - int32 network_outbound = 34; //uint32_t 4 网络响应时间(s->c) - int32 new_session = 35; //uint32_t 4 新会话数 - int32 user_events = 36; //uint32_t 4 用户事件 - int32 server_events = 37; //uint32_t 4 服务事件 - int32 conn_setup_peek = 38; //uint32_t 4 连接建立时间峰值 - int32 vlan_id = 39; //uint32_t 4 -} \ No newline at end of file diff --git a/src/main/proto/SstFlow.proto b/src/main/proto/SstFlow.proto deleted file mode 100644 index 0b9410f..0000000 --- a/src/main/proto/SstFlow.proto +++ /dev/null @@ -1,51 +0,0 @@ -syntax = "proto3"; - -option java_multiple_files = false; -option java_package = "com.yuandian.dataflow.proto.msgtype"; -option go_package = "../grpc-gen;grpcgen"; - - -package dataflow; - -message SstFlow { - int32 table_id = 1; - - int64 mac_src = 2; //源MAC - int64 mac_dst = 3; //目标MAC - int64 ip_src = 4; //源IP - int64 ip_dst = 5; //目标IP - int32 port_src = 6; //源端口,如果没有,为-1 - int32 port_dst = 7; //目标端口,如果没有,为-1 - int32 l3_proto = 8; //第三层协议ID,如果没有,为-1 - int32 l4_proto = 9; //第四层协议ID,如果没有,为-1 - int32 tos = 10; //Tos,一个字节,如果没有,为-1 - int32 vlan_id = 11; //vlan ID,如果没有,为-1 - - int64 bytes = 12; //字节总数 - int64 packets = 13; //数据包总数 - - int64 packets_syn = 14; //TCP同步包数 - int64 packets_syn_ack = 15; //TCP同步确认包数 - int64 packets_syn_rst = 16; //TCP同步重置包数 - - int64 timestamp = 17; //时间戳,秒 - - int64 appid = 18;//应用ID - int64 app_group_id = 19; - int32 mpls_label = 20; - - int64 pkts_syn_rx = 21; //tcp同步包,接收 - int64 pkts_syn_ack_rx = 22;//tcp同步确认包,接收 - int64 pkts_syn_rst_rx = 23; //tcp同步重置包,接收 - int64 pkts_fin = 24;//tcp终止包,接收 - int64 pkts_rst = 25;//tcp重置包,接收 - - int64 bytes_rx = 26;//字节收 - int64 packets_rx = 27;//数据包收 - - int64 probe_time_sec = 28; - int64 probe_time = 29; - int64 create_time = 30; - - int32 probe_if = 31; -} \ No newline at end of file