n8n/packages/nodes-base/nodes/Code
Iván Ovejero 6d6e2488c6
refactor(core): Generalize binary data manager interface (no-changelog) (#7164)
Depends on: #7092 | Story:
[PAY-768](https://linear.app/n8n/issue/PAY-768)

This PR: 
- Generalizes the `IBinaryDataManager` interface.
- Adjusts `Filesystem.ts` to satisfy the interface.
- Sets up an S3 client stub to be filled in in the next PR.
- Turns `BinaryDataManager` into an injectable service.
- Adjusts the config schema and adds new validators.

Note that the PR looks large but all the main changes are in
`packages/core/src/binaryData`.

Out of scope:
- `BinaryDataManager` (now `BinaryDataService`) and `Filesystem.ts` (now
`fs.client.ts`) were slightly refactored for maintainability, but fully
overhauling them is **not** the focus of this PR, which is meant to
clear the way for the S3 implementation. Future improvements for these
two should include setting up a backwards-compatible dir structure that
makes it easier to locate binary data files to delete, removing
duplication, simplifying cloning methods, using integers for binary data
size instead of `prettyBytes()`, writing tests for existing binary data
logic, etc.

---------

Co-authored-by: कारतोफ्फेलस्क्रिप्ट™ <aditya@netroy.in>
2023-09-22 17:22:12 +02:00
..
descriptions feat(Set Node): Overhaul (#6348) 2023-09-19 13:16:35 +03:00
test refactor(core): Generalize binary data manager interface (no-changelog) (#7164) 2023-09-22 17:22:12 +02:00
Code.node.json feat(Code Node): Add Python support (#4295) 2023-05-04 20:00:00 +02:00
Code.node.ts refactor(core): Deprecate prepareOutputData (no-changelog) (#7091) 2023-09-05 12:59:02 +02:00
ExecutionError.ts refactor(core): Remove linting exceptions in nodes-base (#4794) 2022-12-02 21:54:28 +01:00
JavaScriptSandbox.ts fix(Code Node): Disable WASM to address CVE-2023-37903 (#7122) 2023-09-06 16:11:39 +02:00
Pyodide.ts fix(Code Node): Install python modules always in a user-writable folder (#6568) 2023-07-07 16:43:45 +02:00
PythonSandbox.ts fix(Code Node): Consistent redirection of stdout for JS and Python sandboxes (#6818) 2023-08-01 17:47:43 +02:00
Sandbox.ts fix(Code Node): Consistent redirection of stdout for JS and Python sandboxes (#6818) 2023-08-01 17:47:43 +02:00
utils.ts feat(Code Node): Add Python support (#4295) 2023-05-04 20:00:00 +02:00
ValidationError.ts refactor(core): Remove linting exceptions in nodes-base (#4794) 2022-12-02 21:54:28 +01:00