TDX 22: Advanced Salesforce Functions

Overview

Route Planner with Charging Stations

Architecture

architecture

Apex Utility Classes

apex-utility-classes

Salesforce Schema

salesforce-schema

Deployment Instructions

  1. Create a Scratch Org
sfdx force:org:create -s -f config/project-scratch-def.json -a routeplannerdemo
  1. Push Source to Org
sfdx force:source:push
  1. Assign Permission Sets
sfdx force:user:permset:assign -n RoutePlanner
sfdx force:user:permset:assign -n Functions
  1. Import Sample Data
sfdx force:data:tree:import -p data/Account-Service__c-plan.json
  1. Create a Compute Environment to Deploy Functions
sf env create compute -o routeplannerdemo -a routeplannerenv
  1. Deploy Functions
sf deploy functions -o routeplannerdemo
  1. Create Heroku Application for Data Resources
heroku create <app-name>
  1. Add Heroku User Collaborator to Functions Account
sf env compute collaborator add --heroku-user [email protected]
  1. Create Postgres and Redis Resources
 heroku addons:create heroku-postgresql:hobby-dev
 heroku addons:create heroku-redis:hobby-dev
  1. Attach Data Resources to Compute Environment
heroku addons:attach <example-postgres-database> --app <example-compute-environment-name>
heroku addons:attach <example-redis-database> --app <example-compute-environment-name>
  1. Deploy MQTT Heroku App
heroku config:set APP_BASE=apps/pulsar-mqtt-broker
git push https://git.heroku.com/<heroku-app-name>.git main
  1. Setup MQTT_URL env variable
sf env var set MQTT_URL=wss://<heroku-app-name>.herokuapp.com
  1. Load Charging Stations Dataset
cd scripts
heroku config --shell > .env
node create-db.js
You might also like...

This repository contains an Advanced Zoom Apps Sample. It should serve as a starting point for you to build and test your own Zoom App in development.

Advanced Zoom Apps Sample Advanced Sample covers most complex scenarios that you might be needed in apps. App has reference implementation for: Authen

Dec 17, 2022

Base provides advanced Promise Queue Manager, Custom Console Logger and other utilities.

Base Base provides frequently used functionality like cutome logger, response helper, Custom Promise and Instance composer. These are used in almost a

Jun 14, 2022

The most advanced responsive front-end framework in the world. Quickly create prototypes and production code for sites that work on any kind of device.

The most advanced responsive front-end framework in the world. Quickly create prototypes and production code for sites that work on any kind of device.

Install | Documentation | Releases | Contributing Foundation is the most advanced responsive front-end framework in the world. Quickly go from prototy

Jan 4, 2023

Advanced table plugin

Advanced table plugin

Grid.js Advanced table plugin A table library that works everywhere Simple and lightweight implementation No vendor lock-in. Grid.js can be used with

Jan 2, 2023

Remix enables you to build fantastic user experiences for the web and feel happy with the code that got you there. In this workshop, we'll look at some more advanced use cases when building Remix applications.

💿 Advanced Remix Workshop Remix enables you to build fantastic user experiences for the web and feel happy with the code that got you there. In this

Dec 9, 2022

Matt's Advanced TypeScript workshop

Advanced TypeScript Workshop Hello! My name's Matt Pocock. This is a workshop repo to teach you about Advanced TypeScript. Topics Covered Using typeof

Dec 24, 2022

Tiny JavaScript library (1kB) by CurrencyRate.today, providing simple way and advanced number, money and currency formatting and removes all formatting/cruft and returns the raw float value.

Zero dependency tiny JavaScript library (1kB bytes) by CurrencyRate.today, providing simple way and advanced number, money and currency formatting and removes all formatting/cruft and returns the raw float value.

Nov 8, 2022

A Moduler Advanced Whatsapp Bot in NodeJs.

A Moduler Advanced Whatsapp Bot in NodeJs.

Secktor 🖤 Deploy on heroku | Read the Documentation 📚 Introducing Secktor,Secktor is designed to bring a whole new level of excitement to your borin

Dec 26, 2022

The most advanced hack for sploop.io

The most advanced hack for sploop.io

Dsync Client The most advanced hack for sploop.io DOWNLOAD ON GREASYFORK: Dsync client Basic features Autoheal Placement (A LOT OF CPS) Hat hotkeys In

Dec 14, 2022
Owner
null
... a contemporary perspective on how to integrate B2C Commerce and the Salesforce Customer 360 Platform to power frictionless customer experiences in the B2C domain.

Salesforce B2C Commerce / Customer 360 Platform Integration Introduction Salesforce B2C Commerce / CRM Sync is an enablement solution designed by Sale

Salesforce CommerceCloud 45 Dec 9, 2022
This is a demo of updating a map to show air quality data for the user’s current location using Next.js Advanced Middleware, powered by Netlify Edge Functions.

Show Local Air Quality Based on the User's Location Use AQI data to show the air quality near the current user. This is built using Next.js Advanced M

Jason Lengstorf 8 Nov 4, 2022
A long list of (advanced) JavaScript questions, and their explanations

JavaScript Questions I post multiple choice JavaScript questions on my Instagram stories, which I'll also post here! Last updated: June 12th From basi

Lydia Hallie 50.9k Jan 1, 2023
dotdotdot.js, advanced cross-browser ellipsis for multiple line content.

dotdotdot Dotdotdot is a javascript plugin for truncating multiple line content on a webpage. It uses an ellipsis to indicate that there is more text

Fred Heusschen 1.7k Dec 20, 2022
lua-pack is an advanced lua bundler similar to webpack made for lua 5.1+ written in js

lua-pack is an advanced lua bundler similar to webpack made for lua 5.1+ written in js that makes working on large scale projects easy and fast. it takes all the files in your project and packs them into a single production ready file.

Chris 10 May 14, 2022
advanced calculator using only HTML, CSS and JS

Welcome to GitHub Pages You can use the editor on GitHub to maintain and preview the content for your website in Markdown files. Whenever you commit t

null 9 May 14, 2022
Project of advanced web programming for University of California, Irvine

projectWeb Project of advanced web programming for University of California, Irvine The goal is to re create a r/place in our own way. You can see an

Zolaski 2 May 31, 2022
AwardBot is an open source advanced giveaway bot. Written in Discord.js

AwardBot is an open source advanced giveaway bot. Written in Discord.js. You can set conditions for the giveaways, automatically deliver the prizes, and lock the giveaways.

Award 2 Oct 29, 2022
An Advanced Activity Command Using Discord-Together Package For Discord.jsv13 with buttons

Active An Advanced Activity Bot Using Discord-Together Package For Discord.jsv13 with buttons. Report Bug · Request Feature Usage. How to run the bot?

Hypwreck 11 Feb 15, 2022
Node WebStation is a powerful tool designed for developers allowing them to create advanced web sockets for any use all without having the requirement to code.

Node WebStation Node WebStation is a powerful tool designed for developers to use to create an advanced WebStation for any use all without not having

null 2 Jun 4, 2022