Questions tagged [architecture]

Questions about Magento architecture

Filter by
Sorted by
Tagged with
0 votes
0 answers
17 views

Why does Magento 2 disperse product image files into multiple folders?

When uploading products into Magento 2, by default the system disperses images into folders based on the image name. file.jpg would end up in pub/media/catalog/product/f/i/file.jpg Can anyone explain ...
user avatar
  • 1
1 vote
2 answers
114 views

Encrypt Customer data before save into the database and Decrypt Customer data after fetched from the database

I need to encrypt the customer data in the database, so if the database is hacked. the Hacker cannot access my customers (Customer privacy). I need to encrypt the customer data just before saving it ...
user avatar
  • 426
0 votes
1 answer
45 views

Price calculator for small wine e-shop with multiple warehouses in different countries

Problem: My friend runs some small wineries in Italy and owns 3-4 small warehouses in different European countries. He wants his online customers (wine buyers) to decide from which warehouse they ...
user avatar
1 vote
3 answers
118 views

Websites vs Categories

I'm currently managing a fairly large and complex Magento2 site. Admittedly, I'm more of a front-end guy. As such, I had a question. We have 82 stores (one for each corporate customer). Each store ...
user avatar
  • 11
0 votes
1 answer
229 views

Decoupled Frontend Architecture and Magento

Is there anyway we can utilize Decoupled Frontend Architecture in Magento. I would like to know if I can utilize this architecture to create Magento modules or convert my existing extensions? Is it ...
user avatar
0 votes
1 answer
34 views

How do I understand the connection of module components (e.g., code/design/frontend/template/block, etc.) in Magento 1.9?

I'm very new to Magento and am familiar with MVC and OOP and a lot of the design patterns that Magento uses. However, I find it difficult to understand the relationship between all the components of a ...
user avatar
  • 101
2 votes
4 answers
4k views

Magento 2 follows MVVM architecture or MVC architechure?

I am understanding the logic behind working in separate folders in Magento 2 and came across bundle of articles talking about same thing in different ways. Some explain MVC logic behind it and some ...
user avatar
  • 1,521
5 votes
2 answers
801 views

What is the recommended way to integrate to other services from Magento 2?

As part of building out an E-Commerence website for Company X, integrations into other systems within the company are required. These integrations include Ordering and Payment services. The APIs for ...
user avatar
  • 163
5 votes
1 answer
551 views

Magento 2 : Which File & Line app/etc/di.xml Config Will Load by App

I need to know, area wise config will load by application entry point files like /Magento/Framework/App/Http launch method. But I'm not able to figure it out app/etc/di.xml config load.
user avatar
  • 207
15 votes
4 answers
3k views

Magento 2 best practice for class locations and names

In Magento 1 we were used to place our classes in these directories Block Helper Model Resource and use a simple class name without any capital letters in the middle of the name. ...
user avatar
1 vote
2 answers
697 views

Use existing PHP, HTML, and JavaScript based website in the same structure, but use Magento 2.1 Functions and tools such as accounts and Carts

This is specific to Magento 2.1, but knowledge on other versions may help in pointing me in the right direction. I have tried a few things and have scoured the internet for similar solutions but most ...
user avatar
1 vote
0 answers
22 views

Right using models in controllers?

