hawkular-client 0.2.2 → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (108) hide show
  1. checksums.yaml +4 -4
  2. data/.rubocop.yml +3 -0
  3. data/.yardopts +1 -0
  4. data/CHANGES.rdoc +17 -4
  5. data/README.rdoc +15 -6
  6. data/api_breaking_changes.rdoc +79 -0
  7. data/hawkularclient.gemspec +6 -5
  8. data/lib/{alerts → hawkular/alerts}/alerts_api.rb +168 -7
  9. data/lib/{hawkular.rb → hawkular/base_client.rb} +7 -44
  10. data/lib/hawkular/hawkular_client.rb +60 -0
  11. data/lib/hawkular/hawkular_client_utils.rb +40 -0
  12. data/lib/{inventory → hawkular/inventory}/inventory_api.rb +167 -142
  13. data/lib/{metrics → hawkular/metrics}/metric_api.rb +1 -0
  14. data/lib/{metrics → hawkular/metrics}/metrics_client.rb +4 -4
  15. data/lib/{metrics → hawkular/metrics}/tenant_api.rb +0 -0
  16. data/lib/{metrics → hawkular/metrics}/types.rb +0 -0
  17. data/lib/{operations → hawkular/operations}/operations_api.rb +11 -8
  18. data/lib/{tokens → hawkular/tokens}/tokens_api.rb +1 -1
  19. data/lib/{version.rb → hawkular/version.rb} +1 -1
  20. data/spec/integration/alerts_spec.rb +200 -0
  21. data/spec/integration/hawkular_client_spec.rb +228 -0
  22. data/spec/integration/inventory_spec.rb +246 -160
  23. data/spec/integration/metric_spec.rb +52 -59
  24. data/spec/integration/operations_spec.rb +53 -29
  25. data/spec/spec_helper.rb +109 -8
  26. data/spec/unit/base_spec.rb +9 -0
  27. data/spec/unit/canonical_path_spec.rb +2 -2
  28. data/spec/vcr/vcr_setup.rb +6 -0
  29. data/spec/vcr_cassettes/Alert/Events/Should_create_an_event.yml +50 -0
  30. data/spec/vcr_cassettes/Alert/Groups/Should_operate_a_complex_group_trigger.yml +1726 -0
  31. data/spec/vcr_cassettes/Counter_metrics/Should_get_metrics_as_bucketed_results.yml +190 -0
  32. data/spec/vcr_cassettes/Counter_metrics/Should_get_metrics_with_limit_and_order.yml +30 -42
  33. data/spec/vcr_cassettes/HawkularClient/and_Inventory_client/Should_both_create_and_delete_feed.yml +287 -0
  34. data/spec/vcr_cassettes/{Inventory/Should_list_URLs.yml → HawkularClient/and_Inventory_client/Should_both_list_WildFlys.yml} +35 -33
  35. data/spec/vcr_cassettes/{Inventory/Should_list_types_with_bad_feed.yml → HawkularClient/and_Inventory_client/Should_both_list_types_with_bad_feed.yml} +16 -19
  36. data/spec/vcr_cassettes/HawkularClient/and_Inventory_client/Should_list_same_types_when_param_is_given.yml +245 -0
  37. data/spec/vcr_cassettes/{Inventory/Should_list_feeds.yml → HawkularClient/and_Inventory_client/Should_list_the_same_feeds.yml} +20 -20
  38. data/spec/vcr_cassettes/HawkularClient/and_Inventory_client/Should_list_the_same_resource_types.yml +249 -0
  39. data/spec/vcr_cassettes/HawkularClient/and_Metrics_client/Should_both_create_and_retrieve_tags_for_Availability.yml +155 -0
  40. data/spec/vcr_cassettes/HawkularClient/and_Metrics_client/Should_both_create_and_return_Availability_using_Hash_parameter.yml +155 -0
  41. data/spec/vcr_cassettes/HawkularClient/and_Metrics_client/Should_both_return_the_version.yml +89 -0
  42. data/spec/vcr_cassettes/HawkularClient/and_Metrics_client/Should_both_work_the_same_way_when_pushing_metric_data_to_non-existing_counter.yml +114 -0
  43. data/spec/vcr_cassettes/{Inventory/Should_list_WildFlys_with_props.yml → HawkularClient/and_Operations_client/Should_both_work_the_same_way.yml} +28 -50
  44. data/spec/vcr_cassettes/HawkularClient/and_Operations_client_Should_both_work_the_same_way.json +44 -0
  45. data/spec/vcr_cassettes/Inventory/Helpers/create_url.yml +48 -0
  46. data/spec/vcr_cassettes/Inventory/Helpers/generate_some_events_for_websocket.yml +4446 -0
  47. data/spec/vcr_cassettes/Inventory/Helpers/get_feeds.yml +54 -0
  48. data/spec/vcr_cassettes/Inventory/Templates/Client_should_listen_on_various_inventory_events.json +47 -0
  49. data/spec/vcr_cassettes/Inventory/{Should_create_a_resourcetype.yml → Templates/Client_should_listen_on_various_inventory_events.yml} +47 -61
  50. data/spec/vcr_cassettes/Inventory/Templates/Helpers/generate_some_events_for_websocket.yml +542 -0
  51. data/spec/vcr_cassettes/Inventory/{Should_List_datasources_with_no_props.yml → Templates/Should_List_datasources_with_no_props.yml} +26 -85
  52. data/spec/vcr_cassettes/Inventory/Templates/Should_create_a_feed.yml +54 -0
  53. data/spec/vcr_cassettes/Inventory/Templates/Should_create_a_feed_again.yml +164 -0
  54. data/spec/vcr_cassettes/Inventory/{Should_create_a_nested_resource_and_metric_on_it.yml → Templates/Should_create_a_nested_resource_and_metric_on_it.yml} +93 -74
  55. data/spec/vcr_cassettes/Inventory/{Should_create_a_resource_.yml → Templates/Should_create_a_resource.yml} +103 -76
  56. data/spec/vcr_cassettes/Inventory/{Should_create_a_resource_with_metric.yml → Templates/Should_create_a_resource_with_metric.yml} +91 -197
  57. data/spec/vcr_cassettes/Inventory/Templates/Should_create_a_resourcetype.yml +154 -0
  58. data/spec/vcr_cassettes/Inventory/Templates/Should_create_and_delete_feed.yml +145 -0
  59. data/spec/vcr_cassettes/Inventory/{Should_create_and_get_a_resource.yml → Templates/Should_create_and_get_a_resource.yml} +35 -20
  60. data/spec/vcr_cassettes/Inventory/Templates/Should_list_URLs.yml +65 -0
  61. data/spec/vcr_cassettes/Inventory/Templates/Should_list_WildFlys.yml +61 -0
  62. data/spec/vcr_cassettes/Inventory/{Should_list_WildFlys.yml → Templates/Should_list_WildFlys_with_props.yml} +36 -33
  63. data/spec/vcr_cassettes/Inventory/Templates/Should_list_all_the_resource_types.yml +126 -0
  64. data/spec/vcr_cassettes/Inventory/{Should_list_children_of_WildFly.yml → Templates/Should_list_children_of_WildFly.yml} +66 -112
  65. data/spec/vcr_cassettes/Inventory/{Should_list_children_of_nested_resource.yml → Templates/Should_list_children_of_nested_resource.yml} +13 -13
  66. data/spec/vcr_cassettes/Inventory/Templates/Should_list_feeds.yml +54 -0
  67. data/spec/vcr_cassettes/Inventory/Templates/Should_list_heap_metrics_for_WildFlys.yml +712 -0
  68. data/spec/vcr_cassettes/Inventory/Templates/Should_list_metrics_for_WildFlys.yml +278 -0
  69. data/spec/vcr_cassettes/Inventory/Templates/Should_list_metrics_of_given_metric_type.yml +530 -0
  70. data/spec/vcr_cassettes/Inventory/Templates/Should_list_metrics_of_given_resource_type.yml +278 -0
  71. data/spec/vcr_cassettes/Inventory/Templates/Should_list_operation_definitions_of_given_resource.yml +185 -0
  72. data/spec/vcr_cassettes/Inventory/Templates/Should_list_operation_definitions_of_given_resource_type.yml +126 -0
  73. data/spec/vcr_cassettes/Inventory/Templates/Should_list_recursive_children_of_WildFly.yml +2369 -0
  74. data/spec/vcr_cassettes/Inventory/Templates/Should_list_relationships_of_WildFly.yml +415 -0
  75. data/spec/vcr_cassettes/Inventory/Templates/Should_list_types_with_bad_feed.yml +51 -0
  76. data/spec/vcr_cassettes/Inventory/Templates/Should_list_types_with_feed.yml +124 -0
  77. data/spec/vcr_cassettes/Inventory/{Should_not_find_an_unknown_resource.yml → Templates/Should_not_find_an_unknown_resource.yml} +14 -13
  78. data/spec/vcr_cassettes/Inventory/{Should_return_config_data_of_given_nested_resource.yml → Templates/Should_return_config_data_of_given_nested_resource.yml} +4 -4
  79. data/spec/vcr_cassettes/Inventory/{Should_return_config_data_of_given_resource.yml → Templates/Should_return_config_data_of_given_resource.yml} +4 -4
  80. data/spec/vcr_cassettes/Inventory/Tenants/Should_Get_Tenant_For_Explicit_Credentials.yml +50 -0
  81. data/spec/vcr_cassettes/Inventory/Tenants/Should_Get_Tenant_For_Implicit_Credentials.yml +50 -0
  82. data/spec/vcr_cassettes/Operation/Helpers/get_feed.yml +54 -0
  83. data/spec/vcr_cassettes/Operation/Helpers/get_tenant.yml +50 -0
  84. data/spec/vcr_cassettes/Operation/Operation/Add_JDBC_driver_should_add_the_driver.json +26 -0
  85. data/spec/vcr_cassettes/Operation/Operation/Add_datasource_should_be_doable.json +26 -0
  86. data/spec/vcr_cassettes/Operation/Operation/Add_deployment_should_be_doable.json +26 -0
  87. data/spec/vcr_cassettes/Operation/Operation/Redeploy_can_be_run_multiple_times_in_parallel.json +40 -0
  88. data/spec/vcr_cassettes/Operation/Operation/Redeploy_should_be_performed_and_eventually_respond_with_success.json +26 -0
  89. data/spec/vcr_cassettes/Operation/Operation/Redeploy_should_not_be_performed_if_resource_path_is_wrong.json +26 -0
  90. data/spec/vcr_cassettes/Operation/Operation/Remove_JDBC_driver_should_be_performed_and_eventually_respond_with_success.json +26 -0
  91. data/spec/vcr_cassettes/Operation/Operation/Remove_datasource_should_be_performed_and_eventually_respond_with_success.json +26 -0
  92. data/spec/vcr_cassettes/Operation/Operation/Remove_deployment_should_be_performed_and_eventually_respond_with_success.json +26 -0
  93. data/spec/vcr_cassettes/Operation/Operation/Undeploy_should_be_performed_and_eventually_respond_with_success.json +26 -0
  94. data/spec/vcr_cassettes/Operation/Operation/should_not_be_possible_to_perform_on_closed_client.json +12 -0
  95. data/spec/vcr_cassettes/Operation/Websocket_connection/should_be_established.json +9 -0
  96. metadata +171 -72
  97. data/lib/hawkular_all.rb +0 -9
  98. data/spec/vcr_cassettes/Inventory/Should_create_a_feed.yml +0 -107
  99. data/spec/vcr_cassettes/Inventory/Should_create_a_feed_again.yml +0 -211
  100. data/spec/vcr_cassettes/Inventory/Should_create_and_delete_feed.yml +0 -201
  101. data/spec/vcr_cassettes/Inventory/Should_list_all_the_resource_types.yml +0 -177
  102. data/spec/vcr_cassettes/Inventory/Should_list_heap_metrics_for_WildFlys.yml +0 -775
  103. data/spec/vcr_cassettes/Inventory/Should_list_metrics_for_WildFlys.yml +0 -333
  104. data/spec/vcr_cassettes/Inventory/Should_list_metrics_of_given_metric_type.yml +0 -613
  105. data/spec/vcr_cassettes/Inventory/Should_list_metrics_of_given_resource_type.yml +0 -333
  106. data/spec/vcr_cassettes/Inventory/Should_list_recursive_children_of_WildFly.yml +0 -2064
  107. data/spec/vcr_cassettes/Inventory/Should_list_relationships_of_WildFly.yml +0 -460
  108. data/spec/vcr_cassettes/Inventory/Should_list_types_with_feed.yml +0 -175
