Skip to content

Replace AWS RUM with Client Metrics Server#1672

Open
camillecroci wants to merge 9 commits intomainfrom
update-client-metrics-web
Open

Replace AWS RUM with Client Metrics Server#1672
camillecroci wants to merge 9 commits intomainfrom
update-client-metrics-web

Conversation

@camillecroci
Copy link

@camillecroci camillecroci commented Feb 11, 2026

What

We are replacing AWS RUM with our own Client Metrics Server, which is using Vector under the hood.
So we need to adapt the code to use that new server

What are the big changes?

  • All the AWS stuff are removed: AWS RUM, aws* options, isAvailable (was a method specific to RUM)
  • We now POST to the Client Metrics Server to record events. The server just needs a namespace and a systemCode (and to have a namespace setup in the server).
  • Instead of blocking request that are not coming from *.ft.com, we now direct them to our test server (including requests from local.ft.com). The production requests will go to our production server.

What are the medium changes

  • The sample, because we are now doing it in the server
  • The namespace can now be a single word, and no longer need to have a period.
  • We no longer record errors because we prefer to avoid getting every little errors but instead to only have actual metrics or logs for errors people care about / want to monitor
  • We now reinforce having a systemCode as alphanumeric possibly separated by hyphens. This is because this check exists in the server so it would be useless to allow people to set a wrong systemCode only to realise later that it does not work with the server.

Note (to discuss)

The JIRA ticket example specifies serverHostname: 'client-metrics.ft.com' // default
But I do find is strange to be able to set the client metrics server.
I think when developing locally, people should send their metrics to the test and in prod, it should be production. On staging, send it to test. So I don't think this should be a given option to user.

I may need to add staging.ft.com to the exceptions of allowedHostnamePattern and maybe rename that variable to make it clearer

@camillecroci camillecroci force-pushed the update-client-metrics-web branch 2 times, most recently from 7d0369c to 1c7690f Compare February 12, 2026 12:24
Camille Croci added 8 commits February 12, 2026 14:42
We remove everything that is specific to the package:
- the dependency
- aws* options that were only needed by AWS RUM
- isAvailable method was also very specific to RUM
- the sample is now done on the server directly
- we also remove the record error because its just a firehose of all errors on a page
We will encourage people to actually create error events if they
want to monitor something in particular
We now accept to just have , but also  because
we're way more cool now
We now use POST to the client-metrics-server to record events
We have the possibility to set the test or prod servers
We no longer inforce com.ft. to start a namespace
It is possible to have the home page running locally using ft.com hostname
In that case (as its local) we want to send the metrics to our test server
So need that edge case in our allowedHostnamePattern
The same check exists in the client server so instead of letting
people potentially set a wrong system code in the client and then
having the server fail, we reinforce the rule here too.
We also emphasize in the README that a wrong system code will stop
the client from being instanciated.
@camillecroci camillecroci force-pushed the update-client-metrics-web branch from 1c7690f to 16df5e1 Compare February 12, 2026 14:42
@camillecroci camillecroci changed the title Update client metrics web Replace AWS RUM with Client Metrics Server Feb 12, 2026
@camillecroci camillecroci marked this pull request as ready for review February 12, 2026 15:05
We created a new domain for it so now we can use that instead of the hako app
@camillecroci camillecroci force-pushed the update-client-metrics-web branch from 1b144a3 to 07c4e64 Compare February 13, 2026 11:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant