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

Sequence folding in parallel case #20

Open
ThomasArts opened this issue Feb 14, 2019 · 0 comments
Open

Sequence folding in parallel case #20

ThomasArts opened this issue Feb 14, 2019 · 0 comments

Comments

@ThomasArts
Copy link
Member

An unexpeced effect in book_objectfold/5

In a sequential prefix, we put an element in the store and then define a sqn_order object fold over this store with snapshot false. Then in parallel we run the fold and put one more oject in the store. That new object has the same bucket and key, but other value.

Now, I would expect to see as outcome of the fold either the first or the second put for that key. But I see both. And worst, I see the one put in first as last in the outcome of the fold!

Sequential prefix:

   leveledjc_eqc:init_backend(o_rkv,
       [{root_path, Dir}, {log_level, error}, {max_sstslots, 2},
        {cache_size, 10}, {max_pencillercachesize, 40},
        {max_journalsize, 20000}],
       sut) ->
     <0.8007.0>
   leveledjc_eqc:put(<0.8007.0>, <<98, 117, 99, 107, 101, 116, 49>>,
       <<2, 201, 141, 204, 220, 59, 44, 47, 23, 186, 96, 213, 119, 114,
         228, 125>>, 
       <<53, 1, 0, 0, 0, 95, 131, 108, 0, 0, 0, 7, 104, 2, 100, 0, 5,
         99, 108, 97, 114, 97, 97, 1, 104, 2, 100, 0, 6, 103, 101, 111,
         114, 103, 101, 97, 2, 104, 2, 100, 0, 5, 105, 115, 97, 97, 99,
         97, 3, 104, 2, 100, 0, 6, 103, 101, 111, 114, 103, 101, 97, 4,
         104, 2, 100, 0, 5, 105, 115, 97, 97, 99, 97, 5, 104, 2, 100, 0,
         6, 98, 101, 114, 116, 105, 101, 97, 6, 104, 2, 100, 0, 6, 98,
         101, 114, 116, 105, 101, 97, 7, 106, 0, 0, 0, 1, 0, 0, 1, 1, 1,
         102, 36, 5, 193, 191, 22, 53, 85, 105, 9, 89, 22, 207, 140, 34,
         144, 26, 113, 202, 213, 62, 36, 201, 186, 215, 182, 172, 163,
         168, 32, 169, 143, 244, 224, 244, 47, 8, 241, 201, 191, 3, 204,
         240, 248, 81, 29, 117, 128, 186, 180, 245, 171, 195, 63, 193, 13,
         91, 149, 200, 208, 128, 134, 245, 55, 171, 68, 159, 232, 243,
         169, 26, 45, 218, 179, 52, 49, 64, 133, 46, 134, 137, 117, 161,
         84, 146, 174, 66, 134, 42, 113, 221, 75, 57, 180, 187, 228, 174,
         30, 162, 89, 161, 26, 69, 230, 47, 144, 108, 47, 252, 212, 25,
         106, 48, 169, 204, 252, 98, 182, 21, 70, 179, 123, 132, 232, 103,
         66, 168, 91, 20, 69, 118, 109, 104, 170, 251, 52, 234, 164, 214,
         255, 228, 149, 213, 41, 225, 205, 3, 161, 242, 249, 233, 30, 43,
         54, 66, 123, 244, 61, 139, 43, 190, 192, 24, 244, 126, 245, 131,
         15, 29, 146, 230, 223, 194, 133, 35, 52, 166, 116, 107, 0, 12,
         119, 142, 221, 64, 90, 110, 6, 38, 17, 57, 66, 212, 80, 82, 35,
         123, 184, 31, 107, 35, 105, 125, 181, 82, 27, 215, 109, 232, 86,
         47, 13, 74, 126, 254, 199, 239, 128, 87, 79, 145, 123, 19, 162,
         111, 93, 191, 111, 187, 29, 243, 68, 205, 72, 140, 41, 228, 145,
         69, 122, 124, 24, 61, 106, 57, 136, 166, 97, 189, 213, 98, 147,
         189, 86, 56, 182, 0, 0, 0, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
         0, 1, 101, 0>>,
       [], o_rkv) ->
     ok
   leveledjc_eqc:objectfold(<0.8007.0>, o_rkv, {#Fun<leveledjc_eqc.30.115929979>, []},
       false, sqn_order, 1) ->
     #Fun<leveled_runner.10.81953218>
Parallel:

1. leveledjc_eqc:fold_run(1, #Fun<leveled_runner.10.81953218>) ->
  [{<<98, 117, 99, 107, 101, 116, 49>>,
    <<2, 201, 141, 204, 220, 59, 44, 47, 23, 186, 96, 213, 119, 114,
      228, 125>>,
    <<53, 1, 0, 0, 0, 19, 131, 108, 0, 0, 0, 1, 104, 2, 100, 0, 5,
      105, 115, 97, 97, 99, 97, 1, 106, 0, 0, 0, 1, 0, 0, 1, 1, 1, 72,
      91, 51, 204, 93, 141, 134, 68, 135, 44, 79, 97, 32, 185, 231,
      207, 84, 127, 250, 100, 210, 95, 245, 171, 156, 134, 222, 162,
      47, 129, 81, 120, 132, 168, 55, 144, 18, 85, 77, 170, 49, 126,
      18, 189, 102, 97, 237, 249, 94, 128, 210, 250, 229, 70, 105, 152,
      31, 252, 224, 41, 145, 232, 23, 60, 58, 72, 178, 225, 10, 115,
      245, 230, 237, 114, 135, 88, 208, 125, 180, 210, 250, 76, 207,
      188, 96, 14, 32, 63, 88, 2, 254, 127, 79, 103, 22, 52, 250, 194,
      153, 168, 48, 166, 102, 210, 76, 247, 226, 137, 221, 24, 65, 76,
      66, 201, 130, 119, 55, 12, 129, 93, 131, 104, 83, 15, 233, 183,
      114, 223, 41, 229, 237, 12, 50, 219, 192, 184, 172, 77, 110, 176,
      103, 118, 10, 156, 113, 126, 52, 106, 144, 128, 125, 116, 115,
      11, 93, 149, 30, 180, 182, 68, 61, 186, 235, 113, 157, 211, 85,
      50, 78, 24, 184, 222, 14, 147, 172, 232, 100, 98, 252, 201, 22,
      83, 174, 16, 79, 30, 151, 164, 144, 17, 132, 172, 44, 41, 222,
      216, 235, 108, 160, 84, 83, 201, 212, 42, 176, 140, 202, 50, 236,
      14, 222, 111, 143, 44, 54, 98, 7, 122, 164, 21, 218, 195, 45,
      189, 97, 70, 17, 194, 53, 12, 248, 115, 166, 82, 5, 7, 76, 145,
      169, 253, 120, 219, 239, 105, 76, 9, 152, 34, 25, 198, 253, 50,
      132, 12, 94, 55, 0, 0, 0, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
      1, 101, 0>>},
   {<<98, 117, 99, 107, 101, 116, 49>>,
    <<2, 201, 141, 204, 220, 59, 44, 47, 23, 186, 96, 213, 119, 114,
      228, 125>>,
    <<53, 1, 0, 0, 0, 95, 131, 108, 0, 0, 0, 7, 104, 2, 100, 0, 5,
      99, 108, 97, 114, 97, 97, 1, 104, 2, 100, 0, 6, 103, 101, 111,
      114, 103, 101, 97, 2, 104, 2, 100, 0, 5, 105, 115, 97, 97, 99,
      97, 3, 104, 2, 100, 0, 6, 103, 101, 111, 114, 103, 101, 97, 4,
      104, 2, 100, 0, 5, 105, 115, 97, 97, 99, 97, 5, 104, 2, 100, 0,
      6, 98, 101, 114, 116, 105, 101, 97, 6, 104, 2, 100, 0, 6, 98,
      101, 114, 116, 105, 101, 97, 7, 106, 0, 0, 0, 1, 0, 0, 1, 1, 1,
      102, 36, 5, 193, 191, 22, 53, 85, 105, 9, 89, 22, 207, 140, 34,
      144, 26, 113, 202, 213, 62, 36, 201, 186, 215, 182, 172, 163,
      168, 32, 169, 143, 244, 224, 244, 47, 8, 241, 201, 191, 3, 204,
      240, 248, 81, 29, 117, 128, 186, 180, 245, 171, 195, 63, 193, 13,
      91, 149, 200, 208, 128, 134, 245, 55, 171, 68, 159, 232, 243,
      169, 26, 45, 218, 179, 52, 49, 64, 133, 46, 134, 137, 117, 161,
      84, 146, 174, 66, 134, 42, 113, 221, 75, 57, 180, 187, 228, 174,
      30, 162, 89, 161, 26, 69, 230, 47, 144, 108, 47, 252, 212, 25,
      106, 48, 169, 204, 252, 98, 182, 21, 70, 179, 123, 132, 232, 103,
      66, 168, 91, 20, 69, 118, 109, 104, 170, 251, 52, 234, 164, 214,
      255, 228, 149, 213, 41, 225, 205, 3, 161, 242, 249, 233, 30, 43,
      54, 66, 123, 244, 61, 139, 43, 190, 192, 24, 244, 126, 245, 131,
      15, 29, 146, 230, 223, 194, 133, 35, 52, 166, 116, 107, 0, 12,
      119, 142, 221, 64, 90, 110, 6, 38, 17, 57, 66, 212, 80, 82, 35,
      123, 184, 31, 107, 35, 105, 125, 181, 82, 27, 215, 109, 232, 86,
      47, 13, 74, 126, 254, 199, 239, 128, 87, 79, 145, 123, 19, 162,
      111, 93, 191, 111, 187, 29, 243, 68, 205, 72, 140, 41, 228, 145,
      69, 122, 124, 24, 61, 106, 57, 136, 166, 97, 189, 213, 98, 147,
      189, 86, 56, 182, 0, 0, 0, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
      0, 1, 101, 0>>}]
2. leveledjc_eqc:put(<0.8007.0>, <<98, 117, 99, 107, 101, 116, 49>>,
    <<2, 201, 141, 204, 220, 59, 44, 47, 23, 186, 96, 213, 119, 114,
      228, 125>>,
    <<53, 1, 0, 0, 0, 19, 131, 108, 0, 0, 0, 1, 104, 2, 100, 0, 5,
      105, 115, 97, 97, 99, 97, 1, 106, 0, 0, 0, 1, 0, 0, 1, 1, 1, 72,
      91, 51, 204, 93, 141, 134, 68, 135, 44, 79, 97, 32, 185, 231,
      207, 84, 127, 250, 100, 210, 95, 245, 171, 156, 134, 222, 162,
      47, 129, 81, 120, 132, 168, 55, 144, 18, 85, 77, 170, 49, 126,
      18, 189, 102, 97, 237, 249, 94, 128, 210, 250, 229, 70, 105, 152,
      31, 252, 224, 41, 145, 232, 23, 60, 58, 72, 178, 225, 10, 115,
      245, 230, 237, 114, 135, 88, 208, 125, 180, 210, 250, 76, 207,
      188, 96, 14, 32, 63, 88, 2, 254, 127, 79, 103, 22, 52, 250, 194,
      153, 168, 48, 166, 102, 210, 76, 247, 226, 137, 221, 24, 65, 76,
      66, 201, 130, 119, 55, 12, 129, 93, 131, 104, 83, 15, 233, 183,
      114, 223, 41, 229, 237, 12, 50, 219, 192, 184, 172, 77, 110, 176,
      103, 118, 10, 156, 113, 126, 52, 106, 144, 128, 125, 116, 115,
      11, 93, 149, 30, 180, 182, 68, 61, 186, 235, 113, 157, 211, 85, 
      50, 78, 24, 184, 222, 14, 147, 172, 232, 100, 98, 252, 201, 22,
      83, 174, 16, 79, 30, 151, 164, 144, 17, 132, 172, 44, 41, 222,
      216, 235, 108, 160, 84, 83, 201, 212, 42, 176, 140, 202, 50, 236,
      14, 222, 111, 143, 44, 54, 98, 7, 122, 164, 21, 218, 195, 45,
      189, 97, 70, 17, 194, 53, 12, 248, 115, 166, 82, 5, 7, 76, 145,
      169, 253, 120, 219, 239, 105, 76, 9, 152, 34, 25, 198, 253, 50,
      132, 12, 94, 55, 0, 0, 0, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
      1, 101, 0>>,
    [], o_rkv) ->
  ok

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