Okay, let me fix the fallback behavior and get it printing whatever the chunk upload throws and we'll see where that gets us.
- Queries
- All Stories
- Search
- Advanced Search
- Transactions
- Transaction Logs
Advanced Search
Mar 17 2015
Nope, nothing in the error logs on the server.
Hmm, anything in the error log on the server?
OK. I'm having some more issues...
OK, thanks for clarifying.
It's just 8MB * headroom factor.
So where does 32MB come from? If I set the filesize limit to 8MB, why do I need to set the nginx/PHP limits to 32MB?
This API is partly odd because I want to disable chunking into MySQL by default, but allow users to enable it relatively easily. That motivates the <4MB -> 4MB chunk-enabling threshold. We could hard-code the 8MB single-file threshold but I suspect the total number of custom storage engines in the wild is about 3 so I figured I'd wait until the next iteration to figure out where the API should go (I want to the config into the Files web UI, which would let us expose [ ] Enable chunk storage for this engine or whatever).
So, setting a filesize limit allows me to upload files with an unlimited size?
(8MB just stores all 1-chunk and 2-chunk files as single files, and then starts chuking as soon as we'd have 3 chunks.)
Ohhh. Set these options in your custom engine:
It seems that my custom PhabricatorFileStorageEngine class is being selected instead of PhabricatorChunkedFileStorageEngine. If I manually decrease the priority of PhabricatorChunkedFileStorageEngine to 0, I am able to perform a chunked upload.
> arc --conduit-uri=https://phabricator.example.com --trace upload large-file libphutil loaded from '/home/joshua/dotfiles/modules/phabricator/libphutil/src'. arcanist loaded from '/home/joshua/dotfiles/modules/phabricator/arcanist/src'. Config: Reading user configuration file "/home/joshua/.arcrc"... Config: Did not find system configuration at "/etc/arcconfig". Working Copy: No candidate locations for .arcconfig from this working directory. Working Copy: Path "/home/joshua" is not in any working copy. >>> [0] <conduit> conduit.connect() <bytes = 586> >>> [1] <http> https://phabricator.example.com/api/conduit.connect <<< [1] <http> 3,184,008 us <<< [0] <conduit> 3,184,671 us Uploading 'large-file'... >>> [2] <conduit> file.allocate() <bytes = 295> >>> [3] <http> https://phabricator.example.com/api/file.allocate <<< [3] <http> 614,302 us <<< [2] <conduit> 614,989 us >>> [4] <conduit> file.upload() <bytes = 209715421> >>> [5] <http> https://phabricator.example.com/api/file.upload <<< [5] <http> 1,327,965 us <<< [4] <conduit> 1,328,623 us
FWIW, FB is using Quip for this kind of design/idea document these days: http://quip.com
Ah. I did try testing it out on this install with a 100MB file. Perhaps I shall try with a larger file instead.
Hmm, I'm not sure. We use nginx on this server -- client_max_body_size is technically set to 128m, but 32m should be more than enough.
I suspect this is an nginx thing.
DDoS stuff
Not precisely related, but as of a day or so ago, at HEAD, file sizes are unlimited for all users if you have at least one storage engine capable of storing 4MB chunks. The documentation has been updated and should reflect the modern state of the world:
This issue stems from a conversation I had with a PI of one of the projects on which we're using Phabricator, and we're about to open the instance to a wider audience (not necessarily general public, but a wider audience nonetheless). His comment was basically, "Disable the upload button for external users." Note, here, that 'external' are still logged-in users, not "public".
Mar 16 2015
Can you walk me thorough the kind of abuse/misuse you're seeing (or anticipating)? We have quota infrastructure and could extend it to files, but there's currently no per-user component, and I'd like to see if we can come up with better approaches to handle specific abuse scenarios since quotas are a pretty blunt instrument.
We intentionally do not provide this capability from the web UI. For rationale, see:
Mar 15 2015
Chrome 41 is current and does not reproduce this.
This is almost a year old, I can't reproduce it, and we haven't seen other reports.
Support for streaming files (vs fire-and-forget requests) -- which I think was discussed somewhere -- is no longer very important after T7149. We can now store files of arbitrary size in engines that only expose the existing writeEntireFile($big_chunk_of_data) API without major downsides.
After T7149, drag-and-drop uploads support arbitrarily large files and resumable uploads for files larger than the chunk threshold (currently 8MB).
This has been a few months, any idea if there was a resolution?
- In Files → (Choose a File) → Edit File, the only available option is "Visible To".
- Add a "name" field.
- Add a "name" transaction type, editor support, etc., so changing the name shows up in the file's edit history.
I don't think there's any product or technical reasoning here, Files just predated ApplicationTransactions and came from a simpler time.
Mar 13 2015
D12060 or followup work should remove the limit from arc upload.
Mar 12 2015
I'll see if I can get it to work better.
In Safari, dragging files to the homepage now flashes the mask on and off rapidly. You have about a 50% chance of actually hitting an upload.
Blocking a normal means high priority I think.
Mar 8 2015
I don't know if this way an explicit product decision, but I don't think there is any technical reason we don't allow this.
Sure, I understand your concern.
Mar 7 2015
In all seriousness, I understand why these are filed, but my concern is this does not solve a real problem. Specifically in https://secure.phabricator.com/book/phabcontrib/article/feature_requests/ we request people state problems they are having, and not the solution. If there is a real issue using the Application, we'd rather fix the application and not just rely on Documentation for Documentation sake. I don't want to build Phabricator in such a way that Documentation is a vital part of a user understanding the application. On some applications that may be unavoidable.
Mar 6 2015
Mar 3 2015
Mar 1 2015
I suppose that an SSH client for Conduit would mitigate this issue (T550).
Not quite. The main issue I have is that the file is larger than the maximum configured size that nginx/PHP will handle. My solution in the past has been to I crease the nginx/PHP limits.
You can do this with arc upload. Is that sufficient?
Feb 27 2015
Yeah, repros in Safari too, we just have the wrong link happening.
Clicking "Download" is expected to set Content-Disposition: attachment and force a download. We're probably either pointing the button at the wrong place (likely) or Chrome has gone crazy and no longer permits/recognizes this (unlikely).
You can use file.info from the Conduit API console to convert a file ID into a PHID, but will likely have to go to the database for the caching stuff in T4214 anyway.
This isn't the correct solution. I'm going to merge this into T4214 since that task is not marked as complete.
Feb 15 2015
I have half a diff for this (D10530) that I cab probably finish off. The main issue I had was with signing the requests and also the difficulty associated with testing.
I am not sure which project this goes into.
Feb 14 2015
(Ahh, thanks for the merge, @epriestley.)
Feb 9 2015
Jan 27 2015
It would be a lot simpler to use HTML 5 File API together with a regular <input type=file /> field. This won't help the IE8s of the world, but will help users of non-standard, but modern operating systems and browsers.
Jan 20 2015
See also T1692, which claims to have resolved this very issue.
Jan 19 2015
Jan 12 2015
Haha cool, just tested this out on my dev install and it maxes out the CPU on my VM.
Jan 9 2015
This task discusses text (vs code) diffing above. Not sure if you're interested in looking at this, but here's a rough outline:
Jan 5 2015
I don't intend to fix this unless Chrome's fix doesn't make it to production.
Confirmed that in Chrome Canary 41 41.0.2266.2, the image scales down instead of having a scrollbar.
+1 for mobile browsers
Jan 1 2015
We use PHP's Fileinfo extension if it's available and fall back to running file, then fall back to mime_content_type() if that doesn't work either. Presumably Fileinfo will eventually update to perform this detection, although I'm not sure what that timeline might look like or exactly what's going on with it internally.
In T6674#85975, @epriestley wrote:I believe OGG is primarily used for audio in the wild today, and we haven't seen other reports of users running into this same audio vs video issue. If, say, 95% of installs use OGG only for audio, it seems reasonable to leave it as a default and let the other 5% configure it.
Dec 30 2014
I guess as a designer myself I don't understand the optimization here (quick create Pholio). I fundamentally work one of two ways. Serious 'pre-product' or explorative designs (which take 10, 20, 40 hours), which I expect revisions and long discussions on. This product is Pholio. The second is lightweight corrections or attachments to tasks. The 'hey go make this' or 'i just threw this together'. In those cases I drag and drop into comments/descriptions on a task or diff.
In T6831#89086, @chad wrote:Adding a file either requires you click "edit" and drag in a file or scroll to the bottom and comment and drag in a file. I think both are equally easy, just different.
Are there some example tasks on the WMF install where assets are few/simple enough that making a mock is overkill, but numerous enough that finding the latest versions is time consuming/complex? If an asset (like an icon) is straightforward and doesn't need discussion, how often are there a ton of versions of it?
I should mention long-term I want to make the Pholio comment controls work on any image in lightbox, not just Pholio mocks.
Adding a file either requires you click "edit" and drag in a file or scroll to the bottom and comment and drag in a file. I think both are equally easy, just different.
Your reasoning makes sense. I think the actual problem behind this request is that adding a file to a comment is a lot easier than embedding a new mockup to the header or description of a task, counting the steps each path takes and the extra fields that a new mock offers.