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

OTP 17 compatibility #1245

Merged
merged 7 commits into from
Sep 10, 2015
Merged

OTP 17 compatibility #1245

merged 7 commits into from
Sep 10, 2015

Conversation

shino
Copy link
Contributor

@shino shino commented Sep 9, 2015

This PR adds OTP 17 compatibility.

Tested with

  • Erlang/OTP R16B02 basho patch 5 (a little old)
  • Erlang/OTP 17.4 (EQC version 1.33.2 is used)

Note:

In 17.4, os:cmd/* treats input as a list of unicode code points and
it outputs results in a list of unicode code points too.
To avoid this, user administration interface in rtcs* is changed
to use erlcloud instead of curl (and fight with IO/unicode/etc.)

@shino shino added this to the 2.1.0 milestone Sep 9, 2015

-ifdef(namespaced_types).
-type mochiweb_headers() :: gb_trees:tree().
-type robj_md() :: dict:dict().
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why don't you use riakc_obj:metadata() here?

@kuenishi
Copy link
Contributor

Please ping a pre6 tag to basho/riak_cs_multibag#30 and update this branch.

@kuenishi
Copy link
Contributor

Ah, the same unit test failing again!! Looks like eunit parallelism has changed?

$ ./rebar eunit skip_deps=true suites=riak_cs_gc_manager_eqc
Building riak-cs-ee
==> rel (eunit)
==> riak_cs (eunit)
....................................................................................................(x10)..................
..................................................................................(x100)...................................
..........(x10)..(x1).........Failed! Reason: 
{'EXIT',{{badmatch,{error,{already_started,<0.7643.0>}}},
         [{riak_cs_gc_manager_eqc,'-prop_set_interval/0-fun-1-',1,
                                  [{file,"test/riak_cs_gc_manager_eqc.erl"},
                                   {line,94}]}]}}
After 5630 tests.
infinity
riak_cs_gc_manager_eqc:80: eqc_test_...*failed*
in function riak_cs_gc_manager_eqc:'-eqc_test_/0-fun-5-'/1 (test/riak_cs_gc_manager_eqc.erl, line 80)
**error:{assertEqual_failed,[{module,riak_cs_gc_manager_eqc},
                     {line,80},
                     {expression,"eqc : quickcheck ( eqc : testing_time ( 10 , ? QC_OUT ( prop_set_interval ( ) ) ) )"},
                     {expected,true},
                     {value,false}]}
  output:<<"Starting Quviq QuickCheck version 1.33.1

@shino
Copy link
Contributor Author

shino commented Sep 10, 2015

Please ping a pre6 tag to basho/riak_cs_multibag#30 and update this branch.

Sure thing 😄

@shino
Copy link
Contributor Author

shino commented Sep 10, 2015

Ah, the same unit test failing again!! Looks like eunit parallelism has changed?

  • What OTP version? 16 or 17 or both?
  • Particular on this branch?

@@ -52,9 +52,15 @@

-define(DICTMODULE, dict).

-ifdef(namespaced_types).
-type dictionary() :: dict:dict().
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Parameterized types like dict:dict(ref(), timer()) and dict:dict(timer(), ref()) ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What a big love for types ❗

@kuenishi
Copy link
Contributor

What OTP version? 16 or 17 or both?

17.5.6.2, today's HEAD of basho/otp, basho-otp-17 branch. Not tested in R16 but I'm sure it passes ...

Particular on this branch?

I think so.

@kuenishi
Copy link
Contributor

Great work; we still have several points to address. Let's work on them.

@kuenishi
Copy link
Contributor

The checksum of my OTP17 is 57799e53416c915a202909 .

@kuenishi
Copy link
Contributor

I'm sorry, I cannot reproduce above error after I removed .eunit directory. Current error is:

Warning: eqc_fsm header included, but no commands found in module riak_cs_list_objects_fsm_eqc
Compiled src/riak_cs_access.erl
test/riak_cs_list_objects_fsm_eqc.erl:0: variable '_' is unbound
test/riak_cs_list_objects_fsm_eqc.erl:0: variable '_' is unbound
test/riak_cs_list_objects_fsm_eqc.erl:0: variable '_' is unbound
ERROR: eunit failed while processing /Users/kuenishi/cs-2.1/riak_cs: rebar_abort
make: *** [test] Error 1

@kuenishi
Copy link
Contributor

Fmm, weird. As I updated quick check then failed to reproduce. Please ignore my ado about errors.

@shino
Copy link
Contributor Author

shino commented Sep 10, 2015

np!

@shino
Copy link
Contributor Author

shino commented Sep 10, 2015

Addressed comments. Also fixed the error of riak_cs_gc_manager_eqc which could be reproduced with OTP 17 and EQC 1.36.1. Ready for review again.

borshop added a commit that referenced this pull request Sep 10, 2015
OTP 17 compatibility

Reviewed-by: kuenishi
@kuenishi
Copy link
Contributor

@borshop merge

@borshop borshop merged commit 6f1e402 into develop Sep 10, 2015
@kuenishi kuenishi deleted the feature/otp-17 branch September 10, 2015 06:58
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.

3 participants