Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
CMS Pipelines
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
==Example== A simple example that reads a disk file, separates records containing the string "Hello" from those that do not. The selected records are modified by appending the string "World!" to each of them; the other records are translated to upper case. The two streams are then combined and the records are written to a new output file. PIPE (end ?) < input txt | a: locate /Hello/ | insert / World!/ after | i: faninany | > newfile txt a ? a: | xlate upper | i: In this example, the <code><</code> stage reads the input disk file and passes the records to the next stage in the pipeline. The <code>locate</code> stage separates the input stream into two output streams. The primary output of <code>locate</code> (records containing Hello) passes the records to the <code>insert</code> stage. The <code>insert</code> stage modifies the input records as specified in its arguments and passes them to its output. The output is connected to <code>faninany</code> that combines records from all input streams to form a single output stream. The output is written to the new disk file. The secondary output of <code>locate</code> (marked by the second occurrence of the <code>a:</code> label) contains the records that did not meet the selection criterion. These records are translated to upper case (by the <code>xlate</code> stage) and passed to the secondary input stream of <code>faninany</code> (marked by the second occurrence of the <code>i:</code> label). The pipeline topology in this example consists of two connected pipelines. The ''end character'' (the <code>?</code> in this example) separates the individual pipelines in the pipeline set. Records read from the input file pass through either of the two routes of the pipeline topology. Because neither of the routes contain stages that need to buffer records, ''CMS Pipelines'' ensures that records arrive at <code>faninany</code> in the order in which they passed through <code>locate</code>. The example pipeline is presented in 'portrait form' with the individual stages on separate lines. When a pipeline is typed as a CMS command, all stages are written on a single line.
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)