[infinispan-issues] [JBoss JIRA] (ISPN-12096) ConfigurationBuilder::withProperties should not overwrite the transactionMode

Diego Lovison (Jira) issues at jboss.org
Tue Jul 7 14:22:57 EDT 2020


     [ https://issues.redhat.com/browse/ISPN-12096?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Diego Lovison updated ISPN-12096:
---------------------------------
    Description: 
ConfigurationBuilder::withProperties should not overwrite the transactionMode

 
{noformat}
      if (transactionMode != null) {
         config.transaction().transactionMode(TransactionMode.valueOf(transactionMode));
      }      config.maxRetries(maxRetries).socketTimeout(connectionTimeout).connectionTimeout(connectionTimeout);      if (propertiesPath != null) {
         Properties p = new Properties();
         try (Reader r = new FileReader(propertiesPath)) {
            p.load(r);
            config.withProperties(p);
         } catch (IOException e) {
            throw new IllegalStateException("Something went wrong with provided properties file:" + propertiesPath, e);
         }
      }
      return config;
   }{noformat}
 
{noformat}
infinispan.client.hotrod.auth_username=admin
infinispan.client.hotrod.auth_password=password
infinispan.client.hotrod.auth_realm=default
infinispan.client.hotrod.sasl_mechanism=SCRAM-SHA-512{noformat}
 

 

  was:
ConfigurationBuilder::withProperties should not overwrite the transactionMode

 

 

{{      }}
{noformat}

{noformat}
{{      if (transactionMode != null) \{
         config.transaction().transactionMode(TransactionMode.valueOf(transactionMode));
      }

      config.maxRetries(maxRetries).socketTimeout(connectionTimeout).connectionTimeout(connectionTimeout);

      if (propertiesPath != null) \{
         Properties p = new Properties();
         try (Reader r = new FileReader(propertiesPath)) {
            p.load(r);
            config.withProperties(p);
         } catch (IOException e) \{
            throw new IllegalStateException("Something went wrong with provided properties file:" + propertiesPath, e);
         }
      }
      return config;
   }}}

 
{noformat}
infinispan.client.hotrod.auth_username=admin
infinispan.client.hotrod.auth_password=password
infinispan.client.hotrod.auth_realm=default
infinispan.client.hotrod.sasl_mechanism=SCRAM-SHA-512{noformat}
 

 



> ConfigurationBuilder::withProperties should not overwrite the transactionMode
> -----------------------------------------------------------------------------
>
>                 Key: ISPN-12096
>                 URL: https://issues.redhat.com/browse/ISPN-12096
>             Project: Infinispan
>          Issue Type: Bug
>          Components: Hot Rod
>    Affects Versions: 11.0.1.Final, 12.0.0.Dev01
>            Reporter: Diego Lovison
>            Priority: Major
>
> ConfigurationBuilder::withProperties should not overwrite the transactionMode
>  
> {noformat}
>       if (transactionMode != null) {
>          config.transaction().transactionMode(TransactionMode.valueOf(transactionMode));
>       }      config.maxRetries(maxRetries).socketTimeout(connectionTimeout).connectionTimeout(connectionTimeout);      if (propertiesPath != null) {
>          Properties p = new Properties();
>          try (Reader r = new FileReader(propertiesPath)) {
>             p.load(r);
>             config.withProperties(p);
>          } catch (IOException e) {
>             throw new IllegalStateException("Something went wrong with provided properties file:" + propertiesPath, e);
>          }
>       }
>       return config;
>    }{noformat}
>  
> {noformat}
> infinispan.client.hotrod.auth_username=admin
> infinispan.client.hotrod.auth_password=password
> infinispan.client.hotrod.auth_realm=default
> infinispan.client.hotrod.sasl_mechanism=SCRAM-SHA-512{noformat}
>  
>  



--
This message was sent by Atlassian Jira
(v7.13.8#713008)



More information about the infinispan-issues mailing list