about summary refs log tree commit diff
path: root/users
AgeCommit message (Collapse)AuthorFilesLines
2023-11-25 r/7057 fix(tazjin/emacs): pick new primary monitor when disabling currentVincent Ambo1-3/+15
By default, this will be the (only) remaining monitor. In N>2 situations, ask the user. Change-Id: Id68fcf60d56d0414d1072b8ffeef72c608678f52 Reviewed-on: https://cl.tvl.fyi/c/depot/+/10121 Autosubmit: tazjin <tazjin@tvl.su> Reviewed-by: tazjin <tazjin@tvl.su> Tested-by: BuildkiteCI
2023-11-25 r/7056 feat(tazjin/emacs): add interactive commands for configuring screensVincent Ambo1-0/+52
Uses a bunch of weird xrandr invocations and completing reads to configure screens the way I want. Note that this has a known bug where disconnecting a primary screen will *not* make one of the remaining screens primary. Change-Id: Ide5322df446685cc4740d4ddd7b6ca8682375050 Reviewed-on: https://cl.tvl.fyi/c/depot/+/10120 Reviewed-by: tazjin <tazjin@tvl.su> Autosubmit: tazjin <tazjin@tvl.su> Tested-by: BuildkiteCI
2023-11-22 r/7044 fix(3p/exwm): fix EXWM build with depot sourcesVincent Ambo1-1/+1
Something changed in the machinery and broke the overriding. I didn't notice this, as a I was temporarily using an unpatched EXWM. Change-Id: I1a4e8ea63bd116d86a430e680c2b631474e9a0fe Reviewed-on: https://cl.tvl.fyi/c/depot/+/10047 Reviewed-by: tazjin <tazjin@tvl.su> Tested-by: BuildkiteCI
2023-11-19 r/7036 feat(users/flokli/keyboard): align 3rd layer with thinkpadFlorian Klink1-1/+2
Make these keys behave a bit more like the Fn+F* keys on the thinkpad keyboards. Seems there's currently no trivial way to get mic mute, keyboard mute and wifi toggle sent out, but considering the thinkpad usb keyboard is able to, this should be possible somehow here too - but not today, left for a followup. Change-Id: I529a958c78116dd9f7250c938e2e7989b296d6c6 Reviewed-on: https://cl.tvl.fyi/c/depot/+/10076 Autosubmit: flokli <flokli@flokli.de> Tested-by: BuildkiteCI Reviewed-by: flokli <flokli@flokli.de>
2023-11-14 r/7013 fix(users/flokli/archeology/parse_bucket_logs): fix regex and skipFlorian Klink1-1/+2
It seems the regex is not perfect, it choked on a single log line: ``` Nov 13 03:10:19 archeology-ec2 59nkrwmih3ywaxrgxqj79pn395fs6m17-parse-bucket-logs-continuously[11105]: Code: 117. DB::Exception: Line "d57bd890fbd1ae16625bdb8168064125e013198099b7e1b3c24878a4d03c3ab8 nix-cache [12/Nov/2023:09:13:02 +0000] xxx.xx.xxx.xxx - VB7SJVZ108DSSN67 REST.POST.OBJECT index.html "POST /index.html HTTP/1.1" 405 MethodNotAllowed 348 - 4 - "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/39.0.2171.95 Safari/537.36" - 0bFdGKbi0n9JHXU1a2hijcJwmYdc6lG2xgbdozc3wS6mlUkBE7ssrQCHIDdOLebo78o2cGbhivY= - ECDHE-RSA-AES128-GCM-SHA256 - nix-cache.s3.amazonaws.com TLSv1.2 - -" doesn't match the regexp.: (in file/uri log/2023-11-12-10-19-50-80805A702ECF65EB): (at row 5) ``` This was due to the user-agent field. The regex is now fixed. The request itself is fun (someone trying to POST an index.html to the bucket), and we should probably filter this on the Fastly side already, not via IAM, In any case, there's no point failing to parse if a single line doesn't match the regex - we can just skip them. For the sake of completeness, logs for that day have been reprocessed and reuploaded. Change-Id: Id98a7167a381cda06d150ad5118ee9e70ead277e Reviewed-on: https://cl.tvl.fyi/c/depot/+/10034 Tested-by: BuildkiteCI Reviewed-by: flokli <flokli@flokli.de>
2023-11-14 r/7012 feat(users/flokli/archeology): install parquet-toolsedef1-0/+1
Change-Id: I64cd83fbce920eeabace5b49ef623c033d98a8be Reviewed-on: https://cl.tvl.fyi/c/depot/+/10000 Reviewed-by: flokli <flokli@flokli.de> Tested-by: BuildkiteCI
2023-11-14 r/7011 feat(users/flokli/archeology): install DuckDBedef1-0/+1
Change-Id: I76bc20711c7e59d184659db134ba224cfcd7f6cb Reviewed-on: https://cl.tvl.fyi/c/depot/+/9999 Tested-by: BuildkiteCI Reviewed-by: flokli <flokli@flokli.de>
2023-11-13 r/7010 feat(users/grfn/web): Update work sectionAspen Smith1-4/+8
I no longer work at ReadySet. Change-Id: Idc19e2d68846551b6cd94f84594712692ebe35a9 Reviewed-on: https://cl.tvl.fyi/c/depot/+/9976 Tested-by: BuildkiteCI Autosubmit: grfn <grfn@gws.fyi> Reviewed-by: grfn <grfn@gws.fyi>
2023-11-13 r/7009 feat(users/flokli/archeology): turn on task_delayacctedef1-0/+6
More ClickHouse perf stats ^_^ Change-Id: I4f6882b1a6c1ebfed9a430e62ca634a141cd1cf1 Reviewed-on: https://cl.tvl.fyi/c/depot/+/9998 Reviewed-by: flokli <flokli@flokli.de> Tested-by: BuildkiteCI
2023-11-13 r/7008 feat(users/flokli/keyboard): add missing KC_PSCRFlorian Klink1-1/+1
Change-Id: I005defb868151ecec95e710523db3d23c859e489 Reviewed-on: https://cl.tvl.fyi/c/depot/+/10021 Reviewed-by: flokli <flokli@flokli.de> Autosubmit: flokli <flokli@flokli.de> Tested-by: BuildkiteCI
2023-11-13 r/7007 feat(users/flokli/keyboard): initFlorian Klink3-0/+116
This packages up my keyboard firmware used for the Keychron K6 Pro. We add a custom keymap to the `keyboards/keychron/k6_pro/ansi/rgb/ keymaps` directory, a copy from the `default` one (with a modified `keymap.c`), and then build that as a makefile target. `via` is *disabled*, as their keybindings take priority over keymap.c. Luckily, only `qmk` seems to be sufficient to build it. A simple `:flash` target/script is provided as well, it relies on some udev rules set in the global system (`hardware.keyboard.qmk.enable = true`). Change-Id: I9f7a7a992e13516c32033127f94e37aec62d6b67 Reviewed-on: https://cl.tvl.fyi/c/depot/+/10020 Reviewed-by: flokli <flokli@flokli.de> Tested-by: BuildkiteCI
2023-11-12 r/7003 feat(users/flokli/archeology): add AWS config to shellFlorian Klink1-1/+14
This allows using awscli inside a shell. Clickhouse AWS SSO integration still seems broken unfortunately, even with https://github.com/ClickHouse/ClickHouse/pull/54347 included in our bump - it seems it's coming up with another token file path than the AWS SDK: > SSOCredentialsProvider: Unable to open token file on path: /home/flokli/.aws/sso/cache/da39a3ee5e6b4b0d3255bfef95601890afd80709.json This is the sha1sum of the sso_start_url, not the sha1sum of the session-name (nixos / f2f059b8b7298f1ad52636d67cef8b719aa83bf5). Change-Id: Ia1bdec03c4f269a7415c42c90c1f4fd3d928f770 Reviewed-on: https://cl.tvl.fyi/c/depot/+/10012 Reviewed-by: edef <edef@edef.eu> Tested-by: BuildkiteCI
2023-11-12 r/7000 chore(tazjin/tgsa): bump cargo dependenciesVincent Ambo1-226/+294
Fixes: - RUSTSEC-2023-0044 - RUSTSEC-2023-0018 Change-Id: Ifc1acce5696f9ec584ac7790d3a99f8ad7d28707 Reviewed-on: https://cl.tvl.fyi/c/depot/+/10014 Tested-by: BuildkiteCI Reviewed-by: tazjin <tazjin@tvl.su>
2023-11-12 r/6999 chore(tazjin/yddns): bump cargo dependenciesVincent Ambo1-360/+312
Fixes RUSTSEC-2023-0053. Change-Id: I6b9fc31dad405b7f9fc21c27fc7beee3687a4572 Reviewed-on: https://cl.tvl.fyi/c/depot/+/10013 Tested-by: BuildkiteCI Reviewed-by: tazjin <tazjin@tvl.su>
2023-11-12 r/6997 feat(tazjin/blog): import blog post on emacs buffer switching thingVincent Ambo2-0/+24
This was previously only in my Telegram channel, but it might as well be on the blog itself. Change-Id: I301ebeaa4dd1875f3858cee5259a5c689b950790 Reviewed-on: https://cl.tvl.fyi/c/depot/+/10009 Reviewed-by: tazjin <tazjin@tvl.su> Autosubmit: tazjin <tazjin@tvl.su> Tested-by: BuildkiteCI
2023-11-12 r/6996 feat(users/flokli/nixos/archeology-ec2): automate bucket log parsingFlorian Klink2-0/+80
This adds a `parse-bucket-logs.{service,timer}`, running once every night at 3AM UTC, figuring out the last time it was run and parsing bucket logs for all previous days. It invokes the `archeology-parse-bucket-logs` script to produce a .parquet file with the bucket logs in `s3://nix-cache-log/log/` for that day (inside a temporary directory), then on success uploads the produced parquet file to `s3://nix-archeologist/nix-cache-bucket-logs/yyyy-mm-dd.parquet`. Change-Id: Ia75ca8c43f8074fbaa34537ffdba68350c504e52 Reviewed-on: https://cl.tvl.fyi/c/depot/+/10011 Reviewed-by: edef <edef@edef.eu> Tested-by: BuildkiteCI
2023-11-11 r/6994 fix(users/flokli/archaeology): don't use file but column compressionFlorian Klink1-2/+5
Clickhouse also has column compression, configurable with the output_format_parquet_compression_method setting. It defaults to lz4, and the previous setting got a a zstd-compressed parquet file with lz4 data. Set output_format_parquet_compression_method to zstd instead, and sort by timestamp before assembling the parquet file. The existing files were updated to the same format with the following query: ``` SELECT * FROM file('bucket_logs_2023-11-11*.pq', 'Parquet', 'auto') ORDER BY timestamp ASC INTO OUTFILE 'bucket_logs_2023-11-11.parquet' SETTINGS output_format_parquet_compression_method = 'zstd' ``` Change-Id: Id63b14c82e7bf4b9907a500528b569a51e277751 Reviewed-on: https://cl.tvl.fyi/c/depot/+/10008 Reviewed-by: raitobezarius <tvl@lahfa.xyz> Tested-by: BuildkiteCI
2023-11-11 r/6993 feat(users/flokli/nixos/archeology-ec2): add parse-bucket-logsFlorian Klink1-0/+4
This adds a `archeology-parse-bucket-logs` CLI tool to `$PATH`. It can be invoked like this: ``` archeology-parse-bucket-logs http://nix-cache-log.s3.amazonaws.com/log/2023-11-10-00-* bucket_logs_2023-11-10-00.pq.zstd ```` … and will produce a zstd-compressed Parquet file for (roughly) that time range. As the EC2 instance credentials don't give access to the logs bucket (yet), other AWS credentials need to be provided. This can be accomplished by using "AWS_ACCESS_KEY_ID", "AWS_SECRET_ACCESS_KEY", "AWS_SESSION_TOKEN" from "Option 2: Manually add a profile to your AWS credentials file (Short- term credentials)" in AWS IAM Identity Center. Processing logs for a one-hour range takes a minute or two, the resulting zstd-compressed Parquet file is around 40-80M in size. Processing logs for a whole day takes some 25mins, due to the sheer amount of data (12 GB of raw log data, distributed among 450k individual files, 20Mio log lines), but at least clickhouse isn't able to parse the resulting parquet file back in: > Code: 36. DB::Exception: IOError: Couldn't deserialize thrift: MaxMessageSize reached For future automation tasks, it's probably better to run this once an hour, and further join the data later on. Change-Id: I6c8108c0ec17dc8d4e2dbe923175553325210a5c Reviewed-on: https://cl.tvl.fyi/c/depot/+/10007 Tested-by: BuildkiteCI Reviewed-by: raitobezarius <tvl@lahfa.xyz>
2023-11-11 r/6992 fix(users/flokli/archeology): make clickhouse use ambient AWS credsFlorian Klink1-1/+22
Rather than picking up from clickhouse-specific config files, this gets it to pick up from the ambient environment, which is closer to (but not the same as) the AWS default credentials chain. Change-Id: I9c498c231974ed345c3e3d354ec230052b4d0ff2 Reviewed-on: https://cl.tvl.fyi/c/depot/+/10006 Tested-by: BuildkiteCI Reviewed-by: raitobezarius <tvl@lahfa.xyz>
2023-11-11 r/6991 feat(users/flokli/archeology): show clickhouse-local progressFlorian Klink1-1/+2
This behaviour might change (or not), see https://github.com/ClickHouse/ ClickHouse/pull/42003, but as of now, a `--progress` will provide some progress. Change-Id: I4891b6e2f96f2656858e71f88a226d24f0d45dc3 Reviewed-on: https://cl.tvl.fyi/c/depot/+/10005 Reviewed-by: raitobezarius <tvl@lahfa.xyz> Tested-by: BuildkiteCI
2023-11-11 r/6990 feat(users/flokli/archeology): add shellFlorian Klink1-0/+5
Change-Id: Ic34fefdaac82fd1e23d248f2e5fec282384b8fc0 Reviewed-on: https://cl.tvl.fyi/c/depot/+/9984 Tested-by: BuildkiteCI Reviewed-by: raitobezarius <tvl@lahfa.xyz>
2023-11-11 r/6989 feat(users/flokli/archeology): init parse-bucket-logsFlorian Klink4-0/+55
Change-Id: I096b6fed8c73ddd5a417f5183cc113356ffd98c9 Reviewed-on: https://cl.tvl.fyi/c/depot/+/9983 Tested-by: BuildkiteCI Reviewed-by: raitobezarius <tvl@lahfa.xyz>
2023-11-06 r/6969 feat(users/grfn/web): Purge cloudflare cache on deployAspen Smith3-9/+39
Change-Id: Iebaff500bc7bbb92ff4344f185a3b446f9ce9eb9 Reviewed-on: https://cl.tvl.fyi/c/depot/+/9975 Autosubmit: grfn <grfn@gws.fyi> Reviewed-by: grfn <grfn@gws.fyi> Tested-by: BuildkiteCI
2023-11-06 r/6968 feat(grfn/emacs): Refresh org-captureAspen Smith1-7/+2
Change-Id: I67906dc2933fd46f4babe1542a498da131788f21 Reviewed-on: https://cl.tvl.fyi/c/depot/+/9974 Reviewed-by: grfn <grfn@gws.fyi> Tested-by: BuildkiteCI Autosubmit: grfn <grfn@gws.fyi>
2023-11-06 r/6967 fix(grfn/home): Fix home build for darwinGriffin Smith6-10/+21
Change-Id: Ibcf21617a1cee66c157644712918bcd9bb390228 Reviewed-on: https://cl.tvl.fyi/c/depot/+/9827 Tested-by: BuildkiteCI Reviewed-by: grfn <grfn@gws.fyi>
2023-11-06 r/6966 refactor(users/grfn): Rename gws.fyi -> webAspen Smith11-9/+7
Change-Id: Icdee0caa3a053958750d4b81853dbc3eee5b193a Reviewed-on: https://cl.tvl.fyi/c/depot/+/9973 Tested-by: BuildkiteCI Reviewed-by: grfn <grfn@gws.fyi> Autosubmit: grfn <grfn@gws.fyi>
2023-11-06 r/6965 fix(grfn/emacs): Fix clocked-in-ticket-id for linear ticketsAspen Smith2-18/+33
Change-Id: Id0e8883c1b621afb99edde3d256cccd057e89097 Reviewed-on: https://cl.tvl.fyi/c/depot/+/9972 Autosubmit: grfn <grfn@gws.fyi> Tested-by: BuildkiteCI Reviewed-by: grfn <grfn@gws.fyi>
2023-11-06 r/6964 feat(grfn/system): Command to edit the current text input in emacsAspen Smith2-0/+20
First pass at an xdotool-based command to edit the current text input in emacs Change-Id: I1e04612478292fe83083d197d481e034a9fce97f Reviewed-on: https://cl.tvl.fyi/c/depot/+/9971 Reviewed-by: grfn <grfn@gws.fyi> Autosubmit: grfn <grfn@gws.fyi> Tested-by: BuildkiteCI
2023-11-03 r/6935 chore(users/grfn): fonts.fonts -> fonts.packagesFlorian Klink1-1/+1
Change-Id: Iaf223e238713a48f8c50b0c58a8800a82ba24eed Reviewed-on: https://cl.tvl.fyi/c/depot/+/9913 Autosubmit: flokli <flokli@flokli.de> Reviewed-by: grfn <grfn@gws.fyi> Tested-by: BuildkiteCI
2023-11-03 r/6934 chore(users/tazjin): fonts.fonts -> fonts.packagesFlorian Klink1-1/+1
Change-Id: I762f1cb72b9a87850bb2afb9a129a13428fe22e9 Reviewed-on: https://cl.tvl.fyi/c/depot/+/9914 Tested-by: BuildkiteCI Autosubmit: flokli <flokli@flokli.de> Reviewed-by: tazjin <tazjin@tvl.su>
2023-11-03 r/6927 docs(users/tazjin): add graph explaining tvix-eval Value structureVincent Ambo1-0/+98
Change-Id: I436aeba6da6a0d5096452529d7dd0be11a466e8f Reviewed-on: https://cl.tvl.fyi/c/depot/+/9905 Reviewed-by: tazjin <tazjin@tvl.su> Tested-by: BuildkiteCI Autosubmit: tazjin <tazjin@tvl.su>
2023-11-02 r/6925 feat(tazjin/khamovnik): add some perf analysis toolingVincent Ambo1-0/+3
Change-Id: Ia6db1213bb62cfba475ee9d1654763d56c98fc7c Reviewed-on: https://cl.tvl.fyi/c/depot/+/9897 Reviewed-by: tazjin <tazjin@tvl.su> Autosubmit: tazjin <tazjin@tvl.su> Tested-by: BuildkiteCI
2023-11-02 r/6924 chore(tazjin/nixos): remove some unused softwareVincent Ambo1-4/+0
Change-Id: I87e4b709906333ff9316792effb1082973dc918c Reviewed-on: https://cl.tvl.fyi/c/depot/+/9896 Reviewed-by: tazjin <tazjin@tvl.su> Tested-by: BuildkiteCI Autosubmit: tazjin <tazjin@tvl.su>
2023-11-02 r/6923 fix(tazjin/khamovnik): enable services.throttledVincent Ambo1-0/+3
This can apparently work around some of the CPU throttling bugs on ~modern~ computers. Change-Id: I807ece85d3eba53857a1cb1e73a33f7924538e96 Reviewed-on: https://cl.tvl.fyi/c/depot/+/9895 Autosubmit: tazjin <tazjin@tvl.su> Tested-by: BuildkiteCI Reviewed-by: tazjin <tazjin@tvl.su>
2023-10-30 r/6914 feat(users/flokli/nixos): add direnv supportFlorian Klink2-6/+7
Expose `deps` separately, add a direnv with PATH_add for it to bring tooling into $PATH. Change-Id: I432cd2b082cad89e08bef78dc4653e10e137cd6b Reviewed-on: https://cl.tvl.fyi/c/depot/+/9842 Reviewed-by: flokli <flokli@flokli.de> Autosubmit: flokli <flokli@flokli.de> Tested-by: BuildkiteCI
2023-10-30 r/6913 feat(users/flokli/nixos): use lazydeps for shellFlorian Klink1-2/+7
Avoid having to re-enter the shell whenever the config is changed. Change-Id: Ib9f6bb4075e29acaeb4863d64c017695ca85b60b Reviewed-on: https://cl.tvl.fyi/c/depot/+/9841 Autosubmit: flokli <flokli@flokli.de> Tested-by: BuildkiteCI Reviewed-by: flokli <flokli@flokli.de>
2023-10-30 r/6912 feat(users/flokli/archeology): add awscli, htop, kitty terminfoFlorian Klink1-1/+8
Change-Id: Ib7ae1871a5d0b16a68c79b68e7e79fd302da79bd Reviewed-on: https://cl.tvl.fyi/c/depot/+/9840 Autosubmit: flokli <flokli@flokli.de> Tested-by: BuildkiteCI Reviewed-by: flokli <flokli@flokli.de>
2023-10-30 r/6911 feat(users/flokli): use nix-copy-closure instead of nix copyFlorian Klink1-1/+1
nix copy seems to stall on the EC2 box for unknown reasons. Change-Id: I30639a52758814968d3b54d716522fb88db80cfe Reviewed-on: https://cl.tvl.fyi/c/depot/+/9839 Reviewed-by: flokli <flokli@flokli.de> Reviewed-by: edef <edef@edef.eu> Tested-by: BuildkiteCI Autosubmit: flokli <flokli@flokli.de>
2023-10-30 r/6910 feat(users/flokli): expose readTree targets to CIFlorian Klink1-1/+1
Change-Id: I3ea801b47267f4c985c2ab5cb1b79b2659894307 Reviewed-on: https://cl.tvl.fyi/c/depot/+/9838 Reviewed-by: flokli <flokli@flokli.de> Tested-by: BuildkiteCI Autosubmit: flokli <flokli@flokli.de>
2023-10-30 r/6909 refactor(users/flokli): move common stuff to `archeology` profileFlorian Klink3-29/+24
Change-Id: I8470c0a2416c0c397e009affb44f8c7a852cd526 Reviewed-on: https://cl.tvl.fyi/c/depot/+/9837 Reviewed-by: flokli <flokli@flokli.de> Tested-by: BuildkiteCI Autosubmit: flokli <flokli@flokli.de>
2023-10-30 r/6907 feat(users/flokli): add archeology-ec2Florian Klink4-3/+70
This add the EC2 box config to the repo. Change-Id: Id7a888a2cfbf1454cd9f9465018df377e14b4e9f Reviewed-on: https://cl.tvl.fyi/c/depot/+/9836 Tested-by: BuildkiteCI Reviewed-by: flokli <flokli@flokli.de>
2023-10-29 r/6905 feat(users/flokli/nixos): add deploy scriptFlorian Klink1-1/+16
This adds a deploy-archeology script. I tried getting morph to work first, but passing it a depot.ops.nixos.nixosFor seems to be very hard - the NixOS module system doesn't like the arguments it's called with. Replace morph with a 3 line bash script, which assumes your ssh_config contains config for an `archeology` host. Change-Id: I2bf694c60ded39c201efbbb899f3b5512aa4d0f2 Reviewed-on: https://cl.tvl.fyi/c/depot/+/9835 Autosubmit: flokli <flokli@flokli.de> Tested-by: BuildkiteCI Reviewed-by: edef <edef@edef.eu>
2023-10-29 r/6904 refactor(users/flokli): drop some optional args and complexityFlorian Klink3-9/+7
Change-Id: Ifdcac829ede4ec469a7ce1b608e78bae11f2766b Reviewed-on: https://cl.tvl.fyi/c/depot/+/9834 Autosubmit: flokli <flokli@flokli.de> Tested-by: BuildkiteCI Reviewed-by: edef <edef@edef.eu>
2023-10-29 r/6903 feat(users/flokli/nixos): init archeologyFlorian Klink5-0/+88
Change-Id: Ic31cb8030179ff37b1cc3d3d9241e2582cfe3e5e Reviewed-on: https://cl.tvl.fyi/c/depot/+/9833 Tested-by: BuildkiteCI Reviewed-by: edef <edef@edef.eu> Autosubmit: flokli <flokli@flokli.de>
2023-10-25 r/6879 fix(tazjin/emacs): always list ttys locallyVincent Ambo1-1/+2
Change-Id: Ic05378013aa327616a822336881d9a76c8a22d58 Reviewed-on: https://cl.tvl.fyi/c/depot/+/9829 Autosubmit: tazjin <tazjin@tvl.su> Reviewed-by: tazjin <tazjin@tvl.su> Tested-by: BuildkiteCI
2023-10-20 r/6867 fix(users/Profpatsch/openlab-tools): fix cache againProfpatsch1-100/+114
And of course I managed to move the cache creation into the handlers, instead of doing it before starting the webserver. And now I managed to create a hopeless mess of callbacks, but oh well. Change-Id: I73c3aeced71923c7372496286a279e326b20c388 Reviewed-on: https://cl.tvl.fyi/c/depot/+/9813 Reviewed-by: Profpatsch <mail@profpatsch.de> Autosubmit: Profpatsch <mail@profpatsch.de> Tested-by: BuildkiteCI
2023-10-20 r/6866 feat(users/Profpatsch/openlab-tools): introduce handler abstractionProfpatsch1-33/+97
I’ve been wanting to experiment with this stuff for a while, abstracting away a handler type. The existentials for parser and body took a bit of mucking about, but in the end hiding the variable behind a `Body` constructor did the trick. Now every handler has its own cache, which means we can start caching arbitrary results. Change-Id: If57230c47f97ef4c548683f2c2f27660817a31f2 Reviewed-on: https://cl.tvl.fyi/c/depot/+/9812 Autosubmit: Profpatsch <mail@profpatsch.de> Reviewed-by: Profpatsch <mail@profpatsch.de> Tested-by: BuildkiteCI
2023-10-20 r/6865 fix(users/Profpatsch/openlab-tools): return 304 iff cache is sameProfpatsch1-6/+14
Now this is getting cool. After 5 minutes we will ask the backend again (which takes like 3 seconds), but then we compare the old cached result with the new result and only send it back to the client iff it changed. So the client will still have to wait for the roundtrip time, but doesn’t have to pay for the content. Plus, it gets some info that upstream hasn’t been updated. Change-Id: I6dba40321949da5da6a16b2e799d939573c77ba7 Reviewed-on: https://cl.tvl.fyi/c/depot/+/9811 Autosubmit: Profpatsch <mail@profpatsch.de> Reviewed-by: Profpatsch <mail@profpatsch.de> Tested-by: BuildkiteCI
2023-10-20 r/6864 fix(users/Profpatsch/openlab-tools): add cache headersProfpatsch5-33/+118
This is a dumb experiment to see how hard it is to respect cache headers; turns out, medium hard but doable. Sets the correct expiry time according to the cache, plus respects `If-Modified-Since` which is a tiny bit harder. Change-Id: I9e6166af0fa254df2beb0f3919187b91a407487b Reviewed-on: https://cl.tvl.fyi/c/depot/+/9810 Autosubmit: Profpatsch <mail@profpatsch.de> Tested-by: BuildkiteCI Reviewed-by: Profpatsch <mail@profpatsch.de>
2023-10-20 r/6863 fix(users/Profpatsch/openlab-tools): add source to tableProfpatsch1-9/+24
Change-Id: Ia272460d098d2b25d3890853a3cd8e29ffb31545 Reviewed-on: https://cl.tvl.fyi/c/depot/+/9809 Autosubmit: Profpatsch <mail@profpatsch.de> Tested-by: BuildkiteCI Reviewed-by: Profpatsch <mail@profpatsch.de>