Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Tie libcouch to specific version of binaries

  • Loading branch information...
commit 720b79748e65df4aed7ad13c6e13f7ba3f8579e7 1 parent 20d9d68
@daleharvey daleharvey authored
View
BIN  assets/couchbase-1.0-dp-be9fe2f.tgz.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  assets/release-0.1.tgz.jpg
Deleted file not rendered
View
6 src/com/couchbase/libcouch/CouchDB.java
@@ -9,6 +9,7 @@
public class CouchDB {
+ private final static String defaultRelease = "couchbase-1.0-dp-be9fe2f";
private static String releaseName;
private static ICouchService couchService;
@@ -35,11 +36,14 @@ public void onServiceDisconnected(ComponentName className) {
}
};
+ public static ServiceConnection getService(Context ctx, ICouchClient client) {
+ return getService(ctx, defaultRelease, client);
+ }
+
public static ServiceConnection getService(Context ctx, String release, ICouchClient client) {
releaseName = release;
couchClient = client;
ctx.bindService(new Intent(ctx, CouchService.class), mConnection, Context.BIND_AUTO_CREATE);
return mConnection;
}
-
}
View
7 src/com/couchbase/libcouch/CouchService.java
@@ -1,5 +1,7 @@
package com.couchbase.libcouch;
+import java.io.FileNotFoundException;
+import java.io.IOException;
import java.io.PrintWriter;
import java.io.StringWriter;
import java.net.URL;
@@ -125,7 +127,10 @@ void installCouch(final String pkg) {
public void run() {
try {
CouchInstaller.doInstall(pkg, mHandler, service);
- } catch (Exception e) {
+ } catch (FileNotFoundException e) {
+ Message.obtain(mHandler, CouchService.ERROR, e).sendToTarget();
+ e.printStackTrace();
+ } catch (IOException e) {
e.printStackTrace();
}
}
Please sign in to comment.
Something went wrong with that request. Please try again.