@@ -0,0 +1,190 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: http://jdoe:password@localhost:8080/hawkular/metrics/counters
6
+ body:
7
+ encoding: UTF-8
8
+ string: '{"id":"<%= id %>"}'
9
+ headers:
10
+ Accept:
11
+ - application/json
12
+ Accept-Encoding:
13
+ - gzip, deflate
14
+ Content-Type:
15
+ - application/json
16
+ Content-Length:
17
+ - '45'
18
+ User-Agent:
19
+ - Ruby
20
+ response:
21
+ status:
22
+ code: 201
23
+ message: Created
24
+ headers:
25
+ Connection:
26
+ - keep-alive
27
+ X-Powered-By:
28
+ - Undertow/1
29
+ Server:
30
+ - WildFly/10
31
+ Location:
32
+ - http://localhost:8080/hawkular/metrics/counters/<%= id %>
33
+ Content-Length:
34
+ - '0'
35
+ Date:
36
+ - Tue, 10 May 2016 09:54:44 GMT
37
+ body:
38
+ encoding: UTF-8
39
+ string: ''
40
+ http_version:
41
+ recorded_at: Tue, 10 May 2016 09:54:44 GMT
42
+ - request:
43
+ method: post
44
+ uri: http://jdoe:password@localhost:8080/hawkular/metrics/counters/<%= id %>/data
45
+ body:
46
+ encoding: UTF-8
47
+ string: '[{"value":110,"timestamp":<%= now - 110 %>},{"value":100,"timestamp":<%= now - 100 %>},{"value":90,"timestamp":<%= now - 90 %>},{"value":80,"timestamp":<%= now - 80 %>},{"value":70,"timestamp":<%= now - 70 %>},{"value":60,"timestamp":<%= now - 60 %>},{"value":50,"timestamp":<%= now - 50 %>},{"value":40,"timestamp":<%= now - 40 %>},{"value":30,"timestamp":<%= now - 30 %>},{"value":20,"timestamp":<%= now - 20 %>},{"value":10,"timestamp":<%= now - 10 %>}]'
48
+ headers:
49
+ Accept:
50
+ - application/json
51
+ Accept-Encoding:
52
+ - gzip, deflate
53
+ Content-Type:
54
+ - application/json
55
+ Content-Length:
56
+ - '432'
57
+ User-Agent:
58
+ - Ruby
59
+ response:
60
+ status:
61
+ code: 200
62
+ message: OK
63
+ headers:
64
+ Connection:
65
+ - keep-alive
66
+ X-Powered-By:
67
+ - Undertow/1
68
+ Server:
69
+ - WildFly/10
70
+ Content-Length:
71
+ - '0'
72
+ Date:
73
+ - Tue, 10 May 2016 09:54:44 GMT
74
+ body:
75
+ encoding: UTF-8
76
+ string: ''
77
+ http_version:
78
+ recorded_at: Tue, 10 May 2016 09:54:44 GMT
79
+ - request:
80
+ method: get
81
+ uri: http://jdoe:password@localhost:8080/hawkular/metrics/counters/<%= id %>/data/?buckets=5&end=<%= now - 5 %>&start=<%= now - 105 %>
82
+ body:
83
+ encoding: US-ASCII
84
+ string: ''
85
+ headers:
86
+ Accept:
87
+ - application/json
88
+ Accept-Encoding:
89
+ - gzip, deflate
90
+ Content-Type:
91
+ - application/json
92
+ User-Agent:
93
+ - Ruby
94
+ response:
95
+ status:
96
+ code: 200
97
+ message: OK
98
+ headers:
99
+ Connection:
100
+ - keep-alive
101
+ X-Powered-By:
102
+ - Undertow/1
103
+ Server:
104
+ - WildFly/10
105
+ Content-Type:
106
+ - application/json
107
+ Content-Length:
108
+ - '587'
109
+ Date:
110
+ - Tue, 10 May 2016 09:54:44 GMT
111
+ body:
112
+ encoding: ASCII-8BIT
113
+ string: '[{"start":<%= now - 105 %>,"end":<%= now - 85 %>,"min":90.0,"avg":95.0,"median":90.0,"max":100.0,"samples":2,"empty":false},{"start":<%= now - 85 %>,"end":<%= now - 65 %>,"min":70.0,"avg":75.0,"median":70.0,"max":80.0,"samples":2,"empty":false},{"start":<%= now - 65 %>,"end":<%= now - 45 %>,"min":50.0,"avg":55.0,"median":50.0,"max":60.0,"samples":2,"empty":false},{"start":<%= now - 45 %>,"end":<%= now - 25 %>,"min":30.0,"avg":35.0,"median":30.0,"max":40.0,"samples":2,"empty":false},{"start":<%= now - 25 %>,"end":<%= now - 5 %>,"min":10.0,"avg":15.0,"median":10.0,"max":20.0,"samples":2,"empty":false}]'
114
+ http_version:
115
+ recorded_at: Tue, 10 May 2016 09:54:44 GMT
116
+ - request:
117
+ method: get
118
+ uri: http://jdoe:password@localhost:8080/hawkular/metrics/counters/<%= id %>/data/?buckets=2&end=<%= now - 5 %>&start=<%= now - 105 %>
119
+ body:
120
+ encoding: US-ASCII
121
+ string: ''
122
+ headers:
123
+ Accept:
124
+ - application/json
125
+ Accept-Encoding:
126
+ - gzip, deflate
127
+ Content-Type:
128
+ - application/json
129
+ User-Agent:
130
+ - Ruby
131
+ response:
132
+ status:
133
+ code: 200
134
+ message: OK
135
+ headers:
136
+ Connection:
137
+ - keep-alive
138
+ X-Powered-By:
139
+ - Undertow/1
140
+ Server:
141
+ - WildFly/10
142
+ Content-Type:
143
+ - application/json
144
+ Content-Length:
145
+ - '236'
146
+ Date:
147
+ - Tue, 10 May 2016 09:54:44 GMT
148
+ body:
149
+ encoding: ASCII-8BIT
150
+ string: '[{"start":<%= now - 105 %>,"end":<%= now - 55 %>,"min":60.0,"avg":80.0,"median":80.0,"max":100.0,"samples":5,"empty":false},{"start":<%= now - 55 %>,"end":<%= now - 5 %>,"min":10.0,"avg":30.0,"median":30.0,"max":50.0,"samples":5,"empty":false}]'
151
+ http_version:
152
+ recorded_at: Tue, 10 May 2016 09:54:44 GMT
153
+ - request:
154
+ method: get
155
+ uri: http://jdoe:password@localhost:8080/hawkular/metrics/counters/<%= id %>/data/?bucketDuration=50ms&end=<%= now - 5 %>&start=<%= now - 105 %>
156
+ body:
157
+ encoding: US-ASCII
158
+ string: ''
159
+ headers:
160
+ Accept:
161
+ - application/json
162
+ Accept-Encoding:
163
+ - gzip, deflate
164
+ Content-Type:
165
+ - application/json
166
+ User-Agent:
167
+ - Ruby
168
+ response:
169
+ status:
170
+ code: 200
171
+ message: OK
172
+ headers:
173
+ Connection:
174
+ - keep-alive
175
+ X-Powered-By:
176
+ - Undertow/1
177
+ Server:
178
+ - WildFly/10
179
+ Content-Type:
180
+ - application/json
181
+ Content-Length:
182
+ - '236'
183
+ Date:
184
+ - Tue, 10 May 2016 09:54:44 GMT
185
+ body:
186
+ encoding: ASCII-8BIT
187
+ string: '[{"start":<%= now - 105 %>,"end":<%= now - 55 %>,"min":60.0,"avg":80.0,"median":80.0,"max":100.0,"samples":5,"empty":false},{"start":<%= now - 55 %>,"end":<%= now - 5 %>,"min":10.0,"avg":30.0,"median":30.0,"max":50.0,"samples":5,"empty":false}]'
188
+ http_version:
189
+ recorded_at: Tue, 10 May 2016 09:54:44 GMT
190
+ recorded_with: VCR 3.0.1
@@ -5,7 +5,7 @@ http_interactions:
5
5
  uri: http://jdoe:password@localhost:8080/hawkular/metrics/counters
