I'm writing a long running task which fetch from mongodb (using mgo) multiple times. Then write it to an xlsx file using this module. Then read it again using
os.Open then store it to my ftp server.
Stor function consume my memory so much, So I think there should be a way not to save file but pass my data from xlsx.Write to ftp.Store directly. (If I can stream simultaneously would be perfect because I don't have to hold all of my documents in server's memory before send them to Stor function)
These are prototype of the functions
func (f *File) Write(writer io.Writer) (err error) xlsl
func (ftp *FTP) Stor(path string, r io.Reader) (err error) ftp