logging_xml » Revisions »
Differences
This shows you the differences between the selected revisions of the page.
2014-08-18 | 2014-09-11 | ||
the preferred + typo (martin) | in-page anchored links without page name (martin) | ||
Line 27: | Line 27: | ||
The top level ''session'' tag represents one logical session, which may consist of several physical sessions, particularly when connection is lost. Attribute ''name'' refers to name of the logical session. Attribute ''start'' indicates time when the session was initiated ((All timestamps in XML log have XML ''dateTime'' type, where only ''%%YYYY-MM-DD"T"HH:MM:SS.NNN"Z"%%'' syntax is used.)). | The top level ''session'' tag represents one logical session, which may consist of several physical sessions, particularly when connection is lost. Attribute ''name'' refers to name of the logical session. Attribute ''start'' indicates time when the session was initiated ((All timestamps in XML log have XML ''dateTime'' type, where only ''%%YYYY-MM-DD"T"HH:MM:SS.NNN"Z"%%'' syntax is used.)). | ||
- | The ''session'' element includes [[logging_xml#elements|child elements]], where each element represents single log entry, i.e. single physical operation with remote file over the logical session. | + | The ''session'' element includes [[#elements|child elements]], where each element represents single log entry, i.e. single physical operation with remote file over the logical session. |
===== [[operations]] Representing Operations in Log ===== | ===== [[operations]] Representing Operations in Log ===== | ||
Line 65: | Line 65: | ||
==== [[result_script]] Results/Errors of Script ==== | ==== [[result_script]] Results/Errors of Script ==== | ||
- | When the script fails (WinSCP [[scripting#using_scripting|exit code]] is 1), the top level ''session'' element or ''group'' element (when [[logging_xml#group|grouping]] is enabled) will include one or more ''failure'' elements, each containing one or more ''message'' elements with error message(s). | + | When the script fails (WinSCP [[scripting#using_scripting|exit code]] is 1), the top level ''session'' element or ''group'' element (when [[#group|grouping]] is enabled) will include one or more ''failure'' elements, each containing one or more ''message'' elements with error message(s). |
If the particular error was associated with a physical operation, the error message will be included both in ''result'' child element of the respective operation element and in ''failure'' child element of top level ''session'' element or ''group'' element. | If the particular error was associated with a physical operation, the error message will be included both in ''result'' child element of the respective operation element and in ''failure'' child element of top level ''session'' element or ''group'' element. | ||
Line 90: | Line 90: | ||
===== [[group]] Grouping Operations for Commands ===== | ===== [[group]] Grouping Operations for Commands ===== | ||
- | When using XML logging together with [[scripting|scripting]], [[logging_xml#elements|operations]] and [[logging_xml#result_script|failures]] belonging to the same command can be grouped using parent ''group'' element: | + | When using XML logging together with [[scripting|scripting]], [[#elements|operations]] and [[#result_script|failures]] belonging to the same command can be grouped using parent ''group'' element: |
<code xml> | <code xml> | ||
Line 124: | Line 124: | ||
===== [[elements]] Elements ===== | ===== [[elements]] Elements ===== | ||
- | All operation elements below have ''[[logging_xml#result|result]]'' child element in addition to listed child elements. | + | All operation elements below have ''[[#result|result]]'' child element in addition to listed child elements. |
The ''result'' child element is always present. Many other child elements may be absent in case of error. | The ''result'' child element is always present. Many other child elements may be absent in case of error. | ||
Line 309: | Line 309: | ||
^ Element ^ Description ^ | ^ Element ^ Description ^ | ||
| ''filename'' | Absolute path to remote file (in ''value'' attribute) | | | ''filename'' | Absolute path to remote file (in ''value'' attribute) | | ||
- | | ''file'' | Container of file attributes. See specification in description of ''[[logging_xml#ls|ls]]'' element. Note that ''file'' element within ''stat'' misses ''filename'' subelement, comparing to ''file'' element within ''ls''/''files''. | | + | | ''file'' | Container of file attributes. See specification in description of ''[[#ls|ls]]'' element. Note that ''file'' element within ''stat'' misses ''filename'' subelement, comparing to ''file'' element within ''ls''/''files''. | |
Example: | Example: | ||
Line 370: | Line 370: | ||
===== Example ===== | ===== Example ===== | ||
- | //Note that the ''[[logging_xml#group|group]]'' elements will be included, if enabled only.// | + | //Note that the ''[[#group|group]]'' elements will be included, if enabled only.// |
<code xml> | <code xml> |