summaryrefslogtreecommitdiffstats
path: root/lib/public/IDBConnection.php
Commit message (Collapse)AuthorAgeFilesLines
* Allow NULL as well for limit, not integer onlyJoas Schilling2021-11-151-2/+2
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Update php licensesJohn Molakvoæ (skjnldsv)2021-06-041-7/+1
| | | | Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
* Add expression taint source and sanitizerLukas Reschke2021-02-171-0/+10
| | | | Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
* Deprecate the internal IDBConnection event name constantsChristoph Wurst2021-02-091-0/+23
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Add our own DB exception abstractionChristoph Wurst2021-01-121-3/+12
| | | | | | | | | | | | | | | | | | Right now our API exports the Doctrine/dbal exception. As we've seen with the dbal 3 upgrade, the leakage of 3rdparty types is problematic as a dependency update means lots of work in apps, due to the direct dependency of what Nextcloud ships. This breaks this dependency so that apps only need to depend on our public API. That API can then be vendor (db lib) agnostic and we can work around future deprecations/removals in dbal more easily. Right now the type of exception thrown is transported as "reason". For the more popular types of errors we can extend the new exception class and allow apps to catch specific errors only. Right now they have to catch-check-rethrow. This is not ideal, but better than the dependnecy on dbal. Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Bump doctrine/dbal from 2.12.0 to 3.0.0Christoph Wurst2021-01-081-29/+42
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Create primary keys on all tables and add a command to create the afterwardsJoas Schilling2020-11-101-0/+2
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Psalm fixesRoeland Jago Douma2020-10-301-4/+20
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Format code to a single space around binary operatorsChristoph Wurst2020-10-051-1/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Remove @package annotations from public namespaceJulius Härtl2020-08-261-1/+0
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* Add visibility to all constantsChristoph Wurst2020-04-101-4/+4
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Format control structures, classes, methods and functionChristoph Wurst2020-04-101-1/+0
| | | | | | | | | | | | | | | To continue this formatting madness, here's a tiny patch that adds unified formatting for control structures like if and loops as well as classes, their methods and anonymous functions. This basically forces the constructs to start on the same line. This is not exactly what PSR2 wants, but I think we can have a few exceptions with "our" style. The starting of braces on the same line is pracrically standard for our code. This also removes and empty lines from method/function bodies at the beginning and end. Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Use exactly one empty line after the namespace declarationChristoph Wurst2020-04-091-0/+1
| | | | | | For PSR2 Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Merge pull request #19890 from nextcloud/enh/comments-reference-idJoas Schilling2020-04-021-0/+2
|\ | | | | Add optional comments reference_id
| * Add optional column oc_comments.reference_idJoas Schilling2020-03-311-0/+2
| | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | Update the license headers for Nextcloud 19Christoph Wurst2020-03-311-0/+1
|/ | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Use the short array syntax, everywhereChristoph Wurst2020-03-261-2/+2
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Update license headersChristoph Wurst2019-12-051-1/+2
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Some php-cs fixesRoeland Jago Douma2019-11-221-0/+1
| | | | | | | | | | | * Order the imports * No leading slash on imports * Empty line before namespace * One line per import * Empty after imports * Emmpty line at bottom of file Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Code cleanup.Ole Ostergaard2019-03-211-3/+3
| | | | Signed-off-by: Ole Ostergaard <ole.c.ostergaard@gmail.com>
* Add insertIgnoreConflict to IDBConnection interface.Ole Ostergaard2019-03-211-0/+14
| | | | Signed-off-by: Ole Ostergaard <ole.c.ostergaard@gmail.com>
* Add deprecation message ofr insertIfNotExistMorris Jobke2018-11-091-0/+1
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Catch UniqueConstraintViolationException inside insertIfNotExistMorris Jobke2018-11-091-1/+3
| | | | | | | | This is the most common case for the usage of this method. See also https://github.com/nextcloud/server/issues/12369 and the linked tickets. Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Add a hint that some indexes are not added yetMorris Jobke2018-06-061-0/+1
| | | | | | | | | * gives the admin a chance to discover the missing indexes and improve the performance of the instance without digging through the manual * nicely integrated in the setup checks where this kind of hints belong to * also adds an option to integrate this from an app based on events * fix style of setting warnings Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Emit event when running ./occ db:add-missing-indicesRoeland Jago Douma2018-05-241-0/+3
| | | | | | | This allows apps to listen to this event in order to also update indecies there. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Update license headersMorris Jobke2017-11-061-0/+1
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Start migrationsJoas Schilling2017-07-051-0/+17
| | | | | | | | | | Fixme: - Install and update of apps - No revert on live systems (debug only) - Service adjustment to our interface - Loading via autoloader Signed-off-by: Joas Schilling <coding@schilljs.com>
* @since 9.2.0 to @since 11.0.0Roeland Jago Douma2016-11-151-1/+1
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Allow 4byte unicode filenames on supported platformsRobin Appelman2016-10-201-0/+8
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Update with robinJoas Schilling2016-07-211-1/+1
|
* Fix othersJoas Schilling2016-07-211-2/+3
|
* Add a method to lock a tableJoas Schilling2016-05-211-0/+19
|
* Move \OCP to PSR-4Roeland Jago Douma2016-05-191-0/+234