aboutsummaryrefslogtreecommitdiffstats
path: root/storage/filesystem/object_test.go
Commit message (Collapse)AuthorAgeFilesLines
* filesystem: add a new test for EncodedObjectSizeJeremy Stribling2018-10-121-0/+14
| | | | | | Suggested by taruti. Signed-off-by: Jeremy Stribling <strib@alum.mit.edu>
* object: get object size without reading whole objectJeremy Stribling2018-10-111-0/+24
| | | | Signed-off-by: Jeremy Stribling <strib@alum.mit.edu>
* storage/filesystem: keep packs open in PackfileIterJavi Fontan2018-09-201-4/+40
| | | | | | | | PackfileIter was not taking into account the option KeepDescriptors and was always closing the file. This caused "file already closed" errors when iterating packfiles in with KeepDescriptors active. Signed-off-by: Javi Fontan <jfontan@gmail.com>
* Expose Storage cache.kuba--2018-09-071-17/+8
| | | | Signed-off-by: kuba-- <kuba@sourced.tech>
* storage/filesystem: compare files using offset in testJavi Fontan2018-09-061-1/+7
| | | | | | | | Using equals to compare files it uses diff to do so. This can potentially consume lots of ram. Changed the comparison to use file offsets. If the descriptor is reused the offset is maintained. Signed-off-by: Javi Fontan <jfontan@gmail.com>
* storage/filesystem: add KeepDescriptors testJavi Fontan2018-09-051-0/+31
| | | | | | Also delete Close from MockObjectStorage and memory storer. Signed-off-by: Javi Fontan <jfontan@gmail.com>
* plumbing: packfile, open and close packfile on FSObject readsMiguel Molina2018-08-091-3/+37
| | | | Signed-off-by: Miguel Molina <miguel@erizocosmi.co>
* storage: filesystem, add PackfileIter benchmark reading object contentMiguel Molina2018-08-091-0/+67
| | | | Signed-off-by: Miguel Molina <miguel@erizocosmi.co>
* storage: filesystem, benchmark PackfileIterMiguel Molina2018-08-091-11/+68
| | | | Signed-off-by: Miguel Molina <miguel@erizocosmi.co>
* *: use parser to populate non writable storages and bug fixesMiguel Molina2018-08-071-1/+5
| | | | Signed-off-by: Miguel Molina <miguel@erizocosmi.co>
* storage: filesystem, make ObjectStorage constructor publicMiguel Molina2018-06-081-5/+5
| | | | Signed-off-by: Miguel Molina <miguel@erizocosmi.co>
* dotgit: Move package outside internal.Antonio Jesus Navarro Perez2018-06-051-1/+1
| | | | Signed-off-by: Antonio Jesus Navarro Perez <antnavper@gmail.com>
* update to go-billy.v4 and go-git-fixtures.v3Máximo Cuadros2017-11-231-1/+1
| | | | Signed-off-by: Máximo Cuadros <mcuadros@gmail.com>
* storage: reuse deltas from packfilesSantiago M. Mola2017-07-271-2/+2
| | | | | | | | | | | | | | | | | | | * plumbing: add DeltaObject interface for EncodedObjects that are deltas and hold additional information about them, such as the hash of the base object. * plumbing/storer: add DeltaObjectStorer interface for object storers that can return DeltaObject. Note that calls to EncodedObject will never return instances of DeltaObject. That requires explicit calls to DeltaObject. * storage/filesystem: implement DeltaObjectStorer interface. * plumbing/packfile: packfile encoder now supports reusing deltas that are already computed (e.g. from an existing packfile) if the storage implements DeltaObjectStorer. Reusing deltas boosts performance of packfile generation (e.g. on push).
* project: move imports from srcd.works to gopkg.inAntonio Jesus Navarro Perez2017-03-071-2/+2
| | | | To be able to fix #261 we will move again to gopkg.in before v4 stable release.
* new srcd.works/go-git.v4 pathMáximo Cuadros2017-01-301-2/+2
|
* new git fixture pathMáximo Cuadros2017-01-301-1/+1
|
* packfile/decoder: speed up packfile iterator when specific type (#200)Antonio Navarro Perez2017-01-121-11/+48
|
* move plumbing from top level package to plumbing (#183)Santiago M. Mola2016-12-141-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | * plumbing: rename Object -> EncodedObject. * plumbing/storer: rename ObjectStorer -> EncodedObjectStorer. * move difftree to plumbing/difftree. * move diff -> utils/diff * make Object/Tag/Blob/Tree/Commit/File depend on storer. * Object and its implementations now depend only on storer.EncodedObjectStorer, not git.Repository. * Tests are decoupled accordingly. * move Object/Commit/File/Tag/Tree to plumbing/object. * move Object/Commit/File/Tag/Tree to plumbing/object. * move checkClose to utils/ioutil. * move RevListObjects to plumbing/revlist.Objects. * move DiffTree to plumbing/difftree package. * rename files with plural nouns to singular * plumbing/object: add GetBlob/GetCommit/GetTag/GetTree.
* new plumbing package (#118)Máximo Cuadros2016-11-081-12/+12
| | | * plumbing: now core was renamed to core, and formats and clients moved inside
* global storage interface refactor (#112)Máximo Cuadros2016-11-071-4/+4
| | | | | | | | | | | * core: ObjectStorage, ReferenceStorage renamed to ObjectStorer and ReferenceStorer * rebase * general, changes request by @alcortes * general, changes request by @alcortes
* fix fixtures usageMáximo Cuadros2016-10-261-1/+1
|
* fixtures: new fixture package being use in all packagesMáximo Cuadros2016-09-121-5/+3
|
* format: packfile fix ReadObjectAt without decodeMáximo Cuadros2016-09-111-9/+11
|
* storage: filesystem iter implementationMáximo Cuadros2016-09-091-0/+38
|
* storage: filessytem read multiple packfiles support and index decodingMáximo Cuadros2016-09-091-312/+27
|
* format: packfile new interfaceMáximo Cuadros2016-09-071-7/+7
|
* storage: filesystem idx generation (wip)Máximo Cuadros2016-09-061-19/+23
|
* core: ObjectStorage.WriterMáximo Cuadros2016-09-051-0/+17
|
* core: ObjectStorage.Begin and TxObjectStorageMáximo Cuadros2016-09-051-4/+4
|
* core: Storage.Get, switch order of argsMáximo Cuadros2016-08-291-2/+2
|
* storage: Add object type hint parameter to ObjectStorage.Get. (#69)Santiago M. Mola2016-08-291-4/+6
| | | | | | | Some storage backends can optimize object lookup if they get the object type that is expected. So we the signature of the Get method is now Get(Hash, ObjectType). Added generic tests for storage backends.
* storage/filesystem: ConfigStore implementationMáximo Cuadros2016-08-211-8/+9
|
* core: Storage, removing err returning *StoragesMáximo Cuadros2016-08-141-4/+1
|
* core: removing Object.Content, the Reader should be used alwaysMáximo Cuadros2016-08-141-2/+6
|
* storage: Storage entity support, and DotGit support for ReferencesMáximo Cuadros2016-08-121-0/+315