public long written() {
        return buffer.appended() + byteBufferData;
    }
Returns the number of bytes written to this stream
container-core/src/main/java/com/yahoo/container/jdisc/ContentChannelOutputStream.java