This section provides a very brief, very general overview to the ideas behind WebDAV. It should lay the foundation for understanding WebDAV compatibility issues between clients and servers.
Questa sezione fornisce una descrizione molto concisa e generica delle idee dietro WebDAV. Dovrebbe costituire la base per capire i problemi di compatibilità di WebDAV tra client e server.
RFC 2518 defines a set of concepts and accompanying extension methods to HTTP 1.1 that make the web into a more universal read/write medium. The basic idea is that a WebDAV-compliant web server can act like a generic file server; clients can mount shared folders that behave much like NFS or SMB filesystems.
RFC 2518 definisce un insieme di concetti e metodi di estensione accompagnatori a HTTP 1.1 che ha fatto del web un mezzo di lettura/scrittura piú universale. L'idea di base è che un server web compatibile con WebDAV può operare come file server generico; i client possono montare cartelle condivise che si comportano in modo simile a filesystem NFS o SMB.
The tragedy, though, is that the RFC 2518 WebDAV specification does not provide any sort of model for version control, despite the “V” in DAV. Basic WebDAV clients and servers assume only one version of each file or directory exists, and can be repeatedly overwritten.
Tuttavia, la tragedia è che l'RFC 2518 con le specifiche di WebDAV non fornisce nessuna sorta di modello per il controllo di versione, a dispetto della «V» in DAV. I client e i server base di WebDAV assumono che esista solamente una versione di ciascun file o directory, e che questa possa essere ripetutamente sovrascritta.
Here are the concepts and terms introduced in basic WebDAV:
Qui ci sono i concetti e i termini introdotti in WebDAV di base:
WebDAV lingo refers to any server-side object (that can be described with a URI) as a resource.
Il linguaggio di WebDAV si riferisce a ogni oggetto lato server (che può essere descritto con un URI) come una risorsa.
Beyond the standard HTTP PUT
method (which creates or overwrites a web resource),
WebDAV defines new COPY
and
MOVE
methods for duplicating or
rearranging resources.
Oltre al metodo standard PUT
di HTTP (che crea o sovrascrive una risorsa web),
WebDAV definisce i nuovi metodi COPY
e
MOVE
per duplicare o riorganizzare le
risorse.
A collection is the WebDAV
term for a grouping of resources. In most cases, it
is analogous to a directory. Whereas file resources
can be written or created with a
PUT
method, collection resources
are created with the new MKCOL
method.
Una collezione è il termine WebDAV
per un raggruppamento di risorse. Nella maggior parte dei casi,
è l'equivalente di una directory. Considerando che le risorse file
possono essere scritte o create con un metodo
PUT
, le risorse collezione
sono create con il nuovo metodo MKCOL
.
This is the same idea present in
Subversion—metadata attached to files and
collections. A client can list or retrieve properties
attached to a resource with the new
PROPFIND
method, and can change
them with the PROPPATCH
method.
Some properties are wholly created and controlled by
users (e.g. a property called “color”),
and others are wholly created and controlled by the
WebDAV server (e.g. a property that contains the last
modification time of a file). The former kind are
called dead properties, and the
latter kind are called live
properties.
Questa è la stessa idea presente in
Subversion—metadati annessi a file e
collezioni. Un client può elencare o recuperare le proprietà
annesse ad una risorsa con il nuovo metodo
PROPFIND
, e può modificarle
con il metodo PROPPATCH
.
Alcune proprietà sono interamente create e controllate dagli
utenti (es. una proprietà chiamata «colore»),
e altre sono interamente create e controllate dal
server WebDAV (es. una proprietà che contiene l'ora dell'ultima
modifica di un file). Le prime sono
chiamate proprietà morte, e le
ultime proprietà vive.
A WebDAV server may decide to offer a locking
feature to clients—this part of the
specification is optional, although most WebDAV
servers do offer the feature. If present, then
clients can use the new LOCK
and
UNLOCK
methods to mediate access to
a resource. In most cases these methods are used to
create exclusive write locks (as discussed in sezione chiamata «La soluzione blocca-modifica-sblocca (Lock-Modify-Unlock)»), although shared write
locks are also possible in some server
implementations.
Un server WebDAV può decidere di offrire una funzionalità di
bloccaggio ai client—questa parte della specifica è
opzionale, anche se la maggior parte dei server WebDAV
offrono questa caratteristica. Se presente, allora i
client possono usare i nuovi metodi LOCK
e
UNLOCK
per mediare l'accesso a una
risorsa. Nella maggior parte dei casi questi metodi sono utilizzati
per creare blocchi di scrittura esclusivi (come discusso in sezione chiamata «La soluzione blocca-modifica-sblocca (Lock-Modify-Unlock)»), anche se in
qualche implementazione
sono anche possibili blocchi di scrittura condivisa.
A more recent specification (RFC 3744) defines a system for defining access control lists (ACLs) on WebDAV resources. Some clients and servers have begun to implement this feature.
Una specifica più recente (RFC 3744) definisce un sistema per definire liste di controllo di accesso (ACL) su risorse WebDAV. Alcuni client e server hanno iniziato ad implementare questa caratteristica.
Because RFC 2518 left out versioning concepts, another committee was left with the responsibility of writing RFC 3253, which adds versioning to WebDAV, a.k.a. “DeltaV”. WebDAV/DeltaV clients and servers are often called just “DeltaV” programs, since DeltaV implies the existence of basic WebDAV.
Dato che RFC 2518 non si occupa dei concetti di versionamento, ad un altro comitato è stata lasciata la responsabilità di scrivere RFC 3253, la quale aggiunge il versionamento a WebDAV, anche conosciuta come «DeltaV». I client e i server WebDAV/DeltaV sono spesso chiamati solamente programmi «DeltaV», poiché DeltaV implica l'esistenza del WebDAV di base.
DeltaV introduces a whole slew of new acronyms, but don't be intimidated. The ideas are fairly straightforward:
DeltaV introduce un grande numero di nuovi acronimi, ma non c'è da spaventarsi. Le idee sono ragionevolmente dirette:
Like CVS and other version-control systems,
DeltaV assumes that each resource has a potentially
infinite number of states. A client begins by placing
a resource under version control using the new
VERSION-CONTROL
method.
Come CVS e altri sistemi di controllo di versione,
DeltaV assume che ogni risorsa ha potenzialmente un numero
infinito di stati. Un client inizia mettendo
una risorsa sotto controllo di versione utilizzando il nuovo metodo
VERSION-CONTROL
.
Some DeltaV servers support the ability to create
a virtual workspace on the server, where all of your
work is performed. Clients use the
MKWORKSPACE
method to create a
private area, then indicate they want to change
specific resources by “checking them out”
into the workspace, editing them, and “checking
them in” again. In HTTP terms, the sequence of
methods would be CHECKOUT
,
PUT
,
CHECKIN
.
Alcuni server DeltaV permettono di creare
un spazio di lavoro virtuale sul server, dove viene svolto
tutto il proprio lavoro. I client utilizzano il metodo
MKWORKSPACE
per creare un'area privata,
quindi indicano che vogliono cambiare specifiche risorse
«facendone il check out»
nello spazio di lavoro, le modificano, e «ne fanno il check in
». In termini HTTP, la sequenza di metodi
dovrebbe essere CHECKOUT
,
PUT
,
CHECKIN
.
Some DeltaV servers also support the idea that the
client may have a private working copy on local disk.
When the client wants to commit changes to the server,
it begins by creating a temporary server transaction
(called an activity) with the
MKACTIVITY
method. The client then
performs a CHECKOUT
on each
resource it wishes to change and sends
PUT
requests. Finally, the client
performs a CHECKIN
resource, or
sends a MERGE
request to check in
all resources at once.
Altri server DeltaV supportano anche l'idea che il
client possa avere una copia di lavoro privata sul disco locale.
Quando il client vuole fare il commit dei cambiamenti sul server,
inizia col creare una transazione temporanea con il server
(chiamata un'attività) con il metodo
MKACTIVITY
. Il client poi
esegue un CHECKOUT
su ogni
risorsa che vorrebbe cambiare e invia delle richieste
PUT
. Infine, il client
esegue un CHECKIN
della risorsa, o
invia una richiesta MERGE
per fare il check in
di tutte le risorse in una volta sola.
DeltaV allows you define flexible collections of resources called “configurations”, which don't necessarily correspond to particular directories. A configuration can be made to point to specific versions of files, and then a “baseline” snapshot can be made, much like a tag.
DeltaV permette di definire collezioni flessibili di risorse chiamate «configurazioni», che non corrispondono necessariamente a particolari directory. Una configurazione può essere creata per puntare a specifiche versioni di file, e poi può essere creata una fotografia «base», in modo molto simile a una targa.
DeltaV defines a new method,
REPORT
, which allows the client and
server to perform customized data exchanges. While
DeltaV defines a number of standardized history reports
that a client can request, the server is also free
to define custom reports. The client sends a
REPORT
request with a
properly-labeled XML body full of custom data; assuming
the server understands the specific report-type, it
responds with an equally custom XML body. This
technique is very similar to XML-RPC.
DeltaV definisce un nuovo metodo,
REPORT
, che permette al client e al
server di effettuare scambi di dati personalizzati. Mentre
DeltaV definisce un numero di report storici standardizzati
che un client può richiedere, il server è anche libero
di definire report personalizzati. Il client invia una richiesta
REPORT
con un corpo XML propriamente
etichettato pieno di dati personalizzati; assumendo
che il server capisca lo specifico tipo di report, risponde
con un corpo XML ugualmente personalizzato. Questa
tecnica è molto simile a XML-RPC.