For example, I need to get special data from a table for prepare form-data to save (in controller). Currently I have a direct dependency for a model. use Vendor\CustomerSurvey\Model\Survey; /** * @...
user avatar
4 votes
2 answers
3k views

what is the app/bootstrap.php file for?

I just started working on a new magento site and when I moved it to my local I got the below error on my nginx server. 2016/09/14 13:38:41 [error] 7#7: *13 FastCGI sent in stderr: "PHP message: ...
user avatar
  • 4,613
4 votes
1 answer
77 views

Why does Magento need blocks?

I'm reading the PHP Developer's Guide and I see this: Blocks are used in Magento to reduce the burden on the controller by moving most of the logic into blocks. What problem does this solve? ...
user avatar
0 votes
1 answer
26 views

extending custom(not core based) classes

In my project I have a "lib" directory with different custom libs/classes from php community. But unfortunately I need to extend several classes from "lib" directory. How can I do that in magento way? ...
user avatar
  • 93
7 votes
2 answers
274 views

How to avoid Law of Demeter violation ("Newable objects should not hold a field reference to an injectable object")

In the Rules for using dependency injection, the Magento 2 devdocs state: Newable objects should not hold a field reference to an injectable object nor should they request one in their constructor. ...
user avatar
8 votes
2 answers
3k views

what are the zend components using by magento2?

Magento2 now using zend framewok 1 ,zend framework 2 ,symfony etc. I want to know what are the components taken from zend framewok 1 and components taken from zend framewok 2. For example: Zend_Db (...
user avatar
  • 207
24 votes
3 answers
5k views

Is there ever a reason to prefer $model->load() over service contracts?

I understand that the preferred way to work in between modules in Magento 2 is using the service contracts. So if I want to load a product, I use the product repository: $product = $...
user avatar
1 vote
0 answers
145 views

Are there any creative solutions for launching cron.sh for multiple Magento stores in a distributed architecture?

At the company I work for, our architecture is set up in such a way that we have hundreds of Magento stores, and a variable number of application servers (behind a load balancer), but only one ...
user avatar
26 votes
3 answers
9k views

What is Context Object purpose in any class's constructor DI ? How Context works?

In most of the class's Constructors, a Context object is passed . I couldn't understand how this Context Obj works . I also noticed that sometimes this is passed to parent class's constructor like ...
user avatar
  • 271
5 votes
2 answers
2k views

Use preconfigured builders (e.g. for SearchCriteria) in Magento 2

Warning, this is a long winded question about module architecture. I'm not mad if it gets closed as opinion based, but I hope someone has a better idea than me. In Magento 2 we have builders like the ...
user avatar
0 votes
3 answers
1k views

Where does Magento keeps it's business logic?

I went through some articles which describes Magento architecture. As we all knows Magento uses MVC ( Model-View-Controller ) architecture. It separates the business logic, data access layer and ...
user avatar
  • 9,847
1 vote
0 answers
445 views

Magento multi-site data migration. While merging new store needs to keep live existing stores/sites

I am working on Magento enterprise edition. In which, two sites are already set up and working. Both of them are setup and configured by us. Now as per requirement client wants to add one more site in ...
user avatar
18 votes
4 answers
18k views

Why `code` folder is missing under `app` folder in magento 2 stable version?

I have downloaded Magento 2 stable from https://www.magentocommerce.com/download with sample data and installed. It's working fine in both areas i.e. frontend & backend. But I could not find app/...
user avatar
29 votes
1 answer
14k views

Magento ER diagram of 1.9.x

I am looking for ER diagram of magento 1.9.x so that i can understand magento database flow and table-relationships. if anyone can provide me COMPLETE ER diagram that will really help me. Like i saw a ...
user avatar
  • 4,657
1 vote
1 answer
64 views

How to cache (copy) the catalog database in a third-party app and keep it in sync?

We have a third party app that allows users to manage their catalog. The app uses the Magento API to fetch catalog data but it is very slow and it offers no pagination. I want to cache the catalog ...
user avatar
  • 1,414
1 vote
1 answer
93 views

where are static blocks used, and what potential values in eav_attribute

I am about 3 months into Magento at this point. I have worked with static blocks core_blocks being used in a store for categories to either supplement or replace the category list. I know these are ...
user avatar
5 votes
2 answers
259 views

Where’s The V in Magento's MVC? And is there better name?

When you look at the Magento directory structure, the C for ‘controller’ and the M for Model are easily identified as files and classes. But where are the Views and what are they?
user avatar
  • 894
22 votes
3 answers
5k views

Request flow of Magento 2

Their is a lot of fuss going about Magento 2, concept like Namespaces etc has been incorporated into it. I am just curious to know how REQUEST flow has been handled in Magento 2, can somebody give me ...
user avatar
1 vote
2 answers
193 views

Is it possible to configure one event Observer for all Magento events?

Is it possible (whether practical or not) to cut some configuration down by registering an observer to all Magento Events. The purpose for this would be to build an Observer that works as a "service ...
user avatar
1 vote
1 answer
49 views

Fill custom attribute product during checkout

Imagine this situation: in some situation the user, (in the cart view) are able to buy a special discount card, this card need the username, lastname and birthday. In my configuration I have a ...
user avatar
  • 111
5 votes
1 answer
628 views

Is Magento based on 3 tier architecture?

I want to know few things: Is magento based on 3 tier architecture? Is it free from SQL-Injection, cross-site-scripting, CRLF injection attacks and SSI attacks?
user avatar
3 votes
0 answers
69 views

Need to know whole Magento Design Patterns [duplicate]

I want to know how many 'Design Patterns' are magento using, I am exploring my self and found below lists, if you know others than listed patterns. Please feel free to add. 1: MVC - Magento utilizes ...
user avatar
7 votes
1 answer
458 views

what is the need of extra layer(service contracts) in magento2?

With out service contracts: For example I can extend directly class AccountManagement model. I can override any function.At the same time if core developers add anything in class AccountManagement ...
user avatar
  • 207
1 vote
2 answers
289 views

Building a highly customizable marketplace

I have to building a very customized marketplace and would like some advises. Basically weather or not Magento could be a good choice. I have to building a very customized marketplace and would like ...
user avatar
2 votes
2 answers
230 views

Fear about Magento 2.0 as a developer [closed]

I've been working for the last two years as a Magento developer.I have learned some what of magento's folder structure, rewrite of classes, front end customization etc. So if any requirement or ...
user avatar
  • 207
2 votes
3 answers
3k views

What's the difference between order_id and Parent_id in sales Order?

The question might look a bit stupid but I don't understand the difference between parent_id and order_id.
user avatar
  • 109
3 votes
2 answers
202 views

Why separately placing methods in interface instead of abstract class?

I want to delete Interface Mage_Shipping_Model_Carrier_Interface. interface Mage_Shipping_Model_Carrier_Interface { /** * Check if carrier has shipping tracking option available * ...
user avatar
  • 207
3 votes
1 answer
2k views

Why are bundle product tier prices a percent value?

My question is not a coding but architectural one. So for simple products, downloadable, grouped and configurable products the tier pricing uses a monetary value for for each price e.g. 20.59 in what ...
user avatar
1 vote
3 answers
2k views

what is the exact use of interface in real time?

I know how to declare and rules to create interface. i'm trying to understand exact need of interface in real time.I'm reading many articles with examples.still i'm not satisfied. Can any one ...
user avatar
  • 207
1 vote
1 answer
258 views

what is the need of implement arrayaccess interface for Varien_Object class?

I know using ArrayAccess interface we can use object as array(getting setting unseting).And i have idea that ArrayAcess interface contain 4 undefined methods.we should implement these methods if class ...
user avatar
  • 207
1 vote
1 answer
146 views

Why so many classes declared as abstract even it contain all defined methods?

For example these classes are abstract Mage_Catalog_Model_Abstract,Mage_Core_Model_Abstract etc.But it contain only defined methods.and what is the necessity to given class as abstract. I know ...
user avatar
  • 207
3 votes
2 answers
1k views

Finding possible methods for objects in Magento

Lots of confusion on this point, hopefully you will understand my areas of lacking understanding by the trend of my questioning: How does one find available methods for objects in Magento and the ...
user avatar
  • 271
1 vote
1 answer
976 views

Best practices or tips for modules with multiple websites/stores/views

I haven't really seen this topic covered much, but I was wondering what are some things that need to be taken into account when implementing modules when the Magento setup is using multiple websitess. ...
user avatar
  • 161
2 votes
3 answers
4k views

How to access custom table/attributes using the ORM?

I've been struggling with this for a while - I'm new to Magento and haven't programmed in PHP for a while, so please, bear with me. Doing some changes on a Shipping module to magento I've come to ...
user avatar
  • 21
4 votes
2 answers
591 views

Extending newsletter functionality correctly

I have previously made a module which would allow a user to sign up for newsletters and decide on which type of newsletters they would receive e.g. promotion, new lines etc. This module was my first ...
user avatar
  • 1,707
0 votes
1 answer
85 views

What Model Data Is Available On Edit

I have created a custom module with my own db table. My question is; what data is available to me in the block class while I'm editing an entry? For example, I use the products collection in my block ...
user avatar
  • 1,471
2 votes
1 answer
1k views

Is Magento a better choice than, say, OpenCart? [closed]

I've been developing non-ecommerce sites for years and I've learned is that CMS code/architecture quality, and the size of the community/ecosystem around the CMS are two essentials. For example, there ...
user avatar
2 votes
2 answers
820 views

doing topsellers/bestsellers by category elegantly

So I've been tasked with making a bestsellers box, yet I've heard a horror story about the bestsellers box in a previous site taking down the site because of the extensive load. First, I should ...
user avatar
18 votes
3 answers
4k views

Magento running on Percona Server with XtraDB

Does anyone have any experience with Magento db running on Percona Server with XtraDB? Benchmarking, stres testing, numbers... anything
user avatar