By the way, maybe this configuration file helps you get started:
{
"interface":":4984",
"adminInterface":":4985",
"log": ["REST","CRUD", "CRUD+", "HTTP", "HTTP+", "Access", "Cache",
"Shadow", "Shadow+", "Changes", "Changes+"],
"databases":{
"sync_gw":{
"server":"http://localhost:8091",
"bucket":"sync_gw"
"sync":`
// sync function
function(doc) { channel(doc.channels); }
` }
}
}
That is expecting a bucket in your database named "sync_gw", and exposes
the db with the same name. So you would point to it like:
http://yourserever:4984/sync_gw
in your app.
BR,
Thiago
On Monday, September 29, 2014 2:53:22 PM UTC+2, Thiago Alencar wrote:
>
> This is how I start mine:
>
> ./sync_gateway -url http://127.0.0.1:8091 -bucket sync_gw -pretty
> sync_function.js
> If you don't specify the sync function, the default one is used:
>
> function (doc) {
> channel(doc.channels);
> }
>
>
> You can see all the available commands as usual with ./sync_gateway
> --help
>
> Then you just need to make sure that your firewall makes the gateway's
> port accessible.
>
> BR,
> Thiago
>
> On Monday, September 29, 2014 2:46:19 PM UTC+2, Raheel Mateen wrote:
>>
>> Thanks thiago,
>> i installed sync_gateway and now as per document
>>
>> http://developer.couchbase.com/mobile/develop/guides/sync-gateway/getting-started-with-sync-gateway/starting-sync-gateway/index.html
>>
>> how should i start the gateway ? is there config.json file which i write
>> and run in terminal or else ?
>>
>> On Wednesday, September 24, 2014 4:57:12 PM UTC+5, Raheel Mateen wrote:
>>>
>>> I follow the following to start the couch db on android
>>>
>>> http://docs.couchbase.com/couchbase-lite/cbl-android/cbl-android-1.0b2/#developing-apps
>>>
>>> but i actually not understand how to query in couch db for example if i
>>> make a document in a db so how should i access that document with the help
>>> of query.
>>>
>>
--
You received this message because you are subscribed to the Google Groups
"Couchbase Mobile" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/mobile-couchbase/19de10f2-0e18-44fe-9586-e82e9307f009%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.