Re: [hibernate-dev] Ehcache integration

2011-07-14 Thread Alex Snaps
Right, which would work once the ServiceRegistry will be used. Just did a couple of test with changing the RegionFactory Lookup code and it seems like it's all working fine. So that is injected, it'll use ClassLoaderService.locateResource now. Still have to look into why it didn't work when the met

Re: [hibernate-dev] Ehcache integration

2011-07-14 Thread Strong Liu
okay, so the problem is you need ServiceRegistry in your ehcache RegionFactory impl, right? you can do it this way: class EhcacheRegionFactory implements RegionFacotry{ private ClassLoaderService classLoaderService; @InjectService public void setClassLoaderService(ClassL

Re: [hibernate-dev] Ehcache integration

2011-07-14 Thread Alex Snaps
Strong, I did fix that that way now indeed (moved the static method to RegionFactoryInitiator and made it public for now, given the hack still in place). I'll look into having the EhcacheIntegratorService loaded none the less and so I get the ClassLoaderService available in the EhcacheRegionFactori

Re: [hibernate-dev] Ehcache integration

2011-07-14 Thread Strong Liu
Alex (i already commented in your pull request) cache provider is integrated by org.hibernate.cache.internal.RegionFactoryInitiator, and the mapLegency should go into this class too. it is in process of moving from SettingsFactory.createRegionFactory to RegionFactoryInitiator --- Stro

Re: [hibernate-dev] Ehcache integration

2011-07-14 Thread Alex Snaps
Yeah. I wanted to have an EhcacheIntegratorService registered, that would, during the integrate call, do the potential mapping from old to new name (so this would be able to use class.getName()). Also, I could keep a ref to the ServiceRegistry, so I'd be able to address any classloader concerns

Re: [hibernate-dev] Ehcache integration

2011-07-13 Thread Strong Liu
On Jul 14, 2011, at 4:57 AM, Steve Ebersole wrote: > Or do you mean java.util.ServiceLoader ? yes, i think Alex means this > > On Wed 13 Jul 2011 03:54:16 PM CDT, Steve Ebersole wrote: >> On 07/13/2011 09:46 AM, Strong Liu wrote: >>> On Jul 11, 2011, at 10:48 PM, Alex Snaps wrote: >>> >>> a w

Re: [hibernate-dev] Ehcache integration

2011-07-13 Thread Steve Ebersole
Or do you mean java.util.ServiceLoader ? On Wed 13 Jul 2011 03:54:16 PM CDT, Steve Ebersole wrote: > On 07/13/2011 09:46 AM, Strong Liu wrote: >> On Jul 11, 2011, at 10:48 PM, Alex Snaps wrote: >> >> a warning >>> - Second level cache isn't (yet?) using "ServiceInitiator approach", >>> is this goi

Re: [hibernate-dev] Ehcache integration

2011-07-13 Thread Steve Ebersole
On 07/13/2011 09:46 AM, Strong Liu wrote: > On Jul 11, 2011, at 10:48 PM, Alex Snaps wrote: > > a warning >> - Second level cache isn't (yet?) using "ServiceInitiator approach", >> is this going to change ? > > I don't pre-see it, Steve? >> - Right now the mapping plan is "weak" in terms of typing

Re: [hibernate-dev] Ehcache integration

2011-07-13 Thread Strong Liu
On Jul 13, 2011, at 11:40 PM, Alex Snaps wrote: > On Wed, Jul 13, 2011 at 4:46 PM, Strong Liu wrote: >> >> >> On Jul 11, 2011, at 10:48 PM, Alex Snaps wrote: >> >>> Hey guys, >>> I've finished the port of all the Hibernate h2lc from the ehcache >>> source base into the hibernate-ehcache modul

Re: [hibernate-dev] Ehcache integration

2011-07-13 Thread Alex Snaps
On Wed, Jul 13, 2011 at 4:46 PM, Strong Liu wrote: > > > On Jul 11, 2011, at 10:48 PM, Alex Snaps wrote: > >> Hey guys, >> I've finished the port of all the Hibernate h2lc from the ehcache >> source base into the hibernate-ehcache module. >> Now, polishing this, I also addressed this mapping from

Re: [hibernate-dev] Ehcache integration

2011-07-13 Thread Strong Liu
On Jul 11, 2011, at 10:48 PM, Alex Snaps wrote: > Hey guys, > I've finished the port of all the Hibernate h2lc from the ehcache > source base into the hibernate-ehcache module. > Now, polishing this, I also addressed this mapping from old to new names. > You can see the simple fix here: > https:

Re: [hibernate-dev] Ehcache integration

2011-07-11 Thread Alex Snaps
Hey guys, I've finished the port of all the Hibernate h2lc from the ehcache source base into the hibernate-ehcache module. Now, polishing this, I also addressed this mapping from old to new names. You can see the simple fix here: https://github.com/alexsnaps/hibernate-core/commit/fc5d94e8b0b15b43fc

Re: [hibernate-dev] Ehcache integration

2011-06-21 Thread Steve Ebersole
It would not necessarily require users to change config values. Just update the code that instantiates the RegionFactories (org.hibernate.cache.internal.RegionFactoryInitiator) to understand the legacy class FQN as well. Have a look at org.hibernate.engine.transaction.internal.TransactionFact

Re: [hibernate-dev] Ehcache integration

2011-06-21 Thread Strong Liu
yes, but thats the pain we must take --- Strong Liu http://hibernate.org http://github.com/stliu On Jun 21, 2011, at 5:56 PM, Alex Snaps wrote: > Did that... I'll replace internal with ehcache then, as in the infinispan > module. But that would still require existing users to chang

Re: [hibernate-dev] Ehcache integration

2011-06-21 Thread Alex Snaps
Did that... I'll replace internal with ehcache then, as in the infinispan module. But that would still require existing users to change their config though! On Tuesday 21 June 2011 at 11:39, Strong Liu wrote: > take a look of hibernate-infinispan, we should change hibernate-ehcache > package

Re: [hibernate-dev] Ehcache integration

2011-06-21 Thread Strong Liu
take a look of hibernate-infinispan, we should change hibernate-ehcache package name like that, using "internal" in user's configuration file is not a good ghing --- Strong Liu http://hibernate.org http://github.com/stliu On Jun 21, 2011, at 4:42 PM, Alex Snaps wrote: > > On Wednesd

Re: [hibernate-dev] Ehcache integration

2011-06-21 Thread Alex Snaps
On Wednesday 8 June 2011 at 16:47, Strong Liu wrote: > > On Jun 8, 2011, at 9:02 PM, Steve Ebersole wrote: > > > The only use case I am really interested in for "simple map based" > > caching is the test suite. Its the whole reason I did not do the things > > Strong and I discussed on the oth