Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Looking for java library for directories synchronization [closed]

I'm looking for a java library (not tool) that will provide synchronizing local directory with directory on server (ftp). What I need is to put a set of files on server and then I want all clients to have (download when required) the same version of these files.

I noticed that VFS depends on time of file modification. What I need is a library that will use mechanism like hash/delta. Something like rsync, but lib not tool.

like image 903
user759050 Avatar asked Nov 14 '22 23:11

user759050


1 Answers

Commons / VFS is an abstraction over different file systems and protocols (including FTP) with a common API. It has an ant task called SyncTask that synchronizes two virtual file systems (one or more of which can be a real file system). Ant task docs are here. Perhaps you can either use that or look into the underlying code.

like image 123
Sean Patrick Floyd Avatar answered Nov 23 '22 11:11

Sean Patrick Floyd