Skip to content

Conversation

tommaso1
Copy link
Collaborator

List of Changes

Parallel Data Fetching

  • API Calls: Changed sequential calls to parallel using Promise.all() for:
    • getProducts(), getGuidePageProps(), and getGuidesMetadata()
    • Page-level fetching of guide data and URL replace map
  • S3 Downloads: Parallelize menu and body file downloads

Intelligent Caching

  • Guide Page Cache: In-memory caching to prevent duplicate work between metadata generation and rendering
  • S3 File Cache: URL-based caching for downloaded files
  • Metadata Cache: 5-minute TTL cache for metadata with timestamp-based invalidation

Architecture Changes

  • Converted from static generation (generateStaticParams) to dynamic rendering
  • Maintained all existing functionality while improving performance
  • ESLint compliant (removed all console.log performance monitoring)

Files Modified

  • page.tsx - Dynamic rendering config + parallel fetching
  • lib/api.ts - Parallel API calls + caching layer
  • helpers/parseS3Doc.helpers.ts - Parallel S3 downloads
  • helpers/s3Metadata.helpers.ts - Enhanced metadata caching

Expected Impact

  • Significant reduction in page load times through parallel execution
  • Reduced server load through intelligent caching
  • Better user experience with faster guide page rendering
  • Maintained full functionality while improving performance

Motivation and Context

How Has This Been Tested?

Screenshots (if appropriate):

Types of changes

  • Chore (nothing changes by a user perspective)
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

Checklist:

  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.

uolter and others added 6 commits June 16, 2025 16:14
* add to static params page from gitbook

* add changeset

* Fix gitbook parsing for solutions and release notes

* Fix release note pages

* remove console log

* fix generate metadata skip summary

* Add changeset

* Fix after review
…aching strategies. Refactor S3 file downloads to use parallel fetching and introduce cache for metadata to reduce redundant network calls. Update breadcrumb handling for improved navigation. Comment out static generation code to enhance performance.
Copy link

changeset-bot bot commented Jun 25, 2025

🦋 Changeset detected

Latest commit: e8cf35d

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 3 packages
Name Type
nextjs-website Major
gitbook-docs Minor
infrastructure Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Base automatically changed from poc-standalone to main June 26, 2025 15:36
@marcobottaro marcobottaro requested a review from a team as a code owner June 26, 2025 15:36
Copy link
Contributor

github-actions bot commented Jul 1, 2025

Branch is not up to date with base branch

@tommaso1 it seems this Pull Request is not updated with base branch.
Please proceed with a merge or rebase to solve this.

Copy link
Contributor

github-actions bot commented Jul 1, 2025

Jira Pull Request Link

This Pull Request refers to the following Jira issue DEV-2340

@marcobottaro
Copy link
Collaborator

Replaced by #1518

@marcobottaro marcobottaro deleted the DEV-2340-guides-performance branch August 8, 2025 09:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants