Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Web machine breaks with custom riak_core app. #200

Open
mdaiter opened this issue Jan 31, 2017 · 0 comments
Open

Web machine breaks with custom riak_core app. #200

mdaiter opened this issue Jan 31, 2017 · 0 comments

Comments

@mdaiter
Copy link

mdaiter commented Jan 31, 2017

Getting errors when linking this to a current custom riak_core application. Currently, this is reported with a 500 error when attempting to access my admin page.

{error, {error,undef, [{index_dtl,render, [[{csrf_token, "Qjggzctep3_NC0m9L5IEfJiN-3sOFaQni5aCOE8eniWf5rMeMdWm2KKS1YmZh1YbOhOcqhaGKa418KrcHuveAhRG5u7GkBp7xvfMRE5VpEv9xWJG7FMUkPeZdyD7hHtDlt60iJSk1ovDsAs9caKxXhF28GUSev5fAPQsY7-iVGY32Z7HAkTXeJDMoI7PGBGtZVu0SFFPXgvBbMy_8tPMRFZHtv0lolIh6dhsO7ArKg5ps-XJUcmAdfYgyGhecbTLgqlwlXqN3eAvoKbf-FAZyLeQSGDAGS4NZr-z4CItCdnpSg5qcDl8r_C7sopLBb7AGxNdzDtx7B_spen9GPW5hA"}]], []}, {riak_control_wm_gui,to_resource,2, [{file, "/home/nomoko/Code/tester/openMVGErl/_build/default/lib/riak_control/src/riak_control_wm_gui.erl"}, {line,125}]}, {webmachine_resource,resource_call,3, [{file, "/home/nomoko/Code/tester/openMVGErl/_build/default/lib/webmachine/src/webmachine_resource.erl"}, {line,186}]}, {webmachine_resource,do,3, [{file, "/home/nomoko/Code/tester/openMVGErl/_build/default/lib/webmachine/src/webmachine_resource.erl"}, {line,142}]}, {webmachine_decision_core,resource_call,1, [{file, "/home/nomoko/Code/tester/openMVGErl/_build/default/lib/webmachine/src/webmachine_decision_core.erl"}, {line,48}]}, {webmachine_decision_core,decision,1, [{file, "/home/nomoko/Code/tester/openMVGErl/_build/default/lib/webmachine/src/webmachine_decision_core.erl"}, {line,562}]}, {webmachine_decision_core,handle_request,2, [{file, "/home/nomoko/Code/tester/openMVGErl/_build/default/lib/webmachine/src/webmachine_decision_core.erl"}, {line,33}]}, {webmachine_mochiweb,loop,2, [{file, "/home/nomoko/Code/tester/openMVGErl/_build/default/lib/webmachine/src/webmachine_mochiweb.erl"}, {line,72}]}]}}

I've currently set the riak_api and riak_control version to 2.1.0. Furthermore, I've written my rebar.config to include the appropriate patches for getting riak_pb to install.

Here is my rebar.config file:

`{plugins, [
{rebar3_run, {git, "git://github.com/tsloughter/rebar3_run.git", {branch, "master"}}},
{rebar3_protobuffs_plugin, {git, "git://github.com/cmkarlsson/rebar3_protobuffs_plugin", {tag, "0.1.2"}}}
]}.

{project_plugins, [{rebar3_cuttlefish, {git, "git://github.com/tsloughter/rebar3_cuttlefish.git", {branch, "master"}}}]}.

{profiles, [
{prod, [{relx, [{dev_mode, false}, {include_erts, true}]}]},
{dev1, [{relx, [{overlay_vars, ["config/vars.config", "config/vars_dev1.config"]}]}]},
{dev2, [{relx, [{overlay_vars, ["config/vars.config", "config/vars_dev2.config"]}]}]},
{dev3, [{relx, [{overlay_vars, ["config/vars.config", "config/vars_dev3.config"]}]}]}
]}.

{provider_hooks, [{pre, [{compile, {protobuffs, compile}},
{clean, {protobuffs, clean}}]}]}.

{overrides,
[{override, eleveldb,
[
{artifacts, ["priv/eleveldb.so"]},
{pre_hooks, [{compile, "c_src/build_deps.sh get-deps"},
{compile, "c_src/build_deps.sh"}]},

 {post_hooks, [{clean, "c_src/build_deps.sh clean"}]},

 {plugins, [pc]},

 {provider_hooks, [{post,
                     [{compile, {pc, compile}},
                      {clean, {pc, clean}}
                     ]
                   }]
 }

]
},

{override, riak_ensemble,
[
{artifacts, ["c_src/riak_ensemble_clock.o"]},
{plugins, [pc]},
{provider_hooks, [{post,
[{compile, {pc, compile}},
{clean, {pc, clean}}
]}]},
{erl_opts, [debug_info,
warn_untyped_record,
{parse_transform, lager_transform}]}
]},

{override, riak_core,
[
{erl_opts, [debug_info,
{parse_transform, lager_transform},
{platform_define, "^[0-9]+", namespaced_types},
{platform_define, "^R15", "old_hash"}]}
]},

{override, rebar3_protobuffs_plugin, [{deps, [ {protobuffs, {git, "git://github.com/basho/erlang_protobuffs.git", {tag, "0.9.0"}}}]}]},

{override, protobuffs, [{deps, []}]},

{override, riak_pb, [{plugins, [{riak_pb_msgcodegen,
{git, "git://github.com/tsloughter/riak_pb_msgcodegen",
{branch, "master"}}},
{rebar3_protobuffs_plugin,
{git, "git://github.com/cmkarlsson/rebar3_protobuffs_plugin",
{tag, "0.1.2"}}}
]},
{provider_hooks, [{pre, [ {compile, {protobuffs, compile}},
{compile, riak_pb_msgcodegen}
]}]}]}
]}.
`

{deps, [ {poolboy, ".*", {git, "git://github.com/devinus/poolboy.git", "master"}}, {webmachine, "1.10.8", {git, "git://github.com/basho/webmachine.git", {tag, "1.10.8"}}}, {erlydtl, ".*", {git, "git://github.com/erlydtl/erlydtl.git", "d20b53f0"}}, {riak_api, ".*", {git, "https://github.com/basho/riak_api.git", {tag, "2.1"}}}, {riak_control, ".*", {git, "https://github.com/basho/riak_control.git", {tag, "2.1"}}}, {riak_core, ".*", {git, "git://github.com/basho/riak_core", "develop"}}, {pbkdf2, {git, "git://github.com/marianoguerra/erlang-pbkdf2-no-history", {branch, "master"}}}, {exometer_core, {git, "git://github.com/basho/exometer_core.git", {branch, "th/correct-dependencies"}}}, {erlcloud, {git, "git://github.com/basho/erlcloud.git", {tag, "0.4.6"}}} ] }.

Would any of you have happened to run into this problem before? Seems like a web machine problem.

@mdaiter mdaiter changed the title Web machine breaks Web machine breaks with custom riak_core app. Jan 31, 2017
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

No branches or pull requests

1 participant