Am using Apache Mina to build my own SFTP server. I want to notify a server automatically after each file transfer is complete. Please help me with some pointers in this direction.
Ideally, there should be an interface that I need to implement and a class where I need to register my call back function. I know that Apache MIna SSHD uses Apache Mina under the hood which has IO events, handlers and filters to accomplish this.
I am looking for something more concrete. Classes and method names to register my callback function would be pretty helpful.
I tried something similar using an earlier version of Mina SSHD. I ended up creating my own implementation of
FileSystemFactory
,FileSystemView
, andSshFile
. TheSshFile
interface has callback methods forcreate()
,delete()
,createOutputStream()
, etc. If someone has a simpler, more elegant solution I would be very interested to see it.