bbc / simorgh

The BBC's Open Source Web Application. Contributions welcome! Used on some of our biggest websites, e.g.
https://www.bbc.com/pidgin
Other
1.41k stars 224 forks source link

Chartbeat not working on https://www.bbc.com/indonesia (and other sites) #5736

Closed JonBeeb closed 4 years ago

JonBeeb commented 4 years ago

Is your feature request related to a problem? Please describe. Chartbeat is not working for the site :https://www.bbc.com/indonesia . If you use the chartbeat HUD you get a error message. Looking at the beacon we are setting the chartbeat host as indonesia.bbc.co.uk

The following may also have the same problem: https://www.bbc.com/turkce -> turkish.bbc.co.uk https://www.bbc.com/portuguese -> brasil.bbc.co.uk

Describe the solution you'd like Looking at a current PAL page, the chartbeat beacon should set the host as indonesian.bbc.co.uk. The beacon value needs to be updated to reflect this

Describe alternatives you've considered None

Testing notes [Tester to complete]

Dev insight: Will Cypress tests be required or are unit tests sufficient? Will there be any potential regression? etc

Additional context You can see the current behavior on the live pal homepage to compare the values sent by the chartbeat beacon on the old vs new pages. If the fix has worked, the HUD should work on the new index.

sareh commented 4 years ago

We need to update how we set the h which is currently based on serviceName from the ServiceContext: https://github.com/bbc/simorgh/blob/latest/src/app/containers/ChartbeatAnalytics/utils/index.js#L26-L30 We should add a value called chartbeatDomain to the services config for each service, e.g. src/app/lib/config/services/indonesia.js and use that in the code.

indonesia: indonesian.bbc.co.uk turkce: turkish.bbc.co.uk

PriyaKR commented 4 years ago

Testing it locally shows the host value as 'test.bbc.co.uk' also as per discussion looks like it can't be tested on locally.

JonBeeb commented 4 years ago

List of hosts afaanoromoo.bbc.co.uk afrique.bbc.co.uk amharic.bbc.co.uk arabic.bbc.co.uk arts.bbc.co.uk atomised-news-web-server.api.bbc.co.uk autos.bbc.com azeri.bbc.co.uk bbc.au.apple.news bbc.co.uk bbc.com bbc.international.apple.news bbc.sport.apple.news bbc.uk.apple.news bengali.bbc.co.uk brasil.bbc.co.uk burmese.bbc.co.uk capital.bbc.com culture.bbc.com cymrufyw.bbc.co.uk earth.bbc.co.uk future.bbc.com gahuza.bbc.co.uk gujarati.bbc.co.uk hausa.bbc.co.uk hindi.bbc.co.uk igbo.bbc.co.uk indonesian.bbc.co.uk iwonder.bbc.co.uk japanese.bbc.co.uk korean.bbc.co.uk kyrgyz.bbc.co.uk m.bbc.co.uk m.test-branch5.news-javelin.tools.bbc.co.uk marathi.bbc.co.uk mundo.bbc.co.uk nepali.bbc.co.uk newsbeat-explains.ch.bbc.co.uk newsbeat.bbc.co.uk pal.sandbox.dev.bbc.co.uk pashto.bbc.co.uk persian.bbc.co.uk pidgin.bbc.co.uk punjabi.bbc.co.uk rd.bbc.co.uk religion.bbc.co.uk russian.bbc.co.uk serbian.bbc.co.uk sinhala.bbc.co.uk somali.bbc.co.uk stage.bbc.co.uk stage.radio.bbc.co.uk storyworks.bbc.co.uk swahili.bbc.co.uk tamil.bbc.co.uk telugu.bbc.co.uk test.arts.bbc.co.uk test.earth.bbc.co.uk test.homepage.bbc.co.uk test.iwonder.bbc.co.uk test.sport.bbc.co.uk thai.bbc.co.uk tigrinya.bbc.co.uk travel.bbc.com turkish.bbc.co.uk ukchina.bbc.co.uk ukrainian.bbc.co.uk urdu.bbc.co.uk uzbek.bbc.co.uk vietnamese.bbc.co.uk yoruba.bbc.co.uk zhongwen.bbc.co.uk