I've ask then.
We've got 4 MR jobs
MapReduce mr = new
BucketMapReduce.Builder().withMapPhase(Function.newNamedJsFunction("Riak.mapValues"));
MapReduce mr = new
SearchMapReduce.Builder().withIndex("\$key").withQuery(q).withMapPhase(Function.newNamedJsFunction("Riak.mapValues"));
MapReduce mr = n
I've tested Riak Java client 2.0, while searching through BinIndexQuery, and
MapReduce.
Neither of them is working. BinIndexQuery does not allow to search through
$key index (always adding _bin to name). And MapReduce jobs there are no
examples anywhere.
I've been trying with classes BucketMapRe
not possible on that code - I've overrided some classes, and no it is
possible - use MyBinIndexQuery instead - it was tested against $key index -
but problem is with appending _BIN or _INT suffix to key name (always)
package com.thalesgroup.riak
import com.basho.riak.client.api.commands.CoreFutur
there is a bug in BinIndexQuery - I've overriden some classes and now it is
working (with orginal sources of client). Use MyBinIndexQuery instead of
BinIndexQuery. Problem is that _BIN in always apppended to name of index.
import com.basho.riak.client.api.commands.CoreFutureAdapter
import com.bash
You've changed source of java client (if sb fix something else - you need to
port changes to your own implementation).
This not satisfies me.
--
View this message in context:
http://riak-users.197444.n3.nabble.com/Using-bucket-index-in-java-client-tp4032125p4032202.html
Sent from the Riak Users
I know somethink - there are some examples of MR in java client 2.0 - which
does not work on my machine.
Although MR by HTTP is working fine.
--
View this message in context:
http://riak-users.197444.n3.nabble.com/Java-MR-tp4032117p4032205.html
Sent from the Riak Users mailing list archive at
no results (prints 0) on below code (using 2.0 java client from maven, and
connecting to riak 2.0),
I've changed map/reduce functions JS or Erlang, used different MapReduce
classes (for Bucket, BucketKey, or Index one) but without any luck.
It is written in groovy - but I do not think that it diffe
Before you comment that data is not stored in DB - check it first. It is.
And HTTP map reduce gives results. So this is false trace.
Data is in data base, client 1.4 is able to run MR job and fetch that data
(written to default bucket type), HTTP client used by curl is running job &
fetching data.
And I've verified this example without futures (with execute() function) -
does not working as well.
--
View this message in context:
http://riak-users.197444.n3.nabble.com/Java-MR-tp4032117p4032210.html
Sent from the Riak Users mailing list archive at Nabble.com.
_
Always Groovy. Not tried with java. But client 1.4 is working. And I've never
heard that Groovy could possibly interfere.
I will check it with plain java but do not expect much.
--
View this message in context:
http://riak-users.197444.n3.nabble.com/Java-MR-tp4032117p4032212.html
Sent from the
Verified in Java - full code below - does not work - entry/key is in Riak -
and
curl -s -X POST -H "Content-Type: application/json"
http://localhost:8098/mapred -d
'{"inputs":{"bucket":"bucket2","key_filters":[["starts_with", "key"]]},
"query":[{"map":{"language":"javascript", "source":"function(v
this example does not work because I have disabled phase to output,
but I have changed this many times and I will find another example which
does not work,
but tomorrow
now thank Chirs for help
--
View this message in context:
http://riak-users.197444.n3.nabble.com/Java-MR-tp4032117p4032215.h
So I've verified that simple code in Java(1.7) is working fine, but in Groovy
(2.3.6) it is not.
And problem is only in Java Client 2.0. Working with 1.4 is doing fine in
Groovy and Java as well.
Everything is run from Intelij (does not know if matters).
I am astonished. Till now I've tested only o
I've noticed same problem (with $key index), and by overriding (many 3
classes) you can overcome this error - but it is awkward
better solution should be delivered
PS. I've reported bug on github riak-java-client
--
View this message in context:
http://riak-users.197444.n3.nabble.com/Using-b
How should look inputs for mapreduce job in HTTP
something like this is working on default bucket_type
curl -s -X POST -H "Content-Type: application/json"
http://localhost:8098/mapred -d
'{"inputs":{"bucket":"history100","key_filters":[["starts_with", "2014"]]},
"query":[{"map":{"language":"javas
Ok, I've just found
curl -s -X POST -H "Content-Type: application/json"
http://localhost:8098/mapred -d '{"inputs":{"bucket":["bucket_type",
"bucket"],"key_filters":[["starts_with", "2014"]]},
"query":[{"map":{"language":"javascript", "name":"Riak.mapValues"}} ]}'
--
View this message in cont
I have got no clue why in Groove it does not work.
But in meantime (in Java)
I've got another problem - when running
I want to achieve HTTP equivalent
curl -s -X POST -H "Content-Type: application/json"
http://localhost:8098/mapred -d
'{"inputs":{"bucket":["bucket_type","bucket"],"index":"$key",
I know what makes a difference in groovy
with anotation
@groovy.transform.CompileStatic
everything works as in java
but why? and why this is a problem with java client 2.0 only - no idea?
--
View this message in context:
http://riak-users.197444.n3.nabble.com/Java-MR-tp4032117p4032228.html
is it possible to delete or store new key alongside MR job?
in JavaScript?
any example?
is it possible to determine if key still exists (not deleted) in MR job?
how ? example?
--
View this message in context:
http://riak-users.197444.n3.nabble.com/store-delete-of-key-possible-in-MR-tp4032242.h
yes, I do
--
View this message in context:
http://riak-users.197444.n3.nabble.com/store-delete-of-key-possible-in-MR-tp4032242p4032252.html
Sent from the Riak Users mailing list archive at Nabble.com.
___
riak-users mailing list
riak-users@lists.bash
20 matches
Mail list logo