Website Development on Magento / Adobe Commerce
Magento 2 / Adobe Commerce is an enterprise platform for large-scale ecommerce. It is chosen when you need: multi-site setup from a single installation, complex catalog structure with thousands of attributes, custom business processes that cannot be implemented on SaaS platforms.
Magento Open Source vs Adobe Commerce
| Feature | Magento Open Source | Adobe Commerce |
|---|---|---|
| License | MIT (free) | Commercial ($) |
| Hosting | Self-hosted | Self-hosted or Cloud |
| B2B Module | No | Built-in |
| Page Builder | Basic | Advanced |
| Staged Content | No | Yes |
| Customer Segments | No | Yes |
| Live Search | No | Yes (SaaS) |
| Product Recommendations | No | Yes (AI-based) |
| Adobe Experience Cloud | No | Integration |
For most projects, Open Source is sufficient. Adobe Commerce is justified for B2B scenarios, complex personalization, or integration with Adobe Analytics/AEM.
Server Requirements
Magento 2.4.x (current branch):
- PHP 8.1–8.3 (8.2 is optimal)
- MySQL 8.0 or MariaDB 10.6
- Elasticsearch 8.x or OpenSearch 2.x (mandatory for search)
- Redis 7.x (sessions + cache)
- RabbitMQ 3.11+ (for async queues in large stores)
- Nginx 1.24+ / Apache 2.4
- Varnish 7.x (reverse proxy cache, optional)
- Minimum 4 CPU, 8 GB RAM for dev; 8 CPU, 16 GB RAM for prod
Modular System Architecture
Magento is built on modules. Each module is a folder in app/code/Vendor/Module/ or vendor/vendor/module/:
app/code/MyCompany/Catalog/
├── Block/ # PHP classes for View (legacy approach)
├── Controller/ # HTTP controllers
├── etc/
│ ├── module.xml # module declaration
│ ├── di.xml # Dependency Injection configuration
│ ├── routes.xml # routes
│ └── frontend/
│ └── events.xml # event subscriptions
├── Model/ # business logic
├── Plugin/ # Interceptors (before/after/around)
├── Observer/ # Event observers
├── Setup/
│ ├── InstallSchema.php
│ └── Patch/Data/ # Data patches
├── view/
│ └── frontend/
│ ├── layout/ # XML layout
│ └── templates/ # .phtml templates
└── registration.php
Dependency Injection and Plugin
Magento doesn't use new ClassName() — all dependencies are injected through the constructor. Configured in etc/di.xml:
<!-- Class substitution (preference) -->
<preference for="Magento\Catalog\Model\Product"
type="MyCompany\Catalog\Model\Product"/>
<!-- Plugin (interceptor) — without class substitution -->
<type name="Magento\Catalog\Model\ResourceModel\Product\Collection">
<plugin name="mycompany_catalog_collection_plugin"
type="MyCompany\Catalog\Plugin\ProductCollectionPlugin"
sortOrder="10"/>
</type>
Plugin (before/after/around):
// MyCompany/Catalog/Plugin/ProductCollectionPlugin.php
namespace MyCompany\Catalog\Plugin;
use Magento\Catalog\Model\ResourceModel\Product\Collection;
class ProductCollectionPlugin
{
public function afterLoad(Collection $subject, Collection $result): Collection
{
// Add attribute after collection load
foreach ($result as $product) {
$margin = ($product->getPrice() - $product->getCost()) / $product->getPrice() * 100;
$product->setData('margin_percent', round($margin, 2));
}
return $result;
}
}
Custom Product Attribute
// Setup/Patch/Data/AddProductAttributes.php
namespace MyCompany\Catalog\Setup\Patch\Data;
use Magento\Framework\Setup\Patch\DataPatchInterface;
use Magento\Catalog\Setup\CategorySetupFactory;
class AddProductAttributes implements DataPatchInterface
{
public function __construct(
private readonly CategorySetupFactory $categorySetupFactory,
private readonly \Magento\Framework\Setup\ModuleDataSetupInterface $moduleDataSetup,
) {}
public function apply(): void
{
$setup = $this->categorySetupFactory->create(['setup' => $this->moduleDataSetup]);
$setup->addAttribute('catalog_product', 'delivery_days', [
'type' => 'int',
'label' => 'Delivery time (days)',
'input' => 'text',
'required' => false,
'visible' => true,
'user_defined' => true,
'searchable' => false,
'filterable' => false,
'comparable' => false,
'visible_on_front' => true,
'used_in_product_listing' => true,
'unique' => false,
'apply_to' => '',
]);
$setup->addAttributeToSet('catalog_product', 'Default', 'General', 'delivery_days');
}
public static function getDependencies(): array { return []; }
public function getAliases(): array { return []; }
}
GraphQL API Magento
Magento 2.4 has a built-in GraphQL API for headless:
query GetProduct($urlKey: String!) {
products(filter: { url_key: { eq: $urlKey } }) {
items {
id
sku
name
price_range {
minimum_price {
regular_price { value currency }
final_price { value currency }
discount { amount_off percent_off }
}
}
... on ConfigurableProduct {
configurable_options {
label
values { label uid }
}
variants {
attributes { label uid }
product {
sku
stock_status
price_range { minimum_price { final_price { value } } }
}
}
}
custom_attributes {
attribute_metadata { code label }
... on AttributeValue { value }
}
}
}
}
PWA Studio / Vue Storefront
For headless frontend on Magento, use:
- PWA Studio (official, React) — actively developed by Adobe
- Vue Storefront 2 (Nuxt.js) — popular alternative
- Next.js Commerce — with Magento adapter
Multi-site and Performance
Magento natively supports multiple websites, stores, and store views from one installation. Configuration in Admin > Stores > Configuration with scope: Global → Website → Store View.
For high-load installations:
- Varnish FPC (Full Page Cache) — HTML page caching
- Redis: separate instances for cache and sessions
- Elasticsearch: separate cluster from main server
- CDN for static assets (Fastly, CloudFront)
- Horizontal scaling: multiple PHP-FPM servers + shared NFS/GCS for media
Typical Development Stack
# Project initialization
composer create-project --repository-url=https://repo.magento.com/ \
magento/project-community-edition=2.4.7 my-magento
# Installation
bin/magento setup:install \
--db-host=localhost \
--db-name=magento \
--db-user=magento \
--db-password=secret \
--base-url=https://magento.local/ \
--admin-firstname=Admin \
--admin-lastname=User \
[email protected] \
--admin-user=admin \
--admin-password=Admin123! \
--language=en_US \
--currency=USD \
--timezone=UTC \
--use-rewrites=1 \
--search-engine=opensearch \
--opensearch-host=localhost \
--opensearch-port=9200
# After module changes
bin/magento setup:upgrade
bin/magento setup:di:compile
bin/magento setup:static-content:deploy en_US -f
bin/magento cache:flush
Timeline
Launching a store on Open Source with a ready-made theme and standard set of modules: 4–8 weeks. Custom development with multiple modules, ERP/1C integration, and multi-site: 3–6 months. Adobe Commerce with B2B module, Page Builder, Customer Segments, and Adobe Experience Cloud integration: 6 months+, depends on scope.







