Commit Graph

1077 Commits

Author SHA1 Message Date
Eric Promislow
bcf8b7532b [477] - Bring up coverage. 2017-04-28 13:33:35 -07:00
Eric Promislow
122b697e41 Issue 477: Improve handling of escaped substrings
This involves evaluating and interpolating \-escaped sequences
in double-quoted and undelimited strings.

Added tests on various edge-conditions, as well as ruling out bare
strings like '\true' as a bool.
2017-04-27 18:04:47 -07:00
Derek Collison
a94b5e0f4c Merge pull request #479 from nats-io/fix_script_code_cov
Fix code coverage script (remove auth package that no longer exists)
2017-04-27 15:05:34 -07:00
Ivan Kozlovic
aac1e74eb8 Fix code coverage script (remove auth package that no longer exists) 2017-04-27 09:19:01 -06:00
Derek Collison
55404c70b0 Merge pull request #475 from nats-io/updates
Fixes for staticcheck tests, added misspell check and fixes.
2017-04-21 09:37:04 -07:00
Derek Collison
f7ba3d175e Correct invocation of misspell with fixes 2017-04-21 09:21:33 -07:00
Derek Collison
ddd1b472e2 Removed need for ignore check on staticcheck, added misspell check 2017-04-21 09:11:28 -07:00
Derek Collison
345b463cee Merge pull request #474 from nats-io/auth_cleanup
Authorization cleanup
2017-04-20 19:00:05 -07:00
Derek Collison
acb740dbe9 Use checkClusterFormed 2017-04-20 18:34:08 -07:00
Derek Collison
0fa0003c9e Fixes for routes test with bcrypt and auth 2017-04-20 16:55:44 -07:00
Derek Collison
45d523e800 Fixups for auth always being checked now 2017-04-20 13:26:59 -07:00
Derek Collison
eae0834669 lower bcrypt costs for race tests, raise timeouts 2017-04-20 13:20:45 -07:00
Derek Collison
76de921f65 Cleanup for Auth 2017-04-20 12:41:48 -07:00
Derek Collison
e35c4204fc Merge pull request #471 from nats-io/fix_issue_470
[FIXED] Release on linux amd64 is the only one dynamically linked
2017-04-07 12:01:35 -07:00
Ivan Kozlovic
67a4a37616 [FIXED] Release on linux amd64 is the only one dynamically linked
We are using the tool from https://github.com/mitchellh/gox
for cross compilation. When we issue a new release, we create a
tag and trigger Travis build which will then invoke the script and
upload the files to GH.

We were affected by https://github.com/mitchellh/gox/issues/55

Invoking the script on a Linux amd64 would produce this:

file pkg/gnatsd-linux-amd64/gnatsd
pkg/gnatsd-linux-amd64/gnatsd: ELF 64-bit LSB executable, x86-64,
version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, stripped

With the fix, you'll get this:

file pkg/gnatsd-linux-amd64/gnatsd
pkg/gnatsd-linux-amd64/gnatsd: ELF 64-bit LSB executable, x86-64,
version 1 (SYSV), statically linked, stripped

Resolves #470
2017-04-07 12:51:59 -06:00
Derek Collison
64dcdd6a7e Merge pull request #465 from nats-io/add_token_config_support
[ADDED] Support for token in configuration file
2017-03-30 11:22:52 -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
Derek Collison
91f4997795 Merge pull request #461 from nats-io/improve_code_coverage
Increase code coverage
2017-03-24 14:19:06 -07:00
Ivan Kozlovic
474cacad90 Increase code coverage
- Two files were showing poor code coverage affecting the overall
total.
- Fix to a route test that would fail on Windows.

