Giter Club home page Giter Club logo

cos's People

Contributors

denist-huma avatar dmoles avatar dmolesuc avatar

Stargazers

 avatar  avatar

Watchers

 avatar

Forkers

denist-huma

cos's Issues

built-in key lists for keys command should be more systematic

The current set of key lists is fairly random and ad-hoc:

  1. Default: default source (as naughty-strings, filtering out "", ".", and leading "..", all of which are known to fail in Amazon S3) (500 keys)
  2. disallow-backslash: as default source, disallowing backlash (320 keys)
  3. disallow-double-backslash: as default source, disallowing double backlash (498 keys)
  4. misc: miscellenous potential problems, incl. path elements & unicode blocks (612 keys)
  5. naughty-strings: Big List of Naughty Strings (504 keys)

The naughty-strings list is fairly reasonable, although not all that directly applicable to filenames; it tends to produce a lot of redundant failures since many of its Javascript escapes and whatnot are very similar. A better, shorter list could probably be made by boiling it down to more general cases.

The misc list is pretty ad-hoc and doesn't cover every Unicode code block, or even most of them.

We should come up with some systematic cases and some systematic lists based on those cases.

crvd fails with TotalPartsExceeded on very large S3 objects

Steps to reproduce:

Execute the command below:

cos crvd -v s3://<BUCKET>/ --endpoint https://s3.us-west-2.amazonaws.com/ --size 1T

Expected:

Upload completes in about 4 hours (assuming a fast client network)

Actual

Upload fails at 50G with:

Error: MultipartUpload: upload multipart failed
	upload id: iuCCRxEvNJGjfH_ZoA30A1JyUqUxrZkyGJpymOIb8VWq1Yb.ysFPqMaGZQgvRDR4PjFdgsoKn8TvH.ZfoKTdyRMTkx442X9_gD8N5oMiHyLtoVSlPm_nfxY1o3Km.42le_ZTxp_1ZYwpOoqb4SbWcQ--
caused by: TotalPartsExceeded: exceeded total allowed configured MaxUploadParts (10000). Adjust PartSize to fit in this limit

keys command should accept keys from standard input

Passing - as a file argument should read keys from standard input, e.g.

cat mykeylist.txt | cos keys s3://uc3-s3mrt5001-stg/ \
  -e https://s3-us-west-2.amazonaws.com/ \
  --file -

If we want to do this right, we should probably put KeyList take a passed-in function and iterate over its own keys rather than having it expose a []string. This poses problems for KeyList.Count, but we don't use KeyList.Count much except for documentation and for final output.

Reduce log output

  • don't log progress by default
  • separate --verbose / -v and --very-verbose / -vv log levels
    • --verbose would include progress, IAM auth errors, other stuff? (go through uses of log.Detail and Detailf)
    • --very-verbose would include extra debug output like parsed parameters etc.

keys command should have more output formats

Currently the keys command outputs only either raw keys or quoted Go string literals. The first is problematic for keys with newlines or control characters; the second is Go-specific and somewhat confusing for anything involving a backslash; and also still exposes some sequences that can be problematic for viewing in a terminal, such as ANSI color escapes.

Offering strconv.QuoteToASCII as an option would mitigate some of the problems with the latter case, but probably shouldn't be the only additional option. What else makes sense—URL encoding? MIME quoted-printable? Base64?

Swift objects are read and hashed in 4K chunks, using a lot of CPU

Swift objects are read and hashed in 4K chunks, using a lot of CPU, and making the check process CPU-bound rather than IO-bound on fast connections.

This could be inherent to the Swift library we're using, or just Golang default behavior (see ncw/swift #132). But we can probably mitigate it by building up a larger slice before we pass it to the hash.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.