UNPKG

node-red-contrib-snap4city-user

Version:

Nodes for Snap4city project, targeted to standard user (no developer)

101 lines (94 loc) 4.05 kB
<!--/* NODE-RED-CONTRIB-SNAP4CITY-USER Copyright (C) 2018 DISIT Lab http://www.disit.org - University of Florence This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see <http://www.gnu.org/licenses/>. */--> <script type="text/javascript"> RED.nodes.registerType('event-log', { category: 'S4CLogDev', color: '#C0C0C0', defaults: { name: { value: "" }, modcom: { required: true }, motivation: { required: true } }, outputs: 2, inputs: 1, outputLabels: ["original message", "log result"], icon: "debug.png", label: function () { return this.name || "event-log"; } }); </script> <script type="text/x-red" data-template-name="event-log"> <div class="form-row"> <label for="node-input-name">Name</label> <input type="text" autocomplete="off" id="node-input-name" placeholder="Name"> </div> <div class="form-row"> <label for="node-input-modcom">Communication Mode</label> <select id="node-input-modcom"> <option value="TX">TX</option> <option value="RX">RX</option> </select> </div> <div class="form-row"> <label for="node-input-motivation">Motivation</label> <select id="node-input-motivation"> <option value="External_Service">External Service</option> <option value="IoT_Service">IoT Service</option> <option value="Dashboard">Dashboard</option> <option value="ASCAPI">ASCAPI</option> <option value="DB_Storage">DB Storage</option> <option value="FileSystem_Storage">FileSystem Storage</option> <option value="Message_Count">Message Count</option> <option value="User_Count">User Count</option> <option value="IoT_Count">IoT Count</option> <option value="Message_Control">Message Control</option> </select> </div> </script> <script type="text/x-red" data-help-name="event-log"> <p>API-GET per logging event-driven su Snap4City-Rsyslog-SERVER:</p> <h3>Configurations</h3> <dl class="message-properties"> <dt>communication mode <span class="property-type">string</span> </dt> <dd> parameter that indicates whether the LOG block is related to an event in transmission (TX) - e. g. at the head of a NodeRED workflow/application - or in reception (RX) - e. g. at the tail of a NodeRED workflow/application -.</dd> <dt>mootivation <span class="property-type">string</span> </dt> <dd> String encoded through appropriate values that identifies the intent or motivation (high level) of the process / Microservice / Application / Local ETL. In a certain sense it identifies the type of operation performed or requested, for future indexing and filtering of events.</dd> </dl> <h3>Outputs</h3> <ol class="node-ports"> <li>Original Payload <dl class="message-properties"> <dd> The input payload is used to log in and return intact outgoing.</dd> </dl> </li> <li>Response of log <dl class="message-properties"> <dd> The result of the logging operation</dd> </dl> </li> </ol> </script>