Netresearch Blog

Blog

You can find all the news and insights here. We share our knowledge, give tips and inform you about everything that happens internally and externally at our company.

DHL Shipping & Magento - Composition of Packages | PART 4

Composition of Packages

While we experimented with multi-module extensions already on the Magento 1 platform, evolution of technology granted us two significant changes which allowed to thoroughly utilize a modular architecture. First of all, the Composer dependency manager was introduced to the PHP world. Composer does not only allow to define the package requirements of a project, but also makes it possible to separate a package into smaller modules, using the metapackage package type. Secondly, the Magento 2 platform architecture puts strong emphasis on a clearly defined module API. That is, how individual modules are supposed to interact with each other. Based on these factors, the architectural vision was to create a central, abstract DHL shipping framework that on the one hand connects to the Magento core’s shipping module and on the other hand comes with the ability to plug in carrier modules (representing DHL business units) one after the other. Any other common (carrier-agnostic) functionality not offered by Magento core would be provided by further, independent modules.

 

Another step towards a modular extension architecture was to extract any web service communication into plain standalone PHP SDK libraries. One advantage is that possible use of the SDKs is not limited to the Magento platform. Another one is that web services can easily be exchanged without modifying the consuming application: The Location Finder API, used to fetch parcel pickup locations in checkout, was already replaced in the second release (v1.1.0) of the metapackage with no issues.

The modular approach paid off soon when DHL Express requested a Magento 2 extension for offering their shipping methods in checkout, paired with the ability to fulfill shipping in external software. The DHL Express Rates at Checkout module can be considered as a lightweight composition from the pool of available DHL packages.


Leaving technical aspects behind, the upcoming posts will focus on features and usability improvements. The next part highlights how merchants are guided through the label creation process by the new DHL packaging popup.

Extensions for Magento built by Netresearch

for Magento 1

  • DHL Shipping available on GitHub
  • DHL Online Returns available on GitHub
  • DHL Location Finder available on GitHub

for Magento 2

  • DHL Shipping (new official)
    available on Marketplace and GitHub
    features Returns and Location Finder already included
Share article:

Latest posts

Two business professionals shake hands in front of a digital world map – symbolizing a partnership in AI sales and digitalization

By Thomas Fleck

Netresearch is a new partner of the Smart Systems Hub

Netresearch is now a partner of the Smart Systems Hub - for more innovation in B2B commerce, AI and…

Read more
Man holding a smartphone, with the text 'Automated Translations in TYPO3' in the foreground, surrounded by floating country flags
By Thomas Schöne

With the TYPO3 extension autotranslate, content is translated automatically and in real time -…

Read more
Header image for the Netresearch blog article: Orange background with the text "Public Interest Technology: TYPO3 now officially recognized as a Digital Public Good." On the right side, a graphic depiction of a stylized globe surrounded by interconnected people – symbolizing global, public good–oriented digitalization.
By Franka Hesse

The Digital Public Goods Alliance has officially recognised TYPO3 as a digital public good. We…

Read more
Netresearch blog article image: “Digitalisation and AI for SMEs – Netresearch joins the Saxony Business Association” – blurred background with two business hands in handshake (suits), featuring a photo of Thomas Fleck, CEO & VP of Sales at Netresearch.
By Thomas Fleck

The future is created where people are empowered and connected. With our commitment to the Saxony…

Read more