Nikita Vilunov
8a8cb0da5c
style
2024-05-25 23:16:45 +02:00
Mikhail
ca908dea12
Change from to try_from
2024-05-25 19:10:05 +02:00
Mikhail
538de5e849
Merge remote-tracking branch 'lavina/main' into feature/muc-join-messages
2024-05-25 18:11:47 +02:00
Nikita Vilunov
bce8b332d2
irc: handle repeated joins correctly
2024-05-25 12:40:58 +02:00
Mikhail
cb5651c528
Test serialization
2024-05-25 11:37:43 +02:00
Mikhail
021bde729c
Sketch a serialization test
2024-05-24 20:07:40 +02:00
Mikhail
8d2e56fac9
Move delay namespace out of the constructor
2024-05-24 19:25:08 +02:00
Mikhail
6def71b581
Serialize delay separately
2024-05-24 11:33:45 +02:00
Mikhail
8dff974df8
Add tracing info
2024-05-24 11:03:04 +02:00
Mikhail
85c8d03f54
Make fields public
2024-05-24 10:55:11 +02:00
Mikhail
9ae34c99d3
Remove unused
2024-05-24 10:52:53 +02:00
Mikhail
7a75b3fbd1
Change default ordering
2024-05-24 10:51:52 +02:00
Mikhail
6ce8c7a99f
Merge remote-tracking branch 'lavina/main' into feature/muc-join-messages
2024-05-24 10:45:48 +02:00
Mikhail
d02c394e34
Rename
2024-05-23 20:53:57 +02:00
Mikhail
f9eb510062
Read and serve
2024-05-23 20:52:03 +02:00
Mikhail
7e1c4fd939
Rename and remove commented
2024-05-23 19:10:27 +02:00
Mikhail
09abdd5346
Use vectors and commands
2024-05-23 18:02:35 +02:00
Nikita Vilunov
580923814b
xmpp: send user-item and empty room subject on muc join ( #69 )
...
Co-authored-by: Mikhail <mikhail@liamets.dev>
Reviewed-on: lavina/lavina#69
2024-05-22 09:29:44 +00:00
Mikhail
6285a31c85
Remove commented
2024-05-18 20:37:16 +02:00
Mikhail
7ccb76d0df
Fake to and from
2024-05-18 20:35:31 +02:00
Mikhail
d00d57ac44
Sketch message response
2024-05-18 20:18:42 +02:00
Nikita Vilunov
1b59250042
xmpp: add x-user element to muc presence response ( #67 )
...
Reviewed-on: lavina/lavina#67
2024-05-14 14:44:49 +00:00
Nikita Vilunov
89918d9de1
xmpp: add item-not-found error condition to room disco#info iq
2024-05-13 16:42:52 +02:00
Nikita Vilunov
26720a2a08
core: separate the model from the logic implementation ( #66 )
...
This separates the core in two layers – the model objects and the `LavinaCore` service. Service is responsible for implementing the application logic and exposing it as core's public API to projections, while the model objects will be independent of each other and responsible only for managing and owning in-memory data.
The model objects include:
1. `Storage` – the open connection to the SQLite DB.
2. `PlayerRegistry` – creates, stores refs to, and stops player actors.
3. `RoomRegistry` – manages active rooms.
4. `DialogRegistry` – manages active dialogs.
5. `Broadcasting` – manages subscriptions of players to rooms on remote cluster nodes.
6. `LavinaClient` – manages HTTP connections to remote cluster nodes.
7. `ClusterMetadata` – read-only configuration of the cluster metadata, i.e. allocation of entities to nodes.
As a result:
1. Model objects will be fully independent of each other, e.g. it's no longer necessary to provide a `Storage` to all registries, or to provide `PlayerRegistry` and `DialogRegistry` to each other.
2. Model objects will no longer be `Arc`-wrapped; instead the whole `Services` object will be `Arc`ed and provided to projections.
3. The public API of `lavina-core` will be properly delimited by the APIs of `LavinaCore`, `PlayerConnection` and so on.
4. `LavinaCore` and `PlayerConnection` will also contain APIs of all features, unlike it was previously with `RoomRegistry` and `DialogRegistry`. This is unfortunate, but it could be improved in future.
Reviewed-on: lavina/lavina#66
2024-05-13 14:32:45 +00:00
Nikita Vilunov
d1a72e7978
move repo methods into submodules and clean up warnings
2024-05-10 23:50:34 +02:00
Nikita Vilunov
6749103726
scalability: initial support for remote rooms ( #61 )
...
Reviewed-on: lavina/lavina#61
2024-05-10 20:44:24 +00:00
Mikhail
3b454ad7cd
xmpp: unit-tests for resource bind it and muc presence
...
Reviewed-on: lavina/lavina#64
Co-authored-by: Mikhail <mikhail@liamets.dev>
Co-committed-by: Mikhail <mikhail@liamets.dev>
2024-05-10 13:35:34 +00:00
Mikhail
5512a74999
Check if user is a member before inserting a membership ( #62 )
...
It would typically fail on insertion due to uniqueness constraints: user id - room id.
Reviewed-on: lavina/lavina#62
Co-authored-by: Mikhail <mikhail@liamets.dev>
Co-committed-by: Mikhail <mikhail@liamets.dev>
2024-05-08 22:10:32 +00:00
Nikita Vilunov
bb0fe3bf0b
use borrows in http endpoint handlers
2024-05-05 19:24:42 +02:00
Nikita Vilunov
8ac64ba8f5
get rid of storage usages in projections
2024-05-05 19:24:23 +02:00
homycdev
abe9a26925
irc: implement WHOIS command ( #43 )
...
Reviewed-on: lavina/lavina#43
Co-authored-by: homycdev <abdulkhamid98@gmail.com>
Co-committed-by: homycdev <abdulkhamid98@gmail.com>
2024-05-05 17:21:40 +00:00
Mikhail
adf1d8c14c
xmpp: Implement Message Archive Management stub for XEP-0313 ( #60 )
...
https://xmpp.org/extensions/xep-0313.html
Reviewed-on: lavina/lavina#60
Co-authored-by: Mikhail <mikhail@liamets.dev>
Co-committed-by: Mikhail <mikhail@liamets.dev>
2024-05-05 15:12:58 +00:00
Nikita Vilunov
9a09ff717e
management api endpoints for rooms
2024-05-01 17:30:31 +02:00
Nikita Vilunov
a87f7c9d73
xmpp: extract common fragments of integration tests into functions
2024-04-29 23:56:18 +02:00
Nikita Vilunov
25605322a0
player shutdown API ( #58 )
...
Reviewed-on: lavina/lavina#58
2024-04-29 17:24:43 +00:00
Nikita Vilunov
31f9da9b05
xmpp: fix incorrect auth test
2024-04-29 19:13:32 +02:00
Nikita Vilunov
c1dc2df150
xmpp: document xml parsing types
2024-04-28 17:29:31 +02:00
Nikita Vilunov
c69513f38b
xmpp: use mutable namespace and event in parser coroutines
2024-04-28 17:19:31 +02:00
Nikita Vilunov
8ec9ecfe2c
xmpp: handle incorrect credentials by replying with an error
2024-04-28 17:11:29 +02:00
Nikita Vilunov
a047d55ab5
xmpp: handle correctly unavailable self-presence and improve basic test scenario
2024-04-28 15:43:22 +02:00
Nikita Vilunov
ea81ddadfc
dialog message persistence
2024-04-27 12:58:27 +02:00
Nikita Vilunov
4ff09ea05f
tracing otlp exporter and instrumentation annotations ( #57 )
...
Resolves #56
Reviewed-on: lavina/lavina#57
2024-04-26 10:16:23 +00:00
Nikita Vilunov
ec49489ef1
validate that rooms and dialogs are owned exclusively on shutdown
2024-04-23 19:18:46 +02:00
Nikita Vilunov
d305f5bf77
argon2-based password hashing ( #55 )
...
Reviewed-on: lavina/lavina#55
2024-04-23 16:31:00 +00:00
Nikita Vilunov
799da8366c
basic dialog implementation with irc and xmpp support ( #53 )
...
Reviewed-on: lavina/lavina#53
2024-04-23 16:26:40 +00:00
Nikita Vilunov
d805061d5b
refactor auth logic into a common module ( #54 )
...
Reviewed-on: lavina/lavina#54
2024-04-23 10:10:10 +00:00
Nikita Vilunov
6c08d69f41
sasl: remove unused code
2024-04-23 00:41:54 +02:00
Nikita Vilunov
12d30ca5c2
irc: implement server-time capability for incoming messages ( #52 )
...
Spec: https://ircv3.net/specs/extensions/server-time
Reviewed-on: lavina/lavina#52
2024-04-21 21:00:44 +00:00
Nikita Vilunov
ddb348bee9
refactor lavina core by grouping public services into a new LavinaCore struct.
...
this will be useful in future when additional services will be introduced and passed as dependencies
2024-04-21 19:45:50 +02:00
Nikita Vilunov
5a09b743c9
return AlreadyJoined when a player attempts to join a room they are already in
2024-04-20 17:09:44 +02:00