Skip to content

Refactor initialization of storages #85

@vdusek

Description

@vdusek

Description

  • Currently, if you want to initialize Dataset/KVS/RQ you should use open() constructor. And it goes like the following:
    • dataset.open()
    • base_storage.open()
    • dataset.__init__()
    • base_storage.__init__()
  • In the base_storage.open() a specific client is selected (local - MemoryStorageClient or cloud - ApifyClient) using StorageClientManager.
  • Refactor initialization of memory storage resource clients as well.

Desired state

  • Make it more readable, less error-prone (e.g. user uses a wrong constructor), and extensible by supporting other clients.

Metadata

Metadata

Assignees

Labels

debtCode quality improvement or decrease of technical debt.t-toolingIssues with this label are in the ownership of the tooling team.

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions