Tyler Treat
9902c3da84
First pass at implementing config reload
2017-05-30 16:18:36 -05:00
Ivan Kozlovic
a87050c546
[FIXED] Check for negative Offset and/or Limit when processing Connz
...
Ensure that if the offset is negative, it is set to 0. If the limit
is negative, it is set to the default value.
Resolves #491
2017-05-17 12:05:54 -06:00
Derek Collison
f7ba3d175e
Correct invocation of misspell with fixes
2017-04-21 09:21:33 -07:00
Derek Collison
b11ba5b118
Merge pull request #456 from wallyqs/gometalinter-checks
...
Fixes to a couple of `gometalinter` checks
2017-03-24 09:35:09 -07:00
Waldemar Quevedo
ed05c357fc
Remove unused type
2017-03-23 20:41:47 -07:00
Colin Sullivan
3f8a0d8b4a
Use atomic.Load to access fields used in /varz and /subsz requests.
...
* Includes a unit test that checks all endpoints for data races.
2017-03-01 16:13:20 -07:00
Ben Tranter
ad6206078f
Fix non-ASCII quotes in HTML
...
Fixes #304
Changes the non-ASCII curly quotes in the HTML to use the regular ASCII double quotes. Also adds a test to check for the existence of non-ASCII characters in that same HTML.
2016-09-12 11:03:19 -04:00
Ivan Kozlovic
e6039e0a8b
[FIXED] Server panic when poll for Varz and others concurrently
...
Resolves #327
2016-08-16 10:50:49 -06:00
Colin Sullivan
80a504303e
Add uptime sort option for connz.
2016-05-24 19:32:06 -06:00
Ivan Kozlovic
3492d25e69
Use initial buffer on stack
2016-05-23 22:41:40 -06:00
Ivan Kozlovic
2068cc7b36
Minor updates based on comments
2016-05-23 22:32:31 -06:00
Ivan Kozlovic
7bcb699903
Add /stacksz to monitoring
...
Allows to get the server's stacks from the monitoring interface.
2016-05-23 14:59:09 -06:00
Derek Collison
df02549dc2
Report total subscriptions under /varz
2016-05-16 12:46:30 -07:00
Derek Collison
82f04baa12
Allow optional reporting of authorized user under connz
2016-05-15 10:07:37 -07:00
Colin Sullivan
8a07a02a97
Rename the field to 'total'.
2016-04-26 17:49:09 -06:00
Colin Sullivan
19d4848008
Access server clients within lock.
2016-04-26 17:34:03 -06:00
Colin Sullivan
a6dfe88746
Add a live connection count to /connz monitoring.
2016-04-26 17:24:01 -06:00
Derek Collison
5bea74c2ed
Rename and move some things around
2016-04-21 09:33:26 -07:00
Derek Collison
6ce89066fb
race fix
2016-04-03 14:40:45 -07:00
Derek Collison
df02bc0bcf
Removed sublist, hash and hashmap, no longer needed.
2016-04-02 12:52:48 -07:00
Derek Collison
3dd490a449
Go Report Card fixes
2016-03-20 16:06:28 -10:00
Colin Sullivan
2baac47820
Address issues found by golint.
...
* No functional changes
* Did not address the ALL_CAPS issues
* Did not modify public APIs and field names.
2016-03-15 15:21:13 -06:00
Waldemar Quevedo
7ac3eae82e
Set IP and Port for connections using TLS in /connz
2016-02-15 17:40:13 -08:00
Ivan Kozlovic
193597dbab
Update test that would catch incorrect NumConns
...
- Updating TestConnzWithOffsetAndLimit() to test for c.NumConns.
This would have caught the issue that was fixed in my previous change.
- Use of variable sortValue set to pair.Val to help readability. No functional change.
2016-02-09 12:40:20 -07:00
Ivan Kozlovic
e5f0dabe08
Reduce memory allocations + fix c.NumConns that may have been wrong.
...
c.NumConns was set early to len(s.clients). However, after the sort, it was possible that the actual Conns[] array be much smaller due to minoff/maxoff.
So c.NumConns is now updated only after applying the offsets.
In order to pre-allocate the Conns buffer, I no longer skip a client if tlsRequired is true and connection is gone. I will simply not update the TLSVersion and TLSCipher.
2016-02-08 20:46:22 -07:00
Ivan Kozlovic
ecec51a771
Reduce number of objects require to sort connection in HandleConnz
...
- Use 'Pair' again, but this time, the key is an int64 that the selected sort field will be casted to.
We therefore have now only one type of sort.
- Check validity of sort string early on.
- Ensure that the ConnInfo's field used by the sort is not the value from 'client', but really the one
that was used for the sort.
- Added a test for sort by Idle time.
2016-02-08 15:40:42 -07:00
Derek Collison
d7c8e6bca8
Fix races in monitoring
...
- Possible race/invalid value in LastActivity
- Routez
- Believe fixes #189
2016-02-06 07:09:13 -08:00
Derek Collison
c0ba6c291f
Default sort by cid for connz
2016-02-05 06:07:44 -08:00
Derek Collison
9702156d72
Connection sort updates
...
- fix bug that did not update last activity on message delivery
- added sort capabilities for last activity
- avoid extra Reverse by simply changing Less func
2016-02-05 05:49:53 -08:00
Derek Collison
26185a9722
Support for connection last activity tracking
2016-02-04 17:33:40 -08:00
Ivan Kozlovic
0540df470c
Use values from ClientInfo instead of client when returning ConnInfo.
...
When we are returning ConnInfo, if we use the client's current value, they may be off compared to the values used for the sort.
2016-02-03 22:03:38 -07:00
Ivan Kozlovic
e893d873be
Forgot to use atomic for inMsgs and inBytes in one place.
2016-02-03 21:36:07 -07:00
Ivan Kozlovic
1d6dafc6a7
Fix race on connz monitor (issue #189 )
2016-02-03 21:26:26 -07:00
Derek Collison
59a52ed83a
Documentation updates, minor fixes
2016-01-10 09:14:26 -08:00
Derek Collison
6bd8f5fd70
inlined roothtml
2016-01-09 10:04:42 -08:00
Derek Collison
3af90e454f
Track total connections, http request stats
2016-01-09 09:57:04 -08:00
Derek Collison
b0c22e9dfd
Track start and uptime per connection
2016-01-09 08:20:24 -08:00
Derek Collison
1e37a6b23c
Monitoring homepage updates, help and favico
2016-01-09 07:57:58 -08:00
Derek Collison
8393c3c994
Basic INFO for cluster auto-discovery, Addresses #126
2015-12-16 12:36:24 -08:00
Derek Collison
d1a333c713
Add in tls for connection details
2015-12-01 19:23:42 -08:00
Derek Collison
b61da04ef7
Enable HTTPS for monitoring
2015-12-01 19:01:56 -08:00
Derek Collison
a63293db6b
root page cleanup
2015-12-01 15:43:37 -08:00
Waldemar Quevedo
a1a5a3cf9c
Expose name label from client in monitoring endpoint
2015-11-01 17:50:10 -08:00
cmfatih
6b1843a8c6
Fix port info
2015-10-04 01:45:38 -04:00
Derek Collison
eed8b6cf94
Fix for #111
2015-08-23 13:23:02 -07:00
Waldemar Quevedo
9c7de6902c
Add option to sort by pending size
2015-08-22 16:00:27 -07:00
cmfatih
e86e3db2e0
Change getting callback query
2015-08-17 22:22:00 -04:00
cmfatih
7c07d5994c
Updates due to formting
2015-08-15 17:44:37 -04:00
cmfatih
001d42b1ea
Tidy change for HandleRoot
2015-08-15 17:39:35 -04:00
cmfatih
b641b94300
Add ResponseHandler
2015-08-15 17:29:37 -04:00