Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v2: Next major version #672

Merged
merged 100 commits into from
Sep 6, 2023
Merged

v2: Next major version #672

merged 100 commits into from
Sep 6, 2023

Conversation

Acconut
Copy link
Member

@Acconut Acconut commented Mar 1, 2022

Tasks to be done:

General

Hooks

  • docs: Update documentation about hooks
  • docs: Add plugin hooks to documentation
  • cli: Consider moving hooks in pkg/
  • cli: Add tests for hook implementations and system
  • handler: Allow modifying the HTTP response when stopping an upload
  • grpc: Add headers to hook request
  • grpc: Add documentation to proto files
  • grpc: Move proto file into better, public location
  • plugin: Stop zombie processes when tusd terminates
  • plugin: Move into public package. The plugin should not import for the cmd directory
  • plugin: Clean up hooks/plugin.go

Locking

  • Implement functionality for filelocker
  • Adapt implementation at tusd-etcd-locker
  • Add tests for new functionality in handler
  • Increase default read timeout to reduce their likelihood
  • Add documentation

S3

  • Upgrade to AWS SDK v2
  • Fix file already closed error (Close is already called by HTTP transport)

Testing

  • Thorough testing of filestore and s3store under bad network conditions

Release

  • Release notes (breaking changes, new features)
  • Blog post
  • Tweet

Acconut added 17 commits May 18, 2021 10:29
* Add first draft of parallel upload queue

* s3store: Use queue for parallel uploads

* Revert "Add first draft of parallel upload queue"

This reverts commit 86a329c.

* Revert "s3store: Use queue for parallel uploads"

This reverts commit 29b59a2.

* s3store: Cache results from listing parts and checking incomplete object

* s3store: Remove debugging output`

* s3store: Make requests for fetching info concurrently

* s3store: Make parallel uploads work and tests pass

* s3store: Add semaphore package

* s3store: Add comments to semaphore package

* s3store: Encapsulate more logic into s3PartProducer

* s3store: Refactor WriteChunk

* s3store: Remove TODO

* s3store: Acquire lock before uploading

* cli: Add flag for setting concurrency limit

* s3store: One more comment
@Acconut Acconut added the breaking change Backwards compatibility breaking change label Mar 1, 2022
* ci: Remove plugin hook handler

* Rework error type from interface to struct

* Avoid writing to http.ResponseWriter directly

* Allow hooks to modify response

* Add example for HTTP hooks using Python

* Implement new plugin system using Hashicorp/go-plugin

* Enable returning partial HTTPResponses

* Remove some (unnecessary) error handling

* Forward stdout and stderr from plugin to tusd

* docs: Update examples

* cli: Update filehooks to new system

* cli: Renovate gRPC hooks

* docs: Correct casing of gRPC

* misc: Documentation, better examples, and code structure
* handler: Implement prototype of new locking back-end

* memorylocker2: Switch to channel for release notification

* handler: Update locker interface

* handler: Add method to close body with error

* memorylocker: Replace with new implementation

* filelocker: Adjust methods to match interface

* handler: Introduce new httpContext

* handler: Implement upload interruption

* handler: Adjust tests to new inferfaces

* handler, memorylocker: Cancel context to avoid leaks
@oliverpool
Copy link
Contributor

Somewhere in your checklist, you should also add change go.mod to ../v2 and update internal references to .../v2 (see https://go.dev/doc/modules/major-version) - automated tool: https://github.com/marwan-at-work/mod

Currently the v2 is not importable as a go package:

~ go get github.com/tus/tusd@v2.0.0-rc8
go: github.com/tus/tusd@v2.0.0-rc8: invalid version: module contains a go.mod file, so module path must match major version ("github.com/tus/tusd/v2")
~ go get github.com/tus/tusd/v2@v2.0.0-rc8
go: github.com/tus/tusd@v2.0.0-rc8: invalid version: module contains a go.mod file, so module path must match major version ("github.com/tus/tusd/v2"

@Acconut
Copy link
Member Author

Acconut commented Apr 9, 2022

Thanks for the hint, @oliverpool. We need to look into this, you are right.

@Acconut Acconut marked this pull request as ready for review September 6, 2023 15:55
@Acconut
Copy link
Member Author

Acconut commented Sep 6, 2023

There are still some TODOs, but they can be addressed once this has been merged in main.

@Acconut Acconut merged commit a6f8a2b into main Sep 6, 2023
12 checks passed
@Acconut Acconut deleted the v2 branch September 6, 2023 15:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking change Backwards compatibility breaking change
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants