[JBoss JIRA] (ISPN-4837) @CacheEntryActivated events received for keys not matching KeyFilter
by Paul Ferraro (JIRA)
[ https://issues.jboss.org/browse/ISPN-4837?page=com.atlassian.jira.plugin.... ]
Paul Ferraro updated ISPN-4837:
-------------------------------
Description:
I have a local-mode Cache<Object, ?>, for which I register a cache listener using the following KeyFilter:
{noformat}
class MyFIlter implements KeyFilter<Object> {
@Override
public boolean accept(Object key) {
return key instanceof String;
}
}
{noformat}
However, my listener method still receives events for keys that does not match the filter with which my listener was registered.
e.g.
{noformat}
@CacheEntryActivated
public void activated(CacheEntryActivatedEvent<String, ?> event) {
String id = event.getKey(); // Throws a ClassCastException
// ...
}
{noformat}
I have not validated which other event types might exhibit the same issue.
Since this is a behavior regression, I'm filing this as critical.
was:
I have a local-mode Cache<Object, ?>, for which I register a cache listener using the following KeyFilter:
{noformat}
class MyFIlter implements KeyFilter<Object> {
@Override
public boolean accept(Object key) {
return key instanceof String;
}
}
{noformat}
However, my listener method still receives events for keys that does not match the filter with which my listener was registered.
e.g.
{noformat}
@CacheEntryActivated
public void activated(CacheEntryActivatedEvent<String, ?> event) {
if (!event.isPre() && !this.persistent) {
String id = event.getKey(); // Throws a ClassCastException
// ...
}
}
{noformat}
I have not validated which other event types might exhibit the same issue.
Since this is a behavior regression, I'm filing this as critical.
> @CacheEntryActivated events received for keys not matching KeyFilter
> --------------------------------------------------------------------
>
> Key: ISPN-4837
> URL: https://issues.jboss.org/browse/ISPN-4837
> Project: Infinispan
> Issue Type: Bug
> Components: Listeners
> Affects Versions: 7.0.0.CR1
> Reporter: Paul Ferraro
> Assignee: William Burns
> Priority: Critical
>
> I have a local-mode Cache<Object, ?>, for which I register a cache listener using the following KeyFilter:
> {noformat}
> class MyFIlter implements KeyFilter<Object> {
> @Override
> public boolean accept(Object key) {
> return key instanceof String;
> }
> }
> {noformat}
> However, my listener method still receives events for keys that does not match the filter with which my listener was registered.
> e.g.
> {noformat}
> @CacheEntryActivated
> public void activated(CacheEntryActivatedEvent<String, ?> event) {
> String id = event.getKey(); // Throws a ClassCastException
> // ...
> }
> {noformat}
> I have not validated which other event types might exhibit the same issue.
> Since this is a behavior regression, I'm filing this as critical.
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
11 years, 5 months
[JBoss JIRA] (ISPN-4837) @CacheEntryActivated events received for keys not matching KeyFilter
by William Burns (JIRA)
[ https://issues.jboss.org/browse/ISPN-4837?page=com.atlassian.jira.plugin.... ]
William Burns reassigned ISPN-4837:
-----------------------------------
Assignee: William Burns (was: Dan Berindei)
> @CacheEntryActivated events received for keys not matching KeyFilter
> --------------------------------------------------------------------
>
> Key: ISPN-4837
> URL: https://issues.jboss.org/browse/ISPN-4837
> Project: Infinispan
> Issue Type: Bug
> Components: Listeners
> Affects Versions: 7.0.0.CR1
> Reporter: Paul Ferraro
> Assignee: William Burns
> Priority: Critical
>
> I have a local-mode Cache<Object, ?>, for which I register a cache listener using the following KeyFilter:
> {noformat}
> class MyFIlter implements KeyFilter<Object> {
> @Override
> public boolean accept(Object key) {
> return key instanceof String;
> }
> }
> {noformat}
> However, my listener method still receives events for keys that does not match the filter with which my listener was registered.
> e.g.
> {noformat}
> @CacheEntryActivated
> public void activated(CacheEntryActivatedEvent<String, ?> event) {
> if (!event.isPre() && !this.persistent) {
> String id = event.getKey(); // Throws a ClassCastException
> // ...
> }
> }
> {noformat}
> I have not validated which other event types might exhibit the same issue.
> Since this is a behavior regression, I'm filing this as critical.
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
11 years, 5 months
[JBoss JIRA] (ISPN-4837) @CacheEntryActivated events received for keys not matching KeyFilter
by William Burns (JIRA)
[ https://issues.jboss.org/browse/ISPN-4837?page=com.atlassian.jira.plugin.... ]
William Burns updated ISPN-4837:
--------------------------------
Status: Open (was: New)
> @CacheEntryActivated events received for keys not matching KeyFilter
> --------------------------------------------------------------------
>
> Key: ISPN-4837
> URL: https://issues.jboss.org/browse/ISPN-4837
> Project: Infinispan
> Issue Type: Bug
> Components: Listeners
> Affects Versions: 7.0.0.CR1
> Reporter: Paul Ferraro
> Assignee: William Burns
> Priority: Critical
>
> I have a local-mode Cache<Object, ?>, for which I register a cache listener using the following KeyFilter:
> {noformat}
> class MyFIlter implements KeyFilter<Object> {
> @Override
> public boolean accept(Object key) {
> return key instanceof String;
> }
> }
> {noformat}
> However, my listener method still receives events for keys that does not match the filter with which my listener was registered.
> e.g.
> {noformat}
> @CacheEntryActivated
> public void activated(CacheEntryActivatedEvent<String, ?> event) {
> if (!event.isPre() && !this.persistent) {
> String id = event.getKey(); // Throws a ClassCastException
> // ...
> }
> }
> {noformat}
> I have not validated which other event types might exhibit the same issue.
> Since this is a behavior regression, I'm filing this as critical.
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
11 years, 5 months
[JBoss JIRA] (ISPN-4837) @CacheEntryActivated events received for keys not matching KeyFilter
by William Burns (JIRA)
[ https://issues.jboss.org/browse/ISPN-4837?page=com.atlassian.jira.plugin.... ]
Work on ISPN-4837 started by William Burns.
-------------------------------------------
> @CacheEntryActivated events received for keys not matching KeyFilter
> --------------------------------------------------------------------
>
> Key: ISPN-4837
> URL: https://issues.jboss.org/browse/ISPN-4837
> Project: Infinispan
> Issue Type: Bug
> Components: Listeners
> Affects Versions: 7.0.0.CR1
> Reporter: Paul Ferraro
> Assignee: William Burns
> Priority: Critical
>
> I have a local-mode Cache<Object, ?>, for which I register a cache listener using the following KeyFilter:
> {noformat}
> class MyFIlter implements KeyFilter<Object> {
> @Override
> public boolean accept(Object key) {
> return key instanceof String;
> }
> }
> {noformat}
> However, my listener method still receives events for keys that does not match the filter with which my listener was registered.
> e.g.
> {noformat}
> @CacheEntryActivated
> public void activated(CacheEntryActivatedEvent<String, ?> event) {
> if (!event.isPre() && !this.persistent) {
> String id = event.getKey(); // Throws a ClassCastException
> // ...
> }
> }
> {noformat}
> I have not validated which other event types might exhibit the same issue.
> Since this is a behavior regression, I'm filing this as critical.
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
11 years, 5 months
[JBoss JIRA] (ISPN-4837) @CacheEntryActivated events received for keys not matching KeyFilter
by Paul Ferraro (JIRA)
Paul Ferraro created ISPN-4837:
----------------------------------
Summary: @CacheEntryActivated events received for keys not matching KeyFilter
Key: ISPN-4837
URL: https://issues.jboss.org/browse/ISPN-4837
Project: Infinispan
Issue Type: Bug
Components: Listeners
Affects Versions: 7.0.0.CR1
Reporter: Paul Ferraro
Assignee: Dan Berindei
Priority: Critical
I have a local-mode Cache<Object, ?>, for which I register a cache listener using the following KeyFilter:
{noformat}
class MyFIlter implements KeyFilter<Object> {
@Override
public boolean accept(Object key) {
return key instanceof String;
}
}
{noformat}
However, my listener method still receives events for keys that does not match the filter with which my listener was registered.
e.g.
{noformat}
@CacheEntryActivated
public void activated(CacheEntryActivatedEvent<String, ?> event) {
if (!event.isPre() && !this.persistent) {
String id = event.getKey(); // Throws a ClassCastException
// ...
}
}
{noformat}
I have not validated which other event types might exhibit the same issue.
Since this is a behavior regression, I'm filing this as critical.
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
11 years, 5 months
[JBoss JIRA] (ISPN-4836) Change entrySet, keySet and values to be backing maps
by William Burns (JIRA)
William Burns created ISPN-4836:
-----------------------------------
Summary: Change entrySet, keySet and values to be backing maps
Key: ISPN-4836
URL: https://issues.jboss.org/browse/ISPN-4836
Project: Infinispan
Issue Type: Enhancement
Components: Core
Affects Versions: 7.0.0.CR1
Reporter: William Burns
Assignee: William Burns
Currently the entrySet, keySet and values methods are copies of data at the time of invocation. They do not allow for seeing updated values or actually updating the cache through them. It would be nice to support these operations as well.
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
11 years, 5 months