[JBoss JIRA] (ISPN-4542) Programmatic configuration doesn't have loaders() method
by Mikhail Dobrinin (JIRA)
[ https://issues.jboss.org/browse/ISPN-4542?page=com.atlassian.jira.plugin.... ]
Mikhail Dobrinin edited comment on ISPN-4542 at 7/17/14 7:42 PM:
-----------------------------------------------------------------
comment edited
was (Author: mdobrinin):
Actually there does appear to be a way to do it programmatically, but here is the syntax:
{code}
Configuration config = new ConfigurationBuilder()
.persistence()
.addStore(Store.class)
.loaderClass(MockLoader.class.getName())
.build();
{code}
> Programmatic configuration doesn't have loaders() method
> --------------------------------------------------------
>
> Key: ISPN-4542
> URL: https://issues.jboss.org/browse/ISPN-4542
> Project: Infinispan
> Issue Type: Enhancement
> Security Level: Public(Everyone can see)
> Affects Versions: 6.0.0.Final
> Reporter: Mikhail Dobrinin
> Assignee: Mircea Markus
> Priority: Minor
>
> The ConfigurationBuilder class does not actually have a {{loaders}} method. However, the documentation mentions it in a few places such as here -- http://infinispan.org/docs/6.0.x/user_guide/user_guide.html if you search for {{loaders()}} on the page. Also it's not clear to a user if it's possible to configure a custom cache loader programmatically because of this. I'm guessing it's not actually possible. That makes it hard to write tests with a mocked cacheloader.
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
10 years, 6 months
[JBoss JIRA] (ISPN-4542) Programmatic configuration doesn't have loaders() method
by Mikhail Dobrinin (JIRA)
[ https://issues.jboss.org/browse/ISPN-4542?page=com.atlassian.jira.plugin.... ]
Mikhail Dobrinin commented on ISPN-4542:
----------------------------------------
Actually there does appear to be a way to do it programmatically, but here is the syntax:
{code}
Configuration config = new ConfigurationBuilder()
.persistence()
.addStore(Store.class)
.loaderClass(MockLoader.class.getName())
.build();
{code}
> Programmatic configuration doesn't have loaders() method
> --------------------------------------------------------
>
> Key: ISPN-4542
> URL: https://issues.jboss.org/browse/ISPN-4542
> Project: Infinispan
> Issue Type: Enhancement
> Security Level: Public(Everyone can see)
> Affects Versions: 6.0.0.Final
> Reporter: Mikhail Dobrinin
> Assignee: Mircea Markus
> Priority: Minor
>
> The ConfigurationBuilder class does not actually have a {{loaders}} method. However, the documentation mentions it in a few places such as here -- http://infinispan.org/docs/6.0.x/user_guide/user_guide.html if you search for {{loaders()}} on the page. Also it's not clear to a user if it's possible to configure a custom cache loader programmatically because of this. I'm guessing it's not actually possible. That makes it hard to write tests with a mocked cacheloader.
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
10 years, 6 months
[JBoss JIRA] (ISPN-4446) removeCache fails for caches with a SingleFileStore
by Galder Zamarreño (JIRA)
[ https://issues.jboss.org/browse/ISPN-4446?page=com.atlassian.jira.plugin.... ]
Galder Zamarreño updated ISPN-4446:
-----------------------------------
Fix Version/s: 7.0.0.Alpha5
(was: 7.0.0.CR1)
> removeCache fails for caches with a SingleFileStore
> ---------------------------------------------------
>
> Key: ISPN-4446
> URL: https://issues.jboss.org/browse/ISPN-4446
> Project: Infinispan
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Affects Versions: 6.0.2.Final
> Reporter: Jim Crossley
> Assignee: Galder Zamarreño
> Fix For: 7.0.0.Alpha5, 7.0.0.Final
>
>
> If DefaultCacheManager.isRunning("foo") returns true, and "foo" has an associated SingleFileStore, calling DefaultCacheManager.removeCache("foo") tosses an NPE and isRunning("foo") continues to return true, even though the cache is in a TERMINATED state. I can avoid the NPE by stopping the cache before calling removeCache, but isRunning will still incorrectly return true.
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
10 years, 6 months
[JBoss JIRA] (ISPN-4446) removeCache fails for caches with a SingleFileStore
by Galder Zamarreño (JIRA)
[ https://issues.jboss.org/browse/ISPN-4446?page=com.atlassian.jira.plugin.... ]
Galder Zamarreño commented on ISPN-4446:
----------------------------------------
I've got a fix for this, but not sure if I'll be approved since it uses thread locals. See the PR link for comments on it.
> removeCache fails for caches with a SingleFileStore
> ---------------------------------------------------
>
> Key: ISPN-4446
> URL: https://issues.jboss.org/browse/ISPN-4446
> Project: Infinispan
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Affects Versions: 6.0.2.Final
> Reporter: Jim Crossley
> Assignee: Galder Zamarreño
> Fix For: 7.0.0.CR1, 7.0.0.Final
>
>
> If DefaultCacheManager.isRunning("foo") returns true, and "foo" has an associated SingleFileStore, calling DefaultCacheManager.removeCache("foo") tosses an NPE and isRunning("foo") continues to return true, even though the cache is in a TERMINATED state. I can avoid the NPE by stopping the cache before calling removeCache, but isRunning will still incorrectly return true.
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
10 years, 6 months
[JBoss JIRA] (ISPN-4542) Programmatic configuration doesn't have loaders() method
by Mikhail Dobrinin (JIRA)
Mikhail Dobrinin created ISPN-4542:
--------------------------------------
Summary: Programmatic configuration doesn't have loaders() method
Key: ISPN-4542
URL: https://issues.jboss.org/browse/ISPN-4542
Project: Infinispan
Issue Type: Enhancement
Security Level: Public (Everyone can see)
Affects Versions: 6.0.0.Final
Reporter: Mikhail Dobrinin
Assignee: Mircea Markus
Priority: Minor
The ConfigurationBuilder class does not actually have a {{loaders}} method. However, the documentation mentions it in a few places such as here -- http://infinispan.org/docs/6.0.x/user_guide/user_guide.html if you search for {{loaders()}} on the page. Also it's not clear to a user if it's possible to configure a custom cache loader programmatically because of this. I'm guessing it's not actually possible. That makes it hard to write tests with a mocked cacheloader.
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
10 years, 6 months