Commit Graph

1209 Commits

Author SHA1 Message Date
Mathias Jakobsen
6b28a4ee5a Merge pull request #33560 from overleaf/mj-conversion-cleanup
[clsi+web] Small cleanups and improvements to conversions / exports

GitOrigin-RevId: 300adfbb91e89f754ee7f835db792ccb50b27613
2026-05-12 08:06:17 +00:00
Mathias Jakobsen
32da6548c8 Merge pull request #33277 from overleaf/mj-pandoc-clsi-two-step-download
[clsi] Use clsi-nginx for downloading pandoc exports

GitOrigin-RevId: b6013fae6f53c7af714634d700ceed491d724653
2026-05-08 08:09:18 +00:00
Mathias Jakobsen
ae31ad218c Merge pull request #33104 from overleaf/mj-pandoc-arguments
[clsi] Add pandoc arguments for better conversions

GitOrigin-RevId: 76cddc5959237d6d2801c56471d8d3f63d111200
2026-05-08 08:09:12 +00:00
Mathias Jakobsen
5dc67db403 Merge pull request #33089 from overleaf/ds-export-md-files-pandoc
[WEB + CLSI] Download as markdown

GitOrigin-RevId: 181eddf2513e9c5edacbab37e93f9cac2191ee1a
2026-05-08 08:09:07 +00:00
Mathias Jakobsen
eddcc5a42e Merge pull request #32857 from overleaf/ds-pandoc-import-md
[WEB + CLSI] Import markdown files using pandoc

