You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@sentry.apache.org by "Haley Reeve (JIRA)" <ji...@apache.org> on 2018/12/17 20:37:00 UTC

[jira] [Commented] (SENTRY-1797) SentryKerberosContext should use periodic executor instead of managing periodic execution via run() method.

    [ https://issues.apache.org/jira/browse/SENTRY-1797?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16723348#comment-16723348 ] 

Haley Reeve commented on SENTRY-1797:
-------------------------------------

I've replaced the while loops with a ScheduledExecutorService and ScheduledFuture. The future runs every 30 seconds and checks if it needs to renew the context. When the shutdown() method is called it just cancels that future. Patch and review incoming.

> SentryKerberosContext should use periodic executor instead of managing periodic execution via run() method.
> -----------------------------------------------------------------------------------------------------------
>
>                 Key: SENTRY-1797
>                 URL: https://issues.apache.org/jira/browse/SENTRY-1797
>             Project: Sentry
>          Issue Type: Bug
>          Components: Sentry
>    Affects Versions: 1.8.0, 2.0.0
>            Reporter: Alexander Kolbasov
>            Assignee: Brian Towles
>            Priority: Major
>              Labels: bite-sized, newbie
>
> The SentryKerberosContext class tries to simulate periodic executor using while loop with a sleep in the run() method. Instead it should use periodic executor.



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