title: better Java IPC@Linux tactic: (a) java.nio File API on /dev/shm or (b) JNI to shmctl(2)?
body: <p>We want write a Java 7 program that will boot (via 2 cmd line invokes) as two separate JVM process instances.  We want these 2 processes to communicate with each other using native Linux kernel shared-memory  IPC resources.</p>
  
  <p>Does anyone have any insight as to which of these 2 approaches may have more merit?</p>
  
  <ol>
  <li>Use java.nio.* API on /dev/shm</li>
  <li>Use JNI bridge to C++ code that makes native shmctl() system calls</li>
  </ol>
  
  <p>?</p>