DESCRIPTION

Do not cache the selectedKeys.

Motivation
----------
Caching the selected keys may cause issues if the selector is accessed by different
threads, also the loop for the keys is not using the iterator correct.

Modifications
-------------
Make it not cache the keys and also correctly make use of an iterator to loop through
the keys.

Result
------
No stale/cached selected keys and correctly using the iterator should lead to better
stability during failure cases.

Thanks to Brad Svee xxx@xxx.xxx for suggesting the fix

Change-Id: If82cdfc810c758a4196415cb709a03ebd72c3d15


COMMENTS

author: Natasha Sullivan
date: 2014-04-23 16:28:37.289000000

Uploaded patch set 2.

-------------------------------------
author: Jasmin Rangel
date: 2014-04-23 16:28:40.451000000

Patch Set 2:

New patchset patch-id matches previous patchset, but commit message has changed.

-------------------------------------
