### Steps
Follow the steps from https://github.com/owncloud/core/issues/28197… and observe access log.
The linked ticket is about a received shared file (not folder, not file in shared folder).
When upload+overwriting this special file (which is also a shared mount / mount point), the client somehow decides to use the **old chunking** approach but with the **new endpoint**:
```
{"reqId":"sFrpwigItQogTHW5WblS","level":0,"time":"2017-06-23T13:28:48+00:00","remoteAddr":"127.0.0.1","user":"admin","app":"webdav","method":"PUT","url":"\/owncloud\/remote.php\/dav\/files\/admin\/data1.dat-chunking-3886638851-13-1","message":"Exception: {\"Message\":\"HTTP\\\/1.1 412 An If-Match header was specified and the resource did not exist\",\"Exception\":\"Sabre\\\\DAV\\\\Exception\\\\PreconditionFailed\",\"Code\":0,\"Trace\":\"#0 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/lib\\\/composer\\\/sabre\\\/dav\\\/lib\\\/DAV\\\/Server.php(474): Sabre\\\\DAV\\\\Server->checkPreconditions(Object(Sabre\\\\HTTP\\\\Request), Object(Sabre\\\\HTTP\\\\Response))\\n#1 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/lib\\\/composer\\\/sabre\\\/dav\\\/lib\\\/DAV\\\/Server.php(254): Sabre\\\\DAV\\\\Server->invokeMethod(Object(Sabre\\\\HTTP\\\\Request), Object(Sabre\\\\HTTP\\\\Response))\\n#2 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/apps\\\/dav\\\/lib\\\/Server.php(229): Sabre\\\\DAV\\\\Server->exec()\\n#3 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/apps\\\/dav\\\/appinfo\\\/v2\\\/remote.php(31): OCA\\\\DAV\\\\Server->exec()\\n#4 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/remote.php(165): require_once('\\\/srv\\\/www\\\/htdocs...')\\n#5 {main}\",\"File\":\"\\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/lib\\\/composer\\\/sabre\\\/dav\\\/lib\\\/DAV\\\/Server.php\",\"Line\":1309,\"User\":\"admin\"}"}
{"reqId":"gvl4Qhlae2wIh7VHzOHt","level":0,"time":"2017-06-23T13:28:48+00:00","remoteAddr":"127.0.0.1","user":"admin","app":"webdav","method":"PUT","url":"\/owncloud\/remote.php\/dav\/files\/admin\/data1.dat-chunking-3886638851-13-2","message":"Exception: {\"Message\":\"HTTP\\\/1.1 412 An If-Match header was specified and the resource did not exist\",\"Exception\":\"Sabre\\\\DAV\\\\Exception\\\\PreconditionFailed\",\"Code\":0,\"Trace\":\"#0 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/lib\\\/composer\\\/sabre\\\/dav\\\/lib\\\/DAV\\\/Server.php(474): Sabre\\\\DAV\\\\Server->checkPreconditions(Object(Sabre\\\\HTTP\\\\Request), Object(Sabre\\\\HTTP\\\\Response))\\n#1 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/lib\\\/composer\\\/sabre\\\/dav\\\/lib\\\/DAV\\\/Server.php(254): Sabre\\\\DAV\\\\Server->invokeMethod(Object(Sabre\\\\HTTP\\\\Request), Object(Sabre\\\\HTTP\\\\Response))\\n#2 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/apps\\\/dav\\\/lib\\\/Server.php(229): Sabre\\\\DAV\\\\Server->exec()\\n#3 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/apps\\\/dav\\\/appinfo\\\/v2\\\/remote.php(31): OCA\\\\DAV\\\\Server->exec()\\n#4 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/remote.php(165): require_once('\\\/srv\\\/www\\\/htdocs...')\\n#5 {main}\",\"File\":\"\\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/lib\\\/composer\\\/sabre\\\/dav\\\/lib\\\/DAV\\\/Server.php\",\"Line\":1309,\"User\":\"admin\"}"}
{"reqId":"8zYlEnfzBMb1ChuIrY9M","level":0,"time":"2017-06-23T13:28:48+00:00","remoteAddr":"127.0.0.1","user":"admin","app":"webdav","method":"PUT","url":"\/owncloud\/remote.php\/dav\/files\/admin\/data1.dat-chunking-3886638851-13-0","message":"Exception: {\"Message\":\"HTTP\\\/1.1 412 An If-Match header was specified and the resource did not exist\",\"Exception\":\"Sabre\\\\DAV\\\\Exception\\\\PreconditionFailed\",\"Code\":0,\"Trace\":\"#0 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/lib\\\/composer\\\/sabre\\\/dav\\\/lib\\\/DAV\\\/Server.php(474): Sabre\\\\DAV\\\\Server->checkPreconditions(Object(Sabre\\\\HTTP\\\\Request), Object(Sabre\\\\HTTP\\\\Response))\\n#1 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/lib\\\/composer\\\/sabre\\\/dav\\\/lib\\\/DAV\\\/Server.php(254): Sabre\\\\DAV\\\\Server->invokeMethod(Object(Sabre\\\\HTTP\\\\Request), Object(Sabre\\\\HTTP\\\\Response))\\n#2 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/apps\\\/dav\\\/lib\\\/Server.php(229): Sabre\\\\DAV\\\\Server->exec()\\n#3 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/apps\\\/dav\\\/appinfo\\\/v2\\\/remote.php(31): OCA\\\\DAV\\\\Server->exec()\\n#4 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/remote.php(165): require_once('\\\/srv\\\/www\\\/htdocs...')\\n#5 {main}\",\"File\":\"\\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/lib\\\/composer\\\/sabre\\\/dav\\\/lib\\\/DAV\\\/Server.php\",\"Line\":1309,\"User\":\"admin\"}"}
{"reqId":"MKPYz2yrKVCVcwd7rkzS","level":0,"time":"2017-06-23T13:28:51+00:00","remoteAddr":"127.0.0.1","user":"admin","app":"webdav","method":"PUT","url":"\/owncloud\/remote.php\/dav\/files\/admin\/data1.dat-chunking-3246638472-13-2","message":"Exception: {\"Message\":\"HTTP\\\/1.1 412 An If-Match header was specified and the resource did not exist\",\"Exception\":\"Sabre\\\\DAV\\\\Exception\\\\PreconditionFailed\",\"Code\":0,\"Trace\":\"#0 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/lib\\\/composer\\\/sabre\\\/dav\\\/lib\\\/DAV\\\/Server.php(474): Sabre\\\\DAV\\\\Server->checkPreconditions(Object(Sabre\\\\HTTP\\\\Request), Object(Sabre\\\\HTTP\\\\Response))\\n#1 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/lib\\\/composer\\\/sabre\\\/dav\\\/lib\\\/DAV\\\/Server.php(254): Sabre\\\\DAV\\\\Server->invokeMethod(Object(Sabre\\\\HTTP\\\\Request), Object(Sabre\\\\HTTP\\\\Response))\\n#2 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/apps\\\/dav\\\/lib\\\/Server.php(229): Sabre\\\\DAV\\\\Server->exec()\\n#3 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/apps\\\/dav\\\/appinfo\\\/v2\\\/remote.php(31): OCA\\\\DAV\\\\Server->exec()\\n#4 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/remote.php(165): require_once('\\\/srv\\\/www\\\/htdocs...')\\n#5 {main}\",\"File\":\"\\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/lib\\\/composer\\\/sabre\\\/dav\\\/lib\\\/DAV\\\/Server.php\",\"Line\":1309,\"User\":\"admin\"}"}
{"reqId":"ETCSfrMC8JaUaMztJM7w","level":0,"time":"2017-06-23T13:28:51+00:00","remoteAddr":"127.0.0.1","user":"admin","app":"webdav","method":"PUT","url":"\/owncloud\/remote.php\/dav\/files\/admin\/data1.dat-chunking-3246638472-13-1","message":"Exception: {\"Message\":\"HTTP\\\/1.1 412 An If-Match header was specified and the resource did not exist\",\"Exception\":\"Sabre\\\\DAV\\\\Exception\\\\PreconditionFailed\",\"Code\":0,\"Trace\":\"#0 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/lib\\\/composer\\\/sabre\\\/dav\\\/lib\\\/DAV\\\/Server.php(474): Sabre\\\\DAV\\\\Server->checkPreconditions(Object(Sabre\\\\HTTP\\\\Request), Object(Sabre\\\\HTTP\\\\Response))\\n#1 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/lib\\\/composer\\\/sabre\\\/dav\\\/lib\\\/DAV\\\/Server.php(254): Sabre\\\\DAV\\\\Server->invokeMethod(Object(Sabre\\\\HTTP\\\\Request), Object(Sabre\\\\HTTP\\\\Response))\\n#2 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/apps\\\/dav\\\/lib\\\/Server.php(229): Sabre\\\\DAV\\\\Server->exec()\\n#3 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/apps\\\/dav\\\/appinfo\\\/v2\\\/remote.php(31): OCA\\\\DAV\\\\Server->exec()\\n#4 \\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/remote.php(165): require_once('\\\/srv\\\/www\\\/htdocs...')\\n#5 {main}\",\"File\":\"\\\/srv\\\/www\\\/htdocs\\\/owncloud\\\/lib\\\/composer\\\/sabre\\\/dav\\\/lib\\\/DAV\\\/Server.php\",\"Line\":1309,\"User\":\"admin\"}"}
```
If you do the same test with a regular file that you overwrite, it will use the new chunking approach with the "uploads" folder:
```
127.0.0.1 - admin [23/Jun/2017:15:53:36 +0200] "MKCOL /owncloud/remote.php/dav/uploads/admin/1226433652 HTTP/1.1" 201 - "-" "Mozilla/5.0 (Linux) mirall/2.3.2"
127.0.0.1 - admin [23/Jun/2017:15:53:36 +0200] "PUT /owncloud/remote.php/dav/uploads/admin/1226433652/00000000 HTTP/1.1" 201 - "-" "Mozilla/5.0 (Linux) mirall/2.3.2"
127.0.0.1 - admin [23/Jun/2017:15:53:37 +0200] "PUT /owncloud/remote.php/dav/uploads/admin/1226433652/00000001 HTTP/1.1" 201 - "-" "Mozilla/5.0 (Linux) mirall/2.3.2"
```
Is there a special logic in place that makes it fall back to old chunking and keeps the new dav endpoint ?
I'd expect it to always use the "uploads" folder for any uploads when using the new dav endpoint.
The error that happens on the server is not related, to be investigated in https://github.com/owncloud/core/issues/28197.
In general I except all three approaches to be valid:
1. old chunking on old endpoint
2. old chunking on new endpoint
3. new chunking on new endpoint ("uploads")
@guruz