[infinispan-dev] Hotrod 5.3.0.Beta1

Galder Zamarreño galder at redhat.com
Thu May 16 07:46:00 EDT 2013


On May 14, 2013, at 3:54 PM, Mark Addy <maddy at c2b2.co.uk> wrote:

> Hi,
> Thanks for the replies, all sorted now.  I went back through the 
> previous archives and found ISPN-2281 and the changes associated to this.
> So to get Hotrod working you must supply a custom Equivalence 
> implementation as an attribute of the dataContainer element for the cache.
> I have created a wrapper around the enum 
> org.infinispan.util.ByteArrayEquivalence and placed it on the server 
> classpath so I could use it in the XML configuration.

^ The thing is that you shouldn't need to do this. If you've downloaded the new Infinsispan server download from (http://downloads.jboss.org/infinispan/5.3.0.Beta1/infinispan-server-5.3.0.Beta1-bin.zip), it ships a default configuration that has this setting correctly set. (@Tristan, correct me if I'm wrong...)

Hence, if you can explain how you're using the Hot Rod server, we can see if there's anything wrong here.

Cheers,

> Thanks again.
> Mark
> 
> 
> 
> 
> On 14/05/13 13:52, infinispan-dev-request at lists.jboss.org wrote:
>> Message: 4 Date: Tue, 14 May 2013 14:52:01 +0200 From: Galder 
>> Zamarre?o <galder at redhat.com> Subject: Re: [infinispan-dev] Hotrod 
>> 5.3.0.Beta1 To: infinispan -Dev List <infinispan-dev at lists.jboss.org> 
>> Message-ID: <6BFA35D0-DF08-4B02-B7A3-ECA6BF52A546 at redhat.com> 
>> Content-Type: text/plain; charset=iso-8859-1 Indeed, dunno what the 
>> environment this is working on, but indeed there's been some crucial 
>> changes. Data container keyEquivalence configuration must be set to a 
>> Equivalence implementation that can handle byte array keys. (If set, 
>> that same one will be used to compare values too). If that's not 
>> configured, it fails with an exception because the key equivalence 
>> instance is not set. Cheers, On May 14, 2013, at 2:44 PM, Mircea 
>> Markus <mmarkus at redhat.com> wrote:
>>>> Hi Mark,
>>>> 
>>>> Can you please share your config with us, both client and server?
>>>> If you can reproduce this on a single server node even better.
>>>> 
>>>> On 14 May 2013, at 10:05, Mark Addy wrote:
>>>>>> Hi,
>>>>>> Not sure if I have missed something really obvious but I am unable to
>>>>>> get Hotrod to work with this release.  If I do a put I can see the new
>>>>>> entry being written but a subsequent get fails to find it...
>>>>>> Set up is a vanilla install with the distributed-udp.xml configuration file.
>>>>>> Hopefully I have done something daft, any help would be great!
>>>>>> Thanks
>>>>>> Mark
>>>>>> 
>>>>>> Here is the put logging:
>>>>>> 
>>>>>> 2013-05-14 10:02:25,052 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.server.hotrod.Decoder10$] Operation code: 1 has been
>>>>>> matched to PutRequest
>>>>>> 2013-05-14 10:02:25,052 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.server.hotrod.HotRodDecoder] Decoded header
>>>>>> HotRodHeader{op=PutRequest, version=12, messageId=6, cacheName=, flag=6,
>>>>>> clientIntelligence=3, topologyId=0}
>>>>>> 2013-05-14 10:02:25,052 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.server.hotrod.HotRodDecoder] Decode using instance @4aa193fe
>>>>>> 2013-05-14 10:02:25,052 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.server.hotrod.HotRodDecoder] Decode using instance @4aa193fe
>>>>>> 2013-05-14 10:02:25,053 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.server.hotrod.HotRodDecoder] Decode using instance @4aa193fe
>>>>>> 2013-05-14 10:02:25,053 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.interceptors.InvocationContextInterceptor] Invoked with
>>>>>> command VersionedPutKeyValueCommand{key=[B0x034b00000000..,
>>>>>> value=[B0x033e0474657374.., version=ServerEntr
>>>>>> yVersion(4294967299), flags=null, putIfAbsent=false, lifespanMillis=-1,
>>>>>> maxIdleTimeMillis=-1} and InvocationContext
>>>>>> [org.infinispan.context.SingleKeyNonTxInvocationContext at 5a388c74]
>>>>>> 2013-05-14 10:02:25,053 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.statetransfer.StateTransferInterceptor]
>>>>>> handleTopologyAffectedCommand for command
>>>>>> VersionedPutKeyValueCommand{key=[B0x034b00000000..,
>>>>>> value=[B0x033e0474657374..,
>>>>>> version=ServerEntryVersion(4294967299), flags=null, putIfAbsent=false,
>>>>>> lifespanMillis=-1, maxIdleTimeMillis=-1}
>>>>>> 2013-05-14 10:02:25,053 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.interceptors.locking.NonTransactionalLockingInterceptor]
>>>>>> Are (kegley-53518) we the lock owners for key '[B at 368d41f2'? true
>>>>>> 2013-05-14 10:02:25,053 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.util.concurrent.locks.LockManagerImpl] Attempting to
>>>>>> lock [B0x034b00000000.. with acquisition timeout of 10000 millis
>>>>>> 2013-05-14 10:02:25,054 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.util.concurrent.locks.containers.ReentrantPerEntryLockContainer]
>>>>>> Creating and acquiring new lock instance for key [B0x034b00000000..
>>>>>> 2013-05-14 10:02:25,054 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.util.concurrent.locks.LockManagerImpl] Successfully
>>>>>> acquired lock [B0x034b00000000..!
>>>>>> 2013-05-14 10:02:25,054 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.interceptors.EntryWrappingInterceptor] Wrapping entry
>>>>>> '[B0x034b00000000..'? true
>>>>>> 2013-05-14 10:02:25,054 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.container.EntryFactoryImpl] Exists in context? null
>>>>>> 2013-05-14 10:02:25,054 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.container.EntryFactoryImpl] Retrieved from container null
>>>>>> 2013-05-14 10:02:25,054 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.container.EntryFactoryImpl] Creating new entry.
>>>>>> 2013-05-14 10:02:25,054 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.interceptors.distribution.NonTxDistributionInterceptor]
>>>>>> Not doing a remote get for key [B at 368d41f2 since entry is not affected
>>>>>> by rehash or is already in data container. We are kegley-53518, owners
>>>>>> are [kegley-53518]
>>>>>> 2013-05-14 10:02:25,054 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.interceptors.distribution.NonTxConcurrentDistributionInterceptor]
>>>>>> I'm the primary owner, sending the command to all ([kegley-53518]) the
>>>>>> recipients in order to be applied.
>>>>>> 2013-05-14 10:02:25,055 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.interceptors.CallInterceptor] Executing command:
>>>>>> VersionedPutKeyValueCommand{key=[B0x034b00000000..,
>>>>>> value=[B0x033e0474657374.., version=ServerEntryVersion(4294967299),
>>>>>> flags=null, putIfAbsent=false, lifespanMillis=-1, maxIdleTimeMillis=-1}.
>>>>>> 2013-05-14 10:02:25,055 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.remoting.rpc.RpcManagerImpl] kegley-53518 invoking
>>>>>> VersionedPutKeyValueCommand{key=[B0x034b00000000..,
>>>>>> value=[B0x033e0474657374.., version=ServerEntryVersion(4294967299),
>>>>>> flags=null, putIfAbsent=false, lifespanMillis=-1, maxIdleTimeMillis=-1}
>>>>>> to recipient list [kegley-53518] with options RpcOptions{timeout=15000,
>>>>>> unit=MILLISECONDS, fifoOrder=true, totalOrder=false,
>>>>>> responseFilter=null, responseMode=SYNCHRONOUS, skipReplicationQueue=false}
>>>>>> 2013-05-14 10:02:25,055 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.remoting.transport.jgroups.JGroupsTransport]
>>>>>> dests=[kegley-53518],
>>>>>> command=SingleRpcCommand{cacheName='___defaultcache',
>>>>>> command=VersionedPutKeyValueCommand{key=[B0x034b00000000..,
>>>>>> value=[B0x033e0474657374.., version=ServerEntryVersion(4294967299),
>>>>>> flags=null, putIfAbsent=false, lifespanMillis=-1,
>>>>>> maxIdleTimeMillis=-1}}, mode=SYNCHRONOUS, timeout=15000
>>>>>> 2013-05-14 10:02:25,055 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.remoting.rpc.RpcManagerImpl] Response(s) to
>>>>>> SingleRpcCommand{cacheName='___defaultcache',
>>>>>> command=VersionedPutKeyValueCommand{key=[B0x034b00000000..,
>>>>>> value=[B0x033e0474657374.., version=ServerEntryVersion(4294967299),
>>>>>> flags=null, putIfAbsent=false, lifespanMillis=-1, maxIdleTimeMillis=-1}}
>>>>>> is {}
>>>>>> 2013-05-14 10:02:25,055 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.interceptors.EntryWrappingInterceptor] About to commit
>>>>>> entry ReadCommittedEntry(73e492d8){key=[B0x034b00000000..,
>>>>>> value=[B0x033e0474657374.., oldValue=null, isCreated=true,
>>>>>> isChanged=true, isRemoved=false, isValid=true}
>>>>>> 2013-05-14 10:02:25,056 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.container.entries.ReadCommittedEntry] Updating entry
>>>>>> (key=[B0x034b00000000.. removed=false valid=true changed=true
>>>>>> created=true loaded=false value=[B0x033e0474657374..]
>>>>>> 2013-05-14 10:02:25,056 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.interceptors.EntryWrappingInterceptor] The return value
>>>>>> is null
>>>>>> 2013-05-14 10:02:25,056 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.util.concurrent.locks.LockManagerImpl] Attempting to
>>>>>> unlock [B0x034b00000000..
>>>>>> 2013-05-14 10:02:25,056 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.util.concurrent.locks.containers.ReentrantPerEntryLockContainer]
>>>>>> Unlocking lock instance for key [B0x034b00000000..
>>>>>> 2013-05-14 10:02:25,056 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.statetransfer.StateTransferManagerImpl]
>>>>>> CommandTopologyId=0, localTopologyId=0
>>>>>> 2013-05-14 10:02:25,056 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.server.hotrod.HotRodDecoder] Write response
>>>>>> Response{version=12, messageId=6, operation=PutResponse, status=Success,
>>>>>> cacheName=}
>>>>>> 2013-05-14 10:02:25,056 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.server.hotrod.HotRodEncoder] Encode msg
>>>>>> Response{version=12, messageId=6, operation=PutResponse, status=Success,
>>>>>> cacheName=}
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> And here is the get logging:
>>>>>> 
>>>>>> 2013-05-14 10:02:25,063 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.server.hotrod.Decoder10$] Operation code: 3 has been
>>>>>> matched to GetRequest
>>>>>> 2013-05-14 10:02:25,063 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.server.hotrod.HotRodDecoder] Decoded header
>>>>>> HotRodHeader{op=GetRequest, version=12, messageId=8, cacheName=, flag=0,
>>>>>> clientIntelligence=3, topologyId=0}
>>>>>> 2013-05-14 10:02:25,063 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.server.hotrod.HotRodDecoder] Decode using instance @4aa193fe
>>>>>> 2013-05-14 10:02:25,063 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.interceptors.InvocationContextInterceptor] Invoked with
>>>>>> command GetCacheEntryCommand {key=[B0x034b00000000.., flags=null} and
>>>>>> InvocationContext
>>>>>> [org.infinispan.context.SingleKeyNonTxInvocationContext at 2364de59]
>>>>>> 2013-05-14 10:02:25,063 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.statetransfer.StateTransferInterceptor]
>>>>>> handleTopologyAffectedCommand for command GetCacheEntryCommand
>>>>>> {key=[B0x034b00000000.., flags=null}
>>>>>> 2013-05-14 10:02:25,064 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.container.EntryFactoryImpl] Exists in context? null
>>>>>> 2013-05-14 10:02:25,064 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.container.EntryFactoryImpl] Retrieved from container null
>>>>>> 2013-05-14 10:02:25,064 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.interceptors.CallInterceptor] Executing command:
>>>>>> GetCacheEntryCommand {key=[B0x034b00000000.., flags=null}.
>>>>>> 2013-05-14 10:02:25,064 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.commands.read.GetKeyValueCommand] Entry not found
>>>>>> 2013-05-14 10:02:25,064 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.interceptors.distribution.BaseDistributionInterceptor]
>>>>>> Not doing a remote get for key [B0x034b00000000.. since entry is mapped
>>>>>> to current node (kegley-53518) or is in L1. Owners are [kegley-53518]
>>>>>> 2013-05-14 10:02:25,064 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.server.hotrod.HotRodDecoder] Write response
>>>>>> GetResponse{version=12, messageId=8, operation=GetResponse,
>>>>>> status=KeyDoesNotExist, data=null}
>>>>>> 2013-05-14 10:02:25,064 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.server.hotrod.HotRodEncoder] Encode msg
>>>>>> GetResponse{version=12, messageId=8, operation=GetResponse,
>>>>>> status=KeyDoesNotExist, data=null}
>>>>>> 2013-05-14 10:02:25,064 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.server.hotrod.Encoders$Encoder12$] Write topology
>>>>>> response header with no change
>>>>>> 2013-05-14 10:02:25,064 TRACE (HotRodServerWorker-4)
>>>>>> [org.infinispan.server.hotrod.HotRodEncoder] Write buffer contents
>>>>>> A108040200 to channel [id: 0xe9c51ab1, /127.0.0.1:40222 => /127.0.1.1:11111]
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> _______________________________________________
>>>>>> infinispan-dev mailing list
>>>>>> infinispan-dev at lists.jboss.org
>>>>>> https://lists.jboss.org/mailman/listinfo/infinispan-dev
>>>> 
>>>> Cheers,
>>>> -- 
>>>> Mircea Markus
>>>> Infinispan lead (www.infinispan.org)
>>>> 
>>>> 
>>>> 
>>>> 
>>>> 
>>>> _______________________________________________
>>>> infinispan-dev mailing list
>>>> infinispan-dev at lists.jboss.org
>>>> https://lists.jboss.org/mailman/listinfo/infinispan-dev
>> --
>> Galder Zamarre?o
>> galder at redhat.com
>> twitter.com/galderz
>> 
>> Project Lead, Escalante
>> http://escalante.io
>> 
>> Engineer, Infinispan
>> http://infinispan.org
> _______________________________________________
> infinispan-dev mailing list
> infinispan-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/infinispan-dev


--
Galder Zamarreño
galder at redhat.com
twitter.com/galderz

Project Lead, Escalante
http://escalante.io

Engineer, Infinispan
http://infinispan.org




More information about the infinispan-dev mailing list