Mark Haines
646ed87752
Fix infiniteloop
2017-06-06 17:16:20 +01:00
Mark Haines
dc49027f16
Merge branch 'markjh/federation_ingress' into markjh/testing
2017-06-06 10:48:34 +01:00
Mark Haines
db3400d0a7
Comments
2017-06-05 16:54:15 +01:00
Mark Haines
24b34a8498
Put comment back
2017-06-05 16:46:18 +01:00
Mark Haines
5b301d5dc3
Fix append
2017-06-05 16:45:06 +01:00
Mark Haines
08825defef
Fetching missing state from the roomserver.
...
Whenever the syncserver receives an event from the room server that adds
state that isn't in the syncserver's local database it should fetch
those state events from the roomserver.
2017-06-05 16:41:31 +01:00
Robert Swain
def49400bc
cmd/client-api-proxy: Add proxy for media API ( #133 )
2017-06-05 15:55:04 +02:00
Mark Haines
721c2df484
Clean up syncapi storage to match the coding style set by roomserver storage ( #131 )
2017-06-05 10:37:04 +01:00
Mark Haines
f0a639e373
Merge remote-tracking branch 'origin/master' into markjh/federation_ingress
2017-06-02 14:39:20 +01:00
Mark Haines
ef7b934d51
Add Query API for querying events by ID ( #129 )
2017-06-02 14:32:36 +01:00
Mark Haines
1b6e06aa59
Revert "Add API for querying events by ID. ( #127 )" ( #128 )
...
This reverts commit ce82158abb
.
2017-06-02 14:24:13 +01:00
Mark Haines
ee429a56f4
Handle the case where we are missing state
2017-06-02 14:14:49 +01:00
Mark Haines
a024e10054
Merge remote-tracking branch 'origin/master' into markjh/federation_ingress
2017-06-02 11:29:17 +01:00
Mark Haines
ce82158abb
Add API for querying events by ID. ( #127 )
...
* Add API for querying events by ID.
* Fix tense
* Start implementing federation ingress
* More stuff
* Hook up federation event receiving
* Fix comments
* Comment on the order of the arrays
2017-06-02 11:19:34 +01:00
Mark Haines
1b2b837029
Hook up federation event receiving
2017-06-01 20:43:06 +01:00
Mark Haines
32dc94f877
More stuff
2017-06-01 19:03:11 +01:00
Mark Haines
a4a9155623
Start implementing federation ingress
2017-06-01 18:35:09 +01:00
Mark Haines
bf9a3d190e
Fix tense
2017-06-01 18:24:52 +01:00
Mark Haines
e77d9e5329
Add API for querying events by ID.
2017-06-01 18:21:44 +01:00
Robert Swain
3b498c8074
Merge pull request #126 from matrix-org/rob/media-download-remote
...
Add support for downloading of remote files
2017-06-01 18:01:42 +02:00
Robert Swain
7244fc15b3
media/writers/download: Make use of CreateMediaDownloadRequest from lib
2017-06-01 17:57:05 +02:00
Robert Swain
0fff33928e
vendor: Bump gomatrixserverlib to pull in CreateMediaDownloadRequest
2017-06-01 17:56:30 +02:00
Robert Swain
a398cdd193
mediaapi/writers/download: Use mime.ParseMediaType to parse Content-Disposition
2017-06-01 16:04:41 +02:00
Robert Swain
2d822c57f9
mediaapi/writers/download: Use DNS address as not all HSes have SRV
2017-06-01 15:30:36 +02:00
Robert Swain
cae309fa26
mediaapi/writers/download: Handle panic to ensure waking of goroutines
...
If the active request were to panic, we need to ensure all the waiting
goroutines get woken up.
2017-06-01 14:54:59 +02:00
Robert Swain
ce21b32d38
mediaapi/writers/download: Wrap broadcast call in closure to re-evaluate args
2017-06-01 14:44:00 +02:00
Robert Swain
4457ebddca
mediaapi/writers/download: Rework remote file download synchronisation
...
Avoid locking around db requests by only locking around active requests
and always creating an active request if there is none. A nice side
effect of this is that if many parallel requests for remote media come
in (a common case) then only one database query is made for the duration
of the query.
2017-06-01 12:32:15 +02:00
Robert Swain
a3b1c7535a
mediaapi/writers/download: Remove unnecesary Unlock, Lock after Cond.Wait
2017-06-01 08:39:35 +02:00
Robert Swain
923013aa55
mediaapi: Add support for downloading of remote files
2017-05-31 17:56:11 +02:00
Robert Swain
07c821daec
mediaapi/writers: Fix InternalServerError responses
2017-05-31 17:41:42 +02:00
Robert Swain
57ba466da1
Merge pull request #125 from matrix-org/rob/media-download-local
...
mediaapi/writers/download: Add local download support
2017-05-31 15:47:43 +02:00
Robert Swain
2e013e3408
mediaapi/writers/download: Remove unnecessary closeConnection()
2017-05-31 15:39:19 +02:00
Robert Swain
bd96d99a3a
mediaapi/writers/download: 500 ISE if disk and db file size differ
2017-05-31 15:08:00 +02:00
Robert Swain
e33438a37e
mediaapi/writers/upload: Add standard fields to logger
...
So that they apply to all log messages thereafter
2017-05-31 14:54:10 +02:00
Robert Swain
5922ad383d
mediaapi/writers/upload: Don't use deprecated sql.ErrNoRows check
2017-05-31 14:52:45 +02:00
Robert Swain
f0c717b0a1
mediaapi/writers/download: Escalate corrupt db/file cases to errors
2017-05-31 14:33:49 +02:00
Robert Swain
9606ea28ce
mediaapi/writers/download: Always log origin and mediaID
2017-05-31 14:30:57 +02:00
Robert Swain
a45f008c12
mediaapi/storage: Don't leak sql.ErrNoRows out of storage package
2017-05-31 14:29:28 +02:00
Robert Swain
a936ad5063
mediaapi/writers/download: Add local download support
2017-05-31 13:46:21 +02:00
Robert Swain
3f7ef7690b
Merge pull request #124 from matrix-org/rob/media-api-upload
...
/upload handler and storage database
2017-05-31 12:32:10 +02:00
Robert Swain
a0eae6922d
mediaapi/writers: Remove unnecessary fmt.Sprintf
2017-05-31 07:12:22 +02:00
Robert Swain
08d1eb9669
mediaapi/upload: Improve HTTP status codes for error cases
2017-05-31 07:11:21 +02:00
Robert Swain
523303277e
mediaapi/storage: Refer to RFC instead of golang for base64 format
2017-05-31 07:11:00 +02:00
Robert Swain
61329ee380
mediaapi/fileutils: Comment truncation of data when reading
2017-05-31 07:10:01 +02:00
Robert Swain
a4300eefc4
mediaapi/fileutils: Fix and comment os.IsNotExist bug
2017-05-31 07:08:21 +02:00
Robert Swain
63ccd770c6
mediaapi/fileutils: Use filepath not path for filesystem paths
2017-05-31 07:07:48 +02:00
Robert Swain
0ca2931b62
mediaapi/fileutils: Change path schema to put file in subdir of hash
2017-05-31 07:06:42 +02:00
Robert Swain
8c6f30eadc
mediaapi/config: Remove obsolete proxying comment and add default comment
2017-05-31 07:05:07 +02:00
Kegsay
50aacd4f3c
Hook up registration/login APIs and implement access token generation ( #122 )
2017-05-30 17:51:40 +01:00
Mark Haines
65b66a6452
Add API for querying the state after a list of events ( #123 )
...
* Add API for querying the state after a list of events
* Implement state after events API
* Actually implement the API
* Reorder .travis.yml
* Comments
* Use common.MakeAPI
2017-05-30 17:44:31 +01:00