Age | Commit message (Collapse) | Author |
|
upgrade dependencies
See merge request !11
|
|
|
|
|
|
|
|
|
|
sending nothing was keeping the connection alive.
|
|
We may use a different port in the config that is then mapped somehow.
But this should not affect where we try to contact remote nicknym servers.
|
|
bugfix: use user:password@ prefix in http basic auth
See merge request !9
|
|
This will get us more debug info in the logs if it happens again
|
|
http.rb does not do this on its own.
|
|
|
|
test: more meaningful error messages in case of failures
See merge request !8
|
|
|
|
Release 0.9
Version 0.9.0
Allow queries by fingerprint (using keyservers to reply) and support key
lookup from other nickservers.
This is a major rewrite both in terms of our dependencies and our
architecture. We moved the server and http_client from eventmachine to
Celluloid based libraries. This allows for a more concise syntax and
proper https handling.
In addition we now support ruby 2.3, use a Logger instead of stdout and handle
network errors properly
See merge request !7
|
|
Allow queries by fingerprint (using keyservers to reply) and support key
lookup from other nickservers.
This is a major rewrite both in terms of our dependencies and our
architecture. We moved the server and http_client from eventmachine to
Celluloid based libraries. This allows for a more concise syntax and
proper https handling.
In addition we now support ruby 2.3, use a Logger instead of stdout and handle
network errors properly
|
|
Log requests and errors
proper logging
See merge request !6
|
|
|
|
|
|
|
|
|
|
Introduced CelluloidTest as a test class for all tests that depend on
Celluloid being up and running.
|
|
Turns out without this nickserver will not respond to multiple concurrent requests.
|
|
|
|
|
|
|
|
This way the logs do not interfere with test output
|
|
|
|
We handle these errors nicely in the dispatcher and have tests for that.
Tests should fail or err out when running into exceptions we are not
handling yet. But for these it's better to just skip.
|
|
|
|
Turns out http.rb does not support celluloid i/o andymore and we were not making
use of it anyway.
Here's what https://github.com/httprb/http/wiki/Thread-Safety says:
(NOTE: this gem previously supported Celluloid::IO, but that support was removed to add the current timeout backend. It may be added back in a future version)
So now we have a plain http.rb adapter and use that as the default.
This prevents actors from crashing in the adapter (as we don't have any).
|
|
|
|
|
|
|
|
Feature/deal with network failures
Also activates the new nicknym lookup.
See merge request !5
|
|
This way the other RequestHandlers can give it a try.
If none handles it we'll get a 404 anyway. But maybe there's
been an exception before so a 502 should be send.
|
|
|
|
If one source raises a 502 and no other handler has any result we'll
respond with a 502 - bad gateway.
|
|
|
|
|
|
|
|
Handler Chain is of handlers that respond to call.
Invoking handle(*args) on the chain will call the handlers with the given args
until one of them returns a result that is truethy (i.e. not false or nil).
Extracted from the dispatcher so we can also handle exceptions there in the
future. (So that if one of the network connections to the request_handlers
fails we can continue while still tracking the failed exception.)
|
|
|
|
This is a first step. In case the suspected nicknym server cannot be
reached we will now move on and try other sources.
It's robably not what we want in the long run. In order to know wether
no key exists or we just failed to connect to some servers a different
http response code would be nice if network errors occured.
This simplifies testing such scenarios in the unit test and makes the
remote tests skip on network failure.
|
|
bugfix: load order issue in server, include test
Includes our first functional test. This one only makes sure loading
the bin/nickserver actually works fine. Enough to catch this bug.
See merge request !4
|
|
Includes our first functional test. This one only makes sure loading
the bin/nickserver actually works fine. Enough to catch this bug.
|
|
test: properly test nicknym source + fixes
See merge request !3
|
|
|
|
Dropped the webmock dependency. We have our own http adapter. So we can
stub that to inject a mock. As an added bonus this does not mess with
other http requests.
Also wrote down testing strategy. Not completely implemented yet.
|
|
|
|
Also changed Nickserver::Response to not include the status code.
This may be okay for error responses but in most cases we want to
have a parsable message and not some status code prepended to it.
|