On Dec 1, 2010, at 10:08 AM, Kevin Smith wrote:
> There is a cache between the MapReduce machinery and the Javascript VMs to
> reduce demand on the VMs. It is a two-level cache based on the bucket/key
> pair being accessed and the hash of the Javascript function name or source
> being invoked. Changing either the function or writing to the bucket/key pair
> should cause the cache to eject entries.
>
> If you want to disable the cache, you can do so by adding the following lines
> to the riak_kv section of your app.config:
>
> {vnode_cache_entries, 0}
This did make a difference. I suspected this was the case, so I added some code
to make the Javascript I was submitting always unique. I took that back out and
put this setting in place.
> I will dig into the caching code and see if there's an issue with stale
> entries not getting ejected.
I can't say for certain, but it seems to be that the M/R gets an incomplete
list of keys to use because they are queried first. While the M/R is being run,
though, entries are added to that bucket. These are obviously not picked up by
the running M/R code because the list of keys has already been obtained.
Of course that's just a guess because I don't know the specifics of how it
works internally. :)
> What are you using for W or DW on your write calls? With W/DW < N the call
> can return while the data is still being replicated.
I was using the defaults.
What I'm trying now is to set the n_val, w, etc... properties when I start the
tests.
If I'm running a single test server, what should I set and to what value? Just
w=1 or does r need to be set too?
I basically want to make sure that every write is "flushed" before returning. I
don't want to add this to the underlying code, because I want to take advantage
of any caching and what-not. I just want to make sure that things are flushed
and solid while running the test suite. If it takes twice as long, I don't
care. I just want the tests to pass. ;)
jb
>
> --Kevin
>
>>
>> Thanks for all the help so far! :)
>>
>> Jon Brisbin
>> Portal Webmaster
>> NPC International, Inc.
>>
>>
>>
>>
>> _______________________________________________
>> riak-users mailing list
>> [email protected]
>> http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
>
Jon Brisbin
Portal Webmaster
NPC International, Inc.
_______________________________________________
riak-users mailing list
[email protected]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com