SlideShare une entreprise Scribd logo
1  sur  18
Télécharger pour lire hors ligne
PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION
PUNCHKICK INTERACTIVE
WEB APP PERFORMANCE OPTIMIZATION:
MIDDLEWARE BEST PRACTICES




© 2013 Punchkick Interactive Inc. All rights reserved.
WEB APP PERFORMANCE OPTIMIZATION

AGENDA




                                            PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION
1. Planning for Performance Optimizations

2. Traditional Architectural Approach

3. Improved Architectural Approach

4. Summary
PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION
Web App Performance Optimization Best Practices
PLANNING FOR
PERFORMANCE OPTIMIZATION
PLANNING FOR PERFORMANCE OPTIMIZATIONS

CONSIDERATIONS WHEN DESIGNING
A WICKED-FAST WEB/NATIVE APP




                                                                    PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION
The single most important driver of the decision-making process
towards a middleware API is the number of 3rd party integrations.

Factors We Consider During Planning Include:
•   Number of 3rd party API integrations
•   Audiences' client-capabilities
•   Number of clients within the product lifecycle
•   Codebase maintenance plans
•   Remote environment



© 2013 Punchkick Interactive Inc. All rights reserved.
PLANNING FOR PERFORMANCE OPTIMIZATIONS

COMMON PITFALLS DURING PLANNING




                                                                      PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION
It’s very easy to have a well-intentioned plan spin out of control,
into something that has a massive implementation cycle.

Keep the Following in Mind:
•   A complex caching strategy is more difficult to add post-launch
•   Think about each single point of failure abstractly when
    planning for security concerns
•   Some premature optimization is acceptable, but try to avoid
    overly-premature optimization
•   Devices matter; architect for the correct audience
•   3rd party dependencies aren’t always engineered to be fast
•   All projects have an "expires by" sticker; apps should be
    updated as new technologies are hardened
© 2013 Punchkick Interactive Inc. All rights reserved.
PLANNING FOR PERFORMANCE OPTIMIZATIONS

COMMON PAIN-POINTS FOR APPS




                                                                       PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION
Our design principals strive to address several pain points that are
common to most Web projects.

Symptoms of Poorly-Planned Apps:
•   Many data-integrations and business logic present within the
    client-side codebase
•   Each just-in-time page load is expensive
•   Lots of HTTP overhead with each AJAX request
•   Caching is an afterthought, and sometimes missed
•   Page loads depend heavily on 3rd party availability, introducing
    many points of failure



© 2013 Punchkick Interactive Inc. All rights reserved.
PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION
Web App Performance Optimization Best Practices
TRADITIONAL
ARCHITECTURAL APPROACH
TRADITIONAL ARCHITECTURAL APPROACH

WHAT WE OFTEN SEE




                                                                       PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION
Most Web apps we review don’t maintain a middleware strategy,
and this leads to a few less-than-ideal issues.

Fingerprint of a Less-That-Ideal Architecture:
•   Client talks to each API integration one-by-one
•   Multiple clients handle business logic (e.g. mWeb, native, etc.)
•   Each API has its own coding standards, errors, and protocols
•   Every request has HTTP overhead
•   API keys are exposed
•   Static page content isn't cached




© 2013 Punchkick Interactive Inc. All rights reserved.
TRADITIONAL ARCHITECTURAL APPROACH

PROBLEMS/RISKS WE IDENTIFY




                                                               PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION
Without a solid middleware strategy, unforeseen problems and
product risks can arise.

What a Less-That-Ideal Architecture Means to You:
•   Lots of integration code to maintain
•   Many points of failure
•   Page loads are slow
•   Requests not always secure
•   Business logic in the client
•   Can help embrace institutional knowledge isolation




© 2013 Punchkick Interactive Inc. All rights reserved.
PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION
Web App Performance Optimization Best Practices
IMPROVED
ARCHITECTURAL APPROACH
IMPROVED ARCHITECTURAL APPROACH

