[JBoss JIRA] (ISPN-6755) Functional API's metadata support is unusable when using CacheLoaders
by Krzysztof Sobolewski (JIRA)
[ https://issues.jboss.org/browse/ISPN-6755?page=com.atlassian.jira.plugin.... ]
Krzysztof Sobolewski updated ISPN-6755:
---------------------------------------
Git Pull Request: https://github.com/infinispan/infinispan/pull/4396
> Functional API's metadata support is unusable when using CacheLoaders
> ---------------------------------------------------------------------
>
> Key: ISPN-6755
> URL: https://issues.jboss.org/browse/ISPN-6755
> Project: Infinispan
> Issue Type: Bug
> Components: Loaders and Stores
> Affects Versions: 9.0.0.Alpha2
> Reporter: Krzysztof Sobolewski
>
> These are the meta parameters used by the Functional API. They are created and updated when we call EntryView.WriteEntryView.set(value, params...), but this is not the only source of these parameters. The other is the cache loaders: the return value of CacheLoader.load() is a MarshalledEntry that contains three values: the key, the value and the metadata. This is a place where the implementations will want to inject information like the lifetime (for expiration). The only way to do that currently is to create a custom implementation of the Metadata interface, but that won't work, partialy because the Functional API is unfinished in these darker, dustier corners. So when we call MetaParam.Lookup.findMetaParam(Class<T>), the only supported Metadata implementation is the MetaParamsInternalMetadata (which external classes can't create because all the constructors of MetaParams are package-private), and there is a TODO to add interoperability support.
> The PR I'm about to send fixes this by just allowing external classes to instantiate MetaParams so that they can create MetaParamsInternalMetadata which in turn can be returned from CacheLoader.load(). But this is just a RFC, as usual.
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
8 years, 6 months
[JBoss JIRA] (ISPN-6755) Functional API's metadata support is unusable when using CacheLoaders
by Krzysztof Sobolewski (JIRA)
Krzysztof Sobolewski created ISPN-6755:
------------------------------------------
Summary: Functional API's metadata support is unusable when using CacheLoaders
Key: ISPN-6755
URL: https://issues.jboss.org/browse/ISPN-6755
Project: Infinispan
Issue Type: Bug
Components: Loaders and Stores
Affects Versions: 9.0.0.Alpha2
Reporter: Krzysztof Sobolewski
These are the meta parameters used by the Functional API. They are created and updated when we call EntryView.WriteEntryView.set(value, params...), but this is not the only source of these parameters. The other is the cache loaders: the return value of CacheLoader.load() is a MarshalledEntry that contains three values: the key, the value and the metadata. This is a place where the implementations will want to inject information like the lifetime (for expiration). The only way to do that currently is to create a custom implementation of the Metadata interface, but that won't work, partialy because the Functional API is unfinished in these darker, dustier corners. So when we call MetaParam.Lookup.findMetaParam(Class<T>), the only supported Metadata implementation is the MetaParamsInternalMetadata (which external classes can't create because all the constructors of MetaParams are package-private), and there is a TODO to add interoperability support.
The PR I'm about to send fixes this by just allowing external classes to instantiate MetaParams so that they can create MetaParamsInternalMetadata which in turn can be returned from CacheLoader.load(). But this is just a RFC, as usual.
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
8 years, 6 months
[JBoss JIRA] (ISPN-6422) ServerEventLoggerTest.testClusteredServerEventLogging fails randomly
by Dan Berindei (JIRA)
[ https://issues.jboss.org/browse/ISPN-6422?page=com.atlassian.jira.plugin.... ]
Dan Berindei updated ISPN-6422:
-------------------------------
Labels: testsuite_stability (was: )
> ServerEventLoggerTest.testClusteredServerEventLogging fails randomly
> --------------------------------------------------------------------
>
> Key: ISPN-6422
> URL: https://issues.jboss.org/browse/ISPN-6422
> Project: Infinispan
> Issue Type: Bug
> Components: Server
> Reporter: Adrian Nistor
> Assignee: Tristan Tarrant
> Labels: testsuite_stability
> Fix For: 9.0.0.Alpha3
>
>
> http://ci.infinispan.org/viewLog.html?buildId=37676&tab=buildResultsDiv&b...
> {code}
> java.lang.NullPointerException: null
> at java.util.ComparableTimSort.binarySort(ComparableTimSort.java:258)
> at java.util.ComparableTimSort.sort(ComparableTimSort.java:185)
> at java.util.Arrays.sort(Arrays.java:1312)
> at java.util.Arrays.sort(Arrays.java:1506)
> at java.util.ArrayList.sort(ArrayList.java:1454)
> at java.util.Collections.sort(Collections.java:141)
> at org.infinispan.server.eventlogger.ServerEventLogger.getEvents(ServerEventLogger.java:131)
> at org.infinispan.server.eventlogger.ServerEventLoggerTest$2.call(ServerEventLoggerTest.java:86)
> at org.infinispan.test.TestingUtil.withCacheManagers(TestingUtil.java:1348)
> at org.infinispan.server.eventlogger.ServerEventLoggerTest.testClusteredServerEventLogging(ServerEventLoggerTest.java:66)
> ------- Stdout: -------
> Configuring TestNG with: TestNG652Configurator
> Transport protocol stack used = tcp
> ------- Stderr: -------
> Mar 20, 2016 2:14:51 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport start
> INFO: ISPN000078: Starting JGroups channel ISPN
> Mar 20, 2016 2:14:51 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport viewAccepted
> INFO: ISPN000094: Received new cluster view for channel ISPN: [ServerEventLoggerTest-NodeA-31008|0] (1) [ServerEventLoggerTest-NodeA-31008]
> Mar 20, 2016 2:14:51 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport startJGroupsChannelIfNeeded
> INFO: ISPN000079: Channel ISPN local address is ServerEventLoggerTest-NodeA-31008, physical addresses are [127.0.0.1:7900]
> Mar 20, 2016 2:14:51 AM org.infinispan.factories.GlobalComponentRegistry start
> INFO: ISPN000128: Infinispan version: Infinispan 'Chakra' 9.0.0-SNAPSHOT
> Mar 20, 2016 2:14:52 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport start
> INFO: ISPN000078: Starting JGroups channel ISPN
> Mar 20, 2016 2:14:52 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport viewAccepted
> INFO: ISPN000094: Received new cluster view for channel ISPN: [ServerEventLoggerTest-NodeA-31008|1] (2) [ServerEventLoggerTest-NodeA-31008, ServerEventLoggerTest-NodeB-14491]
> Mar 20, 2016 2:14:52 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport viewAccepted
> INFO: ISPN000094: Received new cluster view for channel ISPN: [ServerEventLoggerTest-NodeA-31008|1] (2) [ServerEventLoggerTest-NodeA-31008, ServerEventLoggerTest-NodeB-14491]
> Mar 20, 2016 2:14:52 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport startJGroupsChannelIfNeeded
> INFO: ISPN000079: Channel ISPN local address is ServerEventLoggerTest-NodeB-14491, physical addresses are [127.0.0.1:7901]
> Mar 20, 2016 2:14:52 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport start
> INFO: ISPN000078: Starting JGroups channel ISPN
> Mar 20, 2016 2:14:52 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport viewAccepted
> INFO: ISPN000094: Received new cluster view for channel ISPN: [ServerEventLoggerTest-NodeA-31008|2] (3) [ServerEventLoggerTest-NodeA-31008, ServerEventLoggerTest-NodeB-14491, ServerEventLoggerTest-NodeC-47842]
> Mar 20, 2016 2:14:52 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport viewAccepted
> INFO: ISPN000094: Received new cluster view for channel ISPN: [ServerEventLoggerTest-NodeA-31008|2] (3) [ServerEventLoggerTest-NodeA-31008, ServerEventLoggerTest-NodeB-14491, ServerEventLoggerTest-NodeC-47842]
> Mar 20, 2016 2:14:52 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport viewAccepted
> INFO: ISPN000094: Received new cluster view for channel ISPN: [ServerEventLoggerTest-NodeA-31008|2] (3) [ServerEventLoggerTest-NodeA-31008, ServerEventLoggerTest-NodeB-14491, ServerEventLoggerTest-NodeC-47842]
> Mar 20, 2016 2:14:52 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport startJGroupsChannelIfNeeded
> INFO: ISPN000079: Channel ISPN local address is ServerEventLoggerTest-NodeC-47842, physical addresses are [127.0.0.1:7902]
> Mar 20, 2016 2:14:52 AM org.infinispan.server.eventlogger.ServerEventLogger textLog
> INFO: message #1
> Mar 20, 2016 2:14:52 AM org.infinispan.server.eventlogger.ServerEventLogger textLog
> WARN: message #2
> Mar 20, 2016 2:14:52 AM org.infinispan.server.eventlogger.ServerEventLogger textLog
> INFO: message #3
> Mar 20, 2016 2:14:52 AM org.infinispan.server.eventlogger.ServerEventLogger textLog
> WARN: message #4
> Mar 20, 2016 2:14:52 AM org.infinispan.server.eventlogger.ServerEventLogger textLog
> INFO: message #5
> Mar 20, 2016 2:14:52 AM org.infinispan.server.eventlogger.ServerEventLogger textLog
> WARN: message #6
> Mar 20, 2016 2:14:52 AM org.infinispan.server.eventlogger.ServerEventLogger textLog
> INFO: message #7
> Mar 20, 2016 2:14:52 AM org.infinispan.server.eventlogger.ServerEventLogger textLog
> WARN: message #8
> Mar 20, 2016 2:14:52 AM org.infinispan.server.eventlogger.ServerEventLogger textLog
> INFO: message #9
> Mar 20, 2016 2:14:52 AM org.infinispan.server.eventlogger.ServerEventLogger textLog
> WARN: message #10
> Mar 20, 2016 2:14:52 AM org.infinispan.server.eventlogger.ServerEventLogger textLog
> INFO: message #11
> Mar 20, 2016 2:14:52 AM org.infinispan.server.eventlogger.ServerEventLogger textLog
> WARN: message #12
> Mar 20, 2016 2:14:53 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport stop
> INFO: ISPN000080: Disconnecting JGroups channel ISPN
> Mar 20, 2016 2:14:53 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport viewAccepted
> INFO: ISPN000094: Received new cluster view for channel ISPN: [ServerEventLoggerTest-NodeA-31008|3] (2) [ServerEventLoggerTest-NodeA-31008, ServerEventLoggerTest-NodeB-14491]
> Mar 20, 2016 2:14:53 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport viewAccepted
> INFO: ISPN000094: Received new cluster view for channel ISPN: [ServerEventLoggerTest-NodeA-31008|3] (2) [ServerEventLoggerTest-NodeA-31008, ServerEventLoggerTest-NodeB-14491]
> Mar 20, 2016 2:14:53 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport stop
> INFO: ISPN000082: Stopping the RpcDispatcher for channel ISPN
> Mar 20, 2016 2:14:53 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport stop
> INFO: ISPN000080: Disconnecting JGroups channel ISPN
> Mar 20, 2016 2:14:53 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport viewAccepted
> INFO: ISPN000094: Received new cluster view for channel ISPN: [ServerEventLoggerTest-NodeA-31008|4] (1) [ServerEventLoggerTest-NodeA-31008]
> Mar 20, 2016 2:14:53 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport stop
> INFO: ISPN000082: Stopping the RpcDispatcher for channel ISPN
> Mar 20, 2016 2:14:53 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport stop
> INFO: ISPN000080: Disconnecting JGroups channel ISPN
> Mar 20, 2016 2:14:53 AM org.infinispan.remoting.transport.jgroups.JGroupsTransport stop
> INFO: ISPN000082: Stopping the RpcDispatcher for channel ISPN
> {code}
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
8 years, 6 months
[JBoss JIRA] (ISPN-6686) Improve fluency of persistent store configuration builders
by Krzysztof Sobolewski (JIRA)
[ https://issues.jboss.org/browse/ISPN-6686?page=com.atlassian.jira.plugin.... ]
Krzysztof Sobolewski updated ISPN-6686:
---------------------------------------
Summary: Improve fluency of persistent store configuration builders (was: Improve fluidity of persistent store configuration builders)
> Improve fluency of persistent store configuration builders
> ----------------------------------------------------------
>
> Key: ISPN-6686
> URL: https://issues.jboss.org/browse/ISPN-6686
> Project: Infinispan
> Issue Type: Enhancement
> Components: Configuration, Loaders and Stores
> Affects Versions: 8.2.2.Final
> Reporter: Krzysztof Sobolewski
>
> Configuration of cache stores has some fluidity issues. I'd like to do:
> {code:java}
> ConfigurationBuilder builder = ...;
> builder
> .persistence()
> .addStore(JdbcStringBasedStoreConfigurationBuilder.class)
> .dialect(...)
> .table() // <- compilation error
> ...
> .connectionPool() // <- compilation error
> ...;
> {code}
> but I'm forced to do:
> {code:java}
> ConfigurationBuilder builder = ...;
> JdbcStringBasedStoreConfigurationBuilder store = builder
> .persistence()
> .addStore(JdbcStringBasedStoreConfigurationBuilder.class)
> .dialect(...);
> store
> .table()
> ...;
> store
> .connectionPool()
> ...;
> {code}
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
8 years, 6 months
[JBoss JIRA] (ISPN-6686) Improve fluency of persistent store configuration builders
by Krzysztof Sobolewski (JIRA)
[ https://issues.jboss.org/browse/ISPN-6686?page=com.atlassian.jira.plugin.... ]
Krzysztof Sobolewski updated ISPN-6686:
---------------------------------------
Description:
Configuration of cache stores has some fluency issues. I'd like to do:
{code:java}
ConfigurationBuilder builder = ...;
builder
.persistence()
.addStore(JdbcStringBasedStoreConfigurationBuilder.class)
.dialect(...)
.table() // <- compilation error
...
.connectionPool() // <- compilation error
...;
{code}
but I'm forced to do:
{code:java}
ConfigurationBuilder builder = ...;
JdbcStringBasedStoreConfigurationBuilder store = builder
.persistence()
.addStore(JdbcStringBasedStoreConfigurationBuilder.class)
.dialect(...);
store
.table()
...;
store
.connectionPool()
...;
{code}
was:
Configuration of cache stores has some fluidity issues. I'd like to do:
{code:java}
ConfigurationBuilder builder = ...;
builder
.persistence()
.addStore(JdbcStringBasedStoreConfigurationBuilder.class)
.dialect(...)
.table() // <- compilation error
...
.connectionPool() // <- compilation error
...;
{code}
but I'm forced to do:
{code:java}
ConfigurationBuilder builder = ...;
JdbcStringBasedStoreConfigurationBuilder store = builder
.persistence()
.addStore(JdbcStringBasedStoreConfigurationBuilder.class)
.dialect(...);
store
.table()
...;
store
.connectionPool()
...;
{code}
> Improve fluency of persistent store configuration builders
> ----------------------------------------------------------
>
> Key: ISPN-6686
> URL: https://issues.jboss.org/browse/ISPN-6686
> Project: Infinispan
> Issue Type: Enhancement
> Components: Configuration, Loaders and Stores
> Affects Versions: 8.2.2.Final
> Reporter: Krzysztof Sobolewski
>
> Configuration of cache stores has some fluency issues. I'd like to do:
> {code:java}
> ConfigurationBuilder builder = ...;
> builder
> .persistence()
> .addStore(JdbcStringBasedStoreConfigurationBuilder.class)
> .dialect(...)
> .table() // <- compilation error
> ...
> .connectionPool() // <- compilation error
> ...;
> {code}
> but I'm forced to do:
> {code:java}
> ConfigurationBuilder builder = ...;
> JdbcStringBasedStoreConfigurationBuilder store = builder
> .persistence()
> .addStore(JdbcStringBasedStoreConfigurationBuilder.class)
> .dialect(...);
> store
> .table()
> ...;
> store
> .connectionPool()
> ...;
> {code}
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
8 years, 6 months