Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 314298 - MEMStore is too tolerant against with branch creation if branching is not enabled
Summary: MEMStore is too tolerant against with branch creation if branching is not ena...
Status: CLOSED FIXED
Alias: None
Product: EMF
Classification: Modeling
Component: cdo.core (show other bugs)
Version: 3.0   Edit
Hardware: PC Windows 7
: P3 minor (vote)
Target Milestone: ---   Edit
Assignee: Eike Stepper CLA
QA Contact: Eike Stepper CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-05-25 11:55 EDT by Eike Stepper CLA
Modified: 2010-06-29 09:22 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Eike Stepper CLA 2010-05-25 11:55:39 EDT
With MEMstore branches can even be created if branching support is disabled in the repository.
Comment 1 Eike Stepper CLA 2010-05-25 11:57:16 EDT
Adding a check in Repository.java:

  public int createBranch(int branchID, BranchInfo branchInfo)
  {
    if (!isSupportingBranches())
    {
      throw new IllegalStateException("Branching is not supported by " + this);
    }

    synchronized (createBranchLock)
    {
      IStoreAccessor accessor = StoreThreadLocal.getAccessor();
      return accessor.createBranch(branchID, branchInfo);
    }
  }
Comment 2 Eike Stepper CLA 2010-05-25 12:01:16 EDT
Committed to HEAD
Comment 3 Eike Stepper CLA 2010-05-25 12:01:41 EDT
Reopen for changing assignee
Comment 4 Eike Stepper CLA 2010-05-25 12:02:05 EDT
Assignee changed
Comment 5 Eike Stepper CLA 2010-06-29 04:36:19 EDT
Available in 3.0 GA:
http://download.eclipse.org/modeling/emf/cdo/updates/3.0-releases/