title: ejb - Singleton lock mode when calling methods of same instance?
body: <p>Here is my singleton class:</p>
  
  <pre><code>import javax.ejb.Lock;
  import javax.ejb.LockType;
  import javax.ejb.Singleton;
  
  
  @Singleton
  public class TestSingletons implements TestSingletonsRemote{
  
      @Lock(LockType.READ)
      @Override
      public void foo(int id) {
          bar(id);
      }
  
  
      private void bar(int id){
          // do stuff
      }
  
  }
  </code></pre>
  
  <p>The method <code>foo</code> has a <code>LockType.READ</code>, so it can be accessed concurrently. <code>foo</code> actually does nothing but calls a private method of the class <code>bar</code> which is not annotated, so by default It should have a <code>LockType.WRITE</code> lock mode.</p>
  
  <p>The question, as you might guess from the above scenario, is:
  Will the call to <code>foo</code> be practically concurrent?</p>