Handling large objects with WCF

Handling large objects with WCF

Postby s_tristan » Thu 13 Oct 2011 20:26

I want to optimize uploading/downloading a large binary files with WCF client (Silverlight) and PgSQL. Except loading/saving a file entirely that will decrease server's memory performance, I want to do the same chunk by chunk. This is most important in SaaS scenarios.
Can you provide a small code example with best practice how can I do that?
Thank you!
s_tristan
 
Posts: 9
Joined: Wed 06 Apr 2005 15:34

Postby Shalex » Tue 18 Oct 2011 15:40

An example of storing binary data in and retrieving them from a database is available at http://www.devart.com/dotconnect/postgresql/docs/?Devart.Data.PostgreSql~Devart.Data.PostgreSql.PgSqlBlob.html.
Shalex
Devart Team
 
Posts: 7774
Joined: Thu 14 Aug 2008 12:44

Postby s_tristan » Fri 21 Oct 2011 10:19

Thanks for the example, but is uses non-chunked method for storing/retrieving blobs. Is there an example with "chunking" blobs into parts?
s_tristan
 
Posts: 9
Joined: Wed 06 Apr 2005 15:34

Postby Shalex » Tue 25 Oct 2011 10:57

There is a possibility for storing/retrieving blob to/from PostgreSQL server only entirely (as a whole). But you can read/write blob from/to memory in parts using the Read()/Write() methods of the PgSqlBlob class.
Shalex
Devart Team
 
Posts: 7774
Joined: Thu 14 Aug 2008 12:44


Return to dotConnect for PostgreSQL