[ChicagoBoss 0.8.12] and [Riak 2.0.2]

82 views
Skip to first unread message

Miguel Benitez

unread,
Dec 12, 2014, 5:03:15 PM12/12/14
to chica...@googlegroups.com
Hello community, our company recently decided to start a new development leveraging the benefits of [ChicagoBoss 0.8.12] and [Riak 2.0.2], after making the necessary configurations everything seems to work until you try to do a search from the ChicagoBoss ORM: boss_db: find (model, [{id, 'equals', Id}]). yielding an error. After reading countless amounts of articles and documentation, we decided to enable Riak Search, but now the search returns an empty list [].

ChicagoBoss' ORM uses riakc (Erlang Riak Client, the official client by basho) and this sets the Content-Type to "application / x-erlang-binary", I wonder if this has something to do with indexing, perhaps it prevents the object being indexed?

I wonder if anyone has information. Any help would be welcome.

Greetings
--
Miguel Benitez
Systrix LLC

İbrahim Yılmaz

unread,
Dec 13, 2014, 2:30:59 AM12/13/14
to chica...@googlegroups.com
Hi Miguel,

Please chek with the following command that your bucket has "searchbucket" in props :

curl -v http://127.0.0.1:8098/buckets/test/props

Bryce Verdier

unread,
Dec 13, 2014, 4:13:31 PM12/13/14
to chica...@googlegroups.com

I was playing around with riak search yesterday and found this link very helpful with getting started:
http://docs.basho.com/riak/latest/dev/using/search/#Simple-Setup

I'm not sure if that's your problem but it's it seems like a good idea to make sure search works in general before trying to tie it into chicagoboss.

Warm regards,
Bryce

--
You received this message because you are subscribed to the Google Groups "ChicagoBoss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chicagoboss...@googlegroups.com.
Visit this group at http://groups.google.com/group/chicagoboss.
To view this discussion on the web visit https://groups.google.com/d/msgid/chicagoboss/900e1a70-28d4-40ed-98fd-c7ba045bcb62%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Message has been deleted

Miguel Benitez

unread,
Dec 15, 2014, 5:24:33 PM12/15/14
to chica...@googlegroups.com
Thanks ibrahim,

This the result for my props

* About to connect() to localhost port 8098 (#0)
*   Trying ::1...
* Conexión rehusada
*   Trying 127.0.0.1...
* connected
* Connected to localhost (127.0.0.1) port 8098 (#0)
> GET /buckets/greetings/props HTTP/1.1
> User-Agent: curl/7.26.0
> Host: localhost:8098
> Accept: */*
* HTTP 1.1 or later with persistent connection, pipelining supported
< HTTP/1.1 200 OK
< Vary: Accept-Encoding
< Server: MochiWeb/1.1 WebMachine/1.10.5 (jokes are better explained)
< Date: Mon, 15 Dec 2014 22:16:10 GMT
< Content-Type: application/json
< Content-Length: 474
* Connection #0 to host localhost left intact
{"props":{"allow_mult":false,"basic_quorum":false,"big_vclock":50,"chash_keyfun":{"mod":"riak_core_util","fun":"chash_std_keyfun"},"dvv_enabled":false,"dw":"quorum","last_write_wins":false,"linkfun":{"mod":"riak_kv_wm_link_walker","fun":"mapreduce_linkfun"},"n_val":3,"name":"greetings","notfound_ok":true,"old_vclock":86400,"postcommit":[],"pr":0,"precommit":[],"pw":0,"r":"quorum","rw":"quorum","search_index":"greetings","small_vclock":50,"w":"quorum","young_vclock":20}}* Closing connection #0

I have an index called greetings, with a predetermined scheme, which is associated with greetings bucket, I can insert data to the bucket and list all data from the bucket, but when I try using a conditions query it returns a empty list [],

This is my index definition:

* About to connect() to localhost port 8098 (#0)
*   Trying ::1...
* Conexión rehusada
*   Trying 127.0.0.1...
* connected
* Connected to localhost (127.0.0.1) port 8098 (#0)
> GET /search/index/greetings HTTP/1.1
> User-Agent: curl/7.26.0
> Host: localhost:8098
> Accept: */*
* additional stuff not fine transfer.c:1037: 0 0
* HTTP 1.1 or later with persistent connection, pipelining supported
< HTTP/1.1 200 OK
< Server: MochiWeb/1.1 WebMachine/1.10.5 (jokes are better explained)
< Date: Mon, 15 Dec 2014 22:19:24 GMT
< Content-Type: application/json
< Content-Length: 53
* Connection #0 to host localhost left intact
{"name":"greetings","n_val":3,"schema":"_yz_default"}* Closing connection #0

Nick Golovin

unread,
Apr 8, 2015, 6:38:49 AM4/8/15
to chica...@googlegroups.com
Hi, Miguel, any luck with making CB work with Riak 2.0?

Miguel Benitez

unread,
Apr 8, 2015, 11:20:51 AM4/8/15
to chica...@googlegroups.com
Yes, we fixed it, here at Systrix.com we developed our own adapter for the new version of riak 2.0+, we also developed  an indexer program in erlang which is responsible for the generation of  the indexes for yokozuna (riak's solr implementation) based on model definition in CB.

Unfortunately we actually decided to migrate from CB to Elixir and the PhoenixFramework for various reasons.

Any Systrix would like to contribute all the advances we made in the CB framework with riak. We are currently publishing on github, as soon as we have the repository ready, we will send you the link.

Nick Golovin

unread,
Apr 8, 2015, 11:24:32 AM4/8/15
to chica...@googlegroups.com
Thanks a lot, Miguel



-- 
You received this message because you are subscribed to a topic in the Google Groups "ChicagoBoss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/chicagoboss/9cBdHbYyvi8/unsubscribe.
To unsubscribe from this group and all its topics, send an email to chicagoboss...@googlegroups.com.

Karim Dahmani

unread,
Apr 8, 2015, 12:13:23 PM4/8/15
to chica...@googlegroups.com
Hi,

The repo is now ready and here is the link: https://github.com/systrix/ChicagoBoss-Riak2

Karim
Systrix

Nick Golovin

unread,
Apr 8, 2015, 12:42:39 PM4/8/15
to chica...@googlegroups.com
Great, thanks a lot!

Reply all
Reply to author
Forward
0 new messages