Nodes are mostly configuration helpers. For example, node script (pre_run.js actually) is responsible for creating URLs for any REST api call. They also execute data transforms.
In the nodes directory.
Simple nodes (synchronous nodes, like "split" and "search&replace") use current document as an input and create output based document and settings given.
Complex nodes (asynchronous or IO nodes, like import or lookup nodes) works in phases. The node first gives "orders" to GLAMpipe of how it should make a certain IO task (for example, make a request to web API). Then the result of this IO task gets back to node which processes it and then outputs the final value.
The distinction between simple and complex nodes is purely technical and the end user should know nothing about it.
The name of the output field (or fields) is defined when the node is created. This field(s) is added for all documents in the collection when the node is created.
This what happens when the user clicks the "run" button:
If node is a processing (i.e. not source node) node, then the name of the output field (or fields) is defined when the node is created. This field(s) is added for all documents in the collection when the node is created.
However, if the node is an import, export or view node, then there is no output fields.
This what happens when the user clicks the "run" button (DSpace import node):
If node is an import node, the collection is emptied from previous records imported by this node.
Web import nodes are a special case of complex nodes. There two ways of how importing data from web APIs work. The firt one is that the API gives a list of IDs based on query and then one must fetch the details of every id separately. The other way is that the query gives a paged result with full details and one must page repeat query .