Skip to content

Filesystem plugin separation of concerns#912

Merged
dOrgJelli merged 29 commits intoprealpha-devfrom
pileks-fs-plugin-separation-of-concerns
Jun 24, 2022
Merged

Filesystem plugin separation of concerns#912
dOrgJelli merged 29 commits intoprealpha-devfrom
pileks-fs-plugin-separation-of-concerns

Conversation

@pileks
Copy link
Copy Markdown
Contributor

@pileks pileks commented Jun 10, 2022

Partially closes #622 and #714 (filesystem part)

After discussion with @nerfZael the following was done:

  • Introduced an interface for filesystem-like plugins
  • Extracted uri-resolver interface implementation from filesystem plugin into its own fs-uri-resolver plugin
  • Implemented basic filesystem plugin which implements the filesystem interface
  • Introduced a new build command for interfaces that follow the @web3api/*-interface pattern and added it to the main build command

Advice/feedback would be much appreciated!

@pileks pileks self-assigned this Jun 10, 2022
Comment thread packages/core-interfaces/filesystem/package.json Outdated
Comment thread packages/core-interfaces/filesystem/src/mutation.graphql Outdated
Comment thread packages/core-interfaces/filesystem/src/mutation.graphql Outdated
Comment thread packages/js/plugins/filesystem/src/mutation/index.ts Outdated
Comment thread packages/js/plugins/filesystem/src/mutation/index.ts Outdated
Comment thread packages/js/plugins/filesystem/src/query/index.ts Outdated
Comment thread packages/js/plugins/filesystem/src/__tests__/e2e.spec.ts Outdated
Comment thread packages/js/plugins/filesystem/src/__tests__/e2e.spec.ts Outdated
Comment thread packages/js/plugins/uri-resolvers/filesystem-resolver/src/query/index.ts Outdated
@pileks pileks marked this pull request as ready for review June 13, 2022 23:29
@pileks pileks marked this pull request as draft June 13, 2022 23:34
@pileks pileks marked this pull request as ready for review June 13, 2022 23:44
@pileks pileks linked an issue Jun 14, 2022 that may be closed by this pull request
@pileks pileks mentioned this pull request Jun 18, 2022
2 tasks
@pileks pileks requested a review from nerfZael June 22, 2022 09:17
Comment thread packages/core-interfaces/filesystem/package.json Outdated
Comment thread packages/js/plugins/uri-resolvers/filesystem-resolver/src/index.ts Outdated
Comment thread packages/js/plugins/uri-resolvers/filesystem-resolver/src/index.ts Outdated
Comment thread packages/js/plugins/uri-resolvers/filesystem-resolver/src/__tests__/e2e.spec.ts Outdated
Comment thread packages/js/plugins/filesystem/src/utils/encodingUtils.ts Outdated
Comment thread packages/js/plugins/filesystem/src/__tests__/e2e.spec.ts Outdated
Comment thread packages/js/plugins/filesystem/src/__tests__/e2e.spec.ts Outdated
Comment thread packages/js/plugins/filesystem/src/__tests__/e2e.spec.ts Outdated
Comment thread packages/js/plugins/filesystem/src/__tests__/e2e.spec.ts Outdated
Comment thread packages/js/plugins/filesystem/src/__tests__/e2e.spec.ts Outdated
@nerfZael
Copy link
Copy Markdown
Contributor

nerfZael commented Jun 22, 2022

After talking with @dOrgJelli we decided file system should be two words, so: FileSystem, fileSystem, file-system etc

Comment thread packages/js/plugins/filesystem/src/__tests__/e2e.spec.ts Outdated
Comment thread packages/js/plugins/filesystem/src/__tests__/e2e.spec.ts Outdated
Comment thread packages/js/plugins/filesystem/src/mutation/index.ts Outdated
Comment thread packages/js/plugins/uri-resolvers/filesystem-resolver/src/query/index.ts Outdated
Comment thread packages/core-interfaces/filesystem/src/schema.graphql
Comment thread packages/js/plugins/uri-resolvers/filesystem-resolver/src/__tests__/e2e.spec.ts Outdated
Comment thread packages/js/plugins/filesystem/src/utils/encodingUtils.ts Outdated
@@ -0,0 +1,46 @@
import { Filesystem_Encoding, Filesystem_EncodingEnum } from "../wrap";

export const filesystemEncodingToBufferEncoding = (
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would we then want to export default?

Comment thread packages/js/plugins/filesystem/src/__tests__/e2e.spec.ts Outdated
nerfZael
nerfZael previously approved these changes Jun 23, 2022
dOrgJelli
dOrgJelli previously approved these changes Jun 24, 2022
@dOrgJelli dOrgJelli merged commit 7b9d827 into prealpha-dev Jun 24, 2022
@dOrgJelli dOrgJelli deleted the pileks-fs-plugin-separation-of-concerns branch April 10, 2023 16:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Separate Concerns, IPFS/ENS Plugins, URI Resolver Interface

3 participants