-
Notifications
You must be signed in to change notification settings - Fork 23
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: delete buffer from cache when released
- Loading branch information
1 parent
e6afb04
commit 38d7c8d
Showing
12 changed files
with
57 additions
and
79 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 0 additions & 2 deletions
2
src/apps/fuse/dependency-injection/offline/BoundaryBridge/BoundaryBridgeContainer.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,5 @@ | ||
import { OfflineFileAndContentsCreator } from '../../../../../context/offline-drive/boundaryBridge/application/OfflineFileAndContentsCreator'; | ||
import { OfflineFileUploader } from '../../../../../context/offline-drive/boundaryBridge/application/OfflineFileUploader'; | ||
|
||
export interface BoundaryBridgeContainer { | ||
offlineFileAndContentsCreator: OfflineFileAndContentsCreator; | ||
offlineFileUploader: OfflineFileUploader | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
29 changes: 0 additions & 29 deletions
29
src/context/offline-drive/boundaryBridge/application/OfflineFileUploader.ts
This file was deleted.
Oops, something went wrong.
9 changes: 9 additions & 0 deletions
9
src/context/offline-drive/contents/application/OfflineContentsCacheCleaner.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
import { ContentsRepository } from '../domain/ContentsRepository'; | ||
|
||
export class OfflineContentsCacheCleaner { | ||
constructor(private readonly repository: ContentsRepository) {} | ||
|
||
run(contentsPath: string): Promise<void> { | ||
return this.repository.forget(contentsPath); | ||
} | ||
} |
2 changes: 1 addition & 1 deletion
2
src/context/offline-drive/contents/domain/ContentsRepository.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
export interface ContentsRepository { | ||
read(path: string): Promise<Buffer>; | ||
|
||
forget(path: string): void; | ||
forget(path: string): Promise<void>; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 0 additions & 30 deletions
30
tests/context/offline-drive/boundaryBridge/OfflineFileUploader.test.ts
This file was deleted.
Oops, something went wrong.