summaryrefslogtreecommitdiffstats
path: root/app/file.go
Commit message (Collapse)AuthorAgeFilesLines
* MM-11575: change plugin nil semantics (#9212)Jesse Hallam2018-08-031-7/+14
| | | | | | | | * change MessageWillBePosted nil return semantics * change FileWillBeUploaded nil return semantics * use LogDebug to verify plugin inputs vs. the confusing Delete(User|Team)
* Feature/fileinfo create copy (#9198)dmitrysamuylovpharo2018-08-021-0/+30
| | | | | | | | * Initial implementation of a CopyFileInfos function that creates new FileInfo objects copied from provided FileIds with the provided user as the creator and not linked to a post yet. This can subsequently be used to copy existing attachments from another post to attach to a new post without having to re-upload the actual files * added a unit test for the CopyFileInfos function * resolving pull request suggestions
* [MM-10621] Set createAt timestamp on file upload api call to secure upload ↵Saturnino Abril2018-07-281-4/+5
| | | | | | | | order of files (#9170) * set createAt timestamp on file upload api call to secure upload order of files * fix test on plugin hooks
* Adding FileWillBeUploaded plugin hook (#9169)Christopher Speller2018-07-271-6/+30
| | | | | | | | | | | | | | * Adding file upload hook. * Adding hook test for FileWillBeUploaded * Some debugging fixes. * Fix typo. * Fixing double close * Fix capitalization on docs.
* Fix file streaming to close files. (#9168)Christopher Speller2018-07-261-1/+2
|
* MM-10381: Change the file downloading API to stream file (#9144)Hyeseong Kim2018-07-241-0/+8
| | | | | | | | * Change the file downloading to stream file * Change file downloading to chunk only for preview * Remove unnecessary else case
* MM-10700 - Updating default image preview size (#9002) (#9003)Joram Wilander2018-06-261-1/+1
|
* Implementation of File Exists Function; Delete FileInfos upon Permanent User ↵Daniel Schalla2018-06-251-0/+8
| | | | | | | Delete (#8958) Check if file was deleted on FS Warning message if file couldnt be removed
* MM-8708 Remove api package (#8784)Joram Wilander2018-05-161-5/+0
| | | | | | | | | | | | | | | | | | | | | | * Remove api package * Remove api dependency from cmd package * Remove EnableAPIv3 setting * Update web tests * Add more websocket tests * Move some ws and oauth tests to api4 package * Move command tests into api4 package * Test fixes * Fix msg command test * Add some app file tests
* MM-10188: expect io.Reader in FileBackend.WriteFile (#8765)Jesse Hallam2018-05-101-6/+7
| | | | This is a reworked set of changes originally from @josephGuo to begin reducing the duplicated memory required when uploading files.
* Added missing i18n strings for files and email batching (#8700)Harrison Healey2018-05-041-16/+43
| | | | | | * Added missing i18n strings for files and email batching * Added more fields to log messages
* respect image orientation before saving height and width of FileInfo (#8710)Saturnino Abril2018-05-041-0/+8
|
* Structured logging (#8673)Christopher Speller2018-04-271-20/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Implementing structured logging * Changes to en.json to allow refactor to run. * Fixing global logger * Structured logger initalization. * Add caller. * Do some log redirection. * Auto refactor * Cleaning up l4g reference and removing dependancy. * Removing junk. * Copyright headers. * Fixing tests * Revert "Changes to en.json to allow refactor to run." This reverts commit fd8249e99bcad0231e6ea65cd77c32aae9a54026. * Fixing some auto refactor strangeness and typo. * Making keys more human readable.
* MM-9556 Added ability to upload files without a multipart request (#8306)Harrison Healey2018-02-201-9/+30
| | | | | | * MM-9556 Added ability to upload files without a multipart request * MM-9556 Handled some unusual test behaviour
* Remove license globals entirely (#8229)Chris2018-02-091-1/+2
| | | | | | | | * remove license globals entirely * fix infinite recursion * test fix
* Reorganize file util functionality (#7848)Chris2017-11-161-13/+49
| | | | | | | | * reorganize file util functionality * fix api test compilation * fix rebase issue
* more global config ref cleanup (#7802)Chris2017-11-091-4/+4
|
* several one-line panic, race, and logic fixes (#7766)Chris2017-11-031-1/+1
|
* Reduce utils.Cfg references (#7650)Chris2017-10-181-1/+1
| | | | | | | | | | | | * app.UpdateConfig method * test fix * another test fix * the config override option as-was is just error prone, remove it for now * derp
* PLT-7718 Patch for files (#7564)Joram Wilander2017-10-041-1/+4
| | | | | | | | | | * Patch for files * Fix merge * Fix tests * Fix another test
* Finally do away with NewLocAppError function. (#7498)George Goldberg2017-09-251-2/+1
| | | | | This cleans up the few NewLocAppError calls that crept in since the main bulk of them were removed, and finally removes the NewLocAppError function altogether.
* Renaming repoChristopher Speller2017-09-061-2/+2
|
* app type transition (#7167)Chris2017-09-061-15/+15
|
* set to default value with config is missing (#7320)Saturnino Abril2017-08-301-1/+1
|
* PLT-???? Prepare file upload infrastructure for Data Retention. (#7266)George Goldberg2017-08-251-245/+12
| | | | | | | | | | | | | | | | | * Prepare file upload infrastructure for Data Retention. This commit prepares the file upload infrastructure for the data retention feature that is under construction. Changes are: * Move file management code to utils to allow access to it from jobs. * From now on, store all file uploads in a top level folder which is the date of the day on which they were uploaded. This commit is based on Harrison Healey's branch, but updated to work with the latest master. * Use NewAppError
* Adding check for file write or minio/s3 bucket before server start. (#7254)Christopher Speller2017-08-181-0/+45
|
* Fixing bad merge (#7247)Corey Hulen2017-08-171-2/+2
|
* PLT-7360 Adding SSE to compliance (#7165)Corey Hulen2017-08-111-2/+9
| | | | | | | | * Adding SSE to E20 * Fixing UI bug * Fixing loc strings
* FIXES PLT-6648 Add support for Server Side Encryption on S3 (#6467)Tejay Cardon2017-08-081-5/+24
| | | | | Help from Jason Blais on wording Update storage_settings.jsx Update en.json
* Allow regions to be set and honored for S3 driver. (#7010)Harshavardhana2017-07-311-6/+16
| | | | | | | | | This is necessary for certain users where GetBucketLocation API is disabled using IAM policies. There is a field AmazonS3Region which we need to re-purpose and use to support this properly. Fixes https://github.com/mattermost/platform/issues/6999
* Upgrading server dependancies (#6984)Christopher Speller2017-07-201-4/+7
|
* PLT-6659 Fixed upload thumbnails that weren't properly rotated (#6816)Rich Barton2017-07-101-8/+17
| | | | | | | - Used client-side EXIF data to rotate profile picture thumbnails - Added a small package for correctly translating EXIF orientation into CSS transforms - Instead of displaying the image using FileReader, used URL.createObjectURL because it is faster - For upload thumbnails, the original behavior was scaling the entire original image, without accounting for EXIF rotate. I changed this to use the thumbnail image, which does respect rotation. - The preview image was not available when the upload request returned, because handling the preview image creation was in a goroutine. I used sync.WaitGroup to block until the preview image creation is done.
* PLT-6975 Fixed image thumbnail size being calculated incorrectly (#6855)Harrison Healey2017-07-061-4/+9
|
* [PLT-6496] Remove System Console and config settings for image height and ↵Saturnino Abril2017-06-291-12/+11
| | | | | | | | | | width (#6688) * remove System Console and config settings for image height and width * add constants and update config.json * updated as per review
* Support AWS Signature V2 for Mattermost for S3 storage. (#6462)Harshavardhana2017-05-301-3/+16
| | | | | | | Certain S3 compatible servers only use Legacy Signature (AWS Signature V2), current code only supports signature v4. This PR adds facility to click a button on the UI to enable legacy signature with S3 compatible servers.
* PLT-6534 Rotated uploaded profile pictures to be upright (#6482)Harrison Healey2017-05-241-12/+17
|
* PLT-6262 Add config setting to disable file attachments (#6301)Joram Wilander2017-05-041-1/+1
| | | | | | | | | | | | | | * Add config setting to disable file attachments * Add unit tests * Updating UI for no attachments (#6312) * Update UI text on file upload System Console setting (#6313) * Update storage_settings.jsx * Update en.json
* PLT-5860 Updated copyright date (#6058)Harrison Healey2017-04-121-1/+1
| | | | | | | | | | | | * PLT-5860 Updated copyright date in about modal * PLT-5860 Updated copyright notice in JSX files * PLT-5860 Updated copyright notice in go files * Fixed misc copyright dates * Fixed component snapshots
* Endpoint for APIv4: /files/{file_id}/link (#5607)Saturnino Abril2017-03-111-0/+5
| | | | | | * APIv4: /files/{file_id}/link * updated public link
* Fixing file info caching issue with Aurora for master (#5477)Corey Hulen2017-02-201-1/+1
|
* Implement upload and get file endpoints for APIv4 (#5396)Joram Wilander2017-02-171-0/+57
| | | | | | * Implement POST /files endpoint for APIv4 * Implement GET /files/{file_id} endpoint for APIv4
* Add caching for file infos (#5330)Joram Wilander2017-02-071-1/+1
|
* Implement APIv4 infrastructure (#5191)Joram Wilander2017-01-301-3/+3
| | | | | | * Implement APIv4 infrastructure * Update parameter requirement functions per feedback
* Move Slack Import to App Layer. (#5135)George Goldberg2017-01-201-1/+190
|
* Refactor and migrate more functions out of api into app package (#5063)Joram Wilander2017-01-131-0/+340