There are a wide variety of approaches for uploading and downloading files in SharePoint 2010. The following table provides a description of each and detailed considerations follow.
|
Approach |
Description |
|
|
WebDAV |
File management through HTTP |
|
|
Copy web service |
Out-of-the-box SharePoint web service |
|
|
FrontPage RPC |
FrontPage server extensions RPC protocol |
|
|
Client Object Model |
File operations available in the SharePoint 2010 Client Object Model |
|
|
Custom WCF Service |
Binary, MTOM, and Stream approaches with WCF |
|
Considerations
Each of the various approaches has strengths and weaknesses. The following sections provide a comparison.
WebDAV
Interoperability Considerations
· Other platforms
o Requires simple HTTP commands
· Web Friendly
o Requires simple HTTP commands
· Supports metadata upload
o No
· Sandbox Friendly
o No
Deployment Considerations
Deployment not required for service, just client
Security Considerations
Uses Windows credentials
Performance Considerations
· Message Size: Size of file
· Memory Usage: Good
· Throughput: Good
Maintenance Considerations
No significant considerations
Copy Service
Interoperability Considerations
· Other platforms
o Requires simple SOAP commands
· Web Friendly
o Requires simple SOAP commands
· Supports metadata upload
o No, use Lists web service in conjuntion
· Sandbox Friendly
o No
Deployment Considerations
Deployment not required for service, just client
Security Considerations
Uses Windows credentials
Performance Considerations
· Message Size: Size of file
· Memory Usage: Good
· Throughput: Good
Maintenance Considerations
Tied to SharePoint. May change in future versions.
FrontPage RPC
Interoperability Considerations
· Other platforms
o Uses command syntax that can be created by other applications
· Web Friendly
o Commands can be issued over a network
· Supports metadata upload
o Yes
· Sandbox Friendly
o No
Deployment Considerations
Deployment not required for service, just client
Security Considerations
Uses Windows credentials
Performance Considerations
· Message Size: Size of file
· Memory Usage: Good
· Throughput: Good
Maintenance Considerations
Available, but no longer recommended for use
Client Object Model
Interoperability Considerations
· Other platforms
o Only JavaScript client can be used by other platforms
· Web Friendly
o Uses WCF services
· Supports metadata upload
o Yes
· Sandbox Friendly
o Yes
Deployment Considerations
Requires a SharePoint solution
Security Considerations
Uses Windows credentials or forms-based authentication
Performance Considerations
· Message Size: Files.Add() uses BASE64 encoding. File.OpenBinaryDirect and File.SaveBinaryDirect use Streams
· Memory Usage: Good
· Throughput: Good
Maintenance Considerations
Tied to SharePoint. Could change in future versions.
Binary-Encoded WCF
Interoperability Considerations
· Other platforms
o Any WCF client
· Web Friendly
o Uses WCF
· Supports metadata upload
o Yes
· Sandbox Friendly
o No
Deployment Considerations
Requires a hosting process like IIS
Security Considerations
Uses Windows credentials, forms-based authentication, or anonymous
Performance Considerations
· Message Size: Size of file
· Memory Usage: Affected by buffer size
· Throughput: Good
Maintenance Considerations
Endpoint address can change
MTOM-Encoded WCF
Interoperability Considerations
· Other platforms
o Any WCF client
· Web Friendly
o Uses WCF
· Supports metadata upload
o Yes
· Sandbox Friendly
o No
Deployment Considerations
Requires a hosting process like IIS
Security Considerations
Uses Windows credentials, forms-based authentication, or anonymous
Performance Considerations
· Message Size: Larger than binary, smaller than Text Encoding
· Memory Usage: Affected by buffer size
· Throughput: Good
Maintenance Considerations
Endpoint address can change
Streaming WCF
Interoperability Considerations
· Other platforms
o Any WCF client
· Web Friendly
o Uses WCF
· Supports metadata upload
o No
· Sandbox Friendly
o No
Deployment Considerations
Requires a hosting process like IIS
Security Considerations
Uses Windows credentials, forms-based authentication, or anonymous
Performance Considerations
· Message Size: Streamed
· Memory Usage: Streamed
· Throughput: Excellent
Maintenance Considerations
Endpoint address can change