Questions tagged [couchbase-lite]

Couchbase Lite is an ultra-lightweight, reliable, secure JSON database built for online/offline mobile application needs and is part of Couchbase's Mobile product.

As a lightweight, document-oriented NoSQL database engine, Couchbase Lite supports data synchronization and is suitable for embedding into mobile applications.

Lightweight means:

  • Embedded – the database engine is a library linked into the app, not a separate server process
  • Small code size – important for mobile apps because they’re often downloaded over cell networks
  • Quick startup time – important because mobile devices have relatively slow CPUs
  • Low memory usage – typical mobile data sets are relatively small, but some documents might have large multimedia attachments
  • Good performance – exact figures depend on your data and application

Document-oriented means:

  • Stores records in flexible JSON format instead of requiring predefined schemas or normalization
  • Documents can have arbitrary-sized binary data, such as multimedia content
  • Application data format can evolve over time without any need for explicit migrations
  • Language native query builder API provides fast lookups without needing special query languages

Syncable means:

  • Any two copies of a database can be brought into sync via an efficient, reliable, and proven replication algorithm
  • Sync can be on demand or continuous
  • Devices can sync with a subset of a large database on a remote server
  • The sync engine supports intermittent and unreliable network connections
  • Conflicts can be detected and resolved
  • Revision trees allow for complex replication topologies – including server-to-server (for multiple data centers) and peer-to-peer – without data loss or false conflicts

Couchbase Lite provides native APIs for:

  • Seamless iOS (Objective-C and Swift), Android (Java), and .NET development
  • Frameworks such as Xamarin
  • Embedded platforms

Resources:

521 questions
0
votes
1 answer

Can not understand couchbase todolite demo

github.com/couchbaselabs/ToDoLite-Android Q 1: https://github.com/couchbaselabs/ToDoLite-Android/blob/master/ToDoLite/src/main/java/com/couchbase/todolite/document/Profile.java profile.java have code : Document document = database.getDocument("p:"…
sueboy
  • 11
  • 3
0
votes
1 answer

Validate Couchbase Sync Gateway Credentials from Android

I am working on an Android app which uses Couchbase Lite and Sync Gateway. I'm authenticating against the Sync Gateway using basic HTTP authentication. Is there a way to validate a user's credentials without triggering a replication? I believe I…
Alan
  • 2,962
  • 2
  • 15
  • 18
0
votes
1 answer

couchbase client (android) view returns empty index

I have written a view and inserted it into the couchbase server through the sync gateway. When I click on "Show Results" in the couchbase console, it returns one document. This view is a production view and not a development view. When I tried…
0
votes
1 answer

PullReplication to fetch data from couch base into the Couch Lite not working in Android

I'm using Couchbase Lite DB to fetch data from a Couchbase server. In the Android Emulator it's working fine but in Android devices (Mobiles) it's showing a timeout exception and indeed is taking too much time. Ideas?
Droid_Dev
  • 1,162
  • 1
  • 8
  • 25
0
votes
1 answer

How to determine does couchbase lite database have local changes?

I use couchbase lite for Android. I need to inform the user about unsynced local changes which will be lost during the log out from the app. For example, user changes the data during offline work and wants to log out. Does anybody know a way to…
gio
  • 4,950
  • 3
  • 32
  • 46
0
votes
1 answer

Couchbase-lite replication error

working with pure java and couchbase-lite. running following code: Manager manager = new Manager(new JavaContext("data"), Manager.DEFAULT_OPTIONS); Manager.enableLogging("Sync", Log.VERBOSE); final Database db =…
Waqas
  • 49
  • 4
0
votes
1 answer

Authorizing Users in couchbase sync gateway

Authorizing User through code: String url = "http://localhost:4984/sync_gateway/_user/GUEST"; URL obj = new URL(url); HttpURLConnection con = (HttpURLConnection) obj.openConnection(); con.setRequestMethod("POST"); …
0
votes
1 answer

Save image in couchbase lite java

How do I save image in couchbase lite in core java? As we save image in couchase server, we convert image to bytes and than save bytes. But its not having like that in couchbase lite. Kindly help me. final BufferedImage image = ImageIO.read(new…
Waqas
  • 49
  • 4
0
votes
1 answer

couchbase lite xamarin pull replication with sync-gateway

I want to pull documents with username attribute as user1 for user1 like that for each user only attribute with their name. This is my replication code. private void setupreplication(){ Console.WriteLine ("Setting up replication"); …
0
votes
2 answers

Integrating xamarin, CouchBaseLite, MVVMCross and SyncGateway such that View changes with database

I am working on a xamarin project where i use CouchBase Lite as my Local database. I also want to use MVVMCross library. Could anyone specify where should i include couchbase-Lite library, MVVMCross - hot tuna library(like class library or portable…
0
votes
1 answer

Couchbase filter on pull replication c#

Trying to add pull filter in Couchbase Lite... Added filter in design document "filters": { "user": "function(doc,req) { if(doc.type == 'user' && email == req.query.email) {return true;} return false;}" } In C# replicatoin code added…
Wiz
  • 44
  • 7
0
votes
1 answer

Couchbase server from CouchbaseLite

Is it possible to query the server database from Couchbase Lite. I know there is a REST API that does what I'm looking for but I'm wondering if the Node.js API supports this feature.
Josh Elias
  • 3,250
  • 7
  • 42
  • 73
0
votes
1 answer

Populating a tableView from a couchbase live query

I'm new to programming so please try to explain with details or examples. I'm building an app that uses couchbase-lite to display a list of results in a tableview. I want to display any changes in the list as soon as they happen so I need to use the…
Mr Stanev
  • 1,662
  • 1
  • 19
  • 26
0
votes
1 answer

How can i load data and display it using CouchBase Lite

I'm a in the process of understanding CouchBase Lite for android application,as far i only know how to create a manager, database, document and view.However i want to load data from the documents and show it int the app but failed after trying…
0
votes
2 answers

How i can add Couchbase Documents in a list?

I'm experimenting with Couchbase + Xamarin.Forms trying to do a simple search, showing the results in a ListView but I've stuck. :( Someone know how to add the rows/documents of a query in a list? public List SearchRecord (string word) { …
Jonathan Zúñiga
  • 645
  • 3
  • 13
  • 25