Shared folder implementation
<p>I need to make a shared folder in android.
I want to be able to:</p>

<p>1) create a folder on the device(sdcard/SharedFolder).  ;
2) create a folder on the server.  ;
3) copy some files to that folder.  ;
4) seamlessly synchronize those files with my Android(and vice-versa).  ;</p>

<p>The idea is to make an ftp connection to the ftp server(local filzila server at first) and
compare my local files list to his remote files list(by means of comparing timestamps or any other way).
Then my application would decide which files are the most updated and will copy them(from device to server or from the server to the device).</p>

<p>So i have 3 issues which i wanted to talk about:</p>

<p>I.Currently i made my application be a Broadcast-Receiver which is being called by the    Alarm-Manager repeatedly(with the inexact method) and run on its own process.
  Upon receiving a broadcast i connect to the server and make the above.
currently the broadcast-receiver is set from some Activity(enable/disable buttons and thats it.)</p>

<p>What will happen to my Broadcast-Receiver after killing the Activity which set him? I understood that at some point the system will delete him from the Alarm-Manager too? How should i handle this? I want the program to run without the user handling it... hence after restart of the device and etc i don't want him to re-enable my program.</p>

<p>II. How would you suggest to handle the files compare between the folders? i would like to support copy, delete, edit on those files hence the most suitable version of a file should be on both the server and device after the sync.
i thought about making some manifest file in each folder and save in it data on the file like: 
-who change it last and when
-how much readers does this file have(can it be done as a service of the phone? some event of opening a file or a folder?)
and etc.</p>

<p>III.
Any suggestions will be appreciated!</p>
