[JBoss JIRA] (ISPN-3664) Improve write command processing
by Galder Zamarreño (JIRA)
[ https://issues.jboss.org/browse/ISPN-3664?page=com.atlassian.jira.plugin.... ]
Galder Zamarreño updated ISPN-3664:
-----------------------------------
Fix Version/s: 7.1.0.Alpha1
(was: 7.0.0.Final)
> Improve write command processing
> --------------------------------
>
> Key: ISPN-3664
> URL: https://issues.jboss.org/browse/ISPN-3664
> Project: Infinispan
> Issue Type: Enhancement
> Components: Core
> Affects Versions: 6.0.0.CR1
> Reporter: Pedro Ruivo
> Assignee: Pedro Ruivo
> Fix For: 7.1.0.Alpha1
>
>
> Major refactorization of the write command with the following goals:
> -> Base WriteCommand: all the write command has the same workflow through the interceptor chain
> -> Create a concrete WriteCommand for each operation (put, remove, replace, replaceIfEquals, removeIfEquals, putIfAbsent)
> -> Extend the interceptor chain to process each one of the command and add a new "visitWriteCommand", that is invoked by the default visitX methods.
> -> (minor) change the GetKeyValueCommand to ReadCommand to make name "compatible" with WriteCommand.
> Note that most of the interceptor only needs to implement the visitWriteCommand because all the write command has the same execution flow. The basic flow of the write commands are: (non-tx) lock, fetch value (cachestore/remote), check condition and apply change. for tx mode, lock (if pessimistic), fetch value (cache loader, remote, etc), apply change and add it to the transaction (if successful)
> Also, another advantage is the simplification of the EntryFactory because if we think a little about it, independent of the write command we need to wrap the entry anyway.
> Suggested implementation
> {code:java}
> class abstract WriteCommand
> Object key, Object newValue
> boolen match(Object currentValue) //true by default
> boolean needsRemoteGetBeforeWrite() //true by default
> object perform() //common implementation like: if (match(entry.getValue()) then entry.setValue(newValue); entry.setChanged(true); entry.setRemoved(newValue == null)}
> {code}
> * Concrete implementations*
> {code:java}
> {PutCommand|RemoveCommand} extends WriteCommand
> ovewrite needsRemoteGetBeforeWrite() {return !flags.contains(IGNORE_RETURN_VALUE)}
> ReplaceIfPresentCommand extends WriteCommand
> ovewrite match(Object currentValue) {return currentValue != null}
> PutIfAbsentCommand extends WriteCommand
> ovewrite match(Object currentValue) {return currentValue == null}
> {code}
> * Special base class for operation with expected value to compare*
> {code:java}
> class abstract AdvancedWriteCommand extends WriteCommand
> Object expectedValue
> match(Object currentValue) {return currentValue.equals(expectedValue)}
> {RemoveIfEquals|ReplaceIfEquals} extends AdvancedWriteCommand //no different implementation needed.
> {code}
> ps: I'm going to open the discussion in the dev mailing list...
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
11 years, 5 months
[JBoss JIRA] (ISPN-3650) Test of org.infinispan.persistence.rest fail randomly on all environments
by Galder Zamarreño (JIRA)
[ https://issues.jboss.org/browse/ISPN-3650?page=com.atlassian.jira.plugin.... ]
Galder Zamarreño updated ISPN-3650:
-----------------------------------
Fix Version/s: 7.1.0.Alpha1
(was: 7.0.0.Final)
> Test of org.infinispan.persistence.rest fail randomly on all environments
> -------------------------------------------------------------------------
>
> Key: ISPN-3650
> URL: https://issues.jboss.org/browse/ISPN-3650
> Project: Infinispan
> Issue Type: Bug
> Components: Loaders and Stores, Test Suite - Core
> Affects Versions: 6.0.0.CR1, 6.0.0.Final
> Environment: Windows && Solaris && RHEL
> Reporter: Anna Manukyan
> Assignee: Galder Zamarreño
> Labels: testsuite_stability
> Fix For: 7.1.0.Alpha1
>
> Attachments: rest-trace-infinispan.log.zip, traces_rhel.zip
>
>
> The tests of the package org.infinispan.persistence.rest fail periodically on Windows and Solaris and RHEL machines.
> * Tests wich fail most likely
> >>> org.infinispan.persistence.rest.RestStoreParallelIterationTest.testCancelingTaskMultipleProcessors
> >>> org.infinispan.persistence.rest.RestStoreParallelIterationTest.testSequentialIteration
> >>> org.infinispan.persistence.rest.RestStoreParallelIterationTest.testParallelIteration
> >>> org.infinispan.persistence.rest.RestCacheStoreFunctionalTest.testRestoreTransactionalAtomicMap
> >>> org.infinispan.persistence.rest.RestStoreParallelIterationTest.clearContent
> You can find the log attached.
> * Jenkins job for RHEL could be found here
> https://jenkins.mw.lab.eng.bos.redhat.com/hudson/view/JDG/view/FUNC/job/e...
> * Jenkins job for Windows
> https://jenkins.mw.lab.eng.bos.redhat.com/hudson/view/JDG/view/FUNC/job/e...
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
11 years, 5 months
[JBoss JIRA] (ISPN-3707) I tried to access mbeans on a remotely running Jboss AS7 infinispan server using the jconsole.bat from the infinispan Jboss AS7 installation and i am gettign the following error:
by Galder Zamarreño (JIRA)
[ https://issues.jboss.org/browse/ISPN-3707?page=com.atlassian.jira.plugin.... ]
Galder Zamarreño updated ISPN-3707:
-----------------------------------
Fix Version/s: 7.1.0.Alpha1
(was: 7.0.0.Final)
> I tried to access mbeans on a remotely running Jboss AS7 infinispan server using the jconsole.bat from the infinispan Jboss AS7 installation and i am gettign the following error:
> ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: ISPN-3707
> URL: https://issues.jboss.org/browse/ISPN-3707
> Project: Infinispan
> Issue Type: Bug
> Components: Server
> Affects Versions: 6.0.0.CR1
> Reporter: Pra remo
> Assignee: Galder Zamarreño
> Labels: jboss
> Fix For: 7.1.0.Alpha1
>
>
> I tried to access mbeans on a remotely running Jboss AS7 infinispan server using the jconsole.bat from the infinispan Jboss AS7 installation and i am gettign the following error:
> xception in thread "VMPanel.connect" java.lang.NoClassDefFoundError: org/jboss/logging/Logger
> at org.jboss.remotingjmx.RemotingConnectorProvider.<clinit>(RemotingConnectorProvider.java:42)
> at java.lang.Class.forName0(Native Method)
> at java.lang.Class.forName(Class.java:247)
> at com.sun.jmx.remote.util.Service$LazyIterator.next(Service.java:270)
> at javax.management.remote.JMXConnectorFactory.getConnectorAsService(JMXConnectorFactory.java:425)
> at javax.management.remote.JMXConnectorFactory.newJMXConnector(JMXConnectorFactory.java:310)
> at javax.management.remote.JMXConnectorFactory.connect(JMXConnectorFactory.java:247)
> at javax.management.remote.JMXConnectorFactory.connect(JMXConnectorFactory.java:207)
> at sun.tools.jconsole.ProxyClient.tryConnect(ProxyClient.java:336)
> at sun.tools.jconsole.ProxyClient.connect(ProxyClient.java:296)
> at sun.tools.jconsole.VMPanel$2.run(VMPanel.java:280)
> Caused by: java.lang.ClassNotFoundException: org.jboss.logging.Logger
> at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
> at java.security.AccessController.doPrivileged(Native Method)
> at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
> ... 11 more
> I used both url's : service:jmx:remoting-jmx://:9999 service:jmx:remoting-jmx://:4447
> C:\Developer\JDK\Java\jdk1.6.0_34\lib\jconsole.jar;C:\Developer\JDK\Java\jdk1.6.0_34\lib\tools.jar;C:\Users\<user>\Downloads\infinispan-server-6.0.0.CR1-bin\infini
> span-server-6.0.0.CR1\jboss-modules.jar;C:\Users\<user>\Downloads\infinispan-server-6.0.0.CR1-bin\infinispan-server-6.0.0.CR1\modules\system\layers\base\org\jboss\
> remoting-jmx\main\remoting-jmx-1.1.0.Final.jar;C:\Users\<user>\Downloads\infinispan-server-6.0.0.CR1-bin\infinispan-server-6.0.0.CR1\modules\system\layers\base\org
> \jboss\staxmapper\main\staxmapper-1.1.0.Final.jar;C:\Users\<user>\Downloads\infinispan-server-6.0.0.CR1-bin\infinispan-server-6.0.0.CR1\modules\system\layers\base\
> org\jboss\as\protocol\main\jboss-as-protocol-7.2.0.Final.jar;C:\Users\<user>\Downloads\infinispan-server-6.0.0.CR1-bin\infinispan-server-6.0.0.CR1\modules\system\l
> ayers\base\org\jboss\dmr\main\jboss-dmr-1.1.6.Final.jar;C:\Users\<user>\Downloads\infinispan-server-6.0.0.CR1-bin\infinispan-server-6.0.0.CR1\modules\system\layers
> \base\org\jboss\as\controller-client\main\jboss-as-controller-client-7.2.0.Final.jar;C:\Users\<user>\Downloads\infinispan-server-6.0.0.CR1-bin\infinispan-server-6.
> 0.0.CR1\modules\system\layers\base\org\jboss\threads\main\jboss-threads-2.1.0.Fin
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
11 years, 5 months
[JBoss JIRA] (ISPN-3729) Minimize the number of moved segments for SyncConsistentHashFactory
by Galder Zamarreño (JIRA)
[ https://issues.jboss.org/browse/ISPN-3729?page=com.atlassian.jira.plugin.... ]
Galder Zamarreño updated ISPN-3729:
-----------------------------------
Fix Version/s: 7.1.0.Alpha1
(was: 7.0.0.Final)
> Minimize the number of moved segments for SyncConsistentHashFactory
> -------------------------------------------------------------------
>
> Key: ISPN-3729
> URL: https://issues.jboss.org/browse/ISPN-3729
> Project: Infinispan
> Issue Type: Bug
> Components: Core
> Affects Versions: 6.0.0.Final
> Reporter: Dan Berindei
> Fix For: 7.1.0.Alpha1
>
>
> SyncConsistentHash uses an algorithm that's similar to consistent hashing, but when there is a collision (two nodes map to the same segment), the second node is moved to the next segment. Since the nodes are ordered by their UUID, that means it's possible for a joiner to change the mapping of existing nodes.
> In order to make the load distribution more even, SyncConsistentHash also uses "virtual nodes": each node actually maps to multiple segments. This makes the number of collisions much higher (and implicitly, the number of extra moved segments).
> Reading the original [consistent hashing paper|http://thor.cs.ucsb.edu/~ravenben/papers/coreos/kll%2B97.pdf], it looks like the collision handling should be done differently: a joiner should replace an existing node when it's "closer" to the segment boundary, but the existing node should never "move" to another segment (the property of monotonicity mentioned in the paper). We should investigate whether changing this would allow us to achieve better load balancing by using a much higher number of "virtual nodes" (without moving extra segments). If successful, we could even use SyncConsistentHashFactory as the default hash algorithm.
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
11 years, 5 months
[JBoss JIRA] (ISPN-3727) intermittent test failure AsyncReplExtendedStatisticTest.testReplaceWithOldVal
by Galder Zamarreño (JIRA)
[ https://issues.jboss.org/browse/ISPN-3727?page=com.atlassian.jira.plugin.... ]
Galder Zamarreño updated ISPN-3727:
-----------------------------------
Fix Version/s: 7.1.0.Alpha1
(was: 7.0.0.Final)
> intermittent test failure AsyncReplExtendedStatisticTest.testReplaceWithOldVal
> ------------------------------------------------------------------------------
>
> Key: ISPN-3727
> URL: https://issues.jboss.org/browse/ISPN-3727
> Project: Infinispan
> Issue Type: Bug
> Components: Test Suite - Core
> Affects Versions: 6.0.0.Final
> Reporter: Mircea Markus
> Assignee: Pedro Ruivo
> Labels: testsuite_stability
> Fix For: 7.1.0.Alpha1
>
>
> Failed tests:
> AsyncReplExtendedStatisticTest>BaseClusteredExtendedStatisticTest.testReplaceWithOldVal:190->BaseClusteredExtendedStatisticTest.assertCacheValue:253->MultipleCacheManagersTest.assertEventuallyEquals:554->AbstractInfinispanTest.eventually:173->AbstractInfinispanTest.eventually:45->AbstractInfinispanTest.eventually:62
> expected [true] but found [false]
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
11 years, 5 months
[JBoss JIRA] (ISPN-3716) Shareability of Configuration and ConfigurationBuilder instances (and global versions)
by Galder Zamarreño (JIRA)
[ https://issues.jboss.org/browse/ISPN-3716?page=com.atlassian.jira.plugin.... ]
Galder Zamarreño updated ISPN-3716:
-----------------------------------
Fix Version/s: 7.1.0.Alpha1
(was: 7.0.0.Final)
> Shareability of Configuration and ConfigurationBuilder instances (and global versions)
> --------------------------------------------------------------------------------------
>
> Key: ISPN-3716
> URL: https://issues.jboss.org/browse/ISPN-3716
> Project: Infinispan
> Issue Type: Enhancement
> Components: Configuration
> Reporter: Galder Zamarreño
> Assignee: Mircea Markus
> Fix For: 7.1.0.Alpha1
>
>
> Widlfly is using Configuration/GlobalConfiguration instances of one cache/cachemanager to create other cache managers.
> Configuration/GlobalConfiguration are probably not designed to be shareable at this point in time. The builder classes should be sharable but sharing them would not have resolved the issue in ISPN-3698.
> It probably makes sense to change marshaller to be a factory or lookup configuration to be able to create instances of marshaller when configuration is created.
> ConfigurationBuilder/GlobalConfigurationBuilder classes are expected to be shareable.
> Tests and verifications should be added.
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
11 years, 5 months