[
https://issues.apache.org/jira/browse/PHOENIX-1466?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14220535#comment-14220535
]
Samarth Jain commented on PHOENIX-1466:
---------------------------------------
I don't think you really need the synchronized(this) in getDelegate(). Because
we don't expect a PhoenixConnection to be shared between multiple threads at
the same time, I don't see next() and close() being called concurrently. Having
delegate just as volatile should be sufficient as it will make sure the effect
of a thread calling next() will be seen by another thread calling close() or
vice versa.
> Prevent multiple scans when query run serially
> ----------------------------------------------
>
> Key: PHOENIX-1466
> URL: https://issues.apache.org/jira/browse/PHOENIX-1466
> Project: Phoenix
> Issue Type: Bug
> Reporter: James Taylor
> Attachments: PHOENIX-1466.patch, PHOENIX-1466_v2.patch,
> PHOENIX-1466_v3.patch
>
>
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)