6
6
  body:
7
7
  encoding: UTF-8
8
- string: '{"id":"33c6a285-495a-4442-a818-974b03408a6f"}'
8
+ string: '{"id":"<%= id %>"}'
9
9
  headers:
10
10
  Accept:
11
11
  - application/json
@@ -29,22 +29,22 @@ http_interactions:
29
29
  Server:
30
30
  - WildFly/10
31
31
  Location:
32
- - http://localhost:8080/hawkular/metrics/counters/33c6a285-495a-4442-a818-974b03408a6f
32
+ - http://localhost:8080/hawkular/metrics/counters/<%= id %>
33
33
  Content-Length:
34
34
  - '0'
35
35
  Date:
36
- - Tue, 22 Mar 2016 17:11:09 GMT
36
+ - Tue, 10 May 2016 10:07:07 GMT
37
37
  body:
38
38
  encoding: UTF-8
39
39
  string: ''
40
40
  http_version:
41
- recorded_at: Tue, 22 Mar 2016 17:11:09 GMT
41
+ recorded_at: Tue, 10 May 2016 10:07:07 GMT
42
42
  - request:
43
43
  method: post
44
- uri: http://jdoe:password@localhost:8080/hawkular/metrics/counters/33c6a285-495a-4442-a818-974b03408a6f/data
44
+ uri: http://jdoe:password@localhost:8080/hawkular/metrics/counters/<%= id %>/data
45
45
  body:
