Commit Graph

447 Commits (b4890f214948fbb1796861c563b8329c1daf2d29)

Author SHA1 Message Date
Chocobozzz 073deef886
Handle rejected follows in client
Also add quick filters so it's easier to find pending follows
2022-07-27 13:52:13 +02:00
Chocobozzz 927fa4b11f
Add rejected state to follows
Prevent reprocessing already rejected follows
2022-07-27 13:52:13 +02:00
Chocobozzz 0f58b11f5c
Reduce joins need to generate AP url 2022-07-27 13:52:13 +02:00
Chocobozzz 9e2a4af3a0
Use unique AP id for accept/reject 2022-07-25 11:24:05 +02:00
Chocobozzz 1cc9774668
Fix incorrect error logs 2022-07-18 11:55:13 +02:00
Chocobozzz 654d4ede7f
Correctly handle actors without follow counters 2022-07-15 11:18:29 +02:00
Chocobozzz ba2684cedd
Fix lint 2022-07-13 12:14:26 +02:00
Chocobozzz c5cadb2859
Reduce unknown undo logging level 2022-07-13 11:07:01 +02:00
Chocobozzz 14f7ad399f
Add more error logs 2022-07-13 10:17:47 +02:00
Chocobozzz b0f4204266
Relax log level
401 is expected when the token has expired
federation issues are not very important
2022-07-13 10:04:22 +02:00
Chocobozzz 630d0a1bf5
Introduce experimental telemetry 2022-07-06 15:13:55 +02:00
Chocobozzz 4fae2b1f30
Rename video full loading 2022-06-28 15:06:15 +02:00
Chocobozzz fba911e2c8
Merge branch 'release/4.2.0' into develop 2022-06-17 14:17:06 +02:00
Chocobozzz f27b7a750f
Send views in a dedicated queue 2022-06-17 14:08:13 +02:00
Chocobozzz 3396e65345
Optimize broadcast job creation 2022-06-17 11:55:03 +02:00
Chocobozzz 68d6e57870
Fix transaction when processing local viewer 2022-06-17 09:03:28 +02:00
Chocobozzz b89b0bfce9
Clearer video creation from API regarding rates 2022-06-08 15:42:09 +02:00
luz paz 7a4fd56ccd Fix various typos
Found via `codespell -q 3 -S ./CREDITS.md,./CHANGELOG.md,./client/src/locale,./yarn.lock,./client/yarn.lock -L doubleclick,followings,nd,ot,ro,serie,splitted,tread,truthy`
2022-06-07 16:41:21 +02:00
Chocobozzz 4d52690134
Fix schema.org context 2022-06-07 08:47:41 +02:00
Chocobozzz f82ea670d8
Fix collection type 2022-05-09 09:51:11 +02:00
Chocobozzz bae616273d
Convert followers/following in raw SQL queries
Prevent weird bug in SQL generation
2022-05-05 10:29:35 +02:00
Chocobozzz ac907dc7c1 Improve viewer counter
More precise, avoid weird decrease, reuse an id to federate viewers
2022-04-15 09:49:35 +02:00
Chocobozzz b211106695 Support video views/viewers stats in server
* Add "currentTime" and "event" body params to view endpoint
 * Merge watching and view endpoints
 * Introduce WatchAction AP activity
 * Add tables to store viewer information of local videos
 * Add endpoints to fetch video views/viewers stats of local videos
 * Refactor views/viewers handlers
 * Support "views" and "viewers" counters for both VOD and live videos
