[infinispan-dev] Fluent configuration wiki update

2011-05-16 Thread Galder Zamarreño
A section has been added to http://community.jboss.org/docs/DOC-14839 with some examples on how to configure Infinispan programmatically from 5.0 onwards. Any feedback appreciated Cheers, -- Galder Zamarreño Sr. Software Engineer Infinispan, JBoss Cache

Re: [infinispan-dev] Fluent configuration wiki update

2011-05-16 Thread Manik Surtani
Nice. Perhaps you need a few basic configs though? Stuff that people would typically use? A lot of your examples demonstrate some of the more complex config examples (custom marshallers and interceptors). I think a lot of first-time users will try and copy these into their IDEs and expect a

Re: [infinispan-dev] Infinispan Query entity discovery (Was: Re: new Infinispan Query API - ISPN-194)

2011-05-16 Thread Manik Surtani
On 13 May 2011, at 19:27, Sanne Grinovero wrote: Or does Reflections provide some cool way to find all subtypes of a class? Even if it's a bit expensive, we already cache all new class processing as for each new type we have to restart the Search engine which is quite expensive anyway. I

[infinispan-dev] Local state transfer before going over network

2011-05-16 Thread Galder Zamarreño
Not sure if the idea has come up but while at GeeCON last week I was discussing to one of the attendees about state transfer improvements in replicated environments: The idea is that in a replicated environment, if a cache manager shuts down, it would dump its memory contents to a cache store

Re: [infinispan-dev] Per-invocation flag wiki

2011-05-16 Thread Emmanuel Bernard
Your description explains a use case / pattern but wo code showing how to implement it properly. In this case what's the best way for me to verify that the new data has indeed been pushed to the cache? put and then immediate get Put, wait, get Put all entries, then get all entries, and loop

Re: [infinispan-dev] Fluent configuration wiki update