46
46
  encoding: UTF-8
47
- string: '[{"value":1,"timestamp":1458666669233},{"value":2,"timestamp":1458666669243},{"value":3,"timestamp":1458666669253}]'
47
+ string: '[{"value":1,"timestamp":<%= minus30 %>},{"value":2,"timestamp":<%= minus20 %>},{"value":3,"timestamp":<%= minus10 %>}]'
48
48
  headers:
49
49
  Accept:
50
50
  - application/json
@@ -70,15 +70,15 @@ http_interactions:
70
70
  Content-Length:
71
71
  - '0'
72
72
  Date:
73
- - Tue, 22 Mar 2016 17:11:09 GMT
73
+ - Tue, 10 May 2016 10:07:07 GMT
74
74
  body:
75
75
  encoding: UTF-8
76
76
  string: ''
77
77
  http_version:
78
- recorded_at: Tue, 22 Mar 2016 17:11:09 GMT
78
+ recorded_at: Tue, 10 May 2016 10:07:07 GMT
79
79
  - request:
80
80
  method: get
81
- uri: http://jdoe:password@localhost:8080/hawkular/metrics/counters/33c6a285-495a-4442-a818-974b03408a6f/data/
81
+ uri: http://jdoe:password@localhost:8080/hawkular/metrics/counters/<%= id %>/data/
82
82
  body:
