Commit Graph

77 Commits

Author SHA1 Message Date
Tyler Treat
cc30af8ede Address code review feedback 2017-06-05 17:43:42 -05:00
Tyler Treat
c468abd15f Merge branch 'master' of github.com:nats-io/gnatsd into config_reload 2017-06-05 13:41:04 -05:00
Tyler Treat
28160f1de2 Remove global logger
gnatsd currently uses a global logger. This can cause some problems
(especially around the config-reload work), but global variables are
also just an anti-pattern in general. The current behavior is
particularly surprising because the global logger is configured through
calls to the Server.

This addresses issue #500 by removing the global logger and making it a
field on Server.
2017-05-31 16:06:31 -05:00
Tyler Treat
9902c3da84 First pass at implementing config reload 2017-05-30 16:18:36 -05:00
Ivan Kozlovic
3b6dc5eb2f Changed write_deadline configuration type
Changing from being the number of seconds to a time.Duration.
For backward compatibility, the configuration with the number
of seconds is still accepted but an error message is printed
asking the user to convert to duration.

Resolves #487
2017-05-06 14:20:01 -06:00
Derek Collison
f7ba3d175e Correct invocation of misspell with fixes 2017-04-21 09:21:33 -07:00
Derek Collison
76de921f65 Cleanup for Auth 2017-04-20 12:41:48 -07:00
Ivan Kozlovic
0cf8455a3a [ADDED] Support for token in configuration file
So far, it was only possible to use token from the command line.

Resolves #464
2017-03-30 11:23:07 -06:00
Waldemar Quevedo
8926fa0ff1 Fix unconvert checks in server 2017-03-23 20:41:38 -07:00
Ivan Kozlovic
95d0152449 [ADDED] Make Write deadline configurable
We use a hardcoded value of 2 seconds for Write deadline when
writing data to client's socket.
This PR makes that value configurable.

