trisulrp 3.1.16 → 3.2.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: eb04389fb4e2377b99279a36b656db635f58a560
4
- data.tar.gz: e7e57b4d8d7e38b301ee722d2c074269a3b95aef
3
+ metadata.gz: 619b5368f7199fd9df07e69d166c6a4ec5b19f02
4
+ data.tar.gz: 8e3cd6fedb0b337feced8c58935681fc3d64e4f2
5
5
  SHA512:
6
- metadata.gz: 532cbb05586f8ea2cd849c45784f8b3f08a46bbe5049af8fb34da3c5552daf3ef33f08591dbf1f8eb8a062422e2a7f3c584fd0079596ef32fd3375a0b4d49bc9
7
- data.tar.gz: 80587cbe0bb22c2c5be0140c9591d2550a57ed3294fd6933de0a4de4b1a0f798e5558cc4fd7ab7f44d43b7804d4dc62456ad8a0cba61da8e1ef500a1edbfbb25
6
+ metadata.gz: 4579499fa4d4fa376217ce7b766c24cad3d20b294d50f0fd0ad91810a9bdc95f6ec44bcce69854c1175987a42bfae2b9bbd89853d2cb34c8b4fff0823fc2c69d
7
+ data.tar.gz: b79737d1a78ed7559187822187cd69dd9554c5944d5858f25617e1f0ff6e0ab7e22cfa278db4ee4d212ffe500945c8d365d154e529c9650e4f475aa419ef01d7
data/VERSION CHANGED
@@ -1 +1 @@
1
- 3.1.16
1
+ 3.2.2
@@ -514,6 +514,9 @@ module TrisulRP::Protocol
514
514
  when TRP::Message::Command::FILE_REQUEST
515
515
  fix_TRP_Fields( TRP::FileRequest, params)
516
516
  req.file_request = TRP::FileRequest.new(params)
517
+ when TRP::Message::Command::GRAPH_REQUEST
518
+ fix_TRP_Fields( TRP::GraphRequest, params)
519
+ req.graph_request = TRP::GraphRequest.new(params)
517
520
  else
518
521
  raise "Unknown TRP command ID"
519
522
  end
@@ -609,9 +612,10 @@ module TrisulRP::Protocol
609
612
  resp.async_response
610
613
  when TRP::Message::Command::FILE_RESPONSE
611
614
  resp.file_response
615
+ when TRP::Message::Command::GRAPH_RESPONSE
616
+ resp.graph_response
612
617
  else
613
-
614
- raise "#{resp.trp_commandi.to_i} Unknown TRP command ID"
618
+ raise "#{resp.trp_command.to_i} Unknown TRP command ID"
615
619
  end
616
620
  end
617
621
  end
@@ -80,6 +80,8 @@ module TRP
80
80
 
81
81
  end
82
82
 
83
+ class VertexGroupT < ::Protobuf::Message; end
84
+ class EdgeGraphT < ::Protobuf::Message; end
83
85
  class NameValue < ::Protobuf::Message; end
84
86
  class Message < ::Protobuf::Message
85
87
  class Command < ::Protobuf::Enum
@@ -148,6 +150,8 @@ module TRP
148
150
  define :FILE_RESPONSE, 123
149
151
  define :SUBSYSTEM_INIT, 124
150
152
  define :SUBSYSTEM_EXIT, 125
153
+ define :GRAPH_REQUEST, 130
154
+ define :GRAPH_RESPONSE, 131
151
155
  end
152
156
 
153
157
  end
@@ -252,6 +256,8 @@ module TRP
252
256
  class AsyncRequest < ::Protobuf::Message; end
253
257
  class FileRequest < ::Protobuf::Message; end
254
258
  class FileResponse < ::Protobuf::Message; end
259
+ class GraphRequest < ::Protobuf::Message; end
260
+ class GraphResponse < ::Protobuf::Message; end
255
261
 
256
262
 
257
263
  ##
@@ -389,6 +395,16 @@ module TRP
389
395
  optional :string, :probe_id, 5
390
396
  end
391
397
 
398
+ class VertexGroupT
399
+ required :string, :vertex_group, 1
400
+ repeated ::TRP::KeyT, :vertex_keys, 2
401
+ end
402
+
403
+ class EdgeGraphT
404
+ required ::TRP::TimeInterval, :time_interval, 4
405
+ repeated ::TRP::VertexGroupT, :vertex_groups, 3
406
+ end
407
+
392
408
  class NameValue
393
409
  required :string, :name, 1
394
410
  optional :string, :value, 2
@@ -454,6 +470,8 @@ module TRP
454
470
  optional ::TRP::AsyncResponse, :async_response, 121
455
471
  optional ::TRP::FileRequest, :file_request, 122
456
472
  optional ::TRP::FileResponse, :file_response, 123
473
+ optional ::TRP::GraphRequest, :graph_request, 130
474
+ optional ::TRP::GraphResponse, :graph_response, 131
457
475
  optional :string, :destination_node, 200
458
476
  optional :string, :probe_id, 201
459
477
  optional :bool, :run_async, 202
@@ -986,5 +1004,18 @@ module TRP
986
1004
  optional :string, :context_name, 6
987
1005
  end
988
1006
 
