Browsed by
Category: Magento 2

Cronjob performance optimization: Magento 1 vs. Magento 2

Cronjob performance optimization: Magento 1 vs. Magento 2

Introduction This article is about problems that can occur with Magento cronjobs. The standard way to configure crontab for Magento 1 has it’s limits. The more custom cronjobs  a Magento system has, the more probable the system will face problems considering cronjobs. The most common issues are: Indexer Cronjob (Magento Enterprise malways mode) takes longer than usual so that other cronjobs (mdefault mode) are skipped (not executed) for the time the indexer runs Some of the cronjobs in mdefault scope take a…

Read More Read More

Deploying Magento2 – Releasing to Production [3/4]

Deploying Magento2 – Releasing to Production [3/4]

This post is part of series: History and Overview of Magento2 Deployment Jenkins Build-Pipeline Setup (building assets, controlling the deployment) Releasing to Production (delivering code and assets, managing releases) Future Prospect (cloud deployment, artifacts) Recap In the last post Jenkins Build-Pipeline Setup we had a look at our Jenkins Build-Pipeline and how to the setup and configuration is done. If you haven’t read it yet you should probably do so before reading this post. The last step in our Build-Pipeline was the actual Deployment…

Read More Read More

Workaround for Magento 2 Issue #5418 – Product Grid does not work after Import

Workaround for Magento 2 Issue #5418 – Product Grid does not work after Import

The Magento 2 Importer is a simple way to import and update Product Data and many more. Since July 2016, an Import will throw an Exception at the Product Grid. Today, I added a small script as a Workaround, which I want to share. It is actually simple and based on the Yonn-Trimoreau‘s SQL Query. I setup a bashscript, which enters the working dir and executes the query via n98-magerun2. After that, I added a CronJob to call the Script every…

Read More Read More

Deploying Magento2 – Jenkins Build-Pipeline [2/4]

Deploying Magento2 – Jenkins Build-Pipeline [2/4]

This post is part of series: History and Overview of Magento2 Deployment Jenkins Build-Pipeline Setup (building assets, controlling the deployment) Releasing to Production (delivering code and assets, managing releases) Future Prospect (cloud deployment, artifacts) Recap In the post Deploying Magento2 & History / Overview [1/4] we showed an overview of our deployment for Magento2 and this post will go into more detail on what is happing on the Build-Server and how it is done. So to get you up to speed, this is…

Read More Read More

Deploying Magento2 – History & Overview [1/4]

Deploying Magento2 – History & Overview [1/4]

Quite recently we have updated the deployment of our Magento2 projects to a more flexible and reusable way. Originally I wanted to create one post to present you our deployment setup, the systems involved, the workflow & process and some code that might be interesting. While describing this subject I decided to create a series of posts to cover those parts as it was just getting to extensive for one post. I am planing to cover the following topics in separate posts: History and…

Read More Read More

How to add alternative HTTP headers to Magento 2?

How to add alternative HTTP headers to Magento 2?

If you have more than one frontend server running in your business, it’s needed to load balance the traffic between the nodes. In this case we have a new instance between the browser and the web-server. Often it’s a system like HAProxy or Varnish. If the load balancer or proxy receives a request from a browser, it forwards it to backend server in the internal network. The IP address of the client is than added to a forward header which contains…

Read More Read More

How to Create a Category Image Attribute in Magento 2

How to Create a Category Image Attribute in Magento 2

Creating a custom Category Attribute with an image upload is quite common feature requirement in our shops. So this blog-post will be about the steps you have to take to create a custom category attribute with an image upload in Magento 2. The post turned out to be quite long, but I wanted to provide a complete description of all steps necessary. So stay with us if your interested 🙂 Our Module is called `Dev98_CategoryAttributes` and the image attribute will be called…

Read More Read More

How to create attribute-options in Magento2

How to create attribute-options in Magento2

Recently we had to create Configurable Products in our Product Import. To create those products we had to make sure that all simple products are generated before the configurable products and that all the attribute options for our configurable attribute are available. So this post will focus on how to create those attribute options and a problem where we had to spend some time figuring out. Preface We need to create those attribute options before we call $this->magentoImporter->validateSource($dataSource); otherwise the…

Read More Read More

How to adjust increment-ids in Magento 2

How to adjust increment-ids in Magento 2

Maybe almost every Magento developer has had the task to customize the increment-ids for orders or customers in Magento. Recap Magento 1 In Magento 1 you had to change the column increment_prefix  in the table eav_entity_store . I am sure there are modules out there that let you achieve that in convenient way. We have done that by using Setup-scripts most of the time. When a new store is created you need set the increment_prefix afterwards and do so for all entities that you…

Read More Read More

Creating Configurable Products

Creating Configurable Products

Basically there are different ways for creating Configurable Products in Magento2 (like in Magento1). You can create it using the Admin Panel, using a Setup\InstallData or Setup\UpgradeData class or during a custom import. ADDING THE ATTRIBUTE Let’s assume we are creating our attribute using the Setup\UpgradeData class in our module. The code we might initially create could look something like the following: protected function addAttributeDiameter() { $this->eavSetup->addAttribute( ProductModel::ENTITY, ‘dev98_diameter’, [ ‘type’ => ‘int’, ‘backend’ => ”, ‘frontend’ => ”, ‘label’ =>…

Read More Read More