Wiki Extension Plugin#

The Wiki Extension Plugin is part of the NeWikiPlugins but is not actually a WikiPlugin (and doesn't implement a functional execute() method), but it does implement the InitializablePlugin interface, which means that its initialize(WikiEngine method will be executed when the wiki starts up.

This is used solely to trigger instantiation of implementations of WikiExtension interface upon startup that have been included in the wiki's configuration file.

This is part of the NeWikiPlugins.

Wiki Extension API#

An API for a WikiEngine extension, to be instantiated upon wiki startup.


In order for implementations of this interface to be started along with the WikiEngine, you should include in the JSPWiki properties file a unique name that contains (anywhere) the string "wiki-extension", so that upon startup the property will be noticed by the scanner. Apart from the fragment the property name is otherwise ignored; the value is the fully-qualified package name of the class. For example:

In this case, an instance of both the EventManagerFactory and GraphResource will be created on startup.

There must also be a zero-argument constructor, or in the case of singletons, a static "getInstance()" method.

To use, be sure that this plugin is included in jspwiki_module.xml.

Service URLs#

These are typical URLs of the service endpoints. If the software were installed these would provide expected results...

  • http://localhost:9090/wiki/rest/graph/cypher : returns Cypher statements used to build a graph of the wiki
  • http://localhost:9090/wiki/rest/graph/nodes : returns JSON content for wiki pages-as-graph nodes
  • http://localhost:9090/wiki/rest/graph/edges : returns JSON content for wiki page links-as-graph edges