Files
medusa-store/www/apps/resources/app/infrastructure-modules/page.mdx
Shahed Nasser 76f9da5ef4 docs: Caching Module (#13701)
* standard docs for caching module + deprecated cache module

* added guides for creating + using, and overall changes from cache to caching

* fix details related to redis provider

* fix build errors

* fix build error

* fixes

* add guides to sidebar

* add sidebar util

* document query + index

* moved cache tag conventions

* fix build errors

* added migration guide

* added memcached guide

* fixes

* general fixes and updates

* updated reference

* document medusa cache

* small fix

* fixes

* remove cloud cache

* revert edit dates changes

* revert edit dates

* small update
2025-10-21 10:34:27 +03:00

247 lines
7.4 KiB
Plaintext

import { CardList } from "docs-ui"
export const metadata = {
title: `Infrastructure Modules`,
}
# {metadata.title}
Medusa's architectural functionalities, such as emitting and subscribing to events or caching data, are all implemented in Infrastructure Modules. An Infrastructure Module is a package that can be installed and used in any Medusa application. These modules allow you to choose and integrate custom services for architectural purposes.
For example, you can use our [Redis Event Module](./event/redis/page.mdx) to handle event functionalities, or create a custom module that implements these functionalities with Memcached. Learn more in [the Architecture documentation](!docs!/learn/introduction/architecture).
This section of the documentation showcases Medusa's Infrastructure Modules, how they work, and how to use them in your Medusa application.
## Analytics Module
<Note>
The Analytics Module is available starting [Medusa v2.8.3](https://github.com/medusajs/medusa/releases/tag/v2.8.3).
</Note>
The Analytics Module exposes functionalities to track and analyze user interactions and system events. For example, tracking cart updates or completed orders. Learn more in the [Analytics Module documentation](./analytics/page.mdx).
{/* The Analytics Module has module providers that implement the underlying logic of integrating third-party services for tracking analytics. The following Analytics Module Providers are provided by Medusa. You can also create a custom provider as explained in the [Create Analytics Module Provider guide](/references/analytics/provider). */}
<CardList
items={[
{
title: "Local",
href: "/infrastructure-modules/analytics/local",
badge: {
variant: "neutral",
children: "For Development"
}
},
{
title: "PostHog",
href: "/infrastructure-modules/analytics/posthog",
badge: {
variant: "green",
children: "For Production"
}
}
]}
/>
## Caching Module
The Caching Module provides functionality to cache data in your Medusa application, improving performance and reducing latency for frequently accessed data.
The following Caching modules are provided by Medusa. You can also create a custom Caching Module Provider as explained in the [Create Caching Module Provider guide](#).
<Note>
The Caching Module is available starting [Medusa v2.11.0](https://github.com/medusajs/medusa/releases/tag/v2.11.0). It replaces the deprecated [Cache Module](./cache/page.mdx).
</Note>
<CardList
items={[
{
title: "Redis",
href: "/infrastructure-modules/caching/providers/redis",
badge: {
variant: "green",
children: "For Production"
}
},
{
title: "Memcached",
// TODO add link
href: "#",
badge: {
variant: "blue",
children: "Tutorial"
}
}
]}
/>
---
## Event Module
An Event Module implements the underlying publish/subscribe system that handles queueing events, emitting them, and executing their subscribers. Learn more in [this documentation](./event/page.mdx).
The following Event modules are provided by Medusa. You can also create your own event module as explained in [this guide](./event/create/page.mdx).
<CardList
items={[
{
title: "Local",
href: "/infrastructure-modules/event/local",
badge: {
variant: "neutral",
children: "For Development"
}
},
{
title: "Redis",
href: "/infrastructure-modules/event/redis",
badge: {
variant: "green",
children: "For Production"
}
}
]}
/>
---
## File Module
The File Module handles file upload and storage of assets, such as product images. Refer to the [File Module documentation](./file/page.mdx) to learn more about it.
The File Module has module providers that implement the underlying logic of handling uploads and downloads of assets, such as integrating third-party services. The following File Module Providers are provided by Medusa. You can also create a custom provider as explained in the [Create File Module Provider guide](/references/file-provider-module).
<CardList
items={[
{
title: "Local",
href: "/infrastructure-modules/file/local",
badge: {
variant: "neutral",
children: "For Development"
}
},
{
title: "AWS S3 (and Compatible APIs)",
href: "/infrastructure-modules/file/s3",
badge: {
variant: "green",
children: "For Production"
}
}
]}
/>
---
## Locking Module
The Locking Module manages access to shared resources by multiple processes or threads. It prevents conflicts between processes and ensures data consistency. Refer to the [Locking Module documentation](./locking/page.mdx) to learn more about it.
The Locking Module uses module providers that implement the underlying logic of the locking mechanism. The following Locking Module Providers are provided by Medusa. You can also create a custom provider as explained in the [Create Locking Module Provider guide](/references/locking-module-provider).
<CardList
items={[
{
title: "Redis",
href: "/infrastructure-modules/locking/redis",
badge: {
variant: "green",
children: "Recommended"
}
},
{
title: "PostgreSQL",
href: "/infrastructure-modules/locking/postgres",
}
]}
/>
---
## Notification Module
The Notification Module handles sending notifications to users or customers, such as reset password instructions or newsletters. Refer to the [Notifcation Module documentation](./notification/page.mdx) to learn more about it.
The Notification Module has module providers that implement the underlying logic of sending notifications, typically through integrating a third-party service. The following modules are provided by Medusa. You can also create a custom provider as explained in the [Create Notification Module Provider guide](/references/notification-provider-module).
<CardList
items={[
{
title: "Local",
href: "/infrastructure-modules/notification/local",
badge: {
variant: "neutral",
children: "For Development"
}
},
{
title: "SendGrid",
href: "/infrastructure-modules/notification/sendgrid",
badge: {
variant: "green",
children: "For Production"
}
}
]}
/>
### Notification Module Provider Guides
<CardList
items={[
{
title: "Send Notification",
href: "/infrastructure-modules/notification/send-notification"
},
{
title: "Create Notification Provider",
href: "/references/notification-provider-module"
},
{
title: "Resend",
href: "/integrations/guides/resend",
badge: {
variant: "blue",
children: "Integration"
}
}
]}
/>
---
## Workflow Engine Module
A Workflow Engine Module handles tracking and recording the transactions and statuses of workflows and their steps. Learn more about it in the [Worklow Engine Module documentation](./workflow-engine/page.mdx).
The following Workflow Engine modules are provided by Medusa.
<CardList
items={[
{
title: "In-Memory",
href: "/infrastructure-modules/workflow-engine/in-memory",
badge: {
variant: "neutral",
children: "For Development"
}
},
{
title: "Redis",
href: "/infrastructure-modules/workflow-engine/redis",
badge: {
variant: "green",
children: "For Production"
}
}
]}
/>