This should not happen in production, as the Cache API is
widely implemented as of the date of this commit, but it
will not be available if the user is not in a secure
context. That should only happen during testing.
When a valid `token` message is received from a client, the
socket server will automatically push refreshed tokens at
about half lifetime of the received JWT.
If an invalid token is received the connection is closed.
See #304.
* Use X-JWT header for sending authentication info
both from server to client and from client to server.
* Send token in body of login response.
* Also use Set-Cookie: JWT=… so that calls that are
not issued directly by Dougal (e.g. Deck.gl layers
with a URL `data` property) work without having to
jump through hoops.
Closes#321
This commit adds the ability to pack preplot points in Dougal
binary format. Sail line points take udv=0 and source line points
take udv=1 – udv=2 remains sequence data.
Endpoints for retrieving the data in JSON, GeoJSON and binary
formats have also been added. Data may be retrieved as a single
line or for a whole project.
Map.sequencesBinaryData is now a single object instead of an
array of objects.
DougalSequenceLayer has been greatly simplified. It now
inherits from ScatterplotLayer rather than CompositeLayer.
DougalEventsLayer added. It shows either a ScatteplotLayer
or a ColumnsLayer depending on zoom level.
The original and default "Accept: application/json" will return
a sequence summary.
"Accept: application/geo+json" will return a GeoJSON of the
entire project.
"Accept: application/vnd.aaltronav.dougal+octet-stream" will
return the entire project in Dougal's binary format.
Instead of the user giving the recipe for the payload, it now
only handles predefined payload configurations. Those are
denoted by the `type` query parameter. The only valid value
as of this commit is `type=2`.
Look at lib/binary/bundle.js for the definition of a type 2
bundle.
This is not yet implemented but left visible for demo purposes.
Intended to configure things such as vessel track length, possibly
whether the latest track or the track within the current prospect
is shown, etc.