[JBoss JIRA] Created: (ISPN-281) REST server should be configurable
by Manik Surtani (JIRA)
REST server should be configurable
----------------------------------
Key: ISPN-281
URL: https://jira.jboss.org/jira/browse/ISPN-281
Project: Infinispan
Issue Type: Bug
Components: Cache Server
Affects Versions: 4.0.0.CR2
Reporter: Manik Surtani
Assignee: Michael Neale
Fix For: 4.0.0.GA
Currently the WAR file we build and distribute uses a static cache configuration, embedded in the WAR file. We need to think of a way to have this configurable. One idea would be to ship with, say, 5 different config files in the WAR:
* cache-local.xml
* cache-dist-sync.xml
* cache-dist-async.xml
* cache-repl-sync.xml
* cache-repl-async.xml
... and the servlet starts the appropriate config based on JVM params (eg., -Dinfinispan.server.rest.cfg=cache-local.xml)
Also, cache-local.xml should be the default since running the WAR file with incorrect or inappropriate cluster settings prevents startup.
Finally perhaps there should be a way to customise the cfg even further - perhaps the default web page could offer a way to upload a config file and restart the cache using this instead?
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 11 months
[JBoss JIRA] Created: (ISPN-321) NPE if custom interceptor is created from xml configuration
by Alexander Kosenkov (JIRA)
NPE if custom interceptor is created from xml configuration
-----------------------------------------------------------
Key: ISPN-321
URL: https://jira.jboss.org/jira/browse/ISPN-321
Project: Infinispan
Issue Type: Bug
Components: Configuration
Affects Versions: 4.0.0.CR3
Reporter: Alexander Kosenkov
Assignee: Manik Surtani
Add to config something like this:
<customInterceptors>
<interceptor after="org.infinispan.interceptors.CacheLoaderInterceptor" class="com.devexperts.PersistenceInterceptor"/>
</customInterceptors>
and it will fail Caused by: java.lang.NullPointerException
at org.infinispan.interceptors.InterceptorChain.addInterceptorAfter(InterceptorChain.java:193)
at org.infinispan.factories.InterceptorChainFactory.buildCustomInterceptors(InterceptorChainFactory.java:161)
at org.infinispan.factories.InterceptorChainFactory.buildInterceptorChain(InterceptorChainFactory.java:143)
at org.infinispan.factories.InterceptorChainFactory.construct(InterceptorChainFactory.java:177)
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 11 months
[JBoss JIRA] Created: (ISPN-245) Core module to delegate lifecycle events to sub-modules
by Manik Surtani (JIRA)
Core module to delegate lifecycle events to sub-modules
-------------------------------------------------------
Key: ISPN-245
URL: https://jira.jboss.org/jira/browse/ISPN-245
Project: Infinispan
Issue Type: Feature Request
Components: Core API
Reporter: Manik Surtani
Assignee: Manik Surtani
Fix For: 4.1.0.BETA1, 4.1.0.GA
Follow a 'service registry' style approach to delegating lifecycle events so that modules can register for hooks. The purpose behind this is that some modules need to perform some setup. E.g., the 'tree' module needs to register specific types with the Marshaller. The 'query' module needs to register an interceptor with the Cache if the Cache has enabled querying. Etc.
The approach is to use a JDK service registry style approach. The Core module defines a ModuleLifecycle interface:
interface ModuleLifecycle {
void cacheManagerStarting(GlobalComponentRegistry gcr);
void cacheManagerStarted(GlobalComponentRegistry gcr);
void cacheManagerStopping(GlobalComponentRegistry gcr);
void cacheManagerStopped(GlobalComponentRegistry gcr);
void cacheStarting(ComponentRegistry cr, String cacheName);
void cacheStarted(ComponentRegistry cr, String cacheName);
void cacheStopping(ComponentRegistry cr, String cacheName);
void cacheStopped(ComponentRegistry cr, String cacheName);
}
each module would implement this interface.
"Registration" is performed by each module maintaining a infinispan-module-info.properties file in its classpath, containing:
infinispan.module.lifecycle=<ModuleLifecycle impl>
The DefaultCacheManager, when starting up, scans its classpath for "infinispan-module-info.properties" and registers all listeners. Everytime the cache manager starts, stops, or caches start or stop, the appropriate callbacks are invoked.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 11 months
[JBoss JIRA] Created: (ISPN-324) Cache.clear() raises a NPE if CahceMode is DIST_SYNC and NumOwners is set to 1
by Marco Ferrante (JIRA)
Cache.clear() raises a NPE if CahceMode is DIST_SYNC and NumOwners is set to 1
------------------------------------------------------------------------------
Key: ISPN-324
URL: https://jira.jboss.org/jira/browse/ISPN-324
Project: Infinispan
Issue Type: Bug
Affects Versions: 4.0.0.CR3
Reporter: Marco Ferrante
Assignee: Manik Surtani
Priority: Minor
This fragment:
GlobalConfiguration gc = GlobalConfiguration.getClusteredDefault();
Configuration config = new Configuration();
config.setCacheMode(Configuration.CacheMode.DIST_SYNC);
config.setNumOwners(1); // no redundancy
CacheManager cacheManager = new DefaultCacheManager(gc, config);
Cache cache = cacheManager.getCache();
cache.put("key", "value");
cache.clear();
assert cache.isEmpty();
raises a NullPointerException at cache.clear() invokation.
It works correctly both using other cache modes (LOCAL, REPL and INVALIDATION) or avoiding to set config.setNumOwners to 1.
The stacktrace is:
java.lang.NullPointerException
at org.infinispan.interceptors.DistributionInterceptor.isSingleOwnerAndLocal(DistributionInterceptor.java:317)
at org.infinispan.interceptors.DistributionInterceptor.handleWriteCommand(DistributionInterceptor.java:276)
at org.infinispan.interceptors.DistributionInterceptor.visitClearCommand(DistributionInterceptor.java:180)
at org.infinispan.commands.write.ClearCommand.acceptVisitor(ClearCommand.java:58)
at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:118)
at org.infinispan.interceptors.LockingInterceptor.visitClearCommand(LockingInterceptor.java:169)
at org.infinispan.commands.write.ClearCommand.acceptVisitor(ClearCommand.java:58)
at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:118)
at org.infinispan.interceptors.base.CommandInterceptor.handleDefault(CommandInterceptor.java:132)
....
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 11 months