Uploaded image for project: 'Infinispan'
  1. Infinispan
  2. ISPN-815

Clone caches should be created and started much faster

    Details

      Description

      We must be faster creating caches that are just simply copies of the same configuration.

      Creating 500 caches of the default cache configuration takes around 4 seconds.
      Creating 1000 caches takes around 10 seconds.

      This is too slow. As shown in the profiler screenshot, calling componentRegistry.registerComponent(spi, AdvancedCache.class); is quite expensive.
      The start procedure is also quite expensive, specially due to some reflection going on there.

      IMO, we need fast way to clone caches. IOW, if you create Cache A based on config default config, creating/starting Cache B based on default config should be extremely fast. Simply duplicate objects and set them in the right state.

      This is of particular importance in 2LC use cases where each entity/collection is stored in a separate cache and these are generally created on startup by the Hibernate Session Factory.

      Check the linked user forum post for some feedback from a 2LC user.

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                galder.zamarreno Galder Zamarreño
                Reporter:
                galder.zamarreno Galder Zamarreño
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: