Repository navigation
Conversation
Fusionfire ingest resolves browser stack frames through a new internal service, logfire-source-maps. The chart renders its Deployment, Service and in-cluster certificate behind logfire-source-maps.enabled, which is off by default, and gives the ingest config FF_SOURCE_MAPS_URL when it is enabled.
Fusionfire ingest reads uploaded source maps, so the maps cannot stay on the backend pod's local disk. When logfire-source-maps.enabled is on, the backend, the worker and ingest all get <objectStoreUri>/_source_maps, the same prefix pattern as FF_FAILOVER_OBJECT_STORE_URI.
The chart-testing lint requires a version bump on a chart change.
Fusionfire ingest now serves /v1/sourcemaps/. Without an HAProxy rule the request matches path_backend and reaches the backend. Ingest also needs FF_SOURCE_MAPS_ENABLED to accept the route.
The ingest processor keeps a per-pod disk cache of compiled browser source maps when the source-maps service is enabled. Without a request, the scheduler can place the pod on a node that lacks room for the cache. Request `ephemeral-storage: 4Gi` for `logfire-ff-ingest-processor` in the tiny, small, standard and large sizing presets. Only the request changes. The shared `/tmp` emptyDir has no per-workload `sizeLimit` in the chart, so this keeps the resource request instead of a volume limit.
…into logfire-source-maps-service # Conflicts: # charts/logfire/Chart.yaml # charts/logfire/README.md
…into logfire-source-maps-service # Conflicts: # charts/logfire/Chart.yaml # charts/logfire/README.md
…into logfire-source-maps-service # Conflicts: # charts/logfire/Chart.yaml # charts/logfire/README.md
…into logfire-source-maps-service # Conflicts: # charts/logfire/Chart.yaml # charts/logfire/README.md
…into logfire-source-maps-service # Conflicts: # charts/logfire/Chart.yaml # charts/logfire/README.md # charts/logfire/templates/_helpers.tpl
logfire.autoscaler on main renders the PDB itself, so the template's own logfire.pdb call produced a second PodDisruptionBudget with the same name.
…into logfire-source-maps-service # Conflicts: # charts/logfire/Chart.yaml # charts/logfire/README.md
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Logfire ingest resolves browser stack frames through a new internal service,
logfire-source-maps. This PR adds that service to the chart behindlogfire-source-maps.enabled, which is off by default, so an upgrade changes nothing until an operator turns it on.Changes
templates/logfire-source-maps.yamlrenders a Deployment and a ClusterIP Service, based onlogfire-backend-auth. It uses port 8003, runspython -m logfire_source_mapsfromlogfire-source-maps-prod, and reads onlyCRUD_PG_DSN,FRONTEND_HOSTand the telemetry settings. It has no Redis and no JWT.logfire-backend-auth.logfire-ff-ingest-configgetsFF_SOURCE_MAPS_URLwhen the service is enabled, using the in-cluster TLS scheme and port.SOURCE_MAPS_OBJECT_STORE_URI, the worker gets it too, and ingest getsFF_SOURCE_MAPS_OBJECT_STORE_URI. All three are<objectStoreUri>/_source_maps, the same prefix pattern asFF_FAILOVER_OBJECT_STORE_URI. The worker needs the URI to delete blobs. The backend needs it only until its upload routes move out.Storage move
Today a self-hosted install with no URI stores source maps on the backend pod's local disk, at
file:///var/lib/logfire/source-maps. Ingest cannot read that disk. So when the service is enabled, maps move to the_source_mapsprefix of the shared object store. Maps that are already on a pod's disk are not copied. A project uploads them again on its next release build.Platform PR: https://github.com/pydantic/platform/pull/55571
Validation
helm templaterenders the service and the URL with the flag on. With the flag off, it renders neither.helm unittestlocally, because the plugin is not installed.The chart must not enable this by default until a platform release publishes the
logfire-source-maps-prodimage.This PR also includes the ingest processor ephemeral storage request (4 GiB) from #363.