Resolve IronBank::BadRequestError errors from change in sandbox schema
Problem
We're seeing a bunch of errors like IronBank::BadRequestError
related to a malformed query like this one:
Body: {"detail"=>{"MalformedQueryFault"=>{"FaultMessage"=>"invalid field for query: Subscription.end_customer_details__c", "FaultCode"=>"INVALID_FIELD"}}, "faultcode"=>"fns:INVALID_FIELD", "faultstring"=>"invalid field for query: Subscription.end_customer_details__c"}
The majority of the IronBank::BadRequestError
errors we've seen are related to above, but there is one other error we've seen related to another field Invoice.currencyexchangerate__c
:
IronBank::BadRequestError: Body: {"detail"=>{"MalformedQueryFault"=>{"FaultMessage"=>"invalid field for query: Invoice.currencyexchangerate__c", "FaultCode"=>"INVALID_FIELD"}}, "faultcode"=>"fns:INVALID_FIELD", "faultstring"=>"invalid field for query: Invoice.currencyexchangerate__c"}
Proposal
Fix the schema for Zuora Sandbox. It looks like the custom field was renamed in Zuora Sandbox but we have to match that in our schema. If we don't use that field in our codebase, then the better fix might be to remove it from our schema in case it changes again.
Result
This should fix many errors we're seeing in stg at the moment.
Next steps (if any)
Long term it would be good to notify the Fulfillment team before custom field changes are made in Zuora production or sandbox.
Edited by Tyler Amos