Skip to content

Nhse o40 orkv.i141 silvermachine#3

Draft
martinsumner wants to merge 52 commits intoopenriak-4.0from
nhse-o40-orkv.i141-silvermachine
Draft

Nhse o40 orkv.i141 silvermachine#3
martinsumner wants to merge 52 commits intoopenriak-4.0from
nhse-o40-orkv.i141-silvermachine

Conversation

@martinsumner
Copy link
Copy Markdown
Contributor

Switch HTTP API to use SilverMachine not WebMachine/Mochiweb.

Intentions are:

  • improve performance of common requests, especially with significant volumes of index entries and/or user object metadata;
  • simplify the callbacks required within the application;
  • only implement the basics of HTTP, the full extent of rules (i.e. equivalent webmachine decision_core) may be implemented in the callbacks, but aren't applied by default;
  • allow for streaming on both inbound request bodies as well as outbound response bodies, to ready support for file upload/downloads;
  • simplify the task of providing SSL handshake information to the application

WIP.  A framework of modules and functions for SliverMachine.
Apply only to new files, or heavily altered files so that broader change history is maintained.
Also add callback module and unit test the sending of responses both streamed and whole.
Plus some further testing/formatting
Retain mohijson2 and mochinum to ease transition
Where URI starts "/" will add a leading <<>> to the split path - which is confusing and easy to forget about.
Also provides functions for converting Last Modified Date in KV GET.
Also compile the binary pattern, and cache in a persistent term to speed up parsing
The uri_string:normalize is going to decode that path and the query params (resolve any percent encoding, then check the outcome is unicode).  It will also handle any dot segments.

If there are no dots, or percent encoding - this is unnecessary - the parsed outcome will be the same.  This will normally be the case - so bypass normalization if possible.

Paths can be quite long (with long bucket names, keys etc) - so avoiding this step has value.
Defaults to 1460 on OTP26 - and this means that not all data available in buffer
Nature of clock implementation changed - and so all tests may use cached clock - and so no longer a valid comparison.
Reuse Peer/Cert in all check_permissions callback on the connection.
128 aligns with mochiweb - otherwise some tests with riak_test that use large bursts of connections may fail
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant