Skip to content

Commit b46032e

Browse files
committed
Update for MQ V9.1.4 and mq-golang/4.1.2
1 parent 1a16294 commit b46032e

File tree

23 files changed

+658
-217
lines changed

23 files changed

+658
-217
lines changed

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ RUN chmod 777 $GOPATH/buildInDocker.sh
6969
# make sure it's readable by the user running the container
7070
ENV REPO="mq-metric-samples"
7171
COPY . $GOPATH/src/$ORG/$REPO
72-
RUN chmod -R a+rx $GOPATH/src/$ORG/$REPO
72+
RUN chmod -R a+rwx $GOPATH/src/$ORG/$REPO
7373

7474
# Set the entrypoint to the script that will do the compilation
7575
ENTRYPOINT $GOPATH/buildInDocker.sh

Gopkg.lock

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Gopkg.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[[constraint]]
22
name = "github.com/ibm-messaging/mq-golang"
3-
version = "4.1.0"
3+
version = "4.1.2"
44

55
[prune]
66
go-tests = true

cmd/mq_prometheus/Channels-1554192538476.json renamed to cmd/mq_prometheus/Channel Status-1573633353444.json

Lines changed: 115 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131
"hideTimeOverride": true,
3232
"id": 4,
3333
"links": [],
34+
"options": {},
3435
"pageSize": null,
3536
"scroll": true,
3637
"showHeader": true,
@@ -259,13 +260,15 @@
259260
"dashes": false,
260261
"datasource": "MQ Prometheus",
261262
"fill": 1,
263+
"fillGradient": 0,
262264
"gridPos": {
263265
"h": 5,
264266
"w": 12,
265267
"x": 12,
266268
"y": 0
267269
},
268270
"id": 6,
271+
"interval": "",
269272
"legend": {
270273
"avg": false,
271274
"current": false,
@@ -279,11 +282,20 @@
279282
"linewidth": 1,
280283
"links": [],
281284
"nullPointMode": "null",
285+
"options": {
286+
"dataLinks": []
287+
},
282288
"percentage": false,
283289
"pointradius": 5,
284290
"points": false,
285291
"renderer": "flot",
286-
"seriesOverrides": [],
292+
"seriesOverrides": [
293+
{
294+
"alias": "/Count/",
295+
"nullPointMode": "null as zero",
296+
"yaxis": 2
297+
}
298+
],
287299
"spaceLength": 10,
288300
"stack": false,
289301
"steppedLine": false,
@@ -294,6 +306,12 @@
294306
"intervalFactor": 1,
295307
"legendFormat": "{{channel}} [{{type}}]",
296308
"refId": "A"
309+
},
310+
{
311+
"expr": "count by (channel)(ibmmq_channel_status)",
312+
"instant": false,
313+
"legendFormat": "Count: {{channel}}",
314+
"refId": "B"
297315
}
298316
],
299317
"thresholds": [],
@@ -317,15 +335,16 @@
317335
"yaxes": [
318336
{
319337
"format": "s",
320-
"label": null,
338+
"label": "Time since Msg",
321339
"logBase": 1,
322340
"max": null,
323341
"min": "0",
324342
"show": true
325343
},
326344
{
345+
"decimals": 0,
327346
"format": "short",
328-
"label": null,
347+
"label": "Chl instances",
329348
"logBase": 1,
330349
"max": null,
331350
"min": null,
@@ -344,6 +363,7 @@
344363
"dashes": false,
345364
"datasource": "MQ Prometheus",
346365
"fill": 1,
366+
"fillGradient": 0,
347367
"gridPos": {
348368
"h": 5,
349369
"w": 12,
@@ -364,6 +384,9 @@
364384
"linewidth": 1,
365385
"links": [],
366386
"nullPointMode": "null",
387+
"options": {
388+
"dataLinks": []
389+
},
367390
"percentage": false,
368391
"pointradius": 5,
369392
"points": false,
@@ -429,6 +452,7 @@
429452
"dashes": false,
430453
"datasource": "MQ Prometheus",
431454
"fill": 1,
455+
"fillGradient": 0,
432456
"gridPos": {
433457
"h": 5,
434458
"w": 12,
@@ -449,6 +473,9 @@
449473
"linewidth": 1,
450474
"links": [],
451475
"nullPointMode": "null",
476+
"options": {
477+
"dataLinks": []
478+
},
452479
"percentage": false,
453480
"pointradius": 5,
454481
"points": false,
@@ -521,6 +548,7 @@
521548
"dashes": false,
522549
"datasource": "MQ Prometheus",
523550
"fill": 1,
551+
"fillGradient": 0,
524552
"gridPos": {
525553
"h": 6,
526554
"w": 12,
@@ -541,6 +569,9 @@
541569
"linewidth": 1,
542570
"links": [],
543571
"nullPointMode": "null",
572+
"options": {
573+
"dataLinks": []
574+
},
544575
"percentage": false,
545576
"pointradius": 5,
546577
"points": false,
@@ -627,6 +658,7 @@
627658
"dashes": false,
628659
"datasource": "MQ Prometheus",
629660
"fill": 1,
661+
"fillGradient": 0,
630662
"gridPos": {
631663
"h": 6,
632664
"w": 12,
@@ -647,6 +679,9 @@
647679
"linewidth": 1,
648680
"links": [],
649681
"nullPointMode": "null",
682+
"options": {
683+
"dataLinks": []
684+
},
650685
"percentage": false,
651686
"pointradius": 5,
652687
"points": false,
@@ -713,10 +748,85 @@
713748
"align": false,
714749
"alignLevel": null
715750
}
751+
},
752+
{
753+
"columns": [],
754+
"datasource": "MQ Prometheus",
755+
"fontSize": "100%",
756+
"gridPos": {
757+
"h": 6,
758+
"w": 12,
759+
"x": 5,
760+
"y": 16
761+
},
762+
"id": 14,
763+
"options": {},
764+
"pageSize": null,
765+
"scroll": true,
766+
"showHeader": true,
767+
"sort": {
768+
"col": 0,
769+
"desc": true
770+
},
771+
"styles": [
772+
{
773+
"alias": "Time",
774+
"dateFormat": "YYYY-MM-DD HH:mm:ss",
775+
"pattern": "Time",
776+
"type": "hidden"
777+
},
778+
{
779+
"alias": "Count",
780+
"colorMode": "row",
781+
"colors": [
782+
"rgba(50, 172, 45, 0.97)",
783+
"rgba(237, 129, 40, 0.89)",
784+
"rgba(245, 54, 54, 0.9)"
785+
],
786+
"dateFormat": "YYYY-MM-DD HH:mm:ss",
787+
"decimals": 0,
788+
"mappingType": 1,
789+
"pattern": "/Value/",
790+
"thresholds": [
791+
"7",
792+
"200"
793+
],
794+
"type": "number",
795+
"unit": "short"
796+
},
797+
{
798+
"alias": "Queue Manager",
799+
"colorMode": null,
800+
"colors": [
801+
"rgba(245, 54, 54, 0.9)",
802+
"rgba(237, 129, 40, 0.89)",
803+
"rgba(50, 172, 45, 0.97)"
804+
],
805+
"decimals": 2,
806+
"pattern": "/qmgr/",
807+
"thresholds": [],
808+
"type": "string",
809+
"unit": "short"
810+
}
811+
],
812+
"targets": [
813+
{
814+
"expr": " count(ibmmq_channel_status) by (qmgr)",
815+
"format": "table",
816+
"instant": true,
817+
"legendFormat": "",
818+
"refId": "A"
819+
}
820+
],
821+
"timeFrom": null,
822+
"timeShift": null,
823+
"title": "Total Active Channels",
824+
"transform": "table",
825+
"type": "table"
716826
}
717827
],
718828
"refresh": "10s",
719-
"schemaVersion": 16,
829+
"schemaVersion": 19,
720830
"style": "dark",
721831
"tags": [],
722832
"templating": {
@@ -754,5 +864,5 @@
754864
"timezone": "",
755865
"title": "Channel Status",
756866
"uid": "ik0Jp9-mz",
757-
"version": 13
867+
"version": 14
758868
}

cmd/mq_prometheus/README.md

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -82,10 +82,16 @@ The sets of queues can be given either directly on the command line with the
8282
named on the command line, with the `-ibmmq.monitoredQueuesFile` flag. An
8383
example is included in the startup shell script.
8484

85-
Note that the queue patterns are expanded only at startup
86-
of the monitor program. If you want to change the patterns, or new
87-
queues are defined that match an existing pattern, the monitor must be
88-
restarted with a `STOP SERVICE` and `START SERVICE` pair of commands.
85+
### Wildcard Patterns for Queues
86+
The `ibmmq.monitoredQueues` parameter can include both positive and negative
87+
wildcards. For example `ibmmq.monitoredQueues=A*,!AB*"` will collect data on
88+
queues beginning with "AC" or "AD" but not "AB". The full rules for expansion can
89+
be seen near the bottom of the _discover.go_ module in the _mqmetric_ package.
90+
91+
The queue patterns are expanded at startup of the program and at regular
92+
intervals thereafter. So newly-defined queues will eventually be monitored if
93+
they match the pattern. The rediscovery interval is 1h by default, but can be
94+
modified by the `rediscoverInterval` parameter.
8995

9096
## Channel Status
9197
The monitor program can now process channel status, reporting that back into

0 commit comments

Comments
 (0)