2022-04-15 09:49:35 +02:00
Chocobozzz a219c9100b
Refactor AP context builder 2022-03-24 09:40:46 +01:00
Chocobozzz 7e98a7df7d
Remove activitypub helper
Put functions in lib/activitypub instead
2022-03-23 14:24:50 +01:00
Chocobozzz f4110e0a72
Update server dependencies 2022-03-21 14:20:47 +01:00
Chocobozzz 57e4e1c1a9
Don't store remote rates of remote videos
In the future we'll stop to expose all available rates to improve users
privacy
2022-03-18 11:21:50 +01:00
Chocobozzz f443a74649 Add latency setting support 2022-03-09 09:23:10 +01:00
kontrollanten d0800f7661
Implement avatar miniatures (#4639)
* client: remove unused file

* refactor(client/my-actor-avatar): size from input

Read size from component input instead of scss, to make it possible to
use smaller avatar images when implemented.

* implement avatar miniatures

close #4560

* fix(test): max file size

* fix(search-index): normalize res acc to avatarMini

* refactor avatars to an array

* client/search: resize channel avatar to 120

* refactor(client/videos): remove unused function

* client(actor-avatar): set default size

* fix tests and avatars full result

When findOne is used only an array containting one avatar is returned.

* update migration version and version notations

* server/search: harmonize normalizing

* Cleanup avatar miniature PR

Co-authored-by: Chocobozzz <me@florianbigard.com>
2022-02-28 08:34:43 +01:00
Chocobozzz 0628157fe9
Move uuid stuff in extra utils
Since it requires an external dependency
2021-12-29 14:44:58 +01:00
Chocobozzz d17c7b4e8c
Fix shared imports 2021-12-24 10:14:47 +01:00
Chocobozzz c55e3d7227
Move test functions outside extra-utils 2021-12-17 12:24:03 +01:00
Chocobozzz 6b5f72beda
Move typescript utils in its own directory 2021-12-16 18:04:16 +01:00
lutangar 06aad80165 chore(refactor): remove shared folder dependencies to the server
Many files from the `shared` folder were importing files from the `server` folder.
When attempting to use Typescript project references to describe dependencies,
it highlighted a circular dependency beetween `shared` <-> `server`.

The Typescript project forbid such usages.
Using project references greatly improve performance by rebuilding only
the updated project and not all source files.
> see https://www.typescriptlang.org/docs/handbook/project-references.html
2021-12-16 10:08:43 +01:00
Chocobozzz ab18fadfd1
Fix AP audience 2021-12-13 17:33:59 +01:00
Chocobozzz b5e1cd9a30
Handle channel owner update of remote server 2021-12-13 16:03:16 +01:00
Chocobozzz 9e847c17f9
No notification on moderator abuse 2021-12-09 14:27:32 +01:00
Chocobozzz 4c99953acd
Fix redundancy timeout 2021-11-29 15:45:02 +01:00
Chocobozzz a2f99b54df
Optimize AP fetch 2021-11-16 10:28:31 +01:00
Chocobozzz 51353d9a03 Refactor video views
Introduce viewers attribute for live videos
Count views for live videos
Reduce delay to see the viewer update for lives
Add ability to configure video views buffer interval and view ip
expiration
2021-11-09 15:00:31 +01:00
Chocobozzz 532e6a4172
Remove aws bug workaround
This has been fixed in https://github.com/aws/aws-sdk-js-v3/pull/2835
2021-10-22 16:30:55 +02:00
Chocobozzz 619537426b
Constants consistency 2021-10-22 10:28:00 +02:00
Chocobozzz 400043b1be
Add ability to search by URL with query params 2021-10-20 15:26:38 +02:00
Chocobozzz 1e2fe802d1
Force live type specification in first step 2021-10-15 11:45:03 +02:00
Chocobozzz bacb544dbb
Remove old federation compatibility 2021-10-15 09:44:21 +02:00
Chocobozzz e1a570abff
Fix user subscription follows count 2021-10-14 10:52:15 +02:00
Chocobozzz 1cf0df024e
Fix actor follow counts calculation 2021-10-13 16:18:42 +02:00
Chocobozzz 9db437c815
Process slow followers in unicast job queue 2021-10-13 11:47:32 +02:00
Chocobozzz 41fb13c330
esModuleInterop to true 2021-08-27 15:12:22 +02:00
Jelle Besseling 0305db28c9
Add support for saving video files to object storage (#4290)
* Add support for saving video files to object storage

* Add support for custom url generation on s3 stored files

Uses two config keys to support url generation that doesn't directly go
to (compatible s3). Can be used to generate urls to any cache server or
CDN.

* Upload files to s3 concurrently and delete originals afterwards

* Only publish after move to object storage is complete

* Use base url instead of url template

* Fix mistyped config field

* Add rudenmentary way to download before transcode

* Implement Chocobozzz suggestions

https://github.com/Chocobozzz/PeerTube/pull/4290#issuecomment-891670478

The remarks in question:
    Try to use objectStorage prefix instead of s3 prefix for your function/variables/config names
    Prefer to use a tree for the config: s3.streaming_playlists_bucket -> object_storage.streaming_playlists.bucket
    Use uppercase for config: S3.STREAMING_PLAYLISTS_BUCKETINFO.bucket -> OBJECT_STORAGE.STREAMING_PLAYLISTS.BUCKET (maybe BUCKET_NAME instead of BUCKET)
    I suggest to rename moveJobsRunning to pendingMovingJobs (or better, create a dedicated videoJobInfo table with a pendingMove & videoId columns so we could also use this table to track pending transcoding jobs)
    https://github.com/Chocobozzz/PeerTube/pull/4290/files#diff-3e26d41ca4bda1de8e1747af70ca2af642abcc1e9e0bfb94239ff2165acfbde5R19 uses a string instead of an integer
    I think we should store the origin object storage URL in fileUrl, without base_url injection. Instead, inject the base_url at "runtime" so admins can easily change this configuration without running a script to update DB URLs

* Import correct function

* Support multipart upload

* Remove import of node 15.0 module stream/promises

* Extend maximum upload job length

Using the same value as for redundancy downloading seems logical

* Use dynamic part size for really large uploads

Also adds very small part size for local testing

* Fix decreasePendingMove query

* Resolve various PR comments

* Move to object storage after optimize

* Make upload size configurable and increase default

* Prune webtorrent files that are stored in object storage

* Move files after transcoding jobs

* Fix federation

* Add video path manager

* Support move to external storage job in client

* Fix live object storage tests

Co-authored-by: Chocobozzz <me@florianbigard.com>
2021-08-17 08:26:20 +02:00