guardian / frontend

The Guardian DotCom.
https://theguardian.com
Other
5.82k stars 556 forks source link

Are we still using Formstack? #25491

Open AshCorr opened 1 year ago

AshCorr commented 1 year ago

ISSUE

It was recently raised that we're looking to consolidate all our formstack tokens under one enterprise account. We seemingly use Formstack in our Identity application https://github.com/guardian/frontend/blob/95faf36910c217f490e014788905260dda70a0c0/identity/app/controllers/FormstackController.scala but it seemingly receives very little traffic and has expired Formstack tokens.

Do we still need to keep this integration? I'm not entirely sure what its purpose is. Doing a bit of commit digging it seems like it might be used for identity forms eg password reset

jamesgorrie commented 1 year ago

It seems there is 33 HTTP 200 over a two week period&_a=(columns:!(req.url),filters:!(),index:'50201630-bd0f-11e9-92b3-f10623802d36',interval:auto,query:(language:kuery,query:'req.url.keyword:%2Fform%2F*%20and%20resp.status%20:%20200%20and%20not%20req.url.keyword:%2Fform%2Fcomplete'),sort:!(!('@timestamp',desc)))) for form requests to the FormstackController routes

This is odd as the switch is off?

I wonder if we could try figure this out and remove the code.

/form/2020-03-06/cranbourne
/form/mon-projet
/form/jobba-eller-praktisera-hos-oss
/form/plaintone/4135
/form/nxE5QxfmAwah9bt
/form/hkk5S50Hp4K
/form/2020-02-22/bet365-yarra-valley
/form/contact-us/information-request-form
/form/wishlist
/form/website-feedback
/form/summer-training-internships-form
/form/join-our-mailing-list
/form/2nMfIuWHtZqtzzw4C
/form/2020-02-22/caulfield
rhiannareechaye commented 1 year ago

Comment from James: Basically in terms of the dependency on the formstack team, the keys we have don't exist in either the legacy account, nor new one, so we haven't got anything to do there. We should probably just remove this code for hygiene.

mxdvl commented 1 year ago

To note: the switch is actually ON in the frontend panel.

AshCorr commented 1 year ago

I think that this endpoint is always returning 200 + an internal redirect, so logs show a 200 status even though the end user sees a 404 page.

bryophyta commented 1 year ago

@jamesgorrie and @Georges-GNM to investigate next week?

rhiannareechaye commented 1 year ago

As per our triaging, this is a high impact issue so ideally we should look at it

georgeblahblah commented 11 months ago

My understanding of this issue is that we used to embed forms hosted by Formstack to enable readers to get in touch with more information about a story. This functionality has been migrated to Callouts, where we render the form. Callout forms submit to our Callouts API, which sends data to Formstack. Callouts only work on DCR; they do not work on Frontend.

The functionality to render a Formstack form is in FormstackController^1, and it is behind the IdentityFormstackSwitch switch ^2.

I think we could turn the IdentityFormstackSwitch off because: