Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Insufficient Storage error handling #31284

Closed
pako81 opened this issue Apr 26, 2018 · 12 comments
Closed

Insufficient Storage error handling #31284

pako81 opened this issue Apr 26, 2018 · 12 comments

Comments

@pako81
Copy link

pako81 commented Apr 26, 2018

It looks like there is an uncaught exception in case of Insufficient Storage for WebDAV. This should be probably treated like a normal log message:

{"reqId":"421a6474-d32a-4da7-904f-564c2e4d02a2","level":4,"time":"2018-04-26T11:20:51+00:00","remoteAddr":"xxx.xx.xx.xxx","user":"user2","app":"webdav","method":"PUT","url":"/owncloud1008rc3/remote.php/dav/files/user2/ownCloud%20Manual2.pdf","message":"Exception: {\"Message\":\"HTTP/1.1 507 Insufficient Storage\",\"Exception\":\"Sabre\DAV\Exception\InsufficientStorage\",\"Code\":0,\"Trace\":\"
#0 /var/www/html/owncloud1008rc3/apps/dav/lib/Connector/Sabre/QuotaPlugin.php(134): OCA\DAV\Connector\Sabre\QuotaPlugin->checkQuota('//ownCloud Manu...')
#1 [internal function]: OCA\DAV\Connector\Sabre\QuotaPlugin->handleBeforeCreateFile('files/user2/own...', Resource id #69, Object(OCA\DAV\Connector\Sabre\Directory), false)
#2 /var/www/html/owncloud1008rc3/lib/composer/sabre/event/lib/EventEmitterTrait.php(105): call_user_func_array(Array, Array)
#3 /var/www/html/owncloud1008rc3/lib/composer/sabre/dav/lib/DAV/Server.php(1093): Sabre\Event\EventEmitter->emit('beforeCreateFil...', Array)
#4 /var/www/html/owncloud1008rc3/lib/composer/sabre/dav/lib/DAV/CorePlugin.php(525): Sabre\DAV\Server->createFile('files/user2/own...', Resource id #69, NULL)
#5 [internal function]: Sabre\DAV\CorePlugin->httpPut(Object(Sabre\HTTP\Request), Object(Sabre\HTTP\Response))
#6 /var/www/html/owncloud1008rc3/lib/composer/sabre/event/lib/EventEmitterTrait.php(105): call_user_func_array(Array, Array)
#7 /var/www/html/owncloud1008rc3/lib/composer/sabre/dav/lib/DAV/Server.php(479): Sabre\Event\EventEmitter->emit('method:PUT', Array)
#8 /var/www/html/owncloud1008rc3/lib/composer/sabre/dav/lib/DAV/Server.php(254): Sabre\DAV\Server->invokeMethod(Object(Sabre\HTTP\Request), Object(Sabre\HTTP\Response))
#9 /var/www/html/owncloud1008rc3/apps/dav/lib/Server.php(278): Sabre\DAV\Server->exec()
#10 /var/www/html/owncloud1008rc3/apps/dav/appinfo/v2/remote.php(31): OCA\DAV\Server->exec()
#11 /var/www/html/owncloud1008rc3/remote.php(165): require_once('/var/www/html/o...')
#12 {main}\",\"File\":\"/var/www/html/owncloud1008rc3/apps/dav/lib/Connector/Sabre/QuotaPlugin.php\",\"Line\":169,\"User\":\"user2\"}"}

Tested in 10.0.7 and 10.0.8. @tomneedham as discussed.

@ownclouders
Copy link
Contributor

GitMate.io thinks possibly related issues are #28840 (-Error-), #26902 (error), #15189 ([OC 8.0.2] Sabre Quota Plugin Errors - 507 Insufficient Storage ), #6391 (ownCloud can't handle Unlimited Storage?), and #29082 (a Error).

@ownclouders
Copy link
Contributor

Hey, this issue has been closed because the label status/STALE is set and there were no updates for 7 days. Feel free to reopen this issue if you deem it appropriate.

(This is an automated comment from GitMate.io.)

@pako81
Copy link
Author

pako81 commented Jun 15, 2018

@PVince81 ping

@PVince81 PVince81 added this to the backlog milestone Jun 15, 2018
@PVince81 PVince81 assigned PVince81 and sharidas and unassigned PVince81 Jun 22, 2018
@PVince81 PVince81 modified the milestones: backlog, development Jun 25, 2018
@PVince81
Copy link
Contributor

@pako81 @michaelstingl I think we agreed to make this a debug message instead ?

@michaelstingl
Copy link

HTTP status code 507 Insufficient Storage is okay, but the response body isn't beautiful:

<?xml version="1.0" encoding="utf-8"?>
<d:error xmlns:d="DAV:" xmlns:s="http://sabredav.org/ns">
  <s:exception>Sabre\DAV\Exception\InsufficientStorage</s:exception>
  <s:message/>
</d:error>

@PVince81
Copy link
Contributor

@michaelstingl what message do you want there ?

@michaelstingl
Copy link

@PVince81 response message is the least problem. Level 4 exception in owncloud.log is much much bigger problem.

OCS API for example sometimes responds with a "nice" message:

<message>can't change permission for public link share</message>
(source: docs)

This can be displayed in the clients directly, and it's even translated automatically:
https://github.com/owncloud/core/blob/v10.0.8/apps/files_sharing/l10n/ja.json#L47

I'd love to get more of these "actionable" responses, but's that's probably another discussion…

@PVince81
Copy link
Contributor

so can this ticket be closed ? further wishes to be raised as separate non-support ticket ?

@PVince81
Copy link
Contributor

PR for the log level change was merged, will be in 10.0.10: #31978

@pako81
Copy link
Author

pako81 commented Jul 23, 2018

@PVince81 moving this to debug level would make for an admin more difficult to find out why uploads for a specific user failed, isn't it?

@PVince81
Copy link
Contributor

@pako81 in general I'd expect that for said user the error response 507 is returned, that would be visible in the HTTP status code of the access log

@PVince81
Copy link
Contributor

I'm closing this. @pako81 @michaelstingl if there are additional wishes, please make new tickest.

@PVince81 PVince81 modified the milestones: development, QA Jan 11, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Jan 11, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants