summary refs log tree commit diff
path: root/synapse/storage (follow)
Commit message (Expand)AuthorAgeFilesLines
* SYN-369: Add comments to the sequence number logic in the cacheMark Haines2015-05-051-0/+7
* Add debug flag in synapse/storage/_base.py for debugging the cache logic by c...Mark Haines2015-05-051-1/+12
* Invalidate the room_member cache if the current state events updatesMark Haines2015-05-051-0/+5
* Missing return for when the event was already persistedMark Haines2015-05-051-1/+1
* Invalidate the caches from the correct threadMark Haines2015-05-056-29/+46
* Sequence the modifications to the cache so that selects don't race with insertsMark Haines2015-05-051-3/+23
* Correctly name transactionErik Johnston2015-05-051-1/+1
* Remove some unused indexesErik Johnston2015-05-011-0/+18
* user_id now in user_threepidsDavid Baker2015-05-011-3/+3
* Don't use self.execute: it's designed for fetching stuffDavid Baker2015-05-011-3/+8
* No id field on userDavid Baker2015-05-011-5/+1
* More missed get_user_by_id API changesDavid Baker2015-05-011-3/+3
* Cache latest_event_ids_in_roomErik Johnston2015-05-011-1/+4
* Don't lock user_ips table for upsert.Erik Johnston2015-05-012-4/+10
* Fix bug where we reconnected to the database on every query.Erik Johnston2015-05-012-1/+2
* Split a storage function in two so that we don't have to do extra work.Erik Johnston2015-05-011-0/+11
* Remove pointless joinErik Johnston2015-04-301-5/+4
* Fix broken SQLErik Johnston2015-04-301-1/+1
* Need more yieldErik Johnston2015-04-301-1/+1
* Add missing paramErik Johnston2015-04-301-1/+1
* More join conditionsErik Johnston2015-04-301-2/+6
* Add more conditions on JOINs to make postgres go a little faster.Erik Johnston2015-04-302-4/+6
* Fix up get_current_state and get_room_name_and_aliases queries to parse event...Erik Johnston2015-04-302-32/+30
* Add get_rooms_for_user cacheErik Johnston2015-04-301-0/+2
* Don't use sub queries, it makes postgres sadErik Johnston2015-04-301-11/+5
* SYN-367: Use upsert rather than insert_or_replaceMark Haines2015-04-301-2/+6
* Don't needlessly join on state_eventsErik Johnston2015-04-302-6/+4
* Make simple query rather than long one and then throw away half the resultsErik Johnston2015-04-301-0/+10
* Correctly decode, for sqlite and postgres, rows from pushers tableErik Johnston2015-04-291-19/+24
* pushkey' are also bytes.Erik Johnston2015-04-291-8/+17
* TypoErik Johnston2015-04-291-1/+1
* Also remove yield from within lock in the other generatorErik Johnston2015-04-291-8/+6
* Fix deadlock in id_generators. No idea why this was an actual deadlock.Erik Johnston2015-04-291-14/+16
* Actually return rowsErik Johnston2015-04-291-0/+2
* Typo, args wrong way roundErik Johnston2015-04-291-4/+1
* Decode buffers in same threadErik Johnston2015-04-291-13/+19
* We store pusher data as bytesErik Johnston2015-04-291-2/+2
* Decode the data json in the storage layer (was moved but this part was missed)David Baker2015-04-291-0/+9
* Oops, update the contraint tooDavid Baker2015-04-291-1/+1
* Be more postgressiveDavid Baker2015-04-292-4/+4
* Be postgressiveDavid Baker2015-04-291-4/+3
* Oops, forgot the schema delta fileDavid Baker2015-04-291-0/+10
* txn.execute doesn't return cursorsErik Johnston2015-04-291-4/+4
* txn.execute doesn't return cursorsErik Johnston2015-04-291-2/+2
* Fix invalid SQL to work in postgres landErik Johnston2015-04-291-4/+6
* pushers table requires an access_tokenErik Johnston2015-04-291-0/+1
* We can't use REPLACE when upgrading databases now we have postgresErik Johnston2015-04-291-1/+2
* Merge pull request #129 from matrix-org/key_distributionErik Johnston2015-04-293-1/+90
|\
| * bump database schema versionMark Haines2015-04-292-1/+1
| * Use bytea rather than BLOBMark Haines2015-04-291-1/+1
| * Merge branch 'develop' into key_distributionMark Haines2015-04-2960-734/+2046
| |\
| * | And don't bump the schema version unnecessarilyMark Haines2015-04-281-1/+1
| * | Add server_keys.sql to the current delta rather than creating a new deltaMark Haines2015-04-281-0/+0
| * | Merge branch 'develop' into key_distributionMark Haines2015-04-242-0/+28
| |\ \
| * | | Implement remote key lookup apiMark Haines2015-04-221-13/+22
| * | | Add methods for storing and retrieving the raw key jsonMark Haines2015-04-152-3/+59
| * | | Return a sha256 fingerprint rather than the entire tls certificateMark Haines2015-04-142-1/+25
* | | | Make postgres database error slightly more helpfulErik Johnston2015-04-291-1/+2
* | | | Use __all__ instead of assert to stop pyflakes from warning about unused impo...Erik Johnston2015-04-291-2/+3
* | | | Appease PEP8Erik Johnston2015-04-291-0/+2
* | | | Check that postgres database has correct charset setErik Johnston2015-04-294-0/+33
| |_|/ |/| |
* | | Merge branch 'develop' of github.com:matrix-org/synapse into postgresErik Johnston2015-04-284-74/+133
|\ \ \
| * \ \ Merge pull request #126 from matrix-org/csauthMark Haines2015-04-283-55/+124
| |\ \ \
| | * | | pep8David Baker2015-04-171-1/+1
| | * | | Password reset, finally.David Baker2015-04-171-1/+15
| | * | | Add endpoint to get threepids from serverDavid Baker2015-04-171-0/+11
| | * | | pep8David Baker2015-04-171-1/+1
| | * | | make add3pid servlet workDavid Baker2015-04-171-0/+11
| | * | | Merge branch 'develop' into csauthDavid Baker2015-04-175-196/+373
| | |\| |
| | * | | Delete pushers when changing passwordDavid Baker2015-03-261-35/+10
| | * | | Allow multiple pushers for a single app ID & pushkey, honouring the 'append' ...David Baker2015-03-252-15/+39
| | * | | 1) Pushers are now associated with an access tokenDavid Baker2015-03-243-2/+5
| | * | | Make deleting other access tokens when you change your password actually workDavid Baker2015-03-241-5/+11
| | * | | Implement password changing (finally) along with a start on making client/ser...David Baker2015-03-231-4/+29
| * | | | pep8David Baker2015-04-271-1/+1
| * | | | Run database check before daemonizing, at the cost of database hygiene.David Baker2015-04-272-18/+10
| * | | | rename db method to be more informativeDavid Baker2015-04-271-4/+4
| * | | | pep8David Baker2015-04-241-2/+2
| * | | | Check users in our table aren't on a different domain to the one we're config...David Baker2015-04-241-0/+18
| | |_|/ | |/| |
* | | | Use TEXT instead of VARCHAR(n), since PostgreSQL treats them the same except ...Erik Johnston2015-04-2832-289/+289
* | | | Make get_max_token into inlineCallbacks so that the lock works.Erik Johnston2015-04-271-3/+4
* | | | Merge branch 'develop' of github.com:matrix-org/synapse into postgresErik Johnston2015-04-272-0/+28
|\| | |
| * | | Copyright noticesMark Haines2015-04-242-0/+28
| | |/ | |/|
* | | Shuffle operations so that locking upsert happens last in the txn. This ensur...Erik Johnston2015-04-275-56/+56
* | | Handle the fact that postgres databases can be restarted from under usErik Johnston2015-04-273-1/+33
* | | Revert needless change to storage.profileErik Johnston2015-04-171-6/+1
* | | Add unique index to room_aliases, remove duplicates on upgrade. Convert some ...Erik Johnston2015-04-177-4/+19
* | | PEP8Erik Johnston2015-04-162-5/+0
* | | Go back to storing JSON in TEXTErik Johnston2015-04-1611-41/+20
* | | Move encoding and decoding of JSON into storage layerErik Johnston2015-04-161-20/+6
* | | Remove mysql/maria supportErik Johnston2015-04-153-53/+1
* | | Change full_schemas/11 to work with postgresErik Johnston2015-04-1513-84/+90
* | | Remove debug loggingErik Johnston2015-04-151-2/+0
* | | Add missing yieldErik Johnston2015-04-151-1/+1
* | | pushers table requires a unique id.Erik Johnston2015-04-152-3/+11
* | | Don't pass in removed flagErik Johnston2015-04-151-1/+0
* | | Postgres does not allow you to continue using a cursor after a DB exception h...Erik Johnston2015-04-151-11/+14
* | | Turn off persistance of sent_transactions.response_jsonErik Johnston2015-04-151-1/+1
* | | Add index on events (topological_ordering, stream_ordering) to help with ORDE...Erik Johnston2015-04-152-0/+2
* | | Use try..finally in contextlib.contextmanagerErik Johnston2015-04-151-3/+5
* | | Use True for True rather than 1Erik Johnston2015-04-151-5/+7
* | | Add missing yield in storage funcErik Johnston2015-04-151-1/+1
* | | Correctly identify deadlocksErik Johnston2015-04-151-1/+1
* | | Add postgres database engineErik Johnston2015-04-141-0/+44
* | | Rename user_ips.user -> user_idErik Johnston2015-04-143-8/+8
* | | Add support for postgres instead of mysql. Change sql accourdingly. blob + va...Erik Johnston2015-04-1420-140/+151
* | | Correctly increment the _next_id initiallyErik Johnston2015-04-141-2/+4
* | | For backwards compat, make state_groups.id have a type of int, not varcharErik Johnston2015-04-132-2/+2
* | | Remove duplicate rowsErik Johnston2015-04-101-0/+9
* | | Use case sensitive collationsErik Johnston2015-04-101-1/+1
* | | DROP indexes before recreating themErik Johnston2015-04-102-1/+9
* | | Use LONGBLOB and TEXT for arbitary length rowsErik Johnston2015-04-1012-34/+34
* | | Handle the fact that in sqlite binary data might be stored as unicode or bytesErik Johnston2015-04-105-5/+20
* | | Bump schema versionErik Johnston2015-04-101-1/+1
* | | Use unsigned bigintErik Johnston2015-04-1019-50/+50
* | | SQLite wants INTEGER and not BIGINT for primary keysErik Johnston2015-04-106-9/+9
* | | Update full_schemas/16 to match delta files. Add delta/16 scriptsErik Johnston2015-04-106-0/+245
* | | Revert non-trivial changes to upgrade scriptsErik Johnston2015-04-103-5/+5
* | | Fix schema againErik Johnston2015-04-102-3/+3
* | | Revert non-trivial schema changes and move them to a new schema version.Erik Johnston2015-04-1019-27/+636
* | | Remove unused importErik Johnston2015-04-091-1/+1
* | | Remove spurious spacesErik Johnston2015-04-0915-50/+50
* | | Merge branch 'develop' of github.com:matrix-org/synapse into mysqlErik Johnston2015-04-092-21/+30
|\| |
| * | Merge pull request #114 from matrix-org/improve_get_event_cacheMark Haines2015-04-082-21/+30
| |\ \
| | * | Appease pep8Paul "LeoNerd" Evans2015-03-261-1/+2
| | * | Implement the main getEvent cache using Cache() instead of a custom applicati...Paul "LeoNerd" Evans2015-03-251-12/+7
| | * | Use FrozenEvent's reject_reason to decide whether to return it; don't include...Paul "LeoNerd" Evans2015-03-251-10/+14
| | * | Store the rejected reason in (Frozen)Event structsPaul "LeoNerd" Evans2015-03-251-2/+8
| | * | Indirect invalidations of _get_event_cache via a helper method to keep all us...Paul "LeoNerd" Evans2015-03-252-2/+5
* | | | Stream ordering and out of order insertions.Erik Johnston2015-04-095-65/+153
* | | | Use generic db exceptions rather than sqlite3 specific onesErik Johnston2015-04-082-6/+2
* | | | Merge branch 'develop' of github.com:matrix-org/synapse into mysqlErik Johnston2015-04-081-1/+2
|\| | |
| * | | Move database timer logging to seperate loggerErik Johnston2015-04-081-1/+2
* | | | Retry transaction, not SQL queryErik Johnston2015-04-081-21/+25
* | | | Fix maria engine to correctly recognize deadlocksErik Johnston2015-04-081-2/+2
* | | | Merge branch 'develop' of github.com:matrix-org/synapse into mysqlErik Johnston2015-04-075-207/+429
|\| | |
| * | | Add same user_id char checks as registration.Kegan Dougal2015-03-311-1/+7
| * | | Use a sender localpart instead of a user ID.Kegan Dougal2015-03-311-2/+9
| * | | Edit SQL schema to use string IDs not ints. Use token as ID. Update tests.Kegan Dougal2015-03-312-13/+17
| * | | Fix tests and missing returns on deferreds.Kegan Dougal2015-03-311-7/+11
| * | | Remove more reg/unreg methods. Read config not database for cache.Kegan Dougal2015-03-311-160/+59
| * | | Revert "Add another @cached wrapper, this time on get_presence_state()"Paul "LeoNerd" Evans2015-03-271-8/+2
| * | | Add another @cached wrapper, this time on get_presence_state()Paul "LeoNerd" Evans2015-03-271-2/+8
| * | | Fixes from PR commentsKegan Dougal2015-03-261-2/+2
| * | | Merge branch 'develop' into application-services-txn-reliabilityKegan Dougal2015-03-2619-644/+795
| |\| |
| | * | Allow a choice of LRU behaviour for Cache() by using LruCache() or OrderedDict()Paul "LeoNerd" Evans2015-03-251-8/+12
| | |/
| | * Put a cache on get_aliases_for_roomPaul "LeoNerd" Evans2015-03-201-2/+8
| | * Remember the 'last seen' time for a given user/IP/device combination and only...Paul "LeoNerd" Evans2015-03-201-2/+30
| | * Pull out the cache logic from the @cached wrapper into its own class we can r...Paul "LeoNerd" Evans2015-03-201-35/+54
| | * func(*EXPR) is valid Python syntax, really...Paul "LeoNerd" Evans2015-03-201-2/+1
| * | Set the service ID as soon as it is known.Kegan Dougal2015-03-161-3/+4
| * | Minor PR comment tweaks.Kegan Dougal2015-03-162-4/+4
| * | Merge branch 'develop' into application-services-txn-reliabilityKegan Dougal2015-03-169-54/+83
| |\ \
| * | | Fix remaining scheduler bugs. Add more informative logging.Kegan Dougal2015-03-101-2/+3
| * | | Remove unused importKegan Dougal2015-03-091-1/+0
| * | | Bug fixes whilst putting it all togetherKegan Dougal2015-03-091-5/+4
| * | | Use event IDs instead of dumping event content in the txns table.Kegan Dougal2015-03-092-7/+9
| * | | Use seconds; start gluing in the AS scheduler into the AS handler.Kegan Dougal2015-03-091-2/+5
| * | | Finish appservice txn storage impl and tests.Kegan Dougal2015-03-092-16/+71
| * | | Implement create_appservice_txn with tests.Kegan Dougal2015-03-091-4/+42
| * | | Partially implement txn store methods with tests.Kegan Dougal2015-03-091-17/+44
| * | | Start implementing ApplicationServiceTransactionStoreKegan Dougal2015-03-061-1/+5
| * | | Merge branch 'develop' into application-services-txn-reliabilityKegan Dougal2015-03-062-1/+56
| |\ \ \
| * | | | Assign the AS ID from the database; replace old placeholder txn id.Kegan Dougal2015-03-061-2/+3
| * | | | Add appservice txns sql schemaKegan Dougal2015-03-063-1/+38
| * | | | Apply clarity and docstringsKegan Dougal2015-03-061-1/+13
| * | | | Finish synapse.appservice.scheduler implementation.Kegan Dougal2015-03-061-0/+22
| * | | | Flesh out more stub functions.Kegan Dougal2015-03-061-2/+15
| * | | | Add stub ApplicationServiceTransactionStore. Bootstrap Recoverers. Fill in st...Kegan Dougal2015-03-061-0/+28
* | | | | Retry on deadlockErik Johnston2015-04-073-3/+21
* | | | | PEP8Erik Johnston2015-04-075-8/+0
* | | | | Fix prepare_sqlite3_database's convert_param_styleErik Johnston2015-04-071-7/+2
* | | | | Bump database versionErik Johnston2015-04-071-1/+1
* | | | | Add index to presence tableErik Johnston2015-04-071-0/+2
* | | | | Don't use multiple UNIQUE constraints; it will cause deadlocksErik Johnston2015-04-074-15/+17
* | | | | Implement or_ignore flag on insertsErik Johnston2015-04-072-4/+10
* | | | | Don't use AUTOINCREMENT, use an in memory versionErik Johnston2015-04-075-19/+68
* | | | | Fix unicode supportErik Johnston2015-04-0221-160/+189
* | | | | Make work in both Maria and SQLite. Fix testsErik Johnston2015-04-0124-100/+199
* | | | | Fix unicode database supportErik Johnston2015-03-2512-24/+52
* | | | | Escape non printing ascii characterErik Johnston2015-03-241-3/+3
* | | | | Don't reinsert into event_edgesErik Johnston2015-03-241-8/+8
* | | | | Fix bugs in transactions storageErik Johnston2015-03-241-2/+3
* | | | | Don't use room hosts tableErik Johnston2015-03-241-25/+4
* | | | | Don't order by rowidErik Johnston2015-03-241-1/+1
* | | | | Use _simple_upsertErik Johnston2015-03-242-5/+7
* | | | | Remove uses of REPLACE and ON CONFLICT IGNORE to make the SQL more portable.Erik Johnston2015-03-234-16/+4
* | | | | Sanitize RoomMemberStoreErik Johnston2015-03-231-63/+61
* | | | | Use 'update or insert' rather than on 'conflict replace'Erik Johnston2015-03-231-10/+17
* | | | | Sanitize TransactionStoreErik Johnston2015-03-231-87/+104
* | | | | Merge branch 'develop' of github.com:matrix-org/synapse into mysqlErik Johnston2015-03-2018-115/+227
|\ \ \ \ \ | | |_|_|/ | |/| | |
| * | | | PEP8Erik Johnston2015-03-201-1/+1
| * | | | Merge branch 'develop' of github.com:matrix-org/synapse into store_rearrangementErik Johnston2015-03-203-14/+30
| |\ \ \ \
| | * | | | Add the tiniest of tiny one-element caches to get_room_events_max_id() as it'...Paul "LeoNerd" Evans2015-03-202-1/+3
| | * | | | Allow @cached-wrapped functions to have more or fewer than 1 argument; assert...Paul "LeoNerd" Evans2015-03-201-13/+27
| * | | | | Give sensible names for '_simple_...' transactionsErik Johnston2015-03-2013-38/+93
| * | | | | Start removing TablesErik Johnston2015-03-202-26/+29
| * | | | | Tidy up _simple_... methodsErik Johnston2015-03-202-40/+60
| * | | | | Rearrange storage modulesErik Johnston2015-03-207-515/+493
| |/ / / /
| * | | | Clean out event_forward_extremities table when the server rejoins the roomErik Johnston2015-03-181-0/+12
| * | | | @cached() annotate get_user_by_token() - achieves a minor DB performance impr...Paul "LeoNerd" Evans2015-03-171-1/+6
| * | | | Be polite and ensure we use @functools.wraps() when creating a function decor...Paul "LeoNerd" Evans2015-03-171-0/+2
* | | | | Rearrange storage modulesErik Johnston2015-03-207-509/+486
* | | | | Generate transaction id in codeErik Johnston2015-03-201-1/+1
* | | | | decode_result takes an iterableErik Johnston2015-03-202-2/+5
* | | | | Fix up schemas some moreErik Johnston2015-03-203-3/+3
* | | | | Convert storage layer to be mysql compatibleErik Johnston2015-03-1913-101/+171
* | | | | Remove redundant keyErik Johnston2015-03-191-1/+0
* | | | | Fix up schemas to work with mariadbErik Johnston2015-03-1915-84/+82
* | | | | Update schema to work with mariadbErik Johnston2015-03-1816-256/+224
|/ / / /
* | | | Add a metric for the scheduling latency of SQL queriesPaul "LeoNerd" Evans2015-03-161-0/+5
* | | | Merge pull request #110 from matrix-org/fix_banErik Johnston2015-03-161-1/+1
|\ \ \ \ | |_|_|/ |/| | |
| * | | Copy dict of context.current_state before changing it.Erik Johnston2015-03-161-1/+1
| | |/ | |/|
* | | Bugfix to sql_txn_timer increment - add only the per-TXN duration, not the to...Paul "LeoNerd" Evans2015-03-121-7/+5
* | | Rename the timer metrics exported by synapse.storage to append _time, so the ...Paul "LeoNerd" Evans2015-03-121-3/+3
* | | Rename TimerMetric to DistributionMetric; as it could count more than just timePaul "LeoNerd" Evans2015-03-121-7/+7
* | | Pretend the 'getEvent' cache is just another cache in the set of all the othe...Paul "LeoNerd" Evans2015-03-121-6/+5
* | | Use _ instead of . as a metric namespacing separator, for PrometheusPaul "LeoNerd" Evans2015-03-121-5/+13
* | | Rename Metrics' "keys" to "labels"Paul "LeoNerd" Evans2015-03-121-3/+3
* | | Add TimerMetrics to shadow the PerformanceCounters in synapse.storage; with t...Paul "LeoNerd" Evans2015-03-121-3/+20
* | | Collect per-SQL-verb timer stats on query execution timePaul "LeoNerd" Evans2015-03-121-5/+11
* | | Delete a couple of TODO markers of monitoring stats now donePaul "LeoNerd" Evans2015-03-121-1/+0
* | | Rename CacheCounterMetric to just CacheMetric; add a CallbackMetric component...Paul "LeoNerd" Evans2015-03-121-3/+3
* | | Sprinkle some CacheCounterMetrics around the synapse.storage layerPaul "LeoNerd" Evans2015-03-121-1/+15
* | | Appease pep8Paul "LeoNerd" Evans2015-03-111-2/+2
* | | Also give _execute() a descriptionPaul "LeoNerd" Evans2015-03-116-12/+10
* | | Add a description to storage layer's _execute_and_decode()Paul "LeoNerd" Evans2015-03-115-6/+9
* | | Add the master push rule for the break-my-push button. Allow server default r...David Baker2015-03-101-22/+5
* | | These aren't defined for redacted events so don't crashDavid Baker2015-03-101-2/+4
|/ /
* | Schema change as delta in v14David Baker2015-03-061-0/+0
* | Merge branch 'develop' into pushrules2David Baker2015-03-0429-606/+325
|\|
| * Note that we don't specify execution orderErik Johnston2015-03-041-0/+4
| * s/schema_deltas/applied_schema_deltas/Erik Johnston2015-03-042-9/+11
| * s/%r/%s/Erik Johnston2015-03-041-1/+1
| * Add example directory structures in docErik Johnston2015-03-041-1/+36
| * Don't assume db conn is a Context Manager.Erik Johnston2015-03-041-1/+5
| * Add unique constraint on schema_version.lock schema. Use conflict clause in sql.Erik Johnston2015-03-042-4/+5
| * Change to use logger in db upgrade scriptErik Johnston2015-03-041-1/+4
| * Use context manager with db conn to correctly commit and rollbackErik Johnston2015-03-041-11/+11
| * Actually add full_schemas dirErik Johnston2015-03-0412-0/+645
| * More docs. Rename 'schema/current' to 'schema/full_schemas'Erik Johnston2015-03-0413-652/+23
| * Add some docs and remove unused variablesErik Johnston2015-03-041-8/+10
| * SYN-67: Finish up implementing new database schema managementErik Johnston2015-03-0428-567/+161
| * SYN-67: Begin changing the way we handle schema versioningErik Johnston2015-03-021-38/+106
* | Merge branch 'develop' into pushrules2David Baker2015-03-046-33/+279
|\|
| * Add missing commaErik Johnston2015-03-021-1/+1
| * We purposefully don't have a version 14 delta script.Erik Johnston2015-03-021-1/+1
| * Merge pull request #93 from matrix-org/application-services-exclusiveKegsay2015-03-022-4/+14
| |\
| | * Run deltas and bump user_version in upgrade scriptKegan Dougal2015-03-021-1/+1
| | * Convert expected format for AS regex to include exclusivity.Kegan Dougal2015-02-271-3/+13