83
83
  encoding: US-ASCII
84
84
  string: ''
@@ -96,8 +96,6 @@ http_interactions:
96
96
  code: 200
97
97
  message: OK
98
98
  headers:
99
- Content-Encoding:
100
- - gzip
101
99
  Connection:
102
100
  - keep-alive
103
101
  X-Powered-By:
@@ -107,22 +105,20 @@ http_interactions:
107
105
  Content-Type:
108
106
  - application/json
109
107
  Content-Length:
110
- - '71'
108
+ - '115'
111
109
  Date:
112
- - Tue, 22 Mar 2016 17:11:09 GMT
110
+ - Tue, 10 May 2016 10:07:07 GMT
113
111
  body:
114
112
  encoding: ASCII-8BIT
115
- string: !binary |-
116
- H4sIAAAAAAAAAIuuVirJzE0tLknMLVCyMjQxtTADAUsjU2MdpbLEnNJUJSvj
117
- Wh1cqkwQqoxwqzJGqDKsjQUASv4SJXMAAAA=
113
+ string: '[{"timestamp":<%= minus10 %>,"value":3},{"timestamp":<%= minus20 %>,"value":2},{"timestamp":<%= minus30 %>,"value":1}]'
118
114
  http_version:
119
- recorded_at: Tue, 22 Mar 2016 17:11:09 GMT
115
+ recorded_at: Tue, 10 May 2016 10:07:07 GMT
120
116
  - request:
121
117
  method: post