CLIENT-SIDE SPEED RACING




                                                                PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION
All modern Web clients can benefit from a creative approach to
browser-based optimizations.

Client-Side Speed-Improvement Opportunities:
• Prefetching of subsequent page data
• Browser caching of static NoSQL data
• Just-in-time data filtering (e.g. auto-complete)
• Others… get creative!




© 2013 Punchkick Interactive Inc. All rights reserved.
IMPROVED ARCHITECTURAL APPROACH

ADVANTAGES OF MIDDLEWARE APIS




                                                                             PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION
Designing a project-specific middleware is the single most effective
way to create speed improvements at an order of magnitude,
improve overall code quality and project security, and also lower
client-side development costs.

Middleware-Layers Improve Maintainability:
• Consolidates all 3rd party API calls into one place
• Isolates business logic to provide a single point of maintenance
• Forces the spread of institutional knowledge to broader team
• Simplifies client codebase by providing:
     ✓ Consistent API interface and coding standards for client requests
     ✓ Consistent error codes/messaging for client requests
     ✓ RESTful endpoints, regardless of individual 3rd party API protocols


© 2013 Punchkick Interactive Inc. All rights reserved.
IMPROVED ARCHITECTURAL APPROACH

ADVANTAGES OF MIDDLEWARE APIS
CONTINUED…




                                                                PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION
Middleware-Layers Increase Security:
• Isolates secret security-keys behind firewall
• Can provide secure endpoints to wrap unsecured API requests
• Ensures a single point of failure


Middleware-Layers Speed Execution Times:
• Can leverage multi-threaded server code for expensive data
  analysis, geospatial calculations, etc.
• Can preprocess/optimize binary content (e.g. images)




© 2013 Punchkick Interactive Inc. All rights reserved.
IMPROVED ARCHITECTURAL APPROACH

ADVANTAGES OF MIDDLEWARE APIS
CONTINUED…




                                                                  PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION
Perhaps the single-most compelling advantage of developing a
middleware API is faster data access.

Middleware-Layers Provide Faster Data Access:
•   Consolidate groups of API requests into a single response
•   Eliminate HTTP overhead using sockets
•   Customize caching headers for different content types
•   Cache commonly-used 3rd party API data to memory, NoSQL
    data store, etc. for request-free utilization by clients
•   Provide lightweight data packages to client by throwing out
    extraneous data from heavy 3rd party API queries

© 2013 Punchkick Interactive Inc. All rights reserved.
IMPROVED ARCHITECTURAL APPROACH

DISADVANTAGES OF MIDDLEWARE APIS




                                                                     PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION
What goes up, must also go down. And with many advantages to
support a middleware, there also a few disadvantages as well.

Potential Middleware Disadvantages:
• Adds processing overhead to the server-layer
• Can be a detrimental single point of failure when poorly coded
• Not worth doing unless there is a culture of test-driven
  development, code commenting, and shared documentation
• Initially increases overall product cost
     ✓ Needs to be written and maintained separate from the client
     ✓ Most effective when physically hosted near client-side app




© 2013 Punchkick Interactive Inc. All rights reserved.
PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION
                    Web App Performance Optimization Best Practices
                                                                      SUMMARY
SUMMARY

MIDDLEWARE IS A GOOD THING




                                                                    PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION
If you have many API integrations, middleware is a non-negotiable
part of any product development lifecycle.

Why Middleware APIs Are a Good Thing:
•   Advantages
     ✓ MUCH faster data access and page execution times
     ✓ MUCH easier to maintain business logic
     ✓ Simplifies client codebases, making them easier to maintain
     ✓ Often times more secure
     ✓ Overall product development lifecycle can be faster

•   Disadvantages
     ✓ Initially increases overall product cost
     ✓ MUST be independently maintained


© 2013 Punchkick Interactive Inc. All rights reserved.
WEB APP PERFORMANCE OPTIMIZATION

QUESTIONS?




                                   PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION
