Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Sample module for Infinispan

branch: master

Fetching latest commit…

Octocat-spinner-32-eaf2f5

Cannot retrieve the latest commit at this time

Octocat-spinner-32 src
Octocat-spinner-32 .gitignore
Octocat-spinner-32 README.md
Octocat-spinner-32 pom.xml
README.md

Sample Infinispan Module

The purpose of this sample module is to demonstrate the changes made to Infinispan in ISPN-256 to allow modules - such as query - to implement their own commands outside of the core module.

Status

This sample is a fully working sample and the sample usage class in src/test/java can be examined and even run to demonstrate custom commands working. TRACE level logging is recommended to examine what goes on.

Versions

For this to work, you currently need Infinispan 5.1.0.CR2 or higher.

Instructions for module authors

Here's what you need to do:

  • Create a org.infinispan.commands.module.ModuleCommandExtensions file in META-INF/services folder (see sample).
  • Declare implementation name of ModuleCommandExtensions implementation you've created for your module. Remember that this indirectly requires you to implement both ExtendedModuleCommandFactory and ModuleCommandInitializer.
  • Actually implement them to be able to construct your new commands.
  • Implement your commands and the rest of your module.
  • Add <module.skipComponentMetaDataProcessing>false</module.skipComponentMetaDataProcessing> property to your maven build pom file.
  • Run mvn -Dmaven.test.skip.exec=true install so that metadata index file is generated.
  • Implement MetadataFileFinder and provide the metadata file name that has been generated.
  • Create a org.infinispan.factories.components.ModuleMetadataFileFinder file in META-INF/services folder which the name of the class that implements MetadataFileFinder.

Any feedback please direct it to the Infinispan forums.

Something went wrong with that request. Please try again.