Bug 1412752

Summary: MissingFormatArgumentException thrown by PreferConsistencyStrategy if debug mode is enabled on state-transfer or merge
Product: [JBoss] JBoss Data Grid 6 Reporter: wfink
Component: InfinispanAssignee: Tristan Tarrant <ttarrant>
Status: VERIFIED --- QA Contact: Martin Gencur <mgencur>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 6.6.0CC: jdg-bugs, jsenko, onagano, vjuranek
Target Milestone: DR1   
Target Release: 6.6.2   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1374440    

Description wfink 2017-01-12 17:10:04 UTC
Description of problem:

ERROR o.i.topology.ClusterCacheStatus - ISPN000228: Failed to recover cache AADHAAR_CACHE state after the current node became the coordinator
java.util.MissingFormatArgumentException: Format specifier '%s'
        at java.util.Formatter.format(Formatter.java:2519)
        at java.util.Formatter.format(Formatter.java:2455)
        at java.lang.String.format(String.java:2940)
        at org.jboss.logging.Slf4jLocationAwareLogger.doLogf(Slf4jLocationAwareLogger.java:81)
        at org.jboss.logging.Logger.logf(Logger.java:2143)
        at org.jboss.logging.DelegatingBasicLogger.debugf(DelegatingBasicLogger.java:224)
        at org.infinispan.partionhandling.impl.PreferConsistencyStrategy.onPartitionMerge(PreferConsistencyStrategy.java:197)
        at org.infinispan.topology.ClusterCacheStatus.doMergePartitions(ClusterCacheStatus.java:497)
        at org.infinispan.topology.ClusterTopologyManagerImpl$2.call(ClusterTopologyManagerImpl.java:383)
        at org.infinispan.topology.ClusterTopologyManagerImpl$2.call(ClusterTopologyManagerImpl.java:380)
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)
        at org.infinispan.executors.SemaphoreCompletionService$QueueingTask.runInternal(SemaphoreCompletionService.java:173)
        at org.infinispan.executors.SemaphoreCompletionService$QueueingTask.run(SemaphoreCompletionService.java:151)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
        at java.lang.Thread.run(Thread.java:745)
        at org.jboss.threads.JBossThread.run(JBossThread.java:122)

Comment 2 Osamu Nagano 2017-01-13 03:35:31 UTC
Another non-typesafe printf error in StateConsumerImpl.

11-00-2017 00:00:16.556  [remote-thread-31] ERROR o.i.r.InboundInvocationHandlerImpl - ISPN000260: Exception executing command
java.util.IllegalFormatConversionException: d != java.lang.Boolean
 at java.util.Formatter$FormatSpecifier.failConversion(Formatter.java:4302)
 at java.util.Formatter$FormatSpecifier.printInteger(Formatter.java:2793)
 at java.util.Formatter$FormatSpecifier.print(Formatter.java:2747)
 at java.util.Formatter.format(Formatter.java:2520)
 at java.util.Formatter.format(Formatter.java:2455)
 at java.lang.String.format(String.java:2940)
 at org.jboss.logging.Slf4jLocationAwareLogger.doLogf(Slf4jLocationAwareLogger.java:81)
 at org.jboss.logging.Logger.logf(Logger.java:2129)
 at org.jboss.logging.DelegatingBasicLogger.debugf(DelegatingBasicLogger.java:239)
 at org.infinispan.statetransfer.StateConsumerImpl.applyState(StateConsumerImpl.java:497)
 at org.infinispan.statetransfer.StateResponseCommand.perform(StateResponseCommand.java:62)
 at org.infinispan.remoting.InboundInvocationHandlerImpl.handleInternal(InboundInvocationHandlerImpl.java:92)
 at org.infinispan.remoting.InboundInvocationHandlerImpl.access$000(InboundInvocationHandlerImpl.java:47)
 at org.infinispan.remoting.InboundInvocationHandlerImpl$2.run(InboundInvocationHandlerImpl.java:185)
 at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
 at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
 at java.lang.Thread.run(Thread.java:745)

This, and many others, has been fixed by the following commit in the upstream.
https://github.com/infinispan/infinispan/commit/2ddd584b58f30d261d513dc6944acbdbbf960183

Comment 3 Tristan Tarrant 2017-04-21 10:59:56 UTC
https://github.com/infinispan/jdg/pull/1181

Comment 4 Vojtech Juranek 2017-05-02 08:22:11 UTC
Second exception (org.infinispan.statetransfer.StateConsumerImpl L497) is still not fixed, formater is %d while provided value is boolean.