Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
53 commits
Select commit Hold shift + click to select a range
af08451
Initial Commit
martinsumner Mar 26, 2026
fd5c2b4
Initial test of get_body
martinsumner Mar 26, 2026
256151c
Fix formatting of new files
martinsumner Mar 26, 2026
ea3034b
Add basic chunking support (receive body)
martinsumner Mar 27, 2026
b815a5c
Add further tests - plus date caching
martinsumner Mar 27, 2026
3c11b94
Add behaviour
martinsumner Mar 27, 2026
b471a74
Formatting
martinsumner Mar 27, 2026
57d1867
Accepting chunked requests in slices
martinsumner Mar 30, 2026
df18274
Formatting
martinsumner Mar 30, 2026
f9469ae
Add initial end-to-end test
martinsumner Mar 30, 2026
2812d4b
Revert clock bakc to ETS, and add negative tests
martinsumner Mar 30, 2026
81d1b4e
Add monitoring of exits on acceptors
martinsumner Mar 31, 2026
f4a27d3
Pass the split path as well as path
martinsumner Mar 31, 2026
be07044
Extend tests, add KV store test
martinsumner Mar 31, 2026
7ccac06
Add file upload/download test
martinsumner Mar 31, 2026
52afe86
Formatting
martinsumner Mar 31, 2026
ab1a5b2
Chunked puts
martinsumner Mar 31, 2026
65a4040
Check keepalive in HTTP 1.0
martinsumner Mar 31, 2026
9333085
Remove webmachine/mochiweb
martinsumner Apr 1, 2026
a011b1d
Remove mochijson2/mochinum - included in rhc
martinsumner Apr 1, 2026
3a1714f
Remove leading empty bin if it occurs
martinsumner Apr 1, 2026
01ddd3f
Use nomatch, and context to be last not first
martinsumner Apr 1, 2026
81beed1
Optimise clock management
martinsumner Apr 2, 2026
c553fe2
Tidy-up initial configuration
martinsumner Apr 3, 2026
697631e
Fix return tuple from security function
martinsumner Apr 3, 2026
ee81ccc
Update riak_api_web_security.erl
martinsumner Apr 3, 2026
adf5b51
Be explicit peer is IP
martinsumner Apr 3, 2026
fa6a194
Missed peer()
martinsumner Apr 3, 2026
94ec8f7
Correct security type for peer
martinsumner Apr 3, 2026
9d66650
Align params type with uri_string:dissect_query
martinsumner Apr 3, 2026
746f98f
Unit test request line error handling
martinsumner Apr 12, 2026
95b5314
Trim both ends of path
martinsumner Apr 12, 2026
b826e48
Use binary split not string split
martinsumner Apr 14, 2026
c9139dd
RFC requires only leading whitespace to be removed from header
martinsumner Apr 14, 2026
1793961
RFC requires trimming both leading and trailing whitespace
martinsumner Apr 14, 2026
261afdc
compile URL separator
martinsumner Apr 14, 2026
b45d244
Revert "compile URL separator"
martinsumner Apr 14, 2026
5d7bb83
Only compile separators if not single character
martinsumner Apr 14, 2026
2af1af0
Extend testing of errors
martinsumner Apr 15, 2026
d564509
Allow for neither content-length or transfer-encoding
martinsumner Apr 17, 2026
07d49b5
Hack improvement to uri parse
martinsumner Apr 18, 2026
6bc535c
Tidy-up changes to parse vs normalise
martinsumner Apr 18, 2026
aa0441e
Don't leave URI elements quoted
martinsumner Apr 22, 2026
24c3964
Handle no auth-headers
martinsumner Apr 23, 2026
c9dbccf
Set recv buffer
martinsumner Apr 24, 2026
7e0e92c
fmt issue
martinsumner Apr 24, 2026
211af58
Remove cached vs uncached clock test
martinsumner Apr 24, 2026
6ec0469
Get Peer and Cert at start of connection
martinsumner Apr 24, 2026
917f6cd
Format fix
martinsumner Apr 24, 2026
ffa7553
Make type definition more consistent
martinsumner Apr 24, 2026
a417d2e
And export type
martinsumner Apr 24, 2026
99b9bab
Increase default backlog
martinsumner Apr 29, 2026
1ce27c5
Basic doc added, with doc-inspired tidying
martinsumner May 1, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/workflows/erlang.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,3 +34,5 @@ jobs:
run: ./rebar3 do xref, dialyzer
- name: Run eunit
run: ./rebar3 as gha do eunit
- name: Check format
run: ./rebar3 fmt --check
39 changes: 5 additions & 34 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,40 +2,11 @@