1007
+ class GraphRequest
1008
+ required ::TRP::TimeInterval, :time_interval, 1
1009
+ required :string, :subject_group, 2
1010
+ required ::TRP::KeyT, :subject_key, 3
1011
+ optional :string, :vertex_group, 4
1012
+ end
1013
+
1014
+ class GraphResponse
1015
+ required :string, :subject_group, 1
1016
+ required ::TRP::KeyT, :subject_key, 2
1017
+ repeated ::TRP::EdgeGraphT, :graphs, 3
1018
+ end
1019
+
989
1020
  end
990
1021
 
@@ -194,10 +194,25 @@ message DocumentT {
194
194
  required string key=2;
195
195
  }
196
196
 
197
- repeated Flow flows=4; /// list of flows where this doc was seen
197
+ repeated Flow flows=4; /// list of flows where this doc was seen
198
198
  optional string probe_id=5;
199
199
  }
200
200
 
201
+ /// VertexGroupT : a group of vertices
202
+ ///
203
+ message VertexGroupT {
204
+ required string vertex_group=1; /// GUID of vertices in this message
205
+ repeated KeyT vertex_keys=2; /// list of vertices
206
+ }
207
+
208
+
209
+ /// EdgeGraphT : a graph
210
+ /// subjectnode -> vertices(of a particular type)
211
+ message EdgeGraphT {
212
+ required TimeInterval time_interval=4; /// covers this window
213
+ repeated VertexGroupT vertex_groups=3; /// vertices grouped by type
214
+ }
215
+
201
216
 
202
217
  /// Enums
203
218
  /// Auth Level
@@ -314,7 +329,8 @@ message Message {
314
329
  FILE_RESPONSE=123;
315
330
  SUBSYSTEM_INIT=124; // init msg used to prepare services
316
331
  SUBSYSTEM_EXIT=125;
317
-
332
+ GRAPH_REQUEST=130;
333
+ GRAPH_RESPONSE=131;
318
334
  }
319
335
 
320
336
  required Command trp_command=1;
@@ -376,6 +392,8 @@ message Message {
376
392
  optional AsyncResponse async_response=121;
377
393
  optional FileRequest file_request=122;
378
394
  optional FileResponse file_response=123;
395
+ optional GraphRequest graph_request=130;
396
+ optional GraphResponse graph_response=131;
379
397
  optional string destination_node=200; // todo move 2nd
380
398
  optional string probe_id=201; // todo move 3rd
381
399
  optional bool run_async=202; /// if run_async = true, then you will immediately get a AsynResponse with a token you can poll
@@ -444,7 +462,7 @@ message CounterGroupTopperRequest{
444
462
  required string counter_group=2; /// guid of CG
445
463
  optional int64 meter=3 [default=0]; /// meter; eg to get Top Hosts By Connections use cg=Hosts meter = 6(connections)
446
464
  optional int64 maxitems=4 [default=100]; /// number of top items to retreive
447
- optional TimeInterval time_interval=5; /// time interval
465
+ optional TimeInterval time_interval=5; /// time interval , leave blank for latest interval
448
466
  optional Timestamp time_instant=6; ///
449
467
  optional int64 flags=7;
450
468
  optional bool resolve_keys=8 [default=true]; /// retrieve labels as set in the response for each key
@@ -1082,4 +1100,19 @@ message FileResponse {
1082
1100
  optional string context_name=6;
1083
1101
  }
1084
1102
 
1103
+ /// GraphRequest
1104
+ /// given a subject node, retrive a graph for a given time window
1105
+ message GraphRequest {
1106
+ required TimeInterval time_interval=1; /// time window
1107
+ required string subject_group=2; /// guid of subject, eg counter or alert guid
1108
+ required KeyT subject_key=3; /// key (can specify key.key, key.label, etc too
1109
+ optional string vertex_group=4; /// optional vertex group (only get vertices in this group)
1110
+ }
1111
+
1112
+ message GraphResponse {
1113
+ required string subject_group=1; /// from request
1114
+ required KeyT subject_key=2; /// from request
1115
+ repeated EdgeGraphT graphs=3; /// graphs - an EdgeGraphT message
1116
+ /// repeated because returned in time chunks
1117
+ }
1085
1118
 
data/trisulrp.gemspec CHANGED
@@ -2,16 +2,16 @@
2
2
  # DO NOT EDIT THIS FILE DIRECTLY
3
3
  # Instead, edit Juwelier::Tasks in Rakefile, and run 'rake gemspec'
4
4
  # -*- encoding: utf-8 -*-
5
- # stub: trisulrp 3.1.16 ruby lib
5
+ # stub: trisulrp 3.2.2 ruby lib
6
6
 
7
7
  Gem::Specification.new do |s|
8
8
  s.name = "trisulrp"
9
- s.version = "3.1.16"
9
+ s.version = "3.2.2"
10
10
 
11
11
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
12
12
  s.require_paths = ["lib"]
13
13
  s.authors = ["vivek"]
14
- s.date = "2017-07-12"
14
+ s.date = "2017-11-09"
15
15
  s.description = "This gem deals about the trisul remote protocol"
16
16
  s.email = "vivek_rajagopal@yahoo.com"
17
17
  s.extra_rdoc_files = [
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: trisulrp
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.16
4
+ version: 3.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - vivek
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-07-12 00:00:00.000000000 Z
11
+ date: 2017-11-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: protobuf