Skip to content

Commit

Permalink
Increase max operation count to 10 (#140)
Browse files Browse the repository at this point in the history
On lower end devices most operations end up being empty trash operations.
That issue needs to be addressed, but in the meantime, lets bump this
number up.
  • Loading branch information
garrettmoon authored Nov 2, 2016
1 parent df836fb commit 36b21b4
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion PINCache/PINCache.m
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,8 @@ - (instancetype)initWithName:(NSString *)name rootPath:(NSString *)rootPath seri
if (self = [super init]) {
_name = [name copy];

_operationQueue = [[PINOperationQueue alloc] initWithMaxConcurrentOperations:5];
//10 may actually be a bit high, but currently much of our threads are blocked on empyting the trash. Until we can resolve that, lets bump this up.
_operationQueue = [[PINOperationQueue alloc] initWithMaxConcurrentOperations:10];

_diskCache = [[PINDiskCache alloc] initWithName:_name rootPath:rootPath serializer:serializer deserializer:deserializer fileExtension:fileExtension operationQueue:_operationQueue];
_memoryCache = [[PINMemoryCache alloc] initWithOperationQueue:_operationQueue];
Expand Down

0 comments on commit 36b21b4

Please sign in to comment.