GitOrigin-RevId: adad7831ddb13a8fcb8063871166bde13cbbf1b6
2026-05-08 08:09:02 +00:00
Jakob Ackermann
44efc9d745 [monorepo] avoid corepack network requests (#33502)
* [monorepo] avoid corepack network requests

- Download yarn via corepack as the first step in all the docker files
- Turn off networking in corepack
- Do not run things in the upstream node image
  Instead, use the monorepo image, or base layer in all the services.
- Always build the base layer when running tests (uses cache)

* [monorepo] install corepack in shared place

* [clsi-lb] remove unrelated changes

* [web] add missing DC_RUN_FLAGS

* [monorepo] only rebuild test images locally

Also remove spurious build config in docker-compose.ci.yml.

* [server-ce] test: make yarn files available to host-admin and e2e

* [monorepo] put the corepack install snippet in a few more places

GitOrigin-RevId: 38005016ae5a708e12295e246269d6c18fece937
2026-05-08 08:08:57 +00:00
renovate[bot]
de9b07f0b9 [Platform] Update dependency lodash to v4.18.1 from 4.17.23 [SECURITY] (#33229)
* Upgrade lodash resolution to 4.18.1

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* update lodash in rest of packages

---------

Co-authored-by: Eric Mc Sween <5454374+emcsween@users.noreply.github.com>
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-authored-by: Anna Fields <acfields11@gmail.com>
GitOrigin-RevId: 66ce1610993a592899c25155757ca3267ebcd5c1
2026-05-07 08:07:41 +00:00
Jakob Ackermann
37cc65ec7e [web] consolidate clsi downloads and add zod validation (#33069)
* [web] consolidate clsi downloads and add zod validation

* [validation-tools] make prettier happy

* [web] make clsiServerId optional

* [web] fix type of buildId

* [web] gracefully handle ObjectId

* [web] fix type of buildId

* [monorepo] address review feedback

- cjs export
- update module path in comments
- skip adding ?clsiserverid if not set
- allow nested output file download for submissions and add tests

* [web] address review feedback

* [web] cache one more zod schema

* [web] fix unit tests

GitOrigin-RevId: 0a1e618955983e035defd6d3c0528b81e0e85c95
2026-05-05 08:06:05 +00:00
Jakob Ackermann
da11cf2669 [monorepo] fix running tests locally (#33186)
* [monorepo] fix running tests locally

* [web] fix east invocation

* [web] move corepack into entrypoint

* [web] fix running module acceptance tests locally

* [web] fix merged module targets

* [web] remove spurious change

GitOrigin-RevId: 84cf7f8d768d3429c8a98c789acf76f6cecd6e3e
2026-04-29 08:05:42 +00:00
Anna Claire Fields
0d64a88a46 Yarn 4 Migration (#32253)
Migrates the Overleaf monorepo package manager from npm (v11) to Yarn 4 (v4.9.1) using node-modules linker mode.

GitOrigin-RevId: 50d32ab01955c15e29679eff9e9e9cfb897fab2d
2026-04-28 08:52:37 +00:00
Davinder Singh
be5a7b56c8 [WEB + CLSI] Download as docx file feature (#32851)
* using CLSI logic for fetching the project contents and skip the .zip export

* Use unique conversion directory for project-to-docx export to avoid corrupting the shared compile
  directory when a compile runs concurrently

* Remove X-Accel-Buffering header — not needed as CLSI does not run behind nginx

* moving log before sending the data

* Return CLSI stream directly instead of buffering to disk on web

  Previously convertProjectToDocx wrote the CLSI response to a temp file
  on disk, then the controller read it back to stream to the client.
  Now the stream is returned directly and piped to the response,
  avoiding unnecessary disk I/O on the web server.

* Use href redirect for docx export instead of fetching blob into memory

* making functions and files more generic so they can be used in future for other documents exports as well

* adding export-docx split test

* adding unit tests

* adding cypress E2E test

* format:fix

* renaming the route to download from convert

* adding new icon for export docx button

* format:fix

* remove unused showExportDocumentErrorToast export and adding guard against invalid Content-Length header from CLSI

* format:fix

* refactor(clsi): move promisify(parse) into RequestParser

* refactor: generic conversion endpoint with type as route
  param

* refactor: use type→extension map for validated conversion types

* refactor(clsi): remove --standalone flag and fix rejection test

* fixing the href in cypress test

* renaming function

* adding type to Metrics.inc

* fix: rename exportProjectDocument, add WithLock wrapper and metrics type label

* format:fix

* fix: hide docx export from anonymous users and add WithLock wrapper

* format fix

* remove redundant Content-Length validation from DocumentConversionManager

* format:fix

* removing trailing icon

GitOrigin-RevId: e9764fefac2c4b625d23be9e942ea4a8b283c70d
2026-04-24 08:06:10 +00:00
Jakob Ackermann
926d6bccd7 [clsi] reduce write traffic to clsi-cache from free users (#32958)
GitOrigin-RevId: c01cc21c3c82f361c7d82843e65bb087b21434ed
2026-04-22 08:05:59 +00:00
Anna Claire Fields
1a7de4ddd8 Upgrades Node.js from 24.13.0 → 24.14.1 (#32498)
GitOrigin-RevId: edbe6969c4c28109e3077f48e94084fc5c910727
2026-04-14 08:04:32 +00:00
Andrew Rumble
72586d2ea2 Merge pull request #32497 from overleaf/ar-picomatch-4.0.4
[monorepo] picomatch 4.0.4

GitOrigin-RevId: 433c2b436123b3eff336ef6597a67c7dccc9d6ba
2026-04-01 08:05:59 +00:00
Jakob Ackermann
0544aded40 [clsi] handle draft mode and tikzexternalize as part of sync phase (#32516)
* [clsi] handle draft mode and tikzexternalize as part of sync phase

* [clsi] emit empty string from SafeReader on ENOENT

* [clsi] persist history state after clearing dirty state without changes

GitOrigin-RevId: d9dcd2e6887017f7935b5e95bdbdc6e11a3b18f5
2026-03-31 08:07:19 +00:00
Jakob Ackermann
d66a856baa [clsi] remove locking from docker actions (#32373)
* [clsi] remove locking from docker actions

Start:
- We have an in-memory lock on the compile request

Destroy:
- as part of run: see above
- as part of cleanup: we check the last access time now, so it cannot
  happen concurrent to compiling anymore.

Co-authored-by: Anna Claire Fields <anna.fields@overleaf.com>

* [clsi] update comment

---------

Co-authored-by: Anna Claire Fields <anna.fields@overleaf.com>
GitOrigin-RevId: a58df45416ae31c0b38d5efec7f9371d747303df
2026-03-27 09:06:28 +00:00
Mathias Jakobsen
9c97876268 [web]+clsi] Allow docx import via pandoc (#32004)
Co-authored-by: Jakob Ackermann <jakob.ackermann@overleaf.com>
GitOrigin-RevId: 246b3290ec04867f71545b1a7c5d95d0f68379ff
2026-03-27 09:06:23 +00:00
Jakob Ackermann
07397bbdde [clsi] avoid server error when clearing cache while compiling (#32349)
* [clsi] avoid server error when clearing cache while compiling

* [clsi] tweak API around releasing locks

Co-authored-by: Eric Mc Sween <eric.mcsween@overleaf.com>

---------

Co-authored-by: Eric Mc Sween <eric.mcsween@overleaf.com>
GitOrigin-RevId: d3f171467d3bc26941758dd333f30049b37a05c8
2026-03-23 09:06:18 +00:00
Jakob Ackermann
3aa69c6ffa [k8s] clsi-cache: double the number of shards (#32323)
* [k8s] clsi-cache: double the number of shards

* [monorepo] add missing clsi-cache env vars to dev-env

* [clsi] flip direction of clsi-cache shard migration

* [clsi] remove upper bound from clsi-cache shard migration

GitOrigin-RevId: a325a11c3ac9e22a12ad2d8ea802b91d2e175e24
2026-03-20 09:07:11 +00:00
Jakob Ackermann
6377624d25 [clsi] ignore download errors for binary files in compile from history (#32263)
GitOrigin-RevId: 3c1940b2d56701ec4b07d1457ee1af2de317a047
2026-03-19 09:07:00 +00:00
Brian Gough
9f1e4d99e5 handle old versions of latexmk in run count extraction (#30597)
* handle old versions of latexmk in run count extraction

the log lines for the run number change from stderr to stdout in TL2022

* extend SimpleLatexFileTest to include TL2017

* reset metrics for each scenario in SimpleLatexFileTests

* fix buildscript merge conflict

GitOrigin-RevId: fb74f2025d21ddf43be6a3b90ac6f7df4d975db6
2026-03-19 09:06:55 +00:00
Jakob Ackermann
69a7927267 [clsi] shard clsi_compiles_total metric by syncType (#32255)
GitOrigin-RevId: 43111697323ec6697ef5f42cf17807ea564181a0
2026-03-19 09:05:55 +00:00
Jakob Ackermann
c2130dccb9 [clsi] use cheapest gzip compression level for history snapshot (#32251)
memoir manual with 1.5MiB snapshot:

level |load/decompress time | store/compress time |  size   | ratio | total sync time
 ---  | ---                 | ---                 |  ---    | ---   | ---
 6    | 18ms                | 57ms                |  412KiB | 26%   | 88ms
 1    | 17ms                | 28ms                |  509KiB | 32%   | 53ms
 0    |  8ms                | 10ms                | 1578KiB | 0%    | 33ms

total sync: read snapshot, walk dir, sync files to disk, save snapshot

GitOrigin-RevId: a2b1ee063af5aa749014f942db5e08bb1e685848
2026-03-19 09:05:50 +00:00
Jakob Ackermann
f947b549e4 [clsi-perf] migrate to compile from history mode (#32234)
* [clsi] only download history snapshot from clsi-cache when enabled

* [clsi-perf] migrate to compile from history mode

GitOrigin-RevId: 2dd54e032bd85d6335488741c039a5a1bd60090d
2026-03-18 09:07:51 +00:00
Lucie Germain
bf1f34bca6 Merge pull request #32197 from overleaf/lg-project-number-buildscripts
Replace project name with project number for --pipeline-owner in buildscripts

GitOrigin-RevId: c021447091b388ee3a26e59e7163d53bcd1c8e81
2026-03-18 09:07:27 +00:00
Jakob Ackermann
2e389c5a41 [rails] migrate compiles of conversions/submissions to history mode (#32053)
* [saas-e2e] test gallery templates with binary file

* [rails] add make target for fixing rubocop errors

* [rails] migrate compiles of conversions/submissions to history mode

* [rails] forward version to clsi request

* [rails] trim down compile request

* [saas-e2e] source v1 secrets after make install

GitOrigin-RevId: 65269e1df1051c9f3b4f1813d2e9dcf32a01be50
2026-03-18 09:07:22 +00:00
Jakob Ackermann
d5b55b831d [clsi] make last access tracking more robust (#32192)
* [clsi] do not overwrite last access during initial scan

* [clsi] cleanup submission cache 5-10min after startup

* [clsi] address review comments

GitOrigin-RevId: e03beec1b3deaee50629ada72b0242a8a2b2ae66
2026-03-18 09:07:10 +00:00
Jakob Ackermann
a9c413857a [clsi] avoid destroying containers of recently accessed projects (#32186)
* [clsi] avoid destroying containers of recently accessed projects

Co-authored-by: Anna Claire Fields <anna.fields@overleaf.com>

* [clsi] gracefully handle missing access time during container cleanup

* [clsi] fix cyclic import

---------

Co-authored-by: Anna Claire Fields <anna.fields@overleaf.com>
GitOrigin-RevId: 8195b6fccbe26d2fd673d38356af5d44cf4042a3
2026-03-18 09:07:01 +00:00
Daniel Kontsek
e60ac573bc [clsi] fix nginx regex for submission IDs with uppercase characters
GitOrigin-RevId: 28d85ebcf5abdb146d2fe8886039d0da0af08d53
2026-03-13 09:05:39 +00:00
Alf Eaton
f605a337aa Add with-texlive target to clsi Dockerfile (#31625)
GitOrigin-RevId: f2a971c761f09974921bf043e1f4959c63107dd8
2026-03-06 09:16:47 +00:00
Jakob Ackermann
bb3e1286db [clsi] parse env var for download concurrency as int (#31959)
GitOrigin-RevId: dbd91315318e385d691a6b59efeb3bf22f559fa2
2026-03-06 09:12:25 +00:00
Jakob Ackermann
81b7121408 [clsi] initial implementation of compile from history (#31883)
* [clsi] initial implementation of compile from history

* [clsi] copy changes

* [saas-e2e] extend test case with nested folder

* [saas-e2e] add test case for tracked changes

* [web] fix accumulating changes from multiple chunks

* [web] optimize size check for compile request payload

* [clsi] deduplicate globalBlobs

* [clsi] add validation for request body details

* [clsi] add metrics for compile from history

* [clsi] download binary files concurrently

* [clsi] skip download of empty file blob

* [clsi] break down e2e compile time metric by compileFromHistory

GitOrigin-RevId: 0dadef93e89d8a172c35cb130a1042d9d1bec42a
2026-03-06 09:12:07 +00:00
Andrew Rumble
5723a9589a Merge pull request #31567 from overleaf/ar-fb/handle-clsi-timeout-better
[clsi-lb,v1,clsi,web] handle clsi timeout better

GitOrigin-RevId: 86aa1e01b8cb465b8b9332e17fb97c21849d0489
2026-03-06 09:12:02 +00:00
Andrew Rumble
16cc4026a0 Merge pull request #30890 from overleaf/ar/code-coverage-e2e
[monorepo] code coverage e2e

GitOrigin-RevId: cfdef9e6b485831bd34847f7b7af13d39c18c3e6
2026-03-06 09:10:56 +00:00
Jakob Ackermann
eca31afb4a [clsi] remove unused endpoints for downloading output files (#31692)
GitOrigin-RevId: a0cac10f3585414779b026f38c2af2773c80082f
2026-03-06 09:06:33 +00:00
Jakob Ackermann
9731f061af [monorepo] remove unused firejail profiles (#31790)
GitOrigin-RevId: ba4bac748014d5edf0cf2815af295c573502f144
2026-03-06 09:06:22 +00:00
Jakob Ackermann
6c6e8d9a97 [monorepo] switch all output file reads to clsi-nginx (#31691)
* [monorepo] switch all output file reads to clsi-nginx

* [clsi-lb] allow gallery download requests

* [terraform] clsi: use nginx.conf from clsi service

* [clsi] fix flakey tests

* [clsi] replace alias with rewrite and root in nginx config

* [k8s] clsi-lb: expose download port on internal service

* [web] add explicit endpoint for downloading all output files

Serve the output.zip endpoint from clsi.

* [clsi] fix regex for latexqc submission ids

Previously, we only handled template submission ids.

GitOrigin-RevId: 6c3b21b01ec41ae767530b14aac31fbe3d640dd5
2026-02-24 09:07:12 +00:00
Jakob Ackermann
209f660435 [monorepo] remove endpoints for generating a fake error (#31679)
GitOrigin-RevId: d424881e6ebca157b81344705670021677f856de
2026-02-20 09:06:13 +00:00
Jakob Ackermann
7c70b749d4 [monorepo] remove PII and variables from error messages (#31508)
* [monorepo] remove PII and variables from error messages

Exclusions:
- scripts
- tests
- fuzzing
- SplitTestManager (messages are sent to admin frontend)
- Group setup (we may want an error per unique tuple)
- sharejs (unused types; text type errors are shadowed already)
- history-v1 error messages that are used by the ErrorRecorder
- errors that flag issues with configuration/call signatures

I've used these search terms for finding unwanted error messages:
- new Error(`
- new Error\(\n\s+` (regex search)
- new OError(`
- new OError\(\n\s+` (regex search)

* [web] throw NotFoundError from ProjectLocator

* [github-sync] fix OError.tag call in script

Co-authored-by: Jessica Lawshe <jessica.lawshe@overleaf.com>

* [templates] revert changes to test client

---------

Co-authored-by: Jessica Lawshe <jessica.lawshe@overleaf.com>
GitOrigin-RevId: 736857a4fc5d9bfb0f8cb03e0f004eda87e5a220
2026-02-17 09:05:04 +00:00
Jakob Ackermann
dbf6401f22 [monorepo] move retries from the outside to the per-test level (#31528)
* [monorepo] move retries from the outside to the per-test level

* [web] increase hookTimeout in CI

* [monorepo] consolidate test retries

- do not retry unit tests
- only retry in ci, optionally locally with "RETRIES=3 make test..."
- add retries for web

Co-authored-by: Eric Mc Sween <eric.mcsween@overleaf.com>

---------

Co-authored-by: Eric Mc Sween <eric.mcsween@overleaf.com>
GitOrigin-RevId: 86e45edcfb087d18e0e957ad6df9a6105dcd5770
2026-02-16 09:06:48 +00:00
Brian Gough
f3e8601cba fix caching of minted output files in TL2025 (#31455)
GitOrigin-RevId: b82df4d9c7898332b310fd956c5f002bf5b20e39
2026-02-11 09:06:14 +00:00
Jakob Ackermann
c5bc4a1259 [clsi] tweak logging for clsi-cache (#31452)
* [clsi] tweak logging for clsi-cache

- Use `clsi-cache` identifier on log line
- Add shard to context
- Record nFiles on "too many entries for tar" error

* [clsi] do not trip clsi-cache circuit breaker on ENOENT errors

These can happen when an output/compile-dir is purged while we download
files.

GitOrigin-RevId: ffa73ef312bce5232ef72e3b81966bb6e14d2255
2026-02-11 09:06:09 +00:00
Jakob Ackermann
fd647002f5 [monorepo] enable caching for eslint and prettier (#30967)
* [monorepo] enable caching for eslint/prettier/stylelint

* [monorepo] speed up prettier by swapping --list-different for --check

--list-different will print each file that it processes. We have a lot
of files in the monorepo. Using --check only prints mismatching files.

Co-authored-by: Rebeka <rebeka.dekany@overleaf.com>

* [monorepo] explicitly configure prettier cache-location

This is the default location. Prettier will only discover that location
if the top level node_modules folder is writable, which is not the case
in CI. We create the .cache folder outside of docker, writable to node
inside docker.

The proper fix would be in prettier, to only check for write access in
the cache folder. Something to raise/upstream another day.

* [monorepo] run top-level format/format_fix in a single container

With the cache in place, it is much faster to use a single container.
As there is a single shared cache file, concurrent processes may see a
partially (re-)written cache file and bail out.

- all in a single container: 24s
- previous with -j4: 41s
- previous with -j8: failed due to corrupted cache file

---------

Co-authored-by: Rebeka <rebeka.dekany@overleaf.com>
GitOrigin-RevId: 7850a3a980ae6c836393d97fe56a6316ffc3fa18
2026-02-06 09:05:44 +00:00
Rebeka Dekany
a648015db8 Centralize prettier configuration to root level (#30501)
* Merge all .prettierignore files into top-level config

* Merge all .prettierrc files into top-level config

* Replace service-specific glob patterns in package.json format scripts with `prettier .`

* Add template files with Jinja2, Go template, envsubst, and Handlebars syntax to .prettierignore

* Ignore GitHub templates

* Ignore PUG templates to format them separately with `format:pug`

* Encourage double quotes for YAML, YML files

* Move prettier for PUG source format script to the root

* Move prettier for styles source format script to the root

* Remove prettier for jenkins files from web

* Remove prettier source format script from all services

* Make .prettierrc more readable

* Update format scripts by file type

* Organise `.prettierignore`

* Add `--cache` flag to prettier scripts for faster runs

* Format all files with prettier

* Format all or format services

* Remove `format`/`format:fix` scripts from services since now it runs from root `package.json`

* Avoid conlficts with yamllint configuration

* Remove `--cache` flag from prettier scripts

* Update all service Makefiles to use root-level prettier configuration

* Update all Jenkinsfile to use root-level prettier configuration

* Ignore auto-generated files by build_scripts

* Update package-lock.json

* Update root Makefile format targets

* Update SP Jenkinsfile format target

* Update E2E Makefile format script

* Udpate `format_js` to work in both local and CI env

* Add docker-mailtrap to .prettierignore

docker-mailtrap is a third-party git-ignored directory used for testing

* Added Docker env detection to prevent nested Docker spawning

* Ignore handlebars templates

* Add cryptographic files and test output to `.prettierignore`

* Add terraform modules to `.gitignore`

* Remove prettier-plugin-groovy

* Use npx directly instead of Docker for local formatting for faster formatting

* Auto-generate Makefiles

* Revert "Remove prettier-plugin-groovy"

This reverts commit 194a33589a2e1e4d2225d10c67e9f025e4222025.

* Mount monorepo root in RUN_LINT_FORMAT for prettier config access

* Prettier ignores all `node_modules` by default regardless of location

* Show only changed files in format output

* Ignore LICENSE files

* Enable prettier on rendered build_scripts outputs

* Ignoring all the template folders by prettier

* Remove the public/minjs entry since it does not exist

* Remove all non-existent paths

* Sync `.prettierignore` with ignored files by `.gitignore` and `.dockerignore` files

* Revert "Auto-generate Makefiles"

This reverts commit c0233e490de1bc95fe437219d65e0b66e0331ec9.

* Revert "Use npx directly instead of Docker for local formatting for faster formatting"

This reverts commit 1d2b2cf1a6c6974c76885852a90dd55e84167e41.

* Ignore dashboard JSON files

* Ignore files generated by bin/update_build_scripts

* Remove unsupported file types from `.prettierignore`

* Ignore test fixture generated files

* Ignore README file types by prettier

* Ignore generate snapshots by prettier

* Allow to format generated bin/update_build_scripts by prettier

* Ensure build script outputs prettier-compatible tsconfig.json

* Fix build script output to match prettier formatting
- Fix Jinja2 whitespace in docker-compose templates
- Change YAML quotes from single to double

* Don't read cryptographic files by prettier

* Ignore google verification files by prettier

* Revert npx prettier formatting

* Ignore domain verification files

* Show only changed files in format output

* Make `.github` prettier

* Allow all files to be formatted in jobs by prettier

* Allow server-ce/server-pro files to be formatted by prettier

* Ignore more folders in clsi, filestory, git-bridge by prettier

* Update build script with `RUN_LINTING_CI_MONOREPO`

* Ignore docker-mailtrap and downloads in server-ce by prettier

* Restore prettier configs and prettierignore for V1 since it has its own prettier (an older version)

* Source format

GitOrigin-RevId: 637adc3cc422d1f20c86d6ebc8ec514d60758287
2026-02-04 09:08:22 +00:00
Anna Claire Fields
e80ce42896 Upgrade Node.js from 22.18 to 24.13 (#30509)
GitOrigin-RevId: c2405a0583e68c61351f52b32ba28faec994fbc0
2026-01-30 09:05:28 +00:00
Mathias Jakobsen
8859aaaeb9 Merge pull request #31011 from overleaf/mj-build-scripts-elastic-search
[build-scripts] Remove elastic search (es) dependency from build scripts

GitOrigin-RevId: db21887149dfb6eab3508762695f73f7ecacb492
2026-01-28 09:07:54 +00:00
Jakob Ackermann
8eba220693 [clsi] remove initial vs recompile flag from clsi-perf metric (#31052)
GitOrigin-RevId: 75d101b355b291206386b0e6838571894af17a48
2026-01-28 09:06:43 +00:00
Jakob Ackermann
0ee8b25298 [k8s] clsi-cache: migrate to StatefulSet (#30886)
* [k8s] clsi-cache: migrate to StatefulSet

* clsi-cache: optimize ILB services for GKE subsetting

Update the new clsi-cache internal load balancer services
to use optimal settings for GKE subsetting (NEG backends):

- set allocateLoadBalancerNodePorts: false (not needed with NEGs)
- set externalTrafficPolicy: Local (preserve source IP, keep traffic in zone)
- add trafficDistribution: PreferClose (zone affinity)

These settings ensure traffic from CLSI VMs stays within the same zone
when possible, reducing latency and cross-zone network costs.

* [k8s] clsi-cache: add missing resource paths

* [clsi] exclude readOnly clsi-cache shards

---------

Co-authored-by: Daniel Kontsek <daniel.kontsek@overleaf.com>
GitOrigin-RevId: 34f18b319a0e859ff149a135131c95a44bc674d6
2026-01-27 09:05:50 +00:00
Jakob Ackermann
866e67cef1 [k8s] clsi-cache tweaks (#30949)
* [k8s] clsi-cache: switch parent-app label to 'clsi-cache-legacy'

* [k8s] clsi-cache: add service account from kustomization.yaml

* [k8s] clsi-cache: consolidate on a single array of CLSI_CACHE_INSTANCES

* [clsi-cache] make prettier happy

GitOrigin-RevId: 4082a71df591904cfe437c4bde74759ddd83634c
2026-01-23 09:06:15 +00:00
Andrew Rumble
cd7da983d1 Merge pull request #30232 from overleaf/ar/convert-clsi-to-es-modules
[clsi] convert to ES modules

GitOrigin-RevId: fb7fa52cc8f678ee31be352e62a5dff95e88008b
2026-01-22 09:06:23 +00:00