Re: [Announcement] Official Riak Node.js client released.
Thanks Brian for your reply and trying to work out the links part. I took a look at the RiakObject and could see how to manipulate it with FetchValue and the Secondary Index. However, I failed to figure out how to access the meta while reading an object. Just as an example, when you're updating an object you could be using some meta data, and some of them come from a prior read. If you could just share some examples with code that'd be very helpful. Thanks José On Apr 2, 2015, at 3:18 PM, Brian Roach ro...@basho.com wrote: Jose, See: http://basho.github.io/riak-nodejs-client/classes/RiakObject.html As noted in the docs for StoreValue and FetchValue, you can use RiakObject instead of a plain string or JS object, and metadata is the specific reason. That said, it would appear I forgot about links as link walking is a deprecated feature in Riak 2.0. I apologize for the oversight and will add them. As for explicit examples beyond the normal API docs, our various pages on docs.bacho.com are being updated to include node.js and will be done soon. Thanks! - Brian Roach On Thu, Apr 2, 2015 at 5:47 AM, Jose G. Quenum jose.que...@googlemail.com wrote: Dear Brian, Thank you very much for sharing this link. I have been looking for a riak client for node.js that is compatible with riak 2.0. However, having glanced at it I noticed that there was no method to access the meta information. This is good for link manipulation, for example. As well in order to update an object the meta information could be useful. As a disclaimer here, I should mention that I have been using riak-js to access riak 1.4. Now I'd like to transition to riak 2.0 and I am looking for the right tools. Overall, where can one find more documentation and more concrete examples about how to manipulate riak with this client. Thanks regards, Jose Sent from my iPad On Apr 2, 2015, at 2:36 AM, Brian Roach ro...@basho.com wrote: Greetings Riak Users! Today we released the official Node.js client for Riak. It's available via npm: https://www.npmjs.com/package/basho-riak-client The github repo can be found here: https://github.com/basho/riak-nodejs-client API docs are published here: http://basho.github.io/riak-nodejs-client/classes/Client.html Thanks! - Brian Roach ___ riak-users mailing list riak-users@lists.basho.com http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com ___ riak-users mailing list riak-users@lists.basho.com http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
non-indexable SOLR schema
Hi all, To be able to use counters/sets/maps in Riak I have to store the object into a defined bucket_type indexed via SOLR. However, this will require extra disk space as data will be indexed (if using the default schema). Can I create a custom schema ignoring all fields so nothing is indexed? I don't need to use Riak Search on these objects, as I always know the KEY to fetch them. A schema like this would work? ( I guess that I can not put [ indexed=false ] in the _yz* fields required by Riak, right? Or is it possible to not index that data either? ) —+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+— ?xml version=1.0 encoding=UTF-8 ? schema name=schedule version=1.5 fields dynamicField name=* type=ignored / !-- All of these fields are required by Riak Search -- field name=_yz_id type=_yz_str indexed=true stored=true multiValued=false required=true/ field name=_yz_ed type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_pn type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_fpn type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_vtag type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_rk type=_yz_str indexed=true stored=true multiValued=false/ field name=_yz_rt type=_yz_str indexed=true stored=true multiValued=false/ field name=_yz_rb type=_yz_str indexed=true stored=true multiValued=false/ field name=_yz_err type=_yz_str indexed=true stored=false multiValued=false/ /fields uniqueKey_yz_id/uniqueKey types fieldtype name=ignored stored=false indexed=false multiValued=true class=solr.StrField / !-- YZ String: Used for non-analyzed fields -- fieldType name=_yz_str class=solr.StrField sortMissingLast=true / /types /schema —+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+— Another question, can I use the [ compressed=true ] to save disk space? in both dynamicField name=* type=ignored / and _yz* fields? Thanks, Alex ___ riak-users mailing list riak-users@lists.basho.com http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
Re: non-indexable SOLR schema
Riak does not in any way rely on solr for its KV operations. Not sure where you are seeing that or what code you are looking at but you can define bucket types, activate them without ever touching solr. The basic bucket type set up instructions can be found here: http://docs.basho.com/riak/latest/dev/advanced/bucket-types/. On 4/4/15, 8:51 AM, Alex De la rosa alex.rosa@gmail.commailto:alex.rosa@gmail.com wrote: How to do that? For what I have seen, to use these special data types you need to create a bucket under a bucket_type; and this bucket type is created following an index so data gets indexed in Solr. On Saturday, April 4, 2015, Shawn Debnath sh...@debnath.netmailto:sh...@debnath.net wrote: You do not have to set up Yokozuna (yz) to be able to use counters, sets, maps in Riak. Those types can be used independently via the Riak key value store. You only need to set up the indexes if you were to search for data via yz or search 2.0. And in that case, you can remove the generic mappings, keep the _yz specific ones and then explicitly add the fields you want to index/search on. On 4/4/15, 7:25 AM, Alex De la rosa alex.rosa@gmail.comjavascript:_e(%7B%7D,'cvml','alex.rosa@gmail.com'); wrote: Hi all, To be able to use counters/sets/maps in Riak I have to store the object into a defined bucket_type indexed via SOLR. However, this will require extra disk space as data will be indexed (if using the default schema). Can I create a custom schema ignoring all fields so nothing is indexed? I don't need to use Riak Search on these objects, as I always know the KEY to fetch them. A schema like this would work? ( I guess that I can not put [ indexed=false ] in the _yz* fields required by Riak, right? Or is it possible to not index that data either? ) —+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+— ?xml version=1.0 encoding=UTF-8 ? schema name=schedule version=1.5 fields dynamicField name=* type=ignored / !-- All of these fields are required by Riak Search -- field name=_yz_id type=_yz_str indexed=true stored=true multiValued=false required=true/ field name=_yz_ed type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_pn type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_fpn type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_vtag type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_rk type=_yz_str indexed=true stored=true multiValued=false/ field name=_yz_rt type=_yz_str indexed=true stored=true multiValued=false/ field name=_yz_rb type=_yz_str indexed=true stored=true multiValued=false/ field name=_yz_err type=_yz_str indexed=true stored=false multiValued=false/ /fields uniqueKey_yz_id/uniqueKey types fieldtype name=ignored stored=false indexed=false multiValued=true class=solr.StrField / !-- YZ String: Used for non-analyzed fields -- fieldType name=_yz_str class=solr.StrField sortMissingLast=true / /types /schema —+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+— Another question, can I use the [ compressed=true ] to save disk space? in both dynamicField name=* type=ignored / and _yz* fields? Thanks, Alex ___ riak-users mailing list riak-users@lists.basho.com http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
Re: non-indexable SOLR schema
You do not have to set up Yokozuna (yz) to be able to use counters, sets, maps in Riak. Those types can be used independently via the Riak key value store. You only need to set up the indexes if you were to search for data via yz or search 2.0. And in that case, you can remove the generic mappings, keep the _yz specific ones and then explicitly add the fields you want to index/search on. On 4/4/15, 7:25 AM, Alex De la rosa alex.rosa@gmail.commailto:alex.rosa@gmail.com wrote: Hi all, To be able to use counters/sets/maps in Riak I have to store the object into a defined bucket_type indexed via SOLR. However, this will require extra disk space as data will be indexed (if using the default schema). Can I create a custom schema ignoring all fields so nothing is indexed? I don't need to use Riak Search on these objects, as I always know the KEY to fetch them. A schema like this would work? ( I guess that I can not put [ indexed=false ] in the _yz* fields required by Riak, right? Or is it possible to not index that data either? ) —+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+— ?xml version=1.0 encoding=UTF-8 ? schema name=schedule version=1.5 fields dynamicField name=* type=ignored / !-- All of these fields are required by Riak Search -- field name=_yz_id type=_yz_str indexed=true stored=true multiValued=false required=true/ field name=_yz_ed type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_pn type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_fpn type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_vtag type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_rk type=_yz_str indexed=true stored=true multiValued=false/ field name=_yz_rt type=_yz_str indexed=true stored=true multiValued=false/ field name=_yz_rb type=_yz_str indexed=true stored=true multiValued=false/ field name=_yz_err type=_yz_str indexed=true stored=false multiValued=false/ /fields uniqueKey_yz_id/uniqueKey types fieldtype name=ignored stored=false indexed=false multiValued=true class=solr.StrField / !-- YZ String: Used for non-analyzed fields -- fieldType name=_yz_str class=solr.StrField sortMissingLast=true / /types /schema —+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+— Another question, can I use the [ compressed=true ] to save disk space? in both dynamicField name=* type=ignored / and _yz* fields? Thanks, Alex ___ riak-users mailing list riak-users@lists.basho.com http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
Re: non-indexable SOLR schema
How to do that? For what I have seen, to use these special data types you need to create a bucket under a bucket_type; and this bucket type is created following an index so data gets indexed in Solr. On Saturday, April 4, 2015, Shawn Debnath sh...@debnath.net wrote: You do not have to set up Yokozuna (yz) to be able to use counters, sets, maps in Riak. Those types can be used independently via the Riak key value store. You only need to set up the indexes if you were to search for data via yz or search 2.0. And in that case, you can remove the generic mappings, keep the _yz specific ones and then explicitly add the fields you want to index/search on. On 4/4/15, 7:25 AM, Alex De la rosa alex.rosa@gmail.com javascript:_e(%7B%7D,'cvml','alex.rosa@gmail.com'); wrote: Hi all, To be able to use counters/sets/maps in Riak I have to store the object into a defined bucket_type indexed via SOLR. However, this will require extra disk space as data will be indexed (if using the default schema). Can I create a custom schema ignoring all fields so nothing is indexed? I don't need to use Riak Search on these objects, as I always know the KEY to fetch them. A schema like this would work? ( I guess that I can not put [ indexed=false ] in the _yz* fields required by Riak, right? Or is it possible to not index that data either? ) —+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+— ?xml version=1.0 encoding=UTF-8 ? schema name=schedule version=1.5 fields dynamicField name=* type=ignored / !-- All of these fields are required by Riak Search -- field name=_yz_id type=_yz_str indexed=true stored=true multiValued=false required=true/ field name=_yz_ed type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_pn type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_fpn type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_vtag type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_rk type=_yz_str indexed=true stored=true multiValued=false/ field name=_yz_rt type=_yz_str indexed=true stored=true multiValued=false/ field name=_yz_rb type=_yz_str indexed=true stored=true multiValued=false/ field name=_yz_err type=_yz_str indexed=true stored=false multiValued=false/ /fields uniqueKey_yz_id/uniqueKey types fieldtype name=ignored stored=false indexed=false multiValued=true class=solr.StrField / !-- YZ String: Used for non-analyzed fields -- fieldType name=_yz_str class=solr.StrField sortMissingLast=true / /types /schema —+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+— Another question, can I use the [ compressed=true ] to save disk space? in both dynamicField name=* type=ignored / and _yz* fields? Thanks, Alex ___ riak-users mailing list riak-users@lists.basho.com http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
Re: non-indexable SOLR schema
Uhm, interesting, I didn't see that page; I believe the one I saw was about using Riak Search and that's where my assumption on needing to create an index to make a bucket_type came along. Much easier though! Thanks! Alex On Saturday, April 4, 2015, Shawn Debnath sh...@debnath.net wrote: Riak does not in any way rely on solr for its KV operations. Not sure where you are seeing that or what code you are looking at but you can define bucket types, activate them without ever touching solr. The basic bucket type set up instructions can be found here: http://docs.basho.com/riak/latest/dev/advanced/bucket-types/. On 4/4/15, 8:51 AM, Alex De la rosa alex.rosa@gmail.com javascript:_e(%7B%7D,'cvml','alex.rosa@gmail.com'); wrote: How to do that? For what I have seen, to use these special data types you need to create a bucket under a bucket_type; and this bucket type is created following an index so data gets indexed in Solr. On Saturday, April 4, 2015, Shawn Debnath sh...@debnath.net javascript:_e(%7B%7D,'cvml','sh...@debnath.net'); wrote: You do not have to set up Yokozuna (yz) to be able to use counters, sets, maps in Riak. Those types can be used independently via the Riak key value store. You only need to set up the indexes if you were to search for data via yz or search 2.0. And in that case, you can remove the generic mappings, keep the _yz specific ones and then explicitly add the fields you want to index/search on. On 4/4/15, 7:25 AM, Alex De la rosa alex.rosa@gmail.com wrote: Hi all, To be able to use counters/sets/maps in Riak I have to store the object into a defined bucket_type indexed via SOLR. However, this will require extra disk space as data will be indexed (if using the default schema). Can I create a custom schema ignoring all fields so nothing is indexed? I don't need to use Riak Search on these objects, as I always know the KEY to fetch them. A schema like this would work? ( I guess that I can not put [ indexed=false ] in the _yz* fields required by Riak, right? Or is it possible to not index that data either? ) —+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+— ?xml version=1.0 encoding=UTF-8 ? schema name=schedule version=1.5 fields dynamicField name=* type=ignored / !-- All of these fields are required by Riak Search -- field name=_yz_id type=_yz_str indexed=true stored=true multiValued=false required=true/ field name=_yz_ed type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_pn type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_fpn type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_vtag type=_yz_str indexed=true stored=false multiValued=false/ field name=_yz_rk type=_yz_str indexed=true stored=true multiValued=false/ field name=_yz_rt type=_yz_str indexed=true stored=true multiValued=false/ field name=_yz_rb type=_yz_str indexed=true stored=true multiValued=false/ field name=_yz_err type=_yz_str indexed=true stored=false multiValued=false/ /fields uniqueKey_yz_id/uniqueKey types fieldtype name=ignored stored=false indexed=false multiValued=true class=solr.StrField / !-- YZ String: Used for non-analyzed fields -- fieldType name=_yz_str class=solr.StrField sortMissingLast=true / /types /schema —+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+—+— Another question, can I use the [ compressed=true ] to save disk space? in both dynamicField name=* type=ignored / and _yz* fields? Thanks, Alex ___ riak-users mailing list riak-users@lists.basho.com http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com