Commit graph

130 commits

Author SHA1 Message Date
Namekuji
6025b0ef30
revert when query failed 2023-07-16 22:30:34 -04:00
Namekuji
9ec9746233
feat: scylladb schema migrator 2023-07-16 22:30:30 -04:00
ThatOneCalculator
bdc35a343e
refactor: 🚨 linting fix 2023-07-16 15:32:32 -07:00
ThatOneCalculator
bb22a671b0
Merge branch 'develop' into rebrand 2023-07-15 14:15:01 -07:00
Namekuji
3fc381c050
refactor: use copy_limit if greater than 0 2023-07-13 18:19:08 -04:00
Namekuji
5291fd4f10
fix: add db to redis uri 2023-07-10 03:54:28 -04:00
Namekuji
b9794dd625
make unused dependencies optional 2023-07-10 03:48:46 -04:00
Namekuji
b6d909f79d
fix config parser 2023-07-10 03:23:38 -04:00
Namekuji
a9ac5fcfec
add environment variable of read size 2023-07-10 02:51:54 -04:00
Namekuji
74eb19acdd
add environment variable to skip copying antenna 2023-07-10 02:31:50 -04:00
Namekuji
4d36c7f4ed
fix: renew entity models 2023-07-10 02:17:30 -04:00
Namekuji
61f0f52d42
copy existing posts in antenna to redis at migration 2023-07-10 01:59:14 -04:00
Laura Hausmann
a315c101d4 Remove debug logging 2023-07-06 02:16:51 +00:00
ThatOneCalculator
6da5a5b89b
find and replace 2023-07-02 15:18:30 -07:00
Laura Hausmann
6c29a2ae01
Fix mastodon api conversion for new note id type 2023-07-01 22:07:08 -07:00
Namekuji
9d56db0fbf
index note url 2023-06-27 15:34:30 -04:00
Namekuji
fd6b655a7c
fix compile error 2023-06-24 04:07:19 -04:00
Namekuji
f7631772a3
cache native-utils 2023-06-22 16:25:42 -04:00
Namekuji
99e1f1ad84
chore: format 2023-06-22 16:00:28 -04:00
Namekuji
3780be57c0
clean unnecessary artifacts 2023-06-22 16:00:28 -04:00
Namekuji
e232332a46
fix build and clean scripts 2023-06-22 16:00:28 -04:00
Kainoa Kanter
55902208e7 docs: 📝 fix formatting 2023-06-15 03:49:17 +00:00
ThatOneCalculator
9fa71f37d7
docs: 📝 sea orm migration "Setting Up Migration" doc link 2023-06-14 20:47:49 -07:00
ThatOneCalculator
fe5834e470
docs: 📝 rudamentary sea-orm-cli instructions 2023-06-14 20:46:54 -07:00
ThatOneCalculator
8f61ff7f33
fix: 🚸 make "show replies in timeline" work as expected
Co-authored-by: Syuilo <syuilotan@yahoo.co.jp>
2023-06-14 20:17:56 -07:00
ThatOneCalculator
266534d35c
fix typo 2023-06-11 23:12:22 -07:00
ThatOneCalculator
9bd03cc92e
update cargo.lock 2023-06-05 18:55:27 -07:00
ThatOneCalculator
5483dd567f
Don't ignore Cargo.lock 2023-06-05 18:49:27 -07:00
Namekuji
cf3f566e06
escape database password as it may contain special characters 2023-06-05 11:59:45 -04:00
ThatOneCalculator
02658fee0b
chore: ⬆️ up various deps 2023-06-03 00:41:30 -07:00
Namekuji
382b009ffd
add cargo test script 2023-06-03 00:40:51 -04:00
Namekuji
15f8a4cbba
cargo formats all modules 2023-06-03 00:37:10 -04:00
Namekuji
d7f80edbea
call seaorm migrations after typeorm 2023-06-03 00:27:00 -04:00
Namekuji
afe4c76392
fix migration 2023-06-02 23:48:28 -04:00
Namekuji
d3d30bbbc2
add integration test of antenna 2023-06-02 23:48:28 -04:00
Namekuji
874b0a2c69
add unit test 2023-06-02 23:48:27 -04:00
Namekuji
7cf2b39cde
fix unit tests 2023-06-02 23:48:27 -04:00
Namekuji
c443a5601c
add format script 2023-06-02 23:48:27 -04:00
Namekuji
0224824a36
fix native import 2023-06-02 23:48:26 -04:00
Namekuji
55118df538
add test 2023-06-02 23:48:25 -04:00
Namekuji
a10ade8cf5
fix unit test 2023-06-02 23:48:24 -04:00
Namekuji
752d63e6de
add native calls 2023-06-02 23:48:24 -04:00
Namekuji
e932d6effa
use schema in native-utils 2023-06-02 23:48:24 -04:00
Namekuji
5e9dce3e8c
adjust module structure 2023-06-02 23:48:23 -04:00
Namekuji
148dbbe56d
move files out from crate 2023-06-02 23:48:23 -04:00
Namekuji
403e95b673
fix unit test 2023-06-02 23:48:22 -04:00
Namekuji
e51deb3794
add napi schema 2023-06-02 23:48:22 -04:00
Namekuji
d0734ef4c9
add pack_by_id 2023-06-02 23:48:22 -04:00
Namekuji
c9f31aef9b
add default values 2023-06-02 23:48:21 -04:00
Namekuji
3eb87c8f04
rename feature 2023-06-02 23:48:21 -04:00
Namekuji
193c75a2bb
skip empty array 2023-06-02 23:48:21 -04:00
Namekuji
d9d2673939
use thread to copy data 2023-06-02 23:48:20 -04:00
Namekuji
3010ac9e74
use iden enum 2023-06-02 23:48:20 -04:00
Namekuji
d28f74b513
fix primary key specifier 2023-06-02 23:48:20 -04:00
Namekuji
98f2397fbb
add migration to convert array to jsonb 2023-06-02 23:48:19 -04:00
Namekuji
745384ff58
use vec newtype 2023-06-02 23:48:19 -04:00
Namekuji
6178593e22
make sqlite compat 2023-06-02 23:48:19 -04:00
Namekuji
354ece6432
add abstraction of string array type 2023-06-02 23:48:18 -04:00
Namekuji
0bd5893e7d
fix varchar array 2023-06-02 23:48:18 -04:00
Namekuji
1455068e0c
add newtype 2023-06-02 23:48:18 -04:00
Namekuji
76e5e31411
todo unread note check 2023-06-02 23:48:17 -04:00
Namekuji
6698c00f78
rename test modules 2023-06-02 23:48:17 -04:00
Namekuji
6bbfe1a6b4
add tests 2023-06-02 23:48:17 -04:00
Namekuji
4012d38f7f
add integration test in model 2023-06-02 23:48:16 -04:00
Namekuji
737ccfe11c
remove mock database 2023-06-02 23:48:16 -04:00
Namekuji
f1f3e5976d
add random string generator 2023-06-02 23:48:15 -04:00
Namekuji
6bb8775b2e
change aid to cuid2 2023-06-02 23:48:15 -04:00
Namekuji
eda1e7ab3b
fix features 2023-06-02 23:48:15 -04:00
Namekuji
00ba8a2804
return mock db when mock feature is enabled 2023-06-02 23:48:14 -04:00
Namekuji
2f9a6859f1
add utility crate 2023-06-02 23:48:14 -04:00
Namekuji
535eb3540b
add mock database 2023-06-02 23:48:14 -04:00
Namekuji
d453eaf4ae
remove unused feature 2023-06-02 23:48:13 -04:00
Namekuji
81ba464f1b
format 2023-06-02 23:48:13 -04:00
Namekuji
9220aa3e4c
remove unused serde 2023-06-02 23:48:13 -04:00
Namekuji
bc0e0b14d0
add repository trait 2023-06-02 23:48:12 -04:00
Namekuji
4e82dab1eb
add entities and two schemas 2023-06-02 23:48:07 -04:00
ThatOneCalculator
655cf3dc27
chore: format 2023-05-29 09:31:02 -07:00
Namekuji
98f9e3e5c4
use cuid2 with timestamp 2023-05-28 22:16:42 -04:00
Kainoa Kanter
7fb130b06e formatting 2023-04-06 18:56:46 -07:00
s1idewhist1e
c58ce6c53b Refactor: use rust for native mastodon id conversion (#9786)
This uses [napi-rs](https://napi.rs/) to allow for automatic generation of node bindings for the native code.

I also changed the `isolatedModules` TS flag to false to allow for `static enum` to be shared across modules. It doesn't seem to be necessary for the build system that CK uses.

Currently this method does not work with ID generators with longer IDs. Likely the best solution is to add another key in the database.

Some benchmarks for 1 million conversions:

```
	node, x1_000_000: 2.847s
	rust, x1_000_000: 1.265s
```

There are still optimizations that can be made, but I think this is a good starting point and a good way to bring rust into the CK stack.

Co-authored-by: s1idewhist1e <trombonedude05@gmail.com>
Reviewed-on: https://codeberg.org/calckey/calckey/pulls/9786
Co-authored-by: s1idewhist1e <s1idewhist1e@noreply.codeberg.org>
Co-committed-by: s1idewhist1e <s1idewhist1e@noreply.codeberg.org>
2023-03-31 01:58:28 +00:00