aboutsummaryrefslogtreecommitdiff
path: root/object.go
Commit message (Collapse)AuthorAgeFilesLines
* add ctx argument to Account.CapabilitiesStefan Majewsky2024-07-081-4/+4
|
* Remove context from struct, add ctx as first args to many functionsSandro Jäckel2024-07-011-27/+28
|
* Fix remaining lintsSandro Jäckel2024-07-011-3/+4
|
* Fix gophercloud lint complainsSandro Jäckel2024-07-011-40/+40
|
* Fix remaining lintsSandro Jäckel2023-10-251-10/+16
|
* remove sha512 as a tempurl digest optionStefan Majewsky2022-10-281-4/+1
| | | | | | | After consulting the Swift source code, we learned that sha512 signatures are formatted using a different scheme. Since sha512 offers no real advantage at this point as long as we support sha256 instead, we can just avoid the complexity of supporting the other scheme for now.
* Generate digest preferable with sha2, then sha512 and fallback to insecure sha1Sandro Jäckel2022-10-281-1/+29
|
* Fix linting errorsSandro Jäckel2022-10-281-15/+27
|
* Format with go 1.19Sandro Jäckel2022-10-261-105/+104
|
* rename Object.UploadWithWriter to UploadFromWriterStefan Majewsky2021-05-281-6/+4
|
* document non-threadsafetyStefan Majewsky2020-10-141-0/+12
|
* Cover more readers for automatic tag calculationFabian Ruff2018-09-031-9/+2
| | | | | Not sure If I'm missing something but this seems more general (specifically it covers `*os.File` which doesn't have a `WriteTo` method). Note: This is untested. Just putting it up for discussion.
* add Object.TempURL()Stefan Majewsky2018-07-101-0/+50
|
* add URL() method also to Container, not just to ObjectStefan Majewsky2018-06-071-1/+3
|
* Merge pull request #4 from databus23/patch-1Stefan Majewsky2018-06-071-0/+8
|\ | | | | Add URL() function for Object
| * Add URL() function for ObjectFabian Ruff2018-05-111-0/+8
| |
* | make the IsEqualTo() methods publicStefan Majewsky2018-05-301-1/+6
| |
* | adjust semantics of Object.InspectSymlink, rename to Object.SymlinkHeadersStefan Majewsky2018-05-301-9/+21
|/ | | | | | The additional guarantee that Object.SymlinkHeaders becomes equivalent to Object.Headers for non-symlinks will be useful e.g. for swift-http-import's usecase.
* add support for symlinks to ObjectIteratorStefan Majewsky2018-05-071-0/+5
| | | | Closes #2.
* add Object.SymlinkTo(), Object.InspectSymlink() etc.Stefan Majewsky2018-05-071-23/+111
|
* proof-read documentationStefan Majewsky2018-05-031-9/+15
|
* add (currently empty) CopyOptions arg to Object.CopyToStefan Majewsky2018-05-021-5/+11
| | | | | For backwards compatiblity when later expanding the scope of this function (analogous to DeleteOptions, UploadOptions, TruncateOptions).
* remove Object.MoveToStefan Majewsky2018-05-021-12/+0
| | | | | It's trivially replicable by clients, and has an ugly API that I don't want to commit on at this point.
* test coverage for large object operationsStefan Majewsky2018-05-021-2/+2
|
* revamp the LargeObject APIStefan Majewsky2018-05-021-16/+59
| | | | | | | | | | I thought about this some more, and I believe the Writer-based approach in the previous version of the LargeObject API does not scale: It makes it very hard to write code that uploads segments without resorting to a buffer the same size as the segments. I don't want gigabyte-scale buffers filling up my RAM, so this commit switches to a different API based on Readers. LargeObject.Append() now behaves very similar to Object.Upload(), which I find quite nice.
* add DeleteOptions to Object.Delete()Stefan Majewsky2018-04-301-4/+36
|
* initial support for large objectsStefan Majewsky2018-04-301-7/+15
| | | | | | | | | | | | This has gone through a lot of iterations on my branch, and I'm quite happy with the parts of the API that exist now. Test coverage can still be better, and will get better in the following commits. The API is not yet finished: I want to add Options arguments to Object.Upload(), Object.Copy(), Object.Move() and Object.Delete() that specify how each of these operations affect existing segments (and, later, also existing symlinks). For Upload(), uploading in segments shall become as easy as flipping a single switch.
* tryCompute{ContentLength, Etag}: add special cases for strings.Reader, nilStefan Majewsky2018-04-271-6/+20
|
* revamp the Headers APIStefan Majewsky2018-03-111-31/+24
| | | | | | | | | | | | | | | | | | 1. Move common methods of AccountHeaders, ContainerHeaders, ObjectHeaders into a base type Headers. 2. Fold Headers into RequestOptions to remove one of the two optional arguments on request methods. The new Headers.ToOpts() method offers a nice experience for users passing Headers to request methods. The Update() methods keep the explicit Headers argument since the Headers argument is not optional there. The only downside is that we lose a bit of type-safety because RequestOptions takes any Headers instance, so e.g. ContainerHeaders could be passed to Object.Upload(). I believe the benefits outweigh this problem.
* generalize BulkUploadError into BulkErrorStefan Majewsky2018-03-081-0/+2
| | | | For use in Account.BulkDelete().
* fix a panic in the error case of Object.Download()Stefan Majewsky2018-03-081-1/+3
|
* add Object.Copy() and Object.Move()Stefan Majewsky2018-02-211-8/+55
|
* reorganize codeStefan Majewsky2018-02-191-5/+5
| | | | | | * Gophercloud dependencies move into subpackage gopherschwift. * Tests move into subpackage tests (to avoid import cycles). + Rename "Client" to "Backend".
* test coverage for object upload, download, metadata updateStefan Majewsky2018-02-191-2/+37
|
* add Object.Download(), DownloadedObjectStefan Majewsky2018-02-191-1/+31
|
* initialize .Headers on accounts/containers during GET requestsStefan Majewsky2018-02-191-1/+1
|
* Object.upload: generate, validate Content-Length and EtagStefan Majewsky2018-02-161-5/+87
|
* add object lifecycle testcaseStefan Majewsky2018-02-161-4/+6
|
* ensure that response body is drainedStefan Majewsky2018-02-111-0/+1
|
* sketch out the initial Object APIStefan Majewsky2018-02-101-0/+181