Connecting Apama Applications to External Components > Developing Custom Clients > The EngineClient API > The Java EngineClient API > Delete operations
Delete operations
The delete operations are defined in the interface com.apama.engine.beans.interfaces.DeleteOperationsInterface.
These are implemented in com.apama.engine.beans.EngineClientBean.
Note the distinctions between delete, forced delete, and kill:
*Delete works only if the EPL element being deleted (an event type or monitor) is not referenced by any other element. For example, you cannot delete an event type that is used by any monitors.
*Forced delete deletes the specified element as well as all other elements that refer to it. For example, if monitor A has listeners for B events and C events and you forcibly delete C events the operation deletes monitor A, which of course means that the listener for B events is also deleted.
*For monitors only, kill terminates all instances of the specified monitor regardless of whether an instance is performing any processing. For example, killing a monitor that is stuck in an infinite loop, would remove the monitor at the next loop iteration. Any ondie() and onunload() actions defined in killed monitors are not executed.
The delete operations are:
*void deleteAll() - Deletes everything from the remote correlator (or engine). This is equivalent to a deleteName being applied to everything.
*void deleteName(java.lang.String name, boolean force) - Delete an EPL event type or monitor (i.e., a name) from the remote correlator.
*void deleteNames(java.util.List<java.lang.String> names, boolean force) - Delete a number of EPL elements.
*void deleteNamesFromFile(java.util.List<java.lang.String> filenames, boolean force) - Delete a number of EPL elements listed in one or more filenames (or stdin).
*void deleteNamesFromFile(java.util.List<java.lang.String> filenames, boolean force, boolean utf8) - Delete a number of EPL elements listed in one or more filenames (or stdin).
*void killName(java.lang.String name) - Kill an EPL monitor in the remote correlator.
*void killNames(java.util.List<java.lang.String> names) - Kill a number of EPL monitors.
*void killNamesFromFile(java.util.List<java.lang.String> filenames) - Kill a number of EPL monitors listed in one or more filenames (or stdin).
*void setCancelDeleteFileRead(boolean newCancelFileReadValue) - Setter for the “cancelFileRead” property for the Delete / Kill operations. The purpose of the “cancelFileRead” property is to provide a mechanism to cleanly terminate the processing of deletion of elements from a file, when the deleteNamesFromFile method is in progress. When “cancelFileRead” is set to true, the deleting loop will terminate at the next iteration.
Copyright © 2013-2015 Software AG, Darmstadt, Germany and/or Software AG USA Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors.
Use, reproduction, transfer, publication or disclosure is prohibited except as specifically provided for in your License Agreement with Software AG.