122
- uri: http://jdoe:password@localhost:8080/hawkular/metrics/counters/33c6a285-495a-4442-a818-974b03408a6f/data
118
+ uri: http://jdoe:password@localhost:8080/hawkular/metrics/counters/<%= id %>/data
123
119
  body:
124
120
  encoding: UTF-8
125
- string: '[{"value":4,"timestamp":1458666669360}]'
121
+ string: '[{"value":4,"timestamp":1462874827811}]'
126
122
  headers:
127
123
  Accept:
128
124
  - application/json
@@ -148,15 +144,15 @@ http_interactions:
148
144
  Content-Length:
149
145
  - '0'
150
146
  Date:
151
- - Tue, 22 Mar 2016 17:11:09 GMT
147
+ - Tue, 10 May 2016 10:07:07 GMT
152
148
  body:
153
149
  encoding: UTF-8
154
150
  string: ''
155
151
  http_version:
156
- recorded_at: Tue, 22 Mar 2016 17:11:09 GMT
152
+ recorded_at: Tue, 10 May 2016 10:07:07 GMT
157
153
  - request:
158
154
  method: get
159
- uri: http://jdoe:password@localhost:8080/hawkular/metrics/counters/33c6a285-495a-4442-a818-974b03408a6f/data/
155
+ uri: http://jdoe:password@localhost:8080/hawkular/metrics/counters/<%= id %>/data/
160
156
  body:
161
157
  encoding: US-ASCII
162
158
  string: ''
@@ -174,8 +170,6 @@ http_interactions:
174
170
  code: 200
175
171
  message: OK
176
172
  headers:
177
- Content-Encoding:
178
- - gzip
179
173
  Connection:
180
174
  - keep-alive
181
175
  X-Powered-By:
@@ -185,19 +179,17 @@ http_interactions:
185
179
  Content-Type:
186
180
  - application/json
187
181
  Content-Length:
188
- - '79'
182
+ - '153'
189
183
  Date:
190
- - Tue, 22 Mar 2016 17:11:09 GMT
184
+ - Tue, 10 May 2016 10:07:07 GMT
191
185
  body:
192
186
  encoding: ASCII-8BIT
193
- string: !binary |-
194
- H4sIAAAAAAAAAIuuVirJzE0tLknMLVCyMjQxtTADAUtjMwMdpbLEnNJUJSuT
195
- Wh0cqoxMjeGqjHGrMkGoMsKtyhihyrA2FgCWa63dmQAAAA==
187
+ string: '[{"timestamp":1462874827811,"value":4},{"timestamp":<%= minus10 %>,"value":3},{"timestamp":<%= minus20 %>,"value":2},{"timestamp":<%= minus30 %>,"value":1}]'
196
188
  http_version:
197
- recorded_at: Tue, 22 Mar 2016 17:11:09 GMT
189
+ recorded_at: Tue, 10 May 2016 10:07:07 GMT
198
190
  - request:
199
191
  method: get
200
- uri: http://jdoe:password@localhost:8080/hawkular/metrics/counters/33c6a285-495a-4442-a818-974b03408a6f/data/?limit=1
192
+ uri: http://jdoe:password@localhost:8080/hawkular/metrics/counters/<%= id %>/data/?limit=1&order=DESC
201
193
  body:
202
194
  encoding: US-ASCII
203
195
  string: ''
@@ -215,8 +207,6 @@ http_interactions:
215
207
  code: 200
216
208
  message: OK
217
209
  headers:
218
- Content-Encoding:
219
- - gzip
220
210
  Connection:
221
211
  - keep-alive
222
212
  X-Powered-By:
@@ -226,19 +216,17 @@ http_interactions:
226
216
  Content-Type:
227
217
  - application/json
228
218
  Content-Length:
229
- - '56'
219
+ - '39'
230
220
  Date:
231
- - Tue, 22 Mar 2016 17:11:09 GMT
221
+ - Tue, 10 May 2016 10:07:07 GMT
232
222
  body:
233
223
  encoding: ASCII-8BIT
234
- string: !binary |-
235
- H4sIAAAAAAAAAIuuVirJzE0tLknMLVCyMjQxtTADAUtjMwMdpbLEnNJUJSuT
236
- 2lgAsUFY2CcAAAA=
224
+ string: '[{"timestamp":1462874827811,"value":4}]'
237
225
  http_version:
238
- recorded_at: Tue, 22 Mar 2016 17:11:09 GMT
226
+ recorded_at: Tue, 10 May 2016 10:07:07 GMT
239
227
  - request:
240
228
  method: get
241
- uri: http://jdoe:password@localhost:8080/hawkular/metrics/counters/33c6a285-495a-4442-a818-974b03408a6f/data/?end=1458652269263&start=1458637869263
229
+ uri: http://jdoe:password@localhost:8080/hawkular/metrics/counters/<%= id %>/data/?end=1462857884000&start=1462843484000
242
230
  body:
243
231
  encoding: US-ASCII
244
232
  string: ''
@@ -261,10 +249,10 @@ http_interactions:
261
249
  Server:
