[infinispan-dev] TimeService (ISPN-3069): CacheLoader API break
Mircea Markus
mmarkus at redhat.com
Wed May 8 07:06:47 EDT 2013
On 8 May 2013, at 10:40, Pedro Ruivo wrote:
> On 05/08/2013 10:36 AM, Manik Surtani wrote:
>>
>> On 8 May 2013, at 10:34, Pedro Ruivo <pedro at infinispan.org> wrote:
>>
>>> Hi guys,
>>>
>>> In order to use the TimeService inside the cache loaders/stores I had to
>>> change the method init() to include a new parameter the TimeService.
>>
>> Won't this break custom/3rd party impls?
>
> probably/definitely yes.
-1
>
> but I don't want to create a cache in all the cache loader/store tests
> that will be used to pick the TimeService.
>
> I tried to mock the ComponentRegistry but it is not possible for final
> classes. I don't want to remove the final :(
>
> Another alternative that come to my mind was to add a new method in
> AdvancedCache that returns the TimeService (and this I can mock it in
> the test suite)
+1
Cheers,
--
Mircea Markus
Infinispan lead (www.infinispan.org)
More information about the infinispan-dev
mailing list