Question is should we push the setting down to the client's object
to avoid indirection such as client.srv.opts.WriteDeadline?
2017-01-18 20:33:44 -07:00
Colin Sullivan
b133cda3cd Add curve preference option to configuration files.
* Add a preference to specify and order the curve preferences
* Add details tls help
* Deprecate old 1.4 cipher suite code
2016-12-27 15:41:48 -07:00
Ivan Kozlovic
d3555053d0 Change option/parameter name 2016-12-22 14:59:27 -07:00
Ivan Kozlovic
a8dfaeae3d [ADDED] Ability to configure number of connect retries for implicit routes
When a server is told to connect to a server (with auto-discovery),
it tries to connect once. There have been a report where that
connection fails, but would probably succeed if tried again (#408).
This new parameter allows to configure the number of times a failed
implicit connect should be tried.

Resolves #408
2016-12-20 18:37:23 -07:00
Derek Collison
874921ed9f Remove comment for old cluster options 2016-12-02 15:14:36 -08:00
Derek Collison
8fbacaaea1 Cleanup for cluster opts 2016-12-02 14:29:22 -08:00
Waldemar Quevedo
2a8aa96af4 Remove "max_pending_size" option
Previous implementations of the server checked the pending data size
being currently buffered for a client to detect slow consumers,
though this does not apply to latest version of the server so removing
it as a config option to avoid confusion as it is not implemented.
2016-11-22 20:07:39 -08:00
Derek Collison
e57c949658 Add support for 'include' to configuration files 2016-11-21 14:58:05 -08:00
Volodymyr Khoroz
a35d98eebe [#370] Treat ping interval from config as seconds (there is no point in smaller granularity). 2016-11-16 00:31:38 +02:00
Volodymyr Khoroz
a98b51a5ca [#370] Ability to configure ping_interval and ping_max (with tests) 2016-11-16 00:31:38 +02:00
Ivan Kozlovic
8f7f6e9f8b [FIXED] Client certificate verification when verify is true.
Server was incorrectly requiring a client certificate, but not
verifying it.

Resolves #336
2016-08-25 15:33:13 -06:00
Waldemar Quevedo
e46b187230 Enables using the same listen from server as was specified via -a
in the cmd line for the monitoring server as well.
2016-08-17 23:08:37 -07:00
Ivan Kozlovic
82dbb3a5ab [ADDED] Option to not advertise to clients cluster's IPs
By default, a server is now sending to its clients the client URLs
of all servers in the cluster. This allows clients to be able
to reconnect to any server in the cluster even if those clients
were not configured with the list of servers in the cluster.

However, there may be cases where it would make sense to disable
this feature. This now can be done with this option/command line
parameter.

Resolves #322
2016-08-12 19:24:12 -06:00
Ivan Kozlovic
5185f10fed [FIXED] Route/Cluster override
If the server was started with a cluster section in a configuration
file and one would want to override the routes (using `-routes`) the
server would complain that you need to use `-cluster`. Adding
an override of cluster would not work, server would still complain.
Trying to override simply the cluster listen info (without override
of routes) would also not work.
2016-08-04 13:20:25 -06:00
Derek Collison
67ed61c837 fixups for PR comments 2016-06-17 09:59:39 -07:00
Derek Collison
449aa6e8ef Finalized opts parser for subject authorization 2016-06-16 13:49:26 -07:00
Derek Collison
1d74a0dea3 First pass authorization parser 2016-06-16 10:10:52 -07:00
Derek Collison
46a9e6f0bc First pass at multi-user support 2016-05-13 12:27:57 -07:00
Derek Collison
9e73c1db76 Enable listen address parsing for client, cluster and http, enforce http hosts as separate 2016-05-12 16:47:01 -07:00
Derek Collison
b5a1365349 Set default host for cluster 2016-05-03 16:44:32 -07:00
Ivan Kozlovic
16bd806c46 Move definition of tls usage outside of function that prints it 2016-04-22 15:22:04 -06:00
Derek Collison
b3388db53f Enable dynamic write buffers for client connections 2016-04-15 18:16:13 -07:00
Derek Collison
f23f55518c gosimple fixes 2016-03-31 07:28:40 -07: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
Derek Collison
49a7f2295a gofmt -s fixes 2016-02-29 22:08:49 -08:00
Derek Collison
b61da04ef7 Enable HTTPS for monitoring 2015-12-01 19:01:56 -08:00
Waldemar Quevedo
4958f0f684 Add --cluster_listen flag to set cluster addr and port for others to solicit routes 2015-11-30 14:30:11 -08:00
Derek Collison
9d0695ec47 Merge pull request #143 from nats-io/tls_strict_route
TLS strict route verifications
2015-11-23 12:18:41 -08:00
Derek Collison
40c8cb13ea Strict verification for route TLS 2015-11-23 10:19:47 -08:00
Colin Sullivan
bb286ba424 Merge branch 'master' into tls_add_cipher 2015-11-23 10:55:43 -07:00
Derek Collison
647213b1d7 TLS timeout handling for routes 2015-11-22 15:07:44 -08:00
Derek Collison
3b64567f00 tls flags, proper timeouts 2015-11-22 14:43:16 -08:00
Derek Collison
ef43c19fce Use better ciphers available under 1.5 2015-11-22 08:29:18 -08:00
Colin Sullivan
936259e0d6 Removed the requirement for cipher_suites configuration in TLS and added default ciphers. 2015-11-21 21:15:35 -07:00
Colin Sullivan
c56b3677da Fixed formatting 2015-11-20 16:08:13 -07:00
Colin Sullivan
0ff1b55fa9 Require cipher suites to be specified in the configuration.
* Configuration requires a cipher suite
* Removed default cipher suites
* Added help to assist with TLS configuration and list available cipher suites.
2015-11-20 16:00:25 -07:00
Colin Sullivan
9ff1c9a12c Expand the cipher suite options. This allows older clients (e.g. .NET on Windows 7) to more easily use TLS. 2015-11-19 15:58:46 -07:00
Derek Collison
b8af53e67a Added in clustered TLS 2015-11-08 14:20:01 -08:00
Derek Collison
1c7f708217 Added in support for requiring client certificates 2015-11-08 10:48:39 -08:00
Derek Collison
b75c7b1522 comment out 1.5 only ciphers for now. 2015-10-23 08:43:03 -07:00
Derek Collison
749d4f89cc First pass at client TLS support 2015-10-22 03:30:27 +02:00