Ryan Unger
Co-Founder & CTO

1-800-549-4104 x 703
ryan@punchkickinteractive.com
@ryanunger

Contenu connexe

Dernier

Dernier (20)

Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 

En vedette

How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
ThinkNow
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Kurio // The Social Media Age(ncy)
 

En vedette (20)

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 

Mobile Web App Performance Optimization: Middleware Best Practices

  • 1. PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION PUNCHKICK INTERACTIVE WEB APP PERFORMANCE OPTIMIZATION: MIDDLEWARE BEST PRACTICES © 2013 Punchkick Interactive Inc. All rights reserved.
  • 2. WEB APP PERFORMANCE OPTIMIZATION AGENDA PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION 1. Planning for Performance Optimizations 2. Traditional Architectural Approach 3. Improved Architectural Approach 4. Summary
  • 3. PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION Web App Performance Optimization Best Practices PLANNING FOR PERFORMANCE OPTIMIZATION
  • 4. PLANNING FOR PERFORMANCE OPTIMIZATIONS CONSIDERATIONS WHEN DESIGNING A WICKED-FAST WEB/NATIVE APP PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION The single most important driver of the decision-making process towards a middleware API is the number of 3rd party integrations. Factors We Consider During Planning Include: • Number of 3rd party API integrations • Audiences' client-capabilities • Number of clients within the product lifecycle • Codebase maintenance plans • Remote environment © 2013 Punchkick Interactive Inc. All rights reserved.
  • 5. PLANNING FOR PERFORMANCE OPTIMIZATIONS COMMON PITFALLS DURING PLANNING PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION It’s very easy to have a well-intentioned plan spin out of control, into something that has a massive implementation cycle. Keep the Following in Mind: • A complex caching strategy is more difficult to add post-launch • Think about each single point of failure abstractly when planning for security concerns • Some premature optimization is acceptable, but try to avoid overly-premature optimization • Devices matter; architect for the correct audience • 3rd party dependencies aren’t always engineered to be fast • All projects have an "expires by" sticker; apps should be updated as new technologies are hardened © 2013 Punchkick Interactive Inc. All rights reserved.
  • 6. PLANNING FOR PERFORMANCE OPTIMIZATIONS COMMON PAIN-POINTS FOR APPS PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION Our design principals strive to address several pain points that are common to most Web projects. Symptoms of Poorly-Planned Apps: • Many data-integrations and business logic present within the client-side codebase • Each just-in-time page load is expensive • Lots of HTTP overhead with each AJAX request • Caching is an afterthought, and sometimes missed • Page loads depend heavily on 3rd party availability, introducing many points of failure © 2013 Punchkick Interactive Inc. All rights reserved.
  • 7. PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION Web App Performance Optimization Best Practices TRADITIONAL ARCHITECTURAL APPROACH
  • 8. TRADITIONAL ARCHITECTURAL APPROACH WHAT WE OFTEN SEE PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION Most Web apps we review don’t maintain a middleware strategy, and this leads to a few less-than-ideal issues. Fingerprint of a Less-That-Ideal Architecture: • Client talks to each API integration one-by-one • Multiple clients handle business logic (e.g. mWeb, native, etc.) • Each API has its own coding standards, errors, and protocols • Every request has HTTP overhead • API keys are exposed • Static page content isn't cached © 2013 Punchkick Interactive Inc. All rights reserved.
  • 9. TRADITIONAL ARCHITECTURAL APPROACH PROBLEMS/RISKS WE IDENTIFY PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION Without a solid middleware strategy, unforeseen problems and product risks can arise. What a Less-That-Ideal Architecture Means to You: • Lots of integration code to maintain • Many points of failure • Page loads are slow • Requests not always secure • Business logic in the client • Can help embrace institutional knowledge isolation © 2013 Punchkick Interactive Inc. All rights reserved.
  • 10. PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION Web App Performance Optimization Best Practices IMPROVED ARCHITECTURAL APPROACH
  • 11. IMPROVED ARCHITECTURAL APPROACH CLIENT-SIDE SPEED RACING PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION All modern Web clients can benefit from a creative approach to browser-based optimizations. Client-Side Speed-Improvement Opportunities: • Prefetching of subsequent page data • Browser caching of static NoSQL data • Just-in-time data filtering (e.g. auto-complete) • Others… get creative! © 2013 Punchkick Interactive Inc. All rights reserved.
  • 12. IMPROVED ARCHITECTURAL APPROACH ADVANTAGES OF MIDDLEWARE APIS PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION Designing a project-specific middleware is the single most effective way to create speed improvements at an order of magnitude, improve overall code quality and project security, and also lower client-side development costs. Middleware-Layers Improve Maintainability: • Consolidates all 3rd party API calls into one place • Isolates business logic to provide a single point of maintenance • Forces the spread of institutional knowledge to broader team • Simplifies client codebase by providing: ✓ Consistent API interface and coding standards for client requests ✓ Consistent error codes/messaging for client requests ✓ RESTful endpoints, regardless of individual 3rd party API protocols © 2013 Punchkick Interactive Inc. All rights reserved.
  • 13. IMPROVED ARCHITECTURAL APPROACH ADVANTAGES OF MIDDLEWARE APIS CONTINUED… PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION Middleware-Layers Increase Security: • Isolates secret security-keys behind firewall • Can provide secure endpoints to wrap unsecured API requests • Ensures a single point of failure Middleware-Layers Speed Execution Times: • Can leverage multi-threaded server code for expensive data analysis, geospatial calculations, etc. • Can preprocess/optimize binary content (e.g. images) © 2013 Punchkick Interactive Inc. All rights reserved.
  • 14. IMPROVED ARCHITECTURAL APPROACH ADVANTAGES OF MIDDLEWARE APIS CONTINUED… PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION Perhaps the single-most compelling advantage of developing a middleware API is faster data access. Middleware-Layers Provide Faster Data Access: • Consolidate groups of API requests into a single response • Eliminate HTTP overhead using sockets • Customize caching headers for different content types • Cache commonly-used 3rd party API data to memory, NoSQL data store, etc. for request-free utilization by clients • Provide lightweight data packages to client by throwing out extraneous data from heavy 3rd party API queries © 2013 Punchkick Interactive Inc. All rights reserved.
  • 15. IMPROVED ARCHITECTURAL APPROACH DISADVANTAGES OF MIDDLEWARE APIS PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION What goes up, must also go down. And with many advantages to support a middleware, there also a few disadvantages as well. Potential Middleware Disadvantages: • Adds processing overhead to the server-layer • Can be a detrimental single point of failure when poorly coded • Not worth doing unless there is a culture of test-driven development, code commenting, and shared documentation • Initially increases overall product cost ✓ Needs to be written and maintained separate from the client ✓ Most effective when physically hosted near client-side app © 2013 Punchkick Interactive Inc. All rights reserved.
  • 16. PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION Web App Performance Optimization Best Practices SUMMARY
  • 17. SUMMARY MIDDLEWARE IS A GOOD THING PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION If you have many API integrations, middleware is a non-negotiable part of any product development lifecycle. Why Middleware APIs Are a Good Thing: • Advantages ✓ MUCH faster data access and page execution times ✓ MUCH easier to maintain business logic ✓ Simplifies client codebases, making them easier to maintain ✓ Often times more secure ✓ Overall product development lifecycle can be faster • Disadvantages ✓ Initially increases overall product cost ✓ MUST be independently maintained © 2013 Punchkick Interactive Inc. All rights reserved.
  • 18. WEB APP PERFORMANCE OPTIMIZATION QUESTIONS? PUNCHKICK INTERACTIVE | WEB APP PERFORMANCE OPTIMIZATION Ryan Unger Co-Founder & CTO 1-800-549-4104 x 703 ryan@punchkickinteractive.com @ryanunger