@Override
    public void endProcessing() {
        // Ensure all destinations are returned.
        returnDestinations();

        for (final DestinationProvider destinationProvider : destinationProviders) {
            try {
                destinationProvider.endProcessing();
            } catch (final RuntimeException e) {
                fatal(e);
            }
        }

        super.endProcessing();
    }
Called by the pipeline when processing of a file is complete.

@see stroom.pipeline.filter.AbstractXMLFilter#endProcessing()
stroom-pipeline/src/main/java/stroom/pipeline/writer/AbstractWriter.java