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

Improve fluency of persistent store configuration builders

XMLWordPrintable

      Configuration of cache stores has some fluency issues. I'd like to do:

      ConfigurationBuilder builder = ...;
      
      builder
          .persistence()
              .addStore(JdbcStringBasedStoreConfigurationBuilder.class)
                  .dialect(...)
                  .table() // <- compilation error
                      ...
                  .connectionPool() // <- compilation error
                      ...;
      

      but I'm forced to do:

      ConfigurationBuilder builder = ...;
      
      JdbcStringBasedStoreConfigurationBuilder store = builder
          .persistence()
              .addStore(JdbcStringBasedStoreConfigurationBuilder.class)
                  .dialect(...);
      store
                  .table()
                      ...;
      store
                  .connectionPool()
                      ...;
      

              ksobolewski_jira Krzysztof Sobolewski (Inactive)
              ksobolewski_jira Krzysztof Sobolewski (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: