Introduction to Building E-Commerce Solutions on Heroku and Salesforce
-
Author
salesforce-developers -
Category
Technology
-
view
803 -
download
5
Embed Size (px)
description
Transcript of Introduction to Building E-Commerce Solutions on Heroku and Salesforce

Introduction to Building E-Commerce Solutions on Heroku and Salesforce
Scott Geosits, Trifecta Technologies Inc., Salesforce.com Solutions Architect and Team [email protected]

All about Trifecta Technologies▪ IT Business Solutions Company
▪ Custom Enterprise and Highly Integrated Solutions
▪ Specializing in Salesforce, Mobile, and Web
▪ Engaged by leading brands across many industries
▪ 22+ years of Customer Success

Who is Varsity? We are cheerleading!!!
Leading provider of apparel and accessories to cheer and dance teams across North America

The Varsity Colors business storyBusiness Need: •Create fully branded online fundraising stores on demand for school teams•Leverage existing Salesforce implementation•Quick and simple setup and configuration for users

Solution overview
Microsite Admin
heroku add-ons
Team Store Microsites
Environment Configuration
Worker Services
heroku add-ons
Microsite Configuration
Product Catalog
database.com
Adobe Scene7
Varsity Legacy Platform -AS400 iSeries ERP-Order Management System-CyberSource Payment Gateway
Integration Tier- A
S400 iSeries ERP
- Adobe Scene 7
- CyberSource Payment Gateway
- S3 Static Web Resources

Solution overview – Force.com
Microsite Configuration
Product Catalog
database.com
Adobe Scene7

Solution Details – Force.comWhy we chose Force.com
▪ Varsity has embraced Force.com across all levels of the business▪ Significantly lower development costs▪ Workflow for store approvals▪ Sales reps do most of their work in Salesforce▪ Reporting on fundraising program sales

Force.com – Product catalog and store maintenance▪ Product data sourced from corporate ERP system▪ Administrators configure product data▪ Markup and web content controlled by administrator▪ Configure customizable product layers▪ Adobe Scene 7 integration updates images immediately▪ Color scheme groupings for easy maintenance▪ Sales reps configure store style and content▪ Catalog per school allows reps to select products for sale▪ One click to publish site to Heroku

Force.com – Product catalog and store maintenance

Force.com – Order capture and dashboards▪ Orders captured in both Salesforce and ERP▪ Dashboards provide easy visibility to sales totals

Force.com – Best practices and lessons learned▪ Salesforce pushes updates for products, accounts to Heroku▪ Heroku integration via Salesforce REST API▪ Be aware of governor limits!
▪ Script limits - this has been removed▪ DML Statements / query limits▪ Downstream trigger cascade effects and considerations▪ Large complex data model can cause you to exceed limits▪ External email limit exceptions
▪ Limit your API calls▪ Use custom Apex REST services where appropriate to reduce API calls and define
transaction boundaries

Solution overview – Heroku
Microsite Admin
heroku add-ons
Team Store Microsites
Environment Configuration
Worker Services
heroku add-ons
Adobe Scene7
Varsity Legacy Platform -AS400 iSeries ERP-Order Management System-CyberSource Payment Gateway
Integration Tier- A
S400 iSeries ERP
- Adobe Scene 7
- CyberSource Payment Gateway
- S3 Static Web Resources

Solution Details – HerokuWhy we chose Heroku
▪ Customer facing application functionality• Java gives us more flexibility for pure custom solution.• Customer facing sites do not need full Salesforce capabilities and would be cost
prohibitive for user licensing.
▪ Integration• Real-time processing on Heroku vs. scheduled jobs in Force.com.
▪ Service options• Availability of more ready-to-go functionality via add-ons
▪ Scalability• Start small and add dynos as the application grows

Team store and fundraising site▪ School specific branding, style, and content▪ Hundreds of school sites rendered via single set of CSS and HTML templates

Custom fundraising e-commerce solution▪ Full cart and checkout e-Commerce functionality▪ Adobe Scene 7 renders dynamic product images▪ Social links allow shoppers to share items▪ Custom Heroku authentication for customers

Heroku Application Structure▪ Java / Spring MVC core▪ Add-on services
▪ Cloudant storage▪ Memcachier caching▪ SendGrid email service▪ CloudAMQP Message Queueing
▪ Adobe Scene 7 dynamic image creation▪ S3 static asset hosting▪ New Relic monitoring

Heroku architecture constraints▪ Web dynos must respond in 30 seconds or less▪ Dynos must start up in 60 seconds or less▪ Heap size
▪ 1x dynos get 512 MB, 2x dynos get 1024MB
▪ No session state▪ Need persistence solution such as Cloudant
▪ No web server or filesystem▪ S3 or similar solution for static assets (CSS, javascript, images, etc.)

Heroku – Best practices and lessons learned▪ Caching strategy
▪ Frequently accessed pages pre-generated and cached for fast web dyno response▪ Two level cache for header, footer, catalog and product HTML components
▪ Memcache provides fast primary lookup▪ If item not present in memcache, retrieve from Cloudant if not dirty▪ If dirty, request regeneration of HTML component▪ Product and account information also cached in this manner
▪ Long running processes▪ Use worker dynos, message queues and AJAX calls to check status on web pages▪ Page generation, order completion

Heroku – Best practices and lessons learned▪ Also use worker dynos for batch processing
▪ Integration worker to update Salesforce from AS/400 ERP▪ Batch job to re-generate dirty HTML page components in the background
▪ Cloudant for session persistence▪ Take advantage of add-on services to reduce implementation time
▪ No need to rebuild functionality▪ Use developer level services for prototyping and development
▪ Throughput and scaling▪ Java web dynos support multithreading – use this to boost your throughput

For more information…▪ Heroku Dev Center
• https://devcenter.heroku.com• Heroku is free to try and develop on – sign up for an account at http://www.heroku.com
▪ Salesforce REST API• http://www.salesforce.com/us/developer/docs/api_rest/
▪ Developer.force.com• http://developer.force.com/
▪ Trifecta Technologies• http://www.trifecta.com

Scott Geosits
Salesforce.com Solutions Architect and Team Lead,@scottgeosits

Visit Us at Booth #1207 Moscone Center Expo North or Online at www.trifecta.com!