![Riak API OpenRiak Status](https://github.com/OpenRiak/riak_api/actions/workflows/erlang.yml/badge.svg?branch=openriak-4.0)

This OTP application encapsulates services for presenting Riak's
public-facing interfaces. Currently this means a generic interface for
exposing Protocol Buffers-based services; HTTP services via Webmachine
will be moved here at a later time.
This OTP application encapsulates services for presenting Riak's public-facing interfaces.

## Contributing
There two APIs:

We encourage contributions to `riak_api` from the community.
- An API using protocol buffers, with a codec defined in [riak_pb](https://github.com/OpenRiak/riak_pb), with the handling of messages managed using `riak_kv_pb_*` modules within Riak KV.
- A HTTP REST-based API (code-named Silver Machine), with the handling of requests defined using `riak_kv_ag_*` modules that implement the callbacks defined in the `riak_api_web_handler` behaviour.

1. Fork the [`riak_api`](https://github.com/basho/riak_api) repository
on Github.
2. Clone your fork or add the remote if you already have a clone of
the repository.

```
git clone git@github.com:yourusername/riak_api.git
# or
git remote add mine git@github.com:yourusername/riak_api.git
```

3. Create a topic branch for your change.

```
git checkout -b some-topic-branch
```

4. Make your change and commit. Use a clear and descriptive commit
message, spanning multiple lines if detailed explanation is needed.
5. Push to your fork of the repository and then send a pull-request
through Github.

```
git push mine some-topic-branch
```

6. A Basho engineer or community maintainer will review your patch and
merge it into the main repository or send you feedback.
For further information on using [Sliver Machine see the provided document](/docs/silverMachine.md).
178 changes: 178 additions & 0 deletions docs/silverMachine.md

Large diffs are not rendered by default.

45 changes: 38 additions & 7 deletions rebar.config
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,51 @@

{erl_opts, [warnings_as_errors]}.

{erlfmt, [
write,
{print_width, 80},
{files, [
"src/riak_api_web_acceptor.erl",
"src/riak_api_web_body.erl",
"src/riak_api_web_headers.erl",
"src/riak_api_web_security.erl",
"src/riak_api_web_socket.erl",
"src/riak_api_web.erl",
"src/riak_api_web_handler.erl"
"test/riak_api_web_get_random.erl",
"test/riak_api_web_ets_store.erl",
"test/riak_api_web_trigger.erl",
"rebar.config"
]},
{exclude_files, []}
]}.

{project_plugins, [
{erlfmt, {git, "https://github.com/OpenRiak/erlfmt.git", {branch, "main"}}}
]}.

{eunit_opts, [verbose]}.

{deps, [
{riak_pb, {git, "https://github.com/OpenRiak/riak_pb.git", {branch, "openriak-3.4"}}},
{webmachine, {git, "https://github.com/OpenRiak/webmachine.git", {branch, "openriak-3.4"}}},
{mochiweb, {git, "https://github.com/OpenRiak/mochiweb.git", {branch, "openriak-3.4"}}},
{riak_core, {git, "https://github.com/OpenRiak/riak_core.git", {branch, "openriak-4.0"}}}
]}.
{riak_pb,
{git, "https://github.com/OpenRiak/riak_pb.git",
{branch, "openriak-3.4"}}},
{riak_core,
{git, "https://github.com/OpenRiak/riak_core.git",
{branch, "openriak-4.0"}}}
]}.

{profiles, [
{test, [{deps, [{meck, {git, "https://github.com/OpenRiak/meck.git", {branch, "openriak-3.4"}}}]}]},
{test, [
{deps, [
{meck,
{git, "https://github.com/OpenRiak/meck.git",
{branch, "openriak-3.4"}}}
]}
]},
{gha, [{erl_opts, [{d, 'GITHUBEXCLUDE'}]}]}
]}.

{dialyzer, [{plt_apps, all_deps}]}.

{xref_checks,[undefined_function_calls,undefined_functions,locals_not_used]}.
{xref_checks, [undefined_function_calls, undefined_functions, locals_not_used]}.
4 changes: 1 addition & 3 deletions src/riak_api.app.src
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,7 @@
stdlib,
ssl,
riak_core,
riak_pb,
webmachine,
mochiweb
riak_pb
]},
{registered, [riak_api_sup,
riak_api_pb_sup]},
Expand Down
Loading
Loading