anchor.diff:  
   Logger _libLogger = new Logger("dart_fpm");
   
  -//only for testing!!!
  -int counter = 0;
  -
   main() async {
     hierarchicalLoggingEnabled = true;
     Logger.root.level = Level.ALL;
  
positive.code:         .transform(new FcgiRecordTransformer())
          .listen((FcgiRecord record) {
        //TODO: implement record handling
        _libLogger.info(record.header.type.toString());
  
        FcgiRecord response;
  
        //only for testing
        counter++;
        if (counter < 4) return;
  
        //IMPORTANT: SEND CONTENT TYPE OF RETURN FIRST!!!
        response = new FcgiRecord.generateResponse(record.header.requestId,
            new FcgiStreamBody(FcgiRecordType.STDOUT, new AsciiCodec().encode("Content-type: text/html\r\n\r\n")));
  
        socketAdd(socket, response);
  
        response = new FcgiRecord.generateResponse(record.header.requestId,
            new FcgiStreamBody.fromString(FcgiRecordType.STDOUT, "Hello World!"));
  
        socketAdd(socket, response);
  
        response = new FcgiRecord.generateResponse(record.header.requestId,
            new FcgiStreamBody.fromString(FcgiRecordType.STDOUT,
                '''
                  <!DOCTYPE html>
  <html>
  <body>
  
  <h1>My First Heading</h1>
  
  <p>My first paragraph.</p>
  
  </body>
  </html>
  
  
                  '''
            ));
  
        socketAdd(socket, response);
  
        response = new FcgiRecord.generateResponse(record.header.requestId,
            new FcgiEndRequestBody(1, FcgiProtocolStatus.REQUEST_COMPLETE));
  
        socketAdd(socket, response);
  
      }, onError: (data) {
        //TODO: check if stream is already closed (SocketException)
  
negative.code:         return;
        }
  
        if (data is FcgiRecord) {
          int requestId = data.header.requestId;
          if (requestId != FCGI_NULL_REQUEST_ID) {
            socketAdd(socket, new FcgiRecord.generateResponse(requestId,
                new FcgiStreamBody.empty(FcgiRecordType.STDOUT)));
            socketAdd(socket, new FcgiRecord.generateResponse(requestId,
                new FcgiStreamBody.empty(FcgiRecordType.STDERR)));
          }
          socketAdd(socket, data);
        }
      });
    }
  }
  
  socketAdd(Socket socket, FcgiRecord record) {
    _libLogger.info("<- $record");
  
    socket.add(record.toByteStream());
  }