]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
java: remove create/release synchronization
authorNoah Watkins <noahwatkins@gmail.com>
Fri, 11 Jan 2013 23:19:13 +0000 (15:19 -0800)
committerNoah Watkins <noahwatkins@gmail.com>
Mon, 14 Jan 2013 21:11:09 +0000 (13:11 -0800)
The constructor calls create, and finalize() calls release. Since each
of these can only happen once (enforced by Java), there is no fear of a
race condition.

Signed-off-by: Noah Watkins <noahwatkins@gmail.com>
src/java/java/com/ceph/fs/CephMount.java

index 3bbd4bc701e545029fa5dd865cfab070351093db..3f58a8da149d2a11afad29a18c8613017eb28f22 100644 (file)
@@ -123,7 +123,7 @@ public class CephMount {
     initialized = true;
   }
 
-  private static synchronized native int native_ceph_create(CephMount mount, String id);
+  private static native int native_ceph_create(CephMount mount, String id);
 
   /**
    * Create a new CephMount with default client id.
@@ -158,7 +158,7 @@ public class CephMount {
   /*
    * Private access to low-level ceph_release.
    */
-  private static synchronized native int native_ceph_release(long mountp);
+  private static native int native_ceph_release(long mountp);
 
   /**
    * Load configuration from a file.