func NewResponseWriterCounter(rw http.ResponseWriter) *ResponseWriterCounter {
	return &ResponseWriterCounter{
		ResponseWriter: rw,
		started:        time.Now(),
	}
}
NewResponseWriterCounter function create new ResponseWriterCounter
package handlers
import (
	"bufio"
	"fmt"
	"io"
	"net"
	"net/http"
	"sync/atomic"
	"time"
)
type ReaderCounter struct {
	r     io.ReadCloser
	count uint64
}
func NewReaderCounter(r io.ReadCloser) *ReaderCounter {
	return &ReaderCounter{
		r: r,
	}
}
func (counter *ReaderCounter) Read(buf []byte) (int, error) {
	n, err := counter.r.Read(buf)
	atomic.AddUint64(&counter.count, uint64(n))
	return n, err
}
func (counter *ReaderCounter) Count() uint64 {
	return atomic.LoadUint64(&counter.count)
}
func (counter *ReaderCounter) Close() error {
	return counter.r.Close()
}
type ResponseWriterCounter struct {
	http.ResponseWriter
	count   uint64
	started time.Time
}