package producer

import (
	"os"

	log "github.com/sirupsen/logrus"
)

func sizeOfFile(file string) int64 {
	fileInfo, err := os.Stat(file)
	if err != nil {
		log.Errorf("Failed to get file size: %v", err)
		return 0
	}
	return fileInfo.Size()
}
