Evgeny Poberezkin
6ded721daa
remove monad typeclasses to reduce overhead ( #1077 )
...
* remove monad typeclasses to reduce overhead
* remove unliftIO
* StrictData
* inline
* optional agent port
* avoid MonadUnliftIO instance (#1078 )
* avoid MonadUnliftIO instance
* simpler liftError'
* rename
* narrow down instance
* revert
---------
Co-authored-by: Evgeny Poberezkin <evgeny@poberezkin.com >
* logServer
---------
Co-authored-by: Alexander Bondarenko <486682+dpwiz@users.noreply.github.com >
2024-03-31 20:50:35 +01:00
Alexander Bondarenko
7275714b8e
cli: configure server paths from env ( #992 )
2024-02-14 20:31:06 +00:00
Evgeny Poberezkin
577e3cf14d
agent: add server msg IDs to agent logs, disable 2 tests ( #934 )
...
* agent: race when using agent via TCP
* remove logs
* enable tests
* comments
* use different databases for different clients
* enable all tests
2023-12-26 17:50:39 +00:00
Evgeny Poberezkin
560dc55312
agent: notify about polled message processing (for iOS notifications) ( #908 )
...
* agent: notify about polled message processing (for iOS notifications)
* optionally keep key and support re-opening database
* exports
* test that cannot reopen when created with keepKey: false
* set max number of messages to receive for a notification to 3
2023-12-11 13:03:53 +00:00
Evgeny Poberezkin
84ce037867
extend SMP protocol to allow creating new queues without subscriptions ( #839 )
...
* Trace auto-subs flag
* Replace Bools with SubscriptionMode
* Handle SMOnlyCreate
* Wire remaining todos
* Update tests and fix
* Bump protocol level
* Apply suggestions from code review
Co-authored-by: Evgeny Poberezkin <2769109+epoberezkin@users.noreply.github.com >
* Scrub needs_sub from agent DB
* Scrub a few more needSubs from the agent api
* change API, fix test
* agent: do not subscribe to queue when creating reply queue
* fix encoding
* WIP: SMOnlyCreate test
* Add SM guard for confirmQueue
Allows the test case to pump the allowConnection
reply without getting PROHIBITED.
* Remove tracing
* add noMessages, remove unnecessary getConnectionMessage from test
* add sending messages to the test
---------
Co-authored-by: IC Rainbow <aenor.realm@gmail.com >
Co-authored-by: Alexander Bondarenko <486682+dpwiz@users.noreply.github.com >
2023-09-10 17:07:19 +01:00
Alexander Bondarenko
4eb3b8e113
server: add env lookups for smp server paths ( #817 )
...
* Add env lookups for smp server paths
Allows running smp-server without touching system paths.
Can be helpful for running multiple instances.
* allow empty env var values
* diff
* fix
---------
Co-authored-by: Evgeny Poberezkin <2769109+epoberezkin@users.noreply.github.com >
2023-08-26 15:54:26 +01:00
Evgeny Poberezkin
6a665a0833
support down migrations ( #696 )
...
* support down migrations
* test
* update
* add down migrations and tests
* get current migrations
* corrections
Co-authored-by: spaced4ndy <8711996+spaced4ndy@users.noreply.github.com >
* update tests
---------
Co-authored-by: spaced4ndy <8711996+spaced4ndy@users.noreply.github.com >
2023-03-27 12:44:53 +01:00
spaced4ndy
cf147397a4
xftp: agent receive file ( #637 )
...
* xftp: agent receive file draft
* receiveFile more stubs, changes to types, schema
* cabal file
* comments
* xftp_server_id
* schema changes, get client, local worker/action
* agent env, save file description, adjust schema
* client stubs
* download chunk wip, store, schema, types
* remove commented code
* read file description, schema, types
* check received, decrypt
* remove pure
* todo
* add XFTP to agent client
* add user id
* agent test
* tests
* rename supervisor into agent
---------
Co-authored-by: Evgeny Poberezkin <2769109+epoberezkin@users.noreply.github.com >
2023-03-03 18:50:16 +04:00
spaced4ndy
4e8657097c
xftp: cli client draft ( #635 )
...
* xftp: cli client draft
* more stubs
* compiles
* hash, app
* options parsers, random
* tmp
* xftp CLI client agent, simplify CLI command syntax
* only allow argument as a second parameter
* pivot signature draft
* receive file
* pivot sent chunks to recipients
* encryptFile - temp, chunks, specs
* send (upload) file and save file descriptions
* refactor, remove encrypted file
* save file size in description as string
* include filename inside padded encrypted file
* call chunk uploads concurrently, using queueing in HTTP2 as library client does not support concurrent streaming uploads
* download file (does not work yet)
* add digests to sent chunks
* fix recv - save file using AppendMode
* encrypt/decrypt sent file with secretbox
* remove print
* fix file description parsing in tests
* fix test
---------
Co-authored-by: Evgeny Poberezkin <2769109+epoberezkin@users.noreply.github.com >
2023-02-16 14:06:03 +04:00
Stanislav Dmitrenko
bccef0ba47
files: server and client spike - basic upload/download ( #591 )
...
* Files: main, env, stats, storeLog
* Better + transport
* Executable
* Env
* Update Client.hs, Server.hs, and 4 more files...
* Answer on request
* Delay
* Temp file
* Bypass cert check
* update package.yml, rename
* update store log
* extend HTTP2 transport
* refactor caStore
* HTTP2 body
* update server stats
* file server/client framework
* verify server commands
* process FNEW command, CLI test works
* simple XFTP server test (fails)
* fix test, refactor
* upload chunk works
* receive file chunk in the client
* remove transport handshake
* typo
Co-authored-by: spaced4ndy <8711996+spaced4ndy@users.noreply.github.com >
* fix names
---------
Co-authored-by: Evgeny Poberezkin <2769109+epoberezkin@users.noreply.github.com >
Co-authored-by: spaced4ndy <8711996+spaced4ndy@users.noreply.github.com >
2023-02-13 13:36:02 +00:00
Evgeny Poberezkin
f4ad3a983e
support users in agent to isolate traffic of different users ( #598 )
...
* users table, isolate traffic sessions by users or by queues
* remove extra indices
* corrections
Co-authored-by: JRoberts <8711996+jr-simplex@users.noreply.github.com >
Co-authored-by: JRoberts <8711996+jr-simplex@users.noreply.github.com >
2023-01-11 17:47:20 +04:00
Evgeny Poberezkin
40000047af
server: refactor CLIs, tests ( #564 )
...
* server: refactor CLIs, tests
* add files, test
* rename Executable -> Main
2022-11-17 19:43:01 +00:00
Evgeny Poberezkin
e281efdcb8
server: SMP basic auth ( #561 )
...
* server: SMP basic auth
* update ini default
* rfc, types
* tests
* update INI file
* typo
Co-authored-by: JRoberts <8711996+jr-simplex@users.noreply.github.com >
* refactor
* update INI options, log new queue creation mode on start (on/off/requires auth)
Co-authored-by: JRoberts <8711996+jr-simplex@users.noreply.github.com >
2022-11-12 22:29:36 +00:00
Evgeny Poberezkin
6fc3b26970
server: time/detect blocked message delivery actions ( #546 )
...
* server: log slow operations
* v3.3.1
* base-64 encode IDs
* fixing test
* log
* log
* revert
* log
* fix
* reduce timeout
Co-authored-by: JRoberts <8711996+jr-simplex@users.noreply.github.com >
2022-11-02 20:13:09 +00:00
Evgeny Poberezkin
180b4b9dcb
version 3.2.0 ( #499 )
2022-08-16 20:45:35 +01:00
Evgeny Poberezkin
e9db0a1162
allow passing all network configuration to the agent ( #488 )
2022-08-02 13:30:00 +01:00
Evgeny Poberezkin
b8c23ea8d5
3.1.3
2022-08-01 11:36:46 +01:00
Evgeny Poberezkin
b76ef03dbe
ntf: server stats ( #487 )
...
* nts: server stats
* ntf: collect stats, refactor
* rename property
* fixes
2022-08-01 08:42:23 +01:00
Evgeny Poberezkin
fcaddb7848
agent functions to get/set network configuration ( #484 )
...
* agent functions to get/set network configuration
* fix condition
2022-07-25 13:50:46 +01:00
Evgeny Poberezkin
d788c3ca95
access servers via SOCKS proxy ( #482 )
...
* access servers via SOCKS proxy
* config to pass tcp timeout and option SOCKS5 proxy to the agent
2022-07-23 13:57:10 +01:00
Evgeny Poberezkin
e07121266a
3.1.2
2022-07-22 11:29:20 +01:00
Evgeny Poberezkin
0ab90cb204
3.1.1
2022-07-19 15:08:14 +01:00
Evgeny Poberezkin
0b259af9cb
3.1.0
2022-07-18 07:28:19 +01:00
Evgeny Poberezkin
1670c9c05e
3.0.1
2022-07-15 13:25:29 +01:00
Evgeny Poberezkin
cde8a11693
update stats logging and make it opt-in ( #472 )
...
* update stats logging and make it opt-in
* hSetBuffering
* update var name
2022-07-15 13:21:02 +01:00
Evgeny Poberezkin
23496f1a34
v3.0.0 ( #466 )
...
* v3.0.0
* update changelog
2022-07-09 12:12:36 +01:00
Evgeny Poberezkin
cb5ad1619c
update version v3.0.0-rc.1
2022-07-08 14:48:08 +01:00
Evgeny Poberezkin
991548b64d
ntf server: do not resubscribe to error/ended subscriptions on restart ( #464 )
2022-07-06 18:20:49 +01:00
Evgeny Poberezkin
4339218c57
v3.0.0-rc.0
2022-07-05 22:30:44 +01:00
Evgeny Poberezkin
36b4179b8b
update version v3.0.0-beta.4
2022-07-04 10:48:04 +01:00
Evgeny Poberezkin
bc26dc1d68
save and restore server stats on restart ( #460 )
2022-07-04 10:45:35 +01:00
Evgeny Poberezkin
40ae809033
v3.0.0-beta.3 / v1.0.0-beta.3 (ntf)
2022-07-02 15:08:41 +01:00
Evgeny Poberezkin
77f1d45021
fix invalid ini syntax ( #452 )
2022-07-01 22:38:39 +01:00
JRoberts
e622e12a7f
v3.0.0-beta.2 / v1.0.0-beta.2 (ntf)
2022-07-01 15:27:32 +04:00
JRoberts
07bf2bca3b
v3.0.0-beta.0
2022-06-29 16:52:36 +04:00
Evgeny Poberezkin
85d507d5d3
ntf-server store log ( #435 )
...
* ntf-server store log
* ntf serevr: restore log when server is started, save compacted store log
* log ntf server store changes
* test, store log works
* update ntf-server exe
2022-06-28 17:10:50 +01:00
JRoberts
08a4b41691
v2.3.2 ( #414 )
2022-06-21 12:47:40 +04:00
Evgeny Poberezkin
91802fe94f
Merge branch 'master' into f/notifications
2022-06-12 16:49:56 +01:00
Evgeny Poberezkin
0a71822dd0
v2.3.0: save and restore messages when the server is restarted ( #395 )
...
* save and restore messages when server is restarted
* read file line by line
* add import
* optmize restoring messages by reading the whole file
* update version to 2.3.0
* update scripts
* add script
* update readme
2022-06-12 15:59:14 +01:00
Evgeny Poberezkin
c1348aa54f
SMP connection handshake v2 ( #390 )
...
* SMP connection handshake v2
* hadshake v2 [mostly] works
* all tests pass, some race conditions remain
* fix build
* fix race conditions, send CON after all HELLOs in duplexHandshake mode
* add comments
* comment
* add comments
2022-06-09 13:47:07 +01:00
Evgeny Poberezkin
fd410280b5
gracefully close sockets on client disconnection ( #373 )
...
* gracefully close sockets on client disconnection
* remove -threaded
2022-05-24 19:38:14 +01:00
Evgeny Poberezkin
49070fffe0
make server compatible with old ini files ( #372 )
...
* make server compatible with old ini files
* fix
* clean up
2022-05-18 18:30:06 +01:00
Evgeny Poberezkin
4e4eea34f9
server: configuration to expire inactive clients in ini file ( #369 )
...
* server: configuration to expire inactive clients in ini file
* corrections
Co-authored-by: JRoberts <8711996+jr-simplex@users.noreply.github.com >
Co-authored-by: JRoberts <8711996+jr-simplex@users.noreply.github.com >
2022-05-11 15:43:54 +04:00
Evgeny Poberezkin
964daf5442
v2.0.0 ( #360 )
...
* v2.0.0: notification server release
* update changelog
* update changelog
* update changelog
2022-05-03 14:32:37 +01:00
Evgeny Poberezkin
ace94d7c69
log server stats ( #367 )
...
* log server stats
* separate stats updates from the existing transactions
2022-04-30 13:47:21 +01:00
Evgeny Poberezkin
1064e9c315
disconnect inactive clients ( #366 )
...
* disconnect inactive clients
* update test description
* use one thread per client to disconnect inactive clients
* remove comments
* more comments
2022-04-30 10:56:01 +01:00
Evgeny Poberezkin
f718a84335
change log level to error
2022-04-21 17:07:39 +01:00
Evgeny Poberezkin
60d0f19121
Merge branch 'master' into notifications-server
2022-04-20 08:23:26 +01:00
Evgeny Poberezkin
68f52c47dd
message TTL and periodic expiration; setting to prevent creation of the new queues ( #355 )
...
* message TTL and periodic expiration; setting to prevent creation of the new queues
* fix expiration interval
2022-04-20 08:14:26 +01:00
Evgeny Poberezkin
9d8a9c4fe4
interval notifications (TCRN command) ( #352 )
...
* notifications: periodic notifications
* agent: allow repeat token registrations, delete old tokens from notification server (e.g., when database is moved to another device)
* decrypt token verification code in the agent
* check token status, send TCRN on registration if it was enabled
* fix http2/apns response handling for error responses (also, APNS seems not to send content-length header?)
2022-04-17 10:34:51 +01:00