Solved

Synchronize files/directories via HTTP

Posted on 2001-06-11
3
178 Views
Last Modified: 2011-04-14
Can anyone tell me Is there any algorithm or source-code that synchronize files/directories via HTTP.

thanks.

Dan
0
Comment
Question by:walkdan
3 Comments
 
LVL 6

Accepted Solution

by:
snoegler earned 100 total points
ID: 6176502
There is the same algorithm as there is for synchronizing files via serial cable or via network or ...

HTTP offers to possibility to
- read only the HEADer information of a file
- GET a file
- PUT a file ( which is only supported - if at all - after being authenticated )

which are all methods you need to forward synchronize _files_. To my knowledge, there is no standardized HTTP command to create a directory, to remove a directory or to remove a file.

1. For each directory in the local directory, perform this 2. For each file in the local directory, use the HTTP HEAD command to test if it is available on the destination machine. If it is, compare the date/time of the file (which is also returned by HEAD). If equal, you should be able to assume that is hasn't been modified, and continue at 4.
3. Upload the file via HTTP PUT.
4. If there are any files left in the current directory, continue with 2.

This leaves all not anymore used files and directories on the server. To get around this, you could use FTP which allows all of the tasks to be performed; let me know if you want that.
0
 
LVL 11

Expert Comment

by:griessh
ID: 6814514
I think you forgot this question. I will ask Community Support to close it unless you finalize it within 7 days. Unless there is objection or further activity,  I will suggest to accept "snoegler" comment(s) as an answer.

If you think your question was not answered at all, you can post a request in Community support (please include this link) to refund your points.
The link to the Community Support area is: http://www.experts-exchange.com/jsp/qList.jsp?ta=commspt

Please do not accept this comment as an answer!
======
Werner
0
 
LVL 5

Expert Comment

by:Netminder
ID: 6833233
Per recommendation comment force/accepted by

Netminder
Community Support Moderator
Experts Exchange
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

Suggested Solutions

Unlike C#, C++ doesn't have native support for sealing classes (so they cannot be sub-classed). At the cost of a virtual base class pointer it is possible to implement a pseudo sealing mechanism The trick is to virtually inherit from a base class…
In days of old, returning something by value from a function in C++ was necessarily avoided because it would, invariably, involve one or even two copies of the object being created and potentially costly calls to a copy-constructor and destructor. A…
The goal of the tutorial is to teach the user how to use functions in C++. The video will cover how to define functions, how to call functions and how to create functions prototypes. Microsoft Visual C++ 2010 Express will be used as a text editor an…
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.

708 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now