262
250
  - WildFly/10
263
251
  Date:
264
- - Tue, 22 Mar 2016 17:11:09 GMT
252
+ - Tue, 10 May 2016 10:07:07 GMT
265
253
  body:
266
254
  encoding: UTF-8
267
255
  string: ''
268
256
  http_version:
269
- recorded_at: Tue, 22 Mar 2016 17:11:09 GMT
257
+ recorded_at: Tue, 10 May 2016 10:07:07 GMT
270
258
  recorded_with: VCR 3.0.1
@@ -0,0 +1,287 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: http://jdoe:password@localhost:8080/hawkular/inventory/feeds/
6
+ body:
7
+ encoding: UTF-8
8
+ string: '{"properties":{},"id":"feed_1123sdn","name":null,"outgoing":{},"incoming":{}}'
9
+ headers:
10
+ Accept:
11
+ - application/json
12
+ Accept-Encoding:
13
+ - gzip, deflate
14
+ Content-Type:
15
+ - application/json
16
+ Content-Length:
17
+ - '77'
18
+ User-Agent:
19
+ - Ruby
20
+ response:
21
+ status:
22
+ code: 201
23
+ message: Created
24
+ headers:
25
+ Expires:
26
+ - '0'
27
+ Cache-Control:
28
+ - no-cache, no-store, must-revalidate
29
+ X-Powered-By:
30
+ - Undertow/1
31
+ Server:
32
+ - WildFly/10
33
+ Pragma:
34
+ - no-cache
35
+ Location:
36
+ - http://localhost:8080/hawkular/inventory/feeds/feed_1123sdn
37
+ Date:
38
+ - Tue, 29 Mar 2016 15:26:12 GMT
39
+ Connection:
40
+ - keep-alive
41
+ Content-Type:
42
+ - application/json
43
+ Content-Length:
44
+ - '96'
45
+ body:
46
+ encoding: ASCII-8BIT
47
+ string: |-
48
+ {
49
+ "path" : "/t;28026b36-8fe4-4332-84c8-524e173a68bf/f;feed_1123sdn",
50
+ "id" : "feed_1123sdn"
51
+ }
52
+ http_version:
53
+ recorded_at: Tue, 29 Mar 2016 15:26:12 GMT
54
+ - request:
55
+ method: post
56
+ uri: http://jdoe:password@localhost:8080/hawkular/inventory/feeds/
57
+ body:
58
+ encoding: UTF-8
59
+ string: '{"properties":{},"id":"feed_1124sdn","name":null,"outgoing":{},"incoming":{}}'
60
+ headers:
61
+ Accept:
62
+ - application/json
63
+ Accept-Encoding:
64
+ - gzip, deflate
65
+ Content-Type:
66
+ - application/json
67
+ Content-Length:
68
+ - '77'
69
+ User-Agent:
70
+ - Ruby
71
+ response:
72
+ status:
73
+ code: 201
74
+ message: Created
75
+ headers:
76
+ Expires:
77
+ - '0'
78
+ Cache-Control:
79
+ - no-cache, no-store, must-revalidate
80
+ X-Powered-By:
81
+ - Undertow/1
82
+ Server:
83
+ - WildFly/10
84
+ Pragma:
85
+ - no-cache
86
+ Location:
87
+ - http://localhost:8080/hawkular/inventory/feeds/feed_1124sdn
88
+ Date:
89
+ - Tue, 29 Mar 2016 15:26:12 GMT
90
+ Connection:
91
+ - keep-alive
92
+ Content-Type:
93
+ - application/json
94
+ Content-Length:
95
+ - '96'
96
+ body:
97
+ encoding: ASCII-8BIT
98
+ string: |-
99
+ {
100
+ "path" : "/t;28026b36-8fe4-4332-84c8-524e173a68bf/f;feed_1124sdn",
101
+ "id" : "feed_1124sdn"
102
+ }
103
+ http_version:
104
+ recorded_at: Tue, 29 Mar 2016 15:26:12 GMT
105
+ - request:
106
+ method: get
107
+ uri: http://jdoe:password@localhost:8080/hawkular/inventory/feeds
108
+ body:
109
+ encoding: US-ASCII
110
+ string: ''
111
+ headers:
112
+ Accept:
113
+ - application/json
114
+ Accept-Encoding:
115
+ - gzip, deflate
116
+ Content-Type:
117
+ - application/json
118
+ User-Agent:
119
+ - Ruby
120
+ response:
121
+ status:
122
+ code: 200
123
+ message: OK
124
+ headers:
125
+ Expires:
126
+ - '0'
127
+ Cache-Control:
128
+ - no-cache, no-store, must-revalidate
129
+ X-Powered-By:
130
+ - Undertow/1
131
+ Server:
132
+ - WildFly/10
133
+ Pragma:
134
+ - no-cache
135
+ Date:
136
+ - Tue, 29 Mar 2016 15:26:12 GMT
137
+ X-Total-Count:
138
+ - '3'
139
+ Connection:
140
+ - keep-alive
141
+ Content-Type:
142
+ - application/json
143
+ Content-Length:
144
+ - '344'
145
+ Link:
146
+ - <http://localhost:8080/hawkular/inventory/feeds>; rel="current"
147
+ body:
148
+ encoding: ASCII-8BIT
149
+ string: |-
150
+ [ {
151
+ "path" : "/t;28026b36-8fe4-4332-84c8-524e173a68bf/f;a43ec2b3-94bf-4120-a91b-3a2f63914061",
152
+ "id" : "a43ec2b3-94bf-4120-a91b-3a2f63914061"
153
+ }, {
154
+ "path" : "/t;28026b36-8fe4-4332-84c8-524e173a68bf/f;feed_1123sdn",
155
+ "id" : "feed_1123sdn"
156
+ }, {
157
+ "path" : "/t;28026b36-8fe4-4332-84c8-524e173a68bf/f;feed_1124sdn",
158
+ "id" : "feed_1124sdn"
159
+ } ]
160
+ http_version:
161
+ recorded_at: Tue, 29 Mar 2016 15:26:12 GMT
162
+ - request:
163
+ method: delete
164
+ uri: http://jdoe:password@localhost:8080/hawkular/inventory/feeds/feed_1124sdn
165
+ body:
166
+ encoding: US-ASCII
167
+ string: ''
168
+ headers:
169
+ Accept:
170
+ - application/json
171
+ Accept-Encoding:
172
+ - gzip, deflate
173
+ Content-Type:
174
+ - application/json
175
+ User-Agent:
176
+ - Ruby
177
+ response:
178
+ status:
179
+ code: 204
180
+ message: No Content
181
+ headers:
182
+ Expires:
183
+ - '0'
184
+ Cache-Control:
185
+ - no-cache, no-store, must-revalidate
186
+ X-Powered-By:
187
+ - Undertow/1
188
+ Server:
189
+ - WildFly/10
190
+ Pragma:
191
+ - no-cache
192
+ Date:
193
+ - Tue, 29 Mar 2016 15:26:12 GMT
194
+ body:
195
+ encoding: UTF-8
196
+ string: ''
197
+ http_version:
198
+ recorded_at: Tue, 29 Mar 2016 15:26:12 GMT
199
+ - request:
200
+ method: delete
201
+ uri: http://jdoe:password@localhost:8080/hawkular/inventory/feeds/feed_1123sdn
202
+ body:
203
+ encoding: US-ASCII
204
+ string: ''
205
+ headers:
206
+ Accept:
207
+ - application/json
208
+ Accept-Encoding:
209
+ - gzip, deflate
210
+ Content-Type:
211
+ - application/json
212
+ User-Agent:
213
+ - Ruby
214
+ response:
215
+ status:
216
+ code: 204
217
+ message: No Content
218
+ headers:
219
+ Expires:
220
+ - '0'
221
+ Cache-Control:
222
+ - no-cache, no-store, must-revalidate
223
+ X-Powered-By:
224
+ - Undertow/1
225
+ Server:
226
+ - WildFly/10
227
+ Pragma:
228
+ - no-cache
229
+ Date:
230
+ - Tue, 29 Mar 2016 15:26:13 GMT
231
+ body:
232
+ encoding: UTF-8
233
+ string: ''
234
+ http_version:
235
+ recorded_at: Tue, 29 Mar 2016 15:26:13 GMT
236
+ - request:
237
+ method: get
238
+ uri: http://jdoe:password@localhost:8080/hawkular/inventory/feeds
239
+ body:
240
+ encoding: US-ASCII
241
+ string: ''
242
+ headers:
243
+ Accept:
244
+ - application/json
245
+ Accept-Encoding:
246
+ - gzip, deflate
247
+ Content-Type:
248
+ - application/json
249
+ User-Agent:
250
+ - Ruby
251
+ response:
252
+ status:
253
+ code: 200
254
+ message: OK
255
+ headers:
256
+ Expires:
257
+ - '0'
258
+ Cache-Control:
259
+ - no-cache, no-store, must-revalidate
260
+ X-Powered-By:
261
+ - Undertow/1
262
+ Server:
263
+ - WildFly/10
264
+ Pragma:
265
+ - no-cache
266
+ Date:
267
+ - Tue, 29 Mar 2016 15:26:13 GMT
268
+ X-Total-Count:
269
+ - '1'
270
+ Connection:
271
+ - keep-alive
272
+ Content-Type:
273
+ - application/json
274
+ Content-Length:
275
+ - '148'
276
+ Link:
277
+ - <http://localhost:8080/hawkular/inventory/feeds>; rel="current"
278
+ body:
279
+ encoding: ASCII-8BIT
280
+ string: |-
281
+ [ {
282
+ "path" : "/t;28026b36-8fe4-4332-84c8-524e173a68bf/f;a43ec2b3-94bf-4120-a91b-3a2f63914061",
283
+ "id" : "a43ec2b3-94bf-4120-a91b-3a2f63914061"
284
+ } ]
285
+ http_version:
286
+ recorded_at: Tue, 29 Mar 2016 15:26:13 GMT
287
+ recorded_with: VCR 3.0.1