Commit Graph
1503 Commits
Author SHA1 Message Date
Lee Smet 4e923ca59b Run cargo fmt
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 215f13acfd Add rt-multi-thread feature to lib
This can be removed once the block_in_place calls are fixed

Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet d65f2dd2af Announce our own subnet periodically
Previously removed, but we now support this again. We don't advertise
selected subnets, only our own. In a topology where all nodes connect to
a common set of "public" nodes, this means route requests can be
answered by the public nodes without propagating a route lookup.

Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 79bf755b37 Bump babel protocol version
From 2 to 3. This make sure we don't try to incorrectly decode route
requests, at the cost of not being backwards compatible. This is fine
since we are doing a bump from v0.5.x to v0.6.0 anyway.

Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 847b7213d1 Update docs to reflect new message configuration
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 5dde1d0885 Decrease chunk send timeout
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 4aca36beea Fix message systemd dropping final chunk unexpectedly
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 0b39b8459b Fix push message debug line
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 4379f53514 Add forwarding messages to unix sockets
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 18865a046c Fix API docs
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 296552230c Add topic related API methods
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet c8cfbf4a8a Remove unused message feature in mobile config
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 467645c37c Expose topic related functions in node
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 6eed6dd302 Remove duplicated method
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 55e900134e Expose topic forward config methods on MessageStack
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 6161e40d38 Update TopicConfig to contain forward paths
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 6627a85540 Add feature gated topic config in mobile
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet f84577c435 Add topic config mutators on message stack
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet d95112bfe2 Add methods to mutate TopicConfig
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 8d57a1daed Add rwlock for topic config in message stack
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 77e00b01e2 Fix build if message feature is disabled
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 502455569e Add openrpc api
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 7541b2655e Initial openrpc API implementation
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 59447d8098 Allow loading topic configs from myceliumd-private
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet fe3c110402 Allow loading topic configs from myceliumd
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 03e371b20c Add Topic deserializing
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet b07a496a7c Add topic config for messages
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 8b3e71fad8 Add NoRoute API handler to docs.yaml
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 3b65b6f65d Add cli method to get no routes in myceliumd-private
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet acaa03b8e0 Add cli method to get no routes in myceliumd
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 5bbbe6a794 Add NoRoute API handler
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 104850cd4f Expose method to fetch NoRoute subnets from node
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet d6f8d804c0 Expose method to fetch NoRoute subnets from router
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 532737148e Add NoRoute type and iterator
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 10163534d2 Add CLI method for queried routes in myceliumd-private
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet aaed9495a1 Add CLI method for queried routes in myceliumd
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 95a9da6ebd Add CLI functionality to check queried routes
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 15472959bd Fix fallback route handler operation id in api.yaml
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet dd434aea75 Add queried subnets API endpoint to api.yaml
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 4b44c74371 Format API docs
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 3925fe2b22 Add API handler to list queried routes
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet a829854a9a Expose method to load queried routes on node
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 29f1a5c5c5 Expose method to load queried routes on router
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 2f4b531c83 Add iterator for queried subnets
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet e950761526 Check for query resolution faster
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet fd403b0bc5 Remove development log
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet c856a72bca Only return a writeguard for routes if there are routes
Return None in case the entry is queried or not existing, as we
semantically don't have routes in this case. This matches the
implementatin of routes_mut on the WriteGuard

Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 94afd94f27 Use best_routes to look up route for packet
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet 0267b35e6b Properly reply to route requests
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00
Lee Smet b0a60b4294 Perform a route query when looking up shared secret we don't know
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
2025-04-24 14:23:15 +02:00