Solution overview
Before going deeper into how Heroku and Salesforce Functions are used to accomplish the use cases described in the previous section, let us review the overall components that will be built and how they interact with the FormulaForce application built so far.
The following solution overview diagram shows on the left the web (1) and API (2) experiences built with Heroku and how they interact with data stored in Heroku Postgres (3 and 4) and within the org (5). On the right, the diagram shows a Function (6) interacting with the same org data and the FormulaForce Lightning application as drivers check in to the race location. Finally, both the API (2) and Function (6) are exposed to the rest of the Lightning application via their own Apex Service layer classes (7 and 8).
Figure 8.6: Interaction between the FomulaForce public website and application
The above diagram makes use of the Service layer concept we discussed in Chapter 5, Application...