Task #2957

Bug #2865: Reduce Keep server memory use

Review 2865-keep-memory-usage

Added by Tim Pierce over 6 years ago. Updated over 6 years ago.

Status:
Resolved
Priority:
Normal
Assigned To:
Tim Pierce
Category:
-
Start date:
05/26/2014
Due date:
% Done:

0%

Estimated time:
1.00 h

Description

Review @ 70dd308

Eliminated ioutil.ReadAll, which was naively allocating buffers 2x as large as necessary.

  • Rewrote main.PutBlockHandler to allocate a buffer of exactly req.ContentLength bytes, and fill it with io.ReadFull.
  • UnixVolume.Read now uses ioutil.ReadFile to read the contents of a block file (which it should have been doing in the first place)

History

#1 Updated by Ward Vandewege over 6 years ago

  • Assigned To set to Ward Vandewege

#2 Updated by Ward Vandewege over 6 years ago

  • Status changed from New to In Progress

#3 Updated by Ward Vandewege over 6 years ago

  • Assigned To changed from Ward Vandewege to Tim Pierce

#4 Updated by Tim Pierce over 6 years ago

  • Status changed from In Progress to Resolved
  • Remaining (hours) changed from 1.0 to 0.0

Also available in: Atom PDF