framework/common/servicedef/services_scipio.xml
<?xml version="1.0" encoding="UTF-8"?>
<!--
This file is subject to the terms and conditions defined in the
files 'LICENSE' and 'NOTICE', which are part of this source
code package.
-->
<services xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/services.xsd">
<description>SCIPIO: Common Application Services (New)</description>
<vendor>OFBiz</vendor>
<version>1.0</version>
<service name="reloadVisualThemeResources" engine="java"
location="com.ilscipio.scipio.common.CommonServices" invoke="reloadVisualThemeResources">
<description>SCIPIO: Reload visual theme definitions of specified theme or all themes if not specified</description>
<permission-service service-name="visualThemePermissionCheck" main-action="UPDATE"/>
<attribute name="visualThemeId" type="String" mode="IN" optional="true"/>
</service>
<!-- Scipio services: Common demo data generator interface.
Services must implement this interface in order to have the demo data generator using the common in/out attributes and also to be listed in the demoDataGenerator screen.
-->
<service name="demoDataGenerator" engine="interface">
<attribute name="dataGeneratorProviderId" type="String" mode="IN" optional="true" />
<attribute name="num" type="Integer" mode="IN" optional="true" default-value="50" />
<attribute name="minDate" type="Timestamp" mode="IN" optional="true"/>
<attribute name="maxDate" type="Timestamp" mode="IN" optional="true"/>
<attribute name="dataIntervalMs" type="Long" mode="IN" optional="true" default-value="0"/>
<attribute name="dataSeparateTrans" type="Boolean" mode="IN" optional="true" default-value="true"/>
<attribute name="generatedDataStats" type="java.util.List" optional="true" mode="OUT"/>
</service>
<!-- Scipio: FileListener services -->
<service name="startFileListener" auth="false"
engine="java" location="com.ilscipio.scipio.common.CommonServices" invoke="startFileListener">
<description>Service to boot up FileListeners on the system</description>
</service>
<service name="triggerFileEvent" auth="false"
engine="java" location="com.ilscipio.scipio.common.CommonServices" invoke="triggerFileEvent">
<description>An empty service, which is triggered once a file has changed inside of a filesystem. Can be used to trigger further events down the line.</description>
<attribute name="fileEvent" type="String" mode="IN" />
<attribute name="fileLocation" type="String" mode="IN" />
<attribute name="fileType" type="String" mode="IN" optional="true"/>
<attribute name="eventName" type="String" mode="IN" />
<attribute name="eventRoot" type="String" mode="IN" />
</service>
<!-- Cache Clearing services -->
<service name="clearFileCaches" engine="java" export="true"
location="com.ilscipio.scipio.common.CommonServices" invoke="clearFileCaches" auth="true">
<description>Looks up and clears cache based on a file location.</description>
<attribute name="fileLocation" type="String" mode="IN" optional="true"/>
<attribute name="fileType" type="String" mode="IN" optional="true"/>
<attribute name="cacheName" mode="IN" type="String"/>
</service>
<!-- Messages -->
<service name="createSystemMessage" engine="entity-auto" default-entity-name="SystemMessages" auth="true" invoke="create">
<description>Creates a new system message</description>
<auto-attributes include="pk" mode="IN" optional="false"/>
<auto-attributes include="nonpk" mode="IN" optional="true"/>
<auto-attributes include="pk" mode="OUT" optional="false"/>
</service>
<service name="sendWebsocketMessage" engine="java" auth="true" location="com.ilscipio.scipio.common.CommonServices" invoke="sendWebsocketMessage">
<description>Sends a message (preferrably json object) to connected clients</description>
<attribute name="channel" mode="IN" type="String"/>
<attribute name="message" mode="IN" type="String"/>
</service>
<service name="sendWebsocketObject" engine="java" auth="true" location="com.ilscipio.scipio.common.CommonServices" invoke="sendWebsocketObject">
<description>Converts a map to JSON and sends it to websocket clients</description>
<attribute name="channel" mode="IN" type="String"/>
<attribute name="data" mode="IN" type="Map"/>
</service>
<!-- Partial Screen renderer
removed for now: this cannot be called as request event due to security risk, so
do not want to encourage unless it finds some alternate use
<service name="renderPartialScreen" engine="java" export="true"
location="com.ilscipio.scipio.common.CommonServices" invoke="renderPartialScreen" auth="true">
<description>Renders a partial screen and returns the rendered String. Supported types: section|screen</description>
<attribute name="resource" mode="IN" type="String" optional="false" />
<attribute name="name" mode="IN" type="String" optional="false" />
<attribute name="type" mode="IN" type="String" optional="false" />
<attribute name="html" mode="OUT" type="String" optional="true" allow-html="any"/>
</service>
-->
</services>