Clone Tools
  • last updated a few minutes ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
MODE-2528 Refactors the relational-persistence-provider to provide better support for different types of DBs This also changes the default serialization format to Bson bytes from Json strings, which are very fast to write but slower to read.

  1. … 21 more files in changeset.
MODE-2569 Adds a file and in-memory persistence provider based on H2's MVStore. Changes most of the unit tests to use the new provider.

  1. … 62 more files in changeset.
MODE-2528 Integrates the new relational provider with the modeshape codebase This is a huge commit which makes the necessary changes to remove all Infinispan configuration and dependencies, replacing it with the new mechanism. It also contains several changes to the relational provider design because of various failing tests. This includes among other thing the necessity for ModeShape to notify the provider once exclusive locks have been obtained as part of each transaction.

    • -40
    • +0
    ./concurrent-load-infinispan-cache.xml
  1. … 304 more files in changeset.
MODE-2536 Ads the ability for ModeShape to lookup different JTA transaction managers This is required because in the absence of ISPN, ModeShape will have to be able to support both local and user transactions, regardless of the environment it's being run in. This commit also removes the "transactionMode" configuration option, as ModeShape should be able to auto-detect if it's being run or not in the context of a user transaction.

  1. … 34 more files in changeset.
MODE-2526 Replaces the workspace cache with a simple LRU cache based on a ConcurrentLinkedMap This is also updates both the JSON configuration and the Wildfly configuration with a simple setting - "cacheSize" - which controls the maximum number of elements from the workspace cache.

    • -20
    • +0
    ./concurrent-load-workspace-cache.xml
  1. … 62 more files in changeset.
Updated Infinispan schema to 7.2 together with some cache configurations.

    • -4
    • +5
    ./concurrent-load-infinispan-cache.xml
  1. … 42 more files in changeset.
MODE-2423 Moved to ISPN 7.2.0.CR1

    • -62
    • +36
    ./concurrent-load-infinispan-cache.xml
    • -16
    • +11
    ./concurrent-load-workspace-cache.xml
  1. … 55 more files in changeset.
MODE-2265 After comparing MapDB with the current ISPN cache locally, it runs out MapDB performs worse when there is a lot of churn because the serialization/deserialization process. After looking at the current default ISPN workspace cache config, it turns out there is no reason for enable locking for the WorkspaceCache, so this has been removed.

  1. … 3 more files in changeset.
MODE-2066 Migrated to Infinispan 6.0.1 and JGroups 3.4.1. Beside the changes involving package migrations and API changes, because the BDB and JDBM cachestore have not been ported to 6.x yet, all references (only unit tests) to those cache stores were removed and replaced with LevelDB. The old FileCacheStore has been discontinued and therefore replaced with SingleFileStore.

    • -10
    • +11
    ./concurrent-load-infinispan-cache.xml
  1. … 97 more files in changeset.
MODE-2081 Changed the remaining files over to the ASL 2.0 license

    • -24
    • +0
    ./concurrent-load-infinispan-cache.xml
  1. … 1050 more files in changeset.
MODE-2121 Corrected the concurrency problem within the LazyCachedNode

A new stress test case was added to have lots of calls to the cached nodes, and this highlighted

a problem in the LazyCachedNode.

Although each LazyCachedNode is (mostly) immutable, there still are a number of fields that

are lazily populated. Before this change, these fields were not being updated in an atomic

and thread-safe fashion. Additionally, these fields were not volatile (or Atomic) and thus

there is no guarantee when or in what order one thread sees the fields updated by another

thread.

Most of the fields are self-contained and idempotent, so they did not pose much of a problem.

However, the "parentReferenceToSelf" method used TWO fields to cache the information,

and if a thread saw only one of these fields after being (correctly) updated by another thread,

the reading thread would see an inconsistent state and the logic would incorrectly return null

for the ChildReference containing this node's name and SNS index.

The solution for most of the fields was simply to make them volatile (for most references that

are simply set) or AtomicReference in the one case where the value is somewhat expensive to

compute if it is not really needed.

The solution for the "parentReferenceToSelf" method was to use a single field with an

AtomicReference to an object that encapsulated the information previously stored in two fields.

This also meant that some of the logic could be encapsulated into this new object, and that

a specialized implementation could be used for the root node's ChildReference to itself

(allowing the other implementation to be simplified). The "parentReferenceToSelf" method

is carefully written to not require any synchronization or locking, and thus it is very

fast. Striclty speaking, at any given instant constructing the cached information is idempotent,

meaning that two nearly-concurrent calls might each have to do all of the work. But in

the end, both calls will see consistent information and only one of the representations will

be kept.

After these changes, the stress test runs quite well (albeit with a lot of memory),

and the previously-reported exception is seen no more.

    • -0
    • +88
    ./concurrent-load-infinispan-cache.xml
    • -0
    • +41
    ./concurrent-load-repo-config.json
    • -0
    • +26
    ./concurrent-load-workspace-cache.xml
    • -0
    • +58
    ./deck-cards-resource.cnd
  1. … 4 more files in changeset.
MODE-2121 Corrected the concurrency problem within the LazyCachedNode

A new stress test case was added to have lots of calls to the cached nodes, and this highlighted

a problem in the LazyCachedNode.

Although each LazyCachedNode is (mostly) immutable, there still are a number of fields that

are lazily populated. Before this change, these fields were not being updated in an atomic

and thread-safe fashion. Additionally, these fields were not volatile (or Atomic) and thus

there is no guarantee when or in what order one thread sees the fields updated by another

thread.

Most of the fields are self-contained and idempotent, so they did not pose much of a problem.

However, the "parentReferenceToSelf" method used TWO fields to cache the information,

and if a thread saw only one of these fields after being (correctly) updated by another thread,

the reading thread would see an inconsistent state and the logic would incorrectly return null

for the ChildReference containing this node's name and SNS index.

The solution for most of the fields was simply to make them volatile (for most references that

are simply set) or AtomicReference in the one case where the value is somewhat expensive to

compute if it is not really needed.

The solution for the "parentReferenceToSelf" method was to use a single field with an

AtomicReference to an object that encapsulated the information previously stored in two fields.

This also meant that some of the logic could be encapsulated into this new object, and that

a specialized implementation could be used for the root node's ChildReference to itself

(allowing the other implementation to be simplified). The "parentReferenceToSelf" method

is carefully written to not require any synchronization or locking, and thus it is very

fast. Striclty speaking, at any given instant constructing the cached information is idempotent,

meaning that two nearly-concurrent calls might each have to do all of the work. But in

the end, both calls will see consistent information and only one of the representations will

be kept.

After these changes, the stress test runs quite well (albeit with a lot of memory),

and the previously-reported exception is seen no more.

    • -0
    • +88
    ./concurrent-load-infinispan-cache.xml
    • -0
    • +41
    ./concurrent-load-repo-config.json
    • -0
    • +26
    ./concurrent-load-workspace-cache.xml
    • -0
    • +58
    ./deck-cards-resource.cnd
  1. … 4 more files in changeset.