Resolves #460
2017-03-24 11:58:58 -06: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
Derek Collison
e1abaa5152 Merge pull request #459 from nats-io/fix_ping_to_tls_conn
[FIXED] Server not sending PINGs to TLS connections (clients or routes)
2017-03-24 09:30:47 -07:00
Ivan Kozlovic
a0245fc0c8 [FIXED] Server not sending PINGs to TSL connections (clients or routes)
- Removed unnecessary cast check to (*net.TCPConn). When the timer
fires, the connection is already established. Replaced with check
that connection has not been closed.
- Add PING test that checks that pings are sent to TLS connections.
- Changed Go version to 1.7.5 in travis.
- Removed test package from code coverage.
2017-03-24 09:49:42 -06:00
Waldemar Quevedo
ed05c357fc Remove unused type 2017-03-23 20:41:47 -07:00
Waldemar Quevedo
8926fa0ff1 Fix unconvert checks in server 2017-03-23 20:41:38 -07:00
Derek Collison
42a539f1c1 Merge pull request #454 from nats-io/add-spc-readme
Readme fixups
2017-03-22 22:32:26 -07:00
Derek Collison
2e7682a43c Merge pull request #455 from nats-io/fix_gosimple_error
Fix gosimple report
2017-03-22 22:31:57 -07:00
Ivan Kozlovic
a804516540 Fix gosimple report 2017-03-22 22:52:33 -06:00
Waldemar Quevedo
19e6216cbc Remove -DV from non debugging sections in readme 2017-03-22 19:08:37 -07:00
Waldemar Quevedo
a4fc1b648b Fixups to readme
Add missing space before title
2017-03-22 16:54:18 -07:00
Larry McQueary
902fb62166 Add ROADMAP.md (#448)
* Add initial ROADMAP.md
2017-03-10 13:25:36 -07:00
Peter Miron
4fa3b94645 Merge pull request #445 from nats-io/fix-monitoring-data-races
Use atomic.Load to access fields used in /varz and /subsz requests.
2017-03-03 14:44:28 -05:00
Colin Sullivan
efbd423e96 Updates based on comments. 2017-03-01 20:46: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
Larry McQueary
9dd2f7cb65 [ADDED] Add issue and PR templates [CI SKIP] (#443)
* [ADDED] Add issue and PR templates [CI SKIP]
2017-02-26 14:13:32 -07:00
Colin Sullivan
80490020b2 Merge pull request #440 from nats-io/travis-go18
Update Travis to use Go 1.8
2017-02-22 16:06:49 -07:00
Colin Sullivan
c9d90734c5 Fix staticcheck error found moving to go 1.8 2017-02-21 15:30:15 -07:00
Colin Sullivan
0464583235 Update travis to use the Go 1.8 release. 2017-02-21 15:01:52 -07:00
Derek Collison
37ce250199 Merge pull request #431 from nats-io/fix_staticcheck_error
Fix staticcheck report
2017-02-02 14:48:28 -05:00
Ivan Kozlovic
3316f4bece Fix staticcheck report
Removed `os.Exit()` from function assigned to `flag.Usage`.
2017-02-02 11:50:56 -07:00
Peter Miron
4a82610a38 Updated to use MIT-specific license image. 2017-02-02 12:39:06 -05:00
Derek Collison
33afedcc70 Merge pull request #427 from nats-io/update_test
Update client connect to route port test
2017-01-27 19:18:42 -05:00
Ivan Kozlovic
1c5a34ea42 Update client connect to route port test
With the following client fix: https://github.com/nats-io/go-nats/pull/260
the client should always be able to connect after the initial
failure.
2017-01-27 09:59:29 -07:00
Derek Collison
fdf1a24d78 Merge pull request #424 from nats-io/reject_client_connecting_to_route
[ADDED] Reject clients connecting to route's listen port
2017-01-26 09:50:02 -08:00
Derek Collison
8217ef8058 Merge pull request #426 from nats-io/add_gosimple
Added gosimple
2017-01-26 09:45:30 -08:00
Ivan Kozlovic
1fb9f211ca Added gosimple
- Get gosimple package
- Updated staticcheck's URL
- Moved build and above checks in `before_script` section to fail fast
- Fixed reports from gosimple
2017-01-25 13:30:11 -07:00
Ivan Kozlovic
c925e1c9bf Restored behavior after c.parse() error 2017-01-25 09:15:47 -07:00
Ivan Kozlovic
7c59ce3dba [ADDED] Reject clients connecting to route's listen port
This happens sometimes, and the latest occurence was today:
https://github.com/nats-io/java-nats/issues/96

When it happens, there is no error but subscribers would not receive
anything, etc...

This PR uses the fact that clients set the field Lang in the CONNECT
protocol that ROUTEs do not. I have checked that all Apcera supported
clients do set Lang in the CONNECT protocol.
If we plan to add Lang for routes, we need to find another field or
use a new one, in which case that would work only for new clients
(that would need to be updated).

With this change, when the server accepts a connection on the route
port and detects that this protocol field is present, it now closes
the client connection.

The nice thing is that newer clients, when incorrectly connecting
to the route port, get from the route's INFO the list of client URLs,
which means that on the initial connect error, they are able to
subsequently connect to the proper client port, so it is transparent
to the user (which may or may not be a good thing). However, it is not
guaranteed because if the client is not setting NoRandomize to true,
the client URL is added but the array shuffled, so it is possible that
the client library does not find the correct port in the connect loop.
2017-01-24 19:46:46 -07:00
Derek Collison
0d45f49d90 Merge pull request #423 from nats-io/fix_staticcheck_errors
Fixed errors found by staticcheck
2017-01-24 18:44:20 -08:00
Ivan Kozlovic
27bfed541c Fixed errors found by staticcheck
Staticcheck has probably been updated and is finding new errors.
They have been fixed.

Also, moved the run of staticcheck before running the test suite,
so if it fails, it fails sooner ;-).
2017-01-24 19:34:17 -07:00
Derek Collison
63d6ef9546 Merge pull request #421 from nats-io/make_write_deadline_configurable
[ADDED] Make Write deadline configurable
2017-01-18 21:40:30 -07:00