Skip to content
Snippets Groups Projects
  1. Oct 15, 2020
  2. Oct 14, 2020
  3. Oct 13, 2020
  4. Oct 12, 2020
    • Erik Johnston's avatar
      Make event persisters periodically announce position over replication. (#8499) · 8de3703d
      Erik Johnston authored
      Currently background proccesses stream the events stream use the "minimum persisted position" (i.e. `get_current_token()`) rather than the vector clock style tokens. This is broadly fine as it doesn't matter if the background processes lag a small amount. However, in extreme cases (i.e. SyTests) where we only write to one event persister the background processes will never make progress.
      
      This PR changes it so that the `MultiWriterIDGenerator` keeps the current position of a given instance as up to date as possible (i.e using the latest token it sees if its not in the process of persisting anything), and then periodically announces that over replication. This then allows the "minimum persisted position" to advance, albeit with a small lag.
      Unverified
      8de3703d
  5. Oct 09, 2020
    • Patrick Cloke's avatar
    • Richard van der Hoff's avatar
      Fix threadsafety in ThreadedMemoryReactorClock (#8497) · 9789b1fb
      Richard van der Hoff authored
      This could, very occasionally, cause:
      
      ```
      tests.test_visibility.FilterEventsForServerTestCase.test_large_room
      ===============================================================================
      [ERROR]
      Traceback (most recent call last):
        File "/src/tests/rest/media/v1/test_media_storage.py", line 86, in test_ensure_media_is_in_local_cache
          self.wait_on_thread(x)
        File "/src/tests/unittest.py", line 296, in wait_on_thread
          self.reactor.advance(0.01)
        File "/src/.tox/py35/lib/python3.5/site-packages/twisted/internet/task.py", line 826, in advance
          self._sortCalls()
        File "/src/.tox/py35/lib/python3.5/site-packages/twisted/internet/task.py", line 787, in _sortCalls
          self.calls.sort(key=lambda a: a.getTime())
      builtins.ValueError: list modified during sort
      
      tests.rest.media.v1.test_media_storage.MediaStorageTests.test_ensure_media_is_in_local_cache
      ```
      Unverified
      9789b1fb
    • Andrew Morgan's avatar
      Allow modules to create and send events into rooms (#8479) · 66ac4b1e
      Andrew Morgan authored
      This PR allows Synapse modules making use of the `ModuleApi` to create and send non-membership events into a room. This can useful to have modules send messages, or change power levels in a room etc. Note that they must send event through a user that's already in the room.
      
      The non-membership event limitation is currently arbitrary, as it's another chunk of work and not necessary at the moment.
      Unverified
      66ac4b1e
    • Patrick Cloke's avatar
      Remove the deprecated Handlers object (#8494) · c9c0ad5e
      Patrick Cloke authored
      All handlers now available via get_*_handler() methods on the HomeServer.
      Unverified
      c9c0ad5e
  6. Oct 08, 2020
  7. Oct 07, 2020
  8. Oct 06, 2020
  9. Oct 05, 2020
  10. Oct 02, 2020
  11. Oct 01, 2020
  12. Sep 30, 2020
    • Erik Johnston's avatar
      Make token serializing/deserializing async (#8427) · 7941372e
      Erik Johnston authored
      The idea is that in future tokens will encode a mapping of instance to position. However, we don't want to include the full instance name in the string representation, so instead we'll have a mapping between instance name and an immutable integer ID in the DB that we can use instead. We'll then do the lookup when we serialize/deserialize the token (we could alternatively pass around an `Instance` type that includes both the name and ID, but that turns out to be a lot more invasive).
      Unverified
      7941372e
    • Patrick Cloke's avatar
    • Richard van der Hoff's avatar
      Rewrite BucketCollector · 6d2d42f8
      Richard van der Hoff authored
      This was a bit unweildy for what I wanted: in particular, I wanted to assign
      each measurement straight into a bucket, rather than storing an intermediate
      Counter which didn't do any bucketing at all.
      
      I've replaced it with something that is hopefully a bit easier to use.
      
      (I'm not entirely sure what the difference between a HistogramMetricFamily and
      a GaugeHistogramMetricFamily is, but given our counters can go down as well as
      up the latter *sounds* more accurate?)
      6d2d42f8
  13. Sep 29, 2020
Loading