Code Monkey home page Code Monkey logo

couchbase-lite-android's Introduction

Stories in Ready

Couchbase-Lite-Android

Couchbase-Lite-Android is a lightweight embedded NoSQL database engine for Android with the built-in ability to sync to Couchbase Server on the backend.

It is the Android port of Couchbase Lite iOS.

Architecture

Couchbase Lite databases are able to sync with eachother via Sync Gateway backed by Couchbase Server

Documentation Overview

Getting started with Couchbase Lite

Getting the pre-built jars / maven artifacts

Maven master branch

Maven repo URL: http://files.couchbase.com/maven2/

<dependency>
  <groupId>com.couchbase.lite</groupId>
  <artifactId>android</artifactId>
  <version>0.0.0-426</version>
</dependency>

While 0.0.0-426 was the latest build at the time of writing, it's probably out of date by the time you are reading this. To get the latest build number (eg, the "426" part of the version above), see our Maven Repo and look for the highest numbered version that starts with 0.0.0- and is later than 0.0.0-426

Here is a complete gradle file that uses this maven artifact.

Maven 1.0 release

Maven repo URL: http://files.couchbase.com/maven2/

<dependency>
  <groupId>com.couchbase.lite</groupId>
  <artifactId>android</artifactId>
  <version>1.0.0-75</version>
</dependency>

Zipfile that includes jars

For Eclipse and Phonegap users, here are links to the zip file which includes the jars:

Building Couchbase Lite master branch from source

Prerequisites

  • Download Android Studio. Versions 0.8.2 is known to work, with the following caveat: when importing, you will see this error, but after that you should be able to click the menu bar item "Sync Project with Gradle files" and the project should work after that. If you are trying to build the 1.0.x release branch, you will need to use Android Studio version 0.5.7.

  • Under Tools / Android / Android SDK Manager and install "Extras/Google Repository" and "Extras/Android Support Repository" (future versions of Android Studio may make this step unnecessary)

Clone the git repository

Use Git to clone the Couchbase Lite repository to your local disk:

$ git clone git://github.com/couchbase/couchbase-lite-android.git
$ cd couchbase-lite-android
$ git submodule init && git submodule update

Configure Android Studio SDK location

  • cp local.properties.example local.properties
  • Customize local.properties according to your SDK installation directory

Enable settings.gradle file

  • cp settings.gradle.example settings.gradle

Importing Project into Android Studio

You should be able to import the project directly into Android Studio:

  • Start Android Studio
  • Choose File / Import and choose the settings.gradle file in the couchbase-lite-android directory you cloned earlier
  • Hit Finish and wait for all tasks to finish (may take a while)

Warning when importing, you will probably see an error like Wrong offset: 290. Should be in range: 0, 230, but after that you should be able to click the menu bar item "Sync Project with Gradle files" and the project should work after that

Running tests

There are two wiki pages which describe how to run the tests:

Example Apps

Project Structure

Requirements

  • Android 2.3 Gingerbread (API level 9) and above.

Getting Help

Credits

Credits

License

  • Apache License 2.0

githalytics.com alpha

couchbase-lite-android's People

Contributors

amy-kurtzman avatar andreibaranouski avatar mjq avatar pamalyshev avatar pasin avatar pegli avatar rajasaur avatar tleyden avatar waynecarter avatar yaronyg avatar zgramana avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.