2011-05-16 Thread Galder Zamarreño
On May 16, 2011, at 12:05 PM, Vladimir Blagojevic wrote: On 11-05-16 11:57 AM, Manik Surtani wrote: Nice. Perhaps you need a few basic configs though? Stuff that people would typically use? A lot of your examples demonstrate some of the more complex config examples (custom marshallers

Re: [infinispan-dev] Eventing over Hot Rod vs JMS Was: Hot Rod protocol improvements JIRA

2011-05-16 Thread Manik Surtani
On 16 May 2011, at 13:52, Galder Zamarreño wrote: Maybe your or Sanne can build that wiki or note in down in more detail since you guys implemented it? You could use that code as sample Sanne, do you want to take this, since you had more details of the impl? Cheers Manik -- Manik Surtani

Re: [infinispan-dev] Fluent configuration wiki update

2011-05-16 Thread Mircea Markus
yes, looks good. On 16 May 2011, at 16:15, Galder Zamarreño wrote: Hmmm, maybe you caught me in the middle of updating the wiki? Check the link again... On May 16, 2011, at 5:12 PM, Mircea Markus wrote: Good stuff! My only note is that there are some code snippets that are not code:

Re: [infinispan-dev] Per-invocation flag wiki

2011-05-16 Thread Galder Zamarreño
On May 16, 2011, at 2:23 PM, Emmanuel Bernard wrote: Your description explains a use case / pattern but wo code showing how to implement it properly. True and I think you have a point, though the use of putForExternalRead() itself is something that should be documented either its javadoc

Re: [infinispan-dev] New events to reflect topology change Was: https://issues.jboss.org/browse/ISPN-977

2011-05-16 Thread Mircea Markus
On 13 May 2011, at 10:28, Manik Surtani wrote: So this is related to ISPN-360 which is currently titled create NodeJoinedEvent. Leaving names out for now, essentially, what we need is a notification to inform listeners that (a) a JGroups ViewChange has been detected (b) a rehash has

[infinispan-dev] Compilation errors in the infinispan-spring module

2011-05-16 Thread Dan Berindei
Hi Olaf, Did you see any problems with RHQ + Spring interaction that determined you to exclude the rhq-pluginAnnotations dependency in the spring module? dependency groupId${project.groupId}/groupId artifactIdinfinispan-core/artifactId

Re: [infinispan-dev] [Pull Request] Modular Classloading Compatibility

2011-05-16 Thread Galder Zamarreño
On May 12, 2011, at 11:18 AM, Dan Berindei wrote: On Wed, May 11, 2011 at 11:18 PM, David Bosschaert da...@redhat.com wrote: On 11/05/2011 17:54, Dan Berindei wrote: On Wed, May 11, 2011 at 7:08 PM, Pete Muirpm...@redhat.com wrote: Were we developing for OSGi I would certainly agree with

Re: [infinispan-dev] [Pull Request] Modular Classloading Compatibility

2011-05-16 Thread Pete Muir
On 16 May 2011, at 18:20, Galder Zamarreño wrote: On May 12, 2011, at 11:18 AM, Dan Berindei wrote: On Wed, May 11, 2011 at 11:18 PM, David Bosschaert da...@redhat.com wrote: On 11/05/2011 17:54, Dan Berindei wrote: On Wed, May 11, 2011 at 7:08 PM, Pete Muirpm...@redhat.com wrote: Were

Re: [infinispan-dev] Per-invocation flag wiki

2011-05-16 Thread Sanne Grinovero
good place to remind that if you don't want the return value of a write operation then you need to specify both flags: cache.withFlags(Flag.SKIP_REMOTE_LOOKUP, Flag.SKIP_CACHE_LOAD).put( .. ) I guess that nobody knows that :) Sanne 2011/5/16 Emmanuel Bernard emman...@hibernate.org: Yes I think

Re: [infinispan-dev] Per-invocation flag wiki

2011-05-16 Thread Emmanuel Bernard
Couldn't you have a higher level flag that says Flag.IGNORE_RETURN_VALUE so that people wo a PhD can benefit form the feature? On 16 mai 2011, at 19:37, Sanne Grinovero wrote: good place to remind that if you don't want the return value of a write operation then you need to specify both

Re: [infinispan-dev] [Pull Request] Modular Classloading Compatibility

2011-05-16 Thread Sanne Grinovero
I don't like the TCCL either, so I'll repeat my suggestion from two weeks ago to just have: Cache c = cacheManager.getCache( cacheName, classLoader ); sounds reasonable to me to have the application declare it's intentions once ? BTW I don't like cache.get(K key, ClassV clazz) as we're not

Re: [infinispan-dev] [Pull Request] Modular Classloading Compatibility

2011-05-16 Thread Emmanuel Bernard
I don't enjoy using JBoss Logging for that reason :) I always have to get down to the JavaDoc or figure out the list of available params to understand what debug* does for example and which one I need. I guess that's taste and for something like JBoss Logging, a fluent API is costly

Re: [infinispan-dev] [Pull Request] Modular Classloading Compatibility

2011-05-16 Thread Adrian Cole
What about a helper that just returns a cache with a specific classloader from a cache? cache.withLoader(cl).get(K key) -a On Mon, May 16, 2011 at 11:14 AM, Galder Zamarreño gal...@redhat.comwrote: On May 16, 2011, at 7:57 PM, Sanne Grinovero wrote: I don't like the TCCL either, so I'll

Re: [infinispan-dev] [Pull Request] Modular Classloading Compatibility

2011-05-16 Thread Sanne Grinovero
2011/5/16 Pete Muir pm...@redhat.com: This is the hibernate session style contract that Jason is talking about.   As the CM can be shared (e.g. in JNDI), then the same Cache object can be returned in multiple applications in the app server, meaning you can't simply associate the CL with a

Re: [infinispan-dev] [Pull Request] Modular Classloading Compatibility

2011-05-16 Thread Pete Muir
BTW having thought about it more, this seems to be the only option that actually works at the API level, even if it will require some re-eng in Infinispan core. On 16 May 2011, at 19:29, Pete Muir wrote: On 16 May 2011, at 19:24, Sanne Grinovero wrote: 2011/5/16 Pete Muir

Re: [infinispan-dev] JGroupsDistSync and ISPN-83

2011-05-16 Thread Vladimir Blagojevic
Manik (and others), Can you run this code on your laptops and let me know what happened! Vladimir public static void main (String [] arg) throws Exception { final JGroupsDistSync ds = new JGroupsDistSync(); ds.acquireProcessingLock(false, 3, TimeUnit.SECONDS);

Re: [infinispan-dev] Fluent configuration wiki update

2011-05-16 Thread Vladimir Blagojevic
On 11-05-16 5:15 PM, Galder Zamarreño wrote: Feedback taken onboard: http://community.jboss.org/docs/DOC-14839 On May 16, 2011, at 12:05 PM, Vladimir Blagojevic wrote: Excellent wiki Galder! Finally worth its title (Configuring cache programmatically) Cheers.

Re: [infinispan-dev] Fluent configuration wiki update

2011-05-16 Thread Erik Salter
I guess I qualify as others, since I'm looking at similar issues. Got read lock java.util.concurrent.TimeoutException: Thread-1 could not obtain exclusive processing lock after 3 seconds. Locks in question are java.util.concurrent.locks.ReentrantReadWriteLock$ReadLock@16aa37a6[Read locks = 1]

Re: [infinispan-dev] JGroupsDistSync and ISPN-83

2011-05-16 Thread Sanne Grinovero
Same result here - where you expecting something different? Cheers, Sanne 2011/5/16 Erik Salter esal...@bnivideo.com: EDIT:  Originally posted in the wrong thread.  I blame Outlook. I guess I qualify as others, since I'm looking at similar issues. Got read lock

Re: [infinispan-dev] [Pull Request] Modular Classloading Compatibility

2011-05-16 Thread Dan Berindei
Not to be the guy that breaks the circle, how about the threads that handle incoming RPCs from other nodes? With storeAsBinary=false those threads have to unmarshal the objects in order to store them on the local node, so we'd need a way to register a classloader with the cache, not just with the