Cumulus Java Classes 
Reference Documentation  
Version 11.1.7
  

Package com.canto.cumulus.server.esp

Introduction

See: Description

Package com.canto.cumulus.server.esp Description

Introduction

The Cumulus Server offers several Java APIs for developers. Plugins working with these APIs are called ESPs and are deployed in the Cumulus Server/esp folder. When starting up the server loads all plugins which register to one or more of the available registries. The currently available registries are:
API Summary
API Description
DBMirror
The DBMirror API must be implemented if you want to extend the mirroring functionality for another type of mirroring target.
Scheduler
The Scheduler API must be implemented if you want to provide your own plugin executed within the faceless Scheduler application.
Trigger
The Trigger API must be implemented if you want to provide your own trigger action.
Validator
The Validator API must be implemented if you want to provide your own validator for specific fields.
TableValidator
The TableValidator API must be implemented if you want to provide your own validator for entire items on a table when creating, saving or deleting such an item.

Build Environment

Writing a plugin for the Cumulus Server consists of two parts. The first part is executed inside the Server itself and does not have a complete CumulusJavaClasses environment available. Compiling this part must compile against the CumulusSC.jar and the ESPManager.jar shipped with the Cumulus Server. The second part is executed on the client side, whether it's the Client application, a web container or a CumulusTool and compiles just like any other CJC-based application against the CumulusJC.jar.

Deployment

The built classes are jarred into a yourespname.esp file which is copied into the CumulusServer/esp/youespname folder. The META_INF/MANIFEST.MF file must have a Main-Class entry pointing to the class which implements the ESP interface. Additional libraries must be copied into the CumulusServer/esp/youespname/lib folder. Those libraries will be automatically available for the ESP both on server and client side.

Registering custom functionality

The ESP interface provides the com.canto.cumulus.server.esp.ESP.initialize() method which should be used to register to one or more of the registries listed above. The following example shows how to register a custom scheduler job type:
            import com.canto.cumulus.GUID;
            import com.canto.cumulus.server.esp.ESP;
            import com.canto.cumulus.server.esp.ESPContext;
            import com.canto.cumulus.server.esp.modules.ServerRegistryManager;
            import com.canto.cumulus.server.esp.modules.scheduler.SchedulerRegistry;

            public class SchedulerJobsESP implements ESP
            {
                private static final GUID ID = new GUID ("{d1923ffe-49ba-470e-8e6a-af46ad4745d0}"); // replace with your own GUID

                public SchedulerJobsESP ()
                {
                }

                public void initialize (ESPContext context)
                {
                    ServerRegistryManager serverRegistryManager = ServerRegistryManager.getInstance ();
                    final SchedulerRegistry schedulerRegistry = serverRegistryManager.getSchedulerRegistry ();
                    schedulerRegistry.registerSchedulerESP (new CustomSchedulerJobABC ());
                }

                public void close ()
                {
                }

                public GUID getID ()
                {
                    return ID;
                }

                public String getName (int language)
                {
                    return "Custom Scheduler Job ABC";
                }
            }
            

© 2002-2021 Canto GmbH. All Rights Reserved.
Cumulus Java Classes 
Reference Documentation  
Version 11.1.7
  

www.canto.com
Canto, the Canto logo, the Cumulus logo, and Cumulus are registered trademarks of Canto GmbH, registered in the U.S. and other countries.