sentry-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Xinran Tinney (JIRA)" <j...@apache.org>
Subject [jira] [Assigned] (SENTRY-2124) LeaderStatusMonitor.toString() throws IllegalFormatConversionException with AtomicLong
Date Thu, 18 Jan 2018 20:56:00 GMT

     [ https://issues.apache.org/jira/browse/SENTRY-2124?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Xinran Tinney reassigned SENTRY-2124:
-------------------------------------

    Assignee: Xinran Tinney

> LeaderStatusMonitor.toString() throws IllegalFormatConversionException with AtomicLong
> --------------------------------------------------------------------------------------
>
>                 Key: SENTRY-2124
>                 URL: https://issues.apache.org/jira/browse/SENTRY-2124
>             Project: Sentry
>          Issue Type: Bug
>          Components: Sentry
>    Affects Versions: 2.1.0
>            Reporter: Sergio Peña
>            Assignee: Xinran Tinney
>            Priority: Minor
>
> When I start Sentry, I noticed an exception on the console due to an illegal format string
in LeaderStatusMonitor.toString()
> {noformat}
> java.util.IllegalFormatConversionException: d != java.util.concurrent.atomic.AtomicLong

> 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.apache.sentry.provider.db.service.persistent.LeaderStatusMonitor.toString(LeaderStatusMonitor.java:282)

> at org.slf4j.helpers.MessageFormatter.safeObjectAppend(MessageFormatter.java:297) 
> at org.slf4j.helpers.MessageFormatter.deeplyAppendParameter(MessageFormatter.java:269)

> at org.slf4j.helpers.MessageFormatter.arrayFormat(MessageFormatter.java:227) 
> at org.slf4j.helpers.MessageFormatter.format(MessageFormatter.java:124) 
> at org.slf4j.impl.Log4jLoggerAdapter.info(Log4jLoggerAdapter.java:322) 
> at org.apache.sentry.provider.db.service.persistent.LeaderStatusMonitor.takeLeadership(LeaderStatusMonitor.java:251)

> at sentry.org.apache.curator.framework.recipes.leader.LeaderSelector$WrappedListener.takeLeadership(LeaderSelector.java:537)

> at sentry.org.apache.curator.framework.recipes.leader.LeaderSelector.doWork(LeaderSelector.java:399)

> at sentry.org.apache.curator.framework.recipes.leader.LeaderSelector.doWorkLoop(LeaderSelector.java:444)

> at sentry.org.apache.curator.framework.recipes.leader.LeaderSelector.access$100(LeaderSelector.java:64)

> at sentry.org.apache.curator.framework.recipes.leader.LeaderSelector$2.call(LeaderSelector.java:245)

> at sentry.org.apache.curator.framework.recipes.leader.LeaderSelector$2.call(LeaderSelector.java:239)

> at java.util.concurrent.FutureTask.run(FutureTask.java:266) 
> at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) 
> at java.util.concurrent.FutureTask.run(FutureTask.java:266) 
> at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) 
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
> at java.lang.Thread.run(Thread.java:748){noformat}
> Seems that the {{leaderCount=%d}} used in the String.format() is causing the issue.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message