Process Flow
At a high level the process flow for search operations is simple: A Query is submitted to a Platform, which it turns into a request to the underlying data repository. The Platform implementation then turns that into an Appkit Response and returns.Configurability
Typically the platform will require configuration and initialisation parameters, which can be passed on for example, using the Generic Platform tag. A simple way of achieving this with your platform is to extend the AbstractPlatform class:twigkit.platform.AbstractQueryAdapter
andtwigkit.platform.AbstractResponseAdapter
classes help you to ensure that you map all of the critical components, so that the Appkit widgets can effectively work with the new data source.
After you have done this, your platform is a fully fledged member of the framework which will act and behave like any other supported platform, meaning that it will support the full range of features and can be plugged into any Appkit application, federated to, etc.
Deploying your Platform
You can refer to your platform by fully qualified class name in the Platform tag, as long as it is present on the application’s classpath. A more efficient method would be to package it so that it will be automatically instantiated and provided by Guice. To do that use for example, Maven to create a jar file for the platform, making sure this folder and file structure is included:twigkit.platform.Platform
file should contain a line delimited list of fully qualified class names of all the platforms in your jar. Doing this means that on start-up Appkit will dynamically load all available platforms and make them available for use via Guice injection.