Skip to main content

magento 1 extension converted in to magento 2 process


Simple Install
===================================
Download as a zip below link. unzip and upload it to your public_html or other rootdoc directory. https://github.com/magento/code-migration.

login to your server via shell

switch to the code-migration-develop directory by running following command  
cd code-migration-develop

Run command following command in root directory of this toolkit

composer instal

Before running the migration, the following directories need to be prepared:
=====================================
* `<src>` - Directory that contains custom Magento 1.x code that is intended to be migrated. The code must follow the Magento 1.x directory structure.   Magento1.x core files must not be included.

* `<dst>` - Empty directory for the toolkit to put the generated Magento 2 code to

* `<m1>` - Directory that contains:
* Vanilla Magento 1.x codebase, and
* Custom Magento 1.x code same as in `<src>` directory, and
* Dependencies of the custom Magento 1.x code, if any, that are not part of `<src>` directory as not intended to be migrated at the moment
* `<m2>` - Directory that contains the vanilla Magento 2.x codebase

The above directories are not required to be positioned relatively to each other, they can be anywhere in the file system.

Note that the Magento instances living in the directories `<m1>` and `<m2>` may not necessarily be installed. Being a static analysis tool, the toolkit does not execute the Magento source code.

 Migration Procedure
==================================
The migration consists of the following steps:

1. Migrate Magento 1.x module structure to the structure recognized in Magento 2

2. Migrate Magento 1.x layout XML files to the format recognized in Magento 2

3. Migrate Magento 1.x config XML files to the format recognized in Magento 2

4. Migrate the PHP code in terms of how it interacts with the Magento framework, preserving the business logic

Note that it may be necessary to regenerate the mapping files as the very first step. That is especially important in a case of migration between arbitrary Magento 1.x and Magento 2.x versions rather than the latest ones. It is an optional step, but it greatly influences the quality of the migration results. Please refer to the mapping files discussion later in the document.


Running the Migration
==================================
Run all the migration scripts:

1. `php bin/migrate.php migrateModuleStructure <src> <dst>` - Migrate directory structure

2. `php bin/migrate.php convertLayout <dst>` - Migrate layout

3. `php bin/migrate.php convertConfig <dst>` - Migrate config

4. `php bin/migrate.php convertPhpCode <dst> <m1> <m2>` - Migrate PHP code

The migration scripts are to be ran in the specified order as the output from one script may be used as input for another script.

The scripts read the Magento 1.x code from the `<src>` directory, convert it, and write the transformed code to the `<dst>` directory. All converted code is saved to files with a `*.converted` extension. The directories `<m1>` and `<m2>` are used to lookup the context of the code being migrated.

Comments

  1. Nice artical very usefull Thanks....!

    Magento 1 support end date

    ReplyDelete
  2. Thats great post you submit here and complete steps to conversion of Magento 1 extension. I'm always looking for these kind of informative blog post to get good knowledge as I'm professional Magento Developer.

    ReplyDelete
  3. Very useful for all turning to Magento 2 from Magento 1 since Magento 1 support is going to end in a couple of years.
    https://kssoft.tech

    ReplyDelete
  4. (Thanks for this blogspot)

    I Don’t Miss The Magento Extensions Selling, By partnering with Elsner, Best Magento Extensions Store you can avail service of some best selling Magento extensions like Advanced Summary Report, Multi Line Discount, Axis bank payment gateway, Price Negotiation extension and more.

    ReplyDelete
  5. Check out her latest website: Make Your Store Go Global With Magento Auto Currency Switcher Extension It would be the best decision to install the Magento Auto Currency Switcher Extension right from the inception of your store to avail maximum benefits. This gives you the advantage of reaching every nook and corner of the store and provide your customers with an extravagant shopping experience without any hassle.

    ReplyDelete
  6. hi welcome to this blog. really you have post an informative blog. it will be really helpful to many peoples. thank you for sharing this blog. Magento Ecommerce Services | PHP Services
    Digital Payment Platform
    Big data development company in Chennai

    ReplyDelete
  7. It has provided us the enough information within a relevant period of time ,the articles are encouraging the readers and building inspiration and motivation towards the topic,Your post is helpful to avoid the mistakes.Thanks so much for a detailed post!Hope you will keep on sharing articles.
    TECHNO DATA GROUP

    ReplyDelete

Post a Comment

Popular posts from this blog

Magento 2 product collection Filtering multi-select attribute values

  If you have multi-select attribute of product like below If you want filter value for this option Use below syntax to get product data: ->addAttributeToFilter('store_model', array('finset' => $params['store_model'])) finset key is used for multiselect attribute filter. $objectManager = \Magento\Framework\App\ObjectManager::getInstance(); $products = $objectManager->get('Magento\Catalog\Model\Product')         ->getCollection()         ->addAttributeToSelect('*')         ->addAttributeToSelect('store_brand')         ->addAttributeToSelect('store_model')         ->addAttributeToSelect('store_year')         ->addAttributeToFilter('store_brand', array('finset' => $params['store_brand']))         ->addAttributeToFilter('store_model', array('finset' => $params['store_model']))         ->ad...

Magento Debug HEADERS ALREADY SENT error

When you  receiving the following error in  system.log file: app\code\core\Mage\Core\Controller\Response\Http.php:44  [1] \www.pawan.com\lib\Zend\Controller\Response\Abstract.php:727  [2]  \www.pawan.com\app\code\core\Mage\Core\Controller\Response\Http.php:75  [3]  \www.pawan.com\app\code\core\Mage\Core\Controller\Varien\Front.php:188  [4]  \www.pawan.com\app\code\core\Mage\Core\Model\App.php:304  [5]  \www.pawan.com\app\Mage.php:596  [6]  \www.pawan.com\index.php:81 if you have no idea what file is causing this. Here is the steps to debug. That error is thrown from Mage_Core_Controller_Response_Http -> sendHeaders(). This function calls the super class function that actually does the check to see whether or not headers have already been sent, Zend_Controller_Response_Abstract -> canSendHeaders(). The Zend_Controller_Response_Abstract class handles, among other things, sending response header...