Skip to content

Commit 3fb9035

Browse files
author
Joan He
committed
Merge remote-tracking branch 'upstream/develop' into MAGETWO-34625-ee-packages
Conflicts: composer.lock
2 parents bb92bbe + 809a8b6 commit 3fb9035

File tree

417 files changed

+13671
-4079
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

417 files changed

+13671
-4079
lines changed

CHANGELOG.md

Lines changed: 58 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,72 @@
1+
0.74.0-beta5
2+
=============
3+
* Various
4+
* Added the new methods/fields in the Catalog Product Data Object
5+
* Improved the Nginx configuration sample file for better web-server responsiveness and security
6+
* Implemented the new look & feel for Create New Order page
7+
* Removed the redundant DB constraints for cascade operations related to order management
8+
* Implemented the mechanism of asynchronous email notifications after creation of Orders, Invoices, Shipments and Credit Memos
9+
* Moved the join logic on application level in order to make DB separation possible in Reports component
10+
* Implemented the TTL and event approaches of cache invalidation, introduced the full and the partial Varnish Cache flush
11+
* Moved all Setup commands to Magento CLI
12+
* Exposed CMS API as Web API
13+
* Fixed bugs:
14+
* Unexpected response for API "/V1/customers/password" service
15+
* Can’t include a third-party link to frontend section via layout
16+
* Specified details for Grouped product are lost after adding to wishlist
17+
* Impossible to configure products in customer wishlist in Admin Panel
18+
* Adding the product from wishlist to cart if more than one store view exists
19+
* Specified product field custom options is not displayed in wishlist in Admin Panel
20+
* Checkout doesn't work with JS bundling enabled in production mode
21+
* Issue with price excluding tax when selecting downloadable links
22+
* Undefined index warning in case the frontend cache information is missing in configuration file
23+
* "New Order" email is not sent to customer after placing order via API service
24+
* 503 error when placing order with multiple shipping addresses if mail transport doesn't exist
25+
* Broken words for fields with long labels all over the Admin Panel
26+
* Issue with saving 'is_virtual' flag in quote
27+
* "Void" button available after "Deny Payment" operation
28+
* Uninstall logic did not clean cache properly
29+
* Obsolete code tests did not cover Tests folders
30+
* Random fail of Magento\Log\Test\Unit\Model\VisitorTest
31+
* GitHub issues:
32+
* [#1149] (https://github.com/magento/magento2/issues/1149) -- Checkout Grand Total amount miscalculation
33+
* [#1165] (https://github.com/magento/magento2/pull/1165) -- Fix typos
34+
* [#1182] (https://github.com/magento/magento2/pull/1182) -- Update system.xml for 'fix' sortOrder in adminhtml
35+
* [#1186] (https://github.com/magento/magento2/pull/1186) -- SalesSequence: Fixed composer installer dependency
36+
137
0.74.0-beta4
238
=============
339
* Various
4-
* Implemented the getDefaultResult method, to be able to catch exceptions in FrontController and redirect user to the correct page
5-
* The getDefaultResult method is invoked to return default result of action execution within controllers. It can be used to generate the ‘execute’ method result in action controllers
6-
* Eliminated the unused exceptions. Exceptions that weren't linked to any logic were also eliminated and replaced with LocalizedException or its child classes
7-
* Refactored all controllers where possible: the default exception handling logic moved to FrontController. Controllers that cannot be refactored do not conflict with the new logic
40+
* Implemented the getDefaultResult method, to be able to catch exceptions in FrontController and redirect user to the correct page
41+
* The getDefaultResult method is invoked to return default result of action execution within controllers. It can be used to generate the ‘execute’ method result in action controllers
42+
* Eliminated the unused exceptions. Exceptions that weren't linked to any logic were also eliminated and replaced with LocalizedException or its child classes
43+
* Refactored all controllers where possible: the default exception handling logic moved to FrontController. Controllers that cannot be refactored do not conflict with the new logic
844
* Framework:
9-
* Created Magento Console to perform CLI actions
10-
* Introduced a new SalesSequence module that is responsible for documents numeration management across the Order Management System
11-
* Implemented the mechanism of asynchronous indexing of sales entities grids
45+
* Created Magento Console to perform CLI actions
46+
* Introduced a new SalesSequence module that is responsible for documents numeration management across the Order Management System
47+
* Implemented the mechanism of asynchronous indexing of sales entities grids
1248
* Setup
13-
* Added the ConfigOption and ConfigOptionsList classes to be used by modules to manage deployment configuration
14-
* Moved all existing segments logic to new classes
15-
* Added the config:set command, which enables deployment configuration management
16-
* Removed the old 'install-configuration' tool
49+
* Added the ConfigOption and ConfigOptionsList classes to be used by modules to manage deployment configuration
50+
* Moved all existing segments logic to new classes
51+
* Added the config:set command, which enables deployment configuration management
52+
* Removed the old 'install-configuration' tool
1753
* Functional tests:
18-
* Fixed functional test for order placement from backend
19-
* Replaced the end-to-end test for a product with MAP with an injectable test
54+
* Fixed functional test for order placement from backend
55+
* Replaced the end-to-end test for a product with MAP with an injectable test
2056
* Design
21-
* Updated the Blank and Luma themes to enable theme (not only library) variables overriding in the _theme.less file of any inherited theme. Included LESS code standards to the UI Library documentation
57+
* Updated the Blank and Luma themes to enable theme (not only library) variables overriding in the _theme.less file of any inherited theme. Included LESS code standards to the UI Library documentation
2258
* Fixed bugs:
23-
* Fixed an issue where composite products could not be added to the order from the Recently Viewed Products section
24-
* Fixed an issue where not all .js files were added to a bundle
25-
* Fixed an issue where it was possible to save an incorrect IP value in the Developer Client Restriction field
26-
* Fixed an issue where a raw DB error was thrown when trying to enter a custom variable with duplicated variable code
59+
* Fixed an issue where composite products could not be added to the order from the Recently Viewed Products section
60+
* Fixed an issue where not all .js files were added to a bundle
61+
* Fixed an issue where it was possible to save an incorrect IP value in the Developer Client Restriction field
62+
* Fixed an issue where a raw DB error was thrown when trying to enter a custom variable with duplicated variable code
2763

2864
0.74.0-beta3
2965
=============
3066
* API
31-
* The orders were extended with the gift messages
32-
* The page and block data and repository interfaces
33-
* Updated the public API list
67+
* The orders were extended with the gift messages
68+
* The page and block data and repository interfaces
69+
* Updated the public API list
3470
* Framework improvements
3571
* Improved the profile generator
3672
* Introduced the new environment for Jasmine tests
@@ -54,7 +90,7 @@
5490
* Fixed the Navigation Menu items on Admin Area
5591
* Various unit and integration tests bugs
5692
* GitHub issues and requests
57-
[#675] (https://github.com/magento/magento2/issues/675) -- Fix for Textarea element cols and rows #675
93+
* [#675] (https://github.com/magento/magento2/issues/675) -- Fix for Textarea element cols and rows #675
5894

5995
0.74.0-beta2
6096
=============

app/code/Magento/AdminNotification/composer.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,15 @@
33
"description": "N/A",
44
"require": {
55
"php": "~5.5.0|~5.6.0",
6-
"magento/module-store": "0.74.0-beta4",
7-
"magento/module-backend": "0.74.0-beta4",
8-
"magento/module-media-storage": "0.74.0-beta4",
9-
"magento/framework": "0.74.0-beta4",
6+
"magento/module-store": "0.74.0-beta5",
7+
"magento/module-backend": "0.74.0-beta5",
8+
"magento/module-media-storage": "0.74.0-beta5",
9+
"magento/framework": "0.74.0-beta5",
1010
"lib-libxml": "*",
1111
"magento/magento-composer-installer": "*"
1212
},
1313
"type": "magento2-module",
14-
"version": "0.74.0-beta4",
14+
"version": "0.74.0-beta5",
1515
"license": [
1616
"OSL-3.0",
1717
"AFL-3.0"

app/code/Magento/Authorization/composer.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@
33
"description": "Authorization module provides access to Magento ACL functionality.",
44
"require": {
55
"php": "~5.5.0|~5.6.0",
6-
"magento/module-backend": "0.74.0-beta4",
7-
"magento/framework": "0.74.0-beta4",
6+
"magento/module-backend": "0.74.0-beta5",
7+
"magento/framework": "0.74.0-beta5",
88
"magento/magento-composer-installer": "*"
99
},
1010
"type": "magento2-module",
11-
"version": "0.74.0-beta4",
11+
"version": "0.74.0-beta5",
1212
"license": [
1313
"OSL-3.0",
1414
"AFL-3.0"

app/code/Magento/Backend/composer.json

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -3,27 +3,27 @@
33
"description": "N/A",
44
"require": {
55
"php": "~5.5.0|~5.6.0",
6-
"magento/module-store": "0.74.0-beta4",
7-
"magento/module-directory": "0.74.0-beta4",
8-
"magento/module-developer": "0.74.0-beta4",
9-
"magento/module-eav": "0.74.0-beta4",
10-
"magento/module-cron": "0.74.0-beta4",
11-
"magento/module-theme": "0.74.0-beta4",
12-
"magento/module-reports": "0.74.0-beta4",
13-
"magento/module-sales": "0.74.0-beta4",
14-
"magento/module-quote": "0.74.0-beta4",
15-
"magento/module-catalog": "0.74.0-beta4",
16-
"magento/module-user": "0.74.0-beta4",
17-
"magento/module-backup": "0.74.0-beta4",
18-
"magento/module-customer": "0.74.0-beta4",
19-
"magento/module-translation": "0.74.0-beta4",
20-
"magento/module-require-js": "0.74.0-beta4",
21-
"magento/module-config": "0.74.0-beta4",
22-
"magento/framework": "0.74.0-beta4",
6+
"magento/module-store": "0.74.0-beta5",
7+
"magento/module-directory": "0.74.0-beta5",
8+
"magento/module-developer": "0.74.0-beta5",
9+
"magento/module-eav": "0.74.0-beta5",
10+
"magento/module-cron": "0.74.0-beta5",
11+
"magento/module-theme": "0.74.0-beta5",
12+
"magento/module-reports": "0.74.0-beta5",
13+
"magento/module-sales": "0.74.0-beta5",
14+
"magento/module-quote": "0.74.0-beta5",
15+
"magento/module-catalog": "0.74.0-beta5",
16+
"magento/module-user": "0.74.0-beta5",
17+
"magento/module-backup": "0.74.0-beta5",
18+
"magento/module-customer": "0.74.0-beta5",
19+
"magento/module-translation": "0.74.0-beta5",
20+
"magento/module-require-js": "0.74.0-beta5",
21+
"magento/module-config": "0.74.0-beta5",
22+
"magento/framework": "0.74.0-beta5",
2323
"magento/magento-composer-installer": "*"
2424
},
2525
"type": "magento2-module",
26-
"version": "0.74.0-beta4",
26+
"version": "0.74.0-beta5",
2727
"license": [
2828
"OSL-3.0",
2929
"AFL-3.0"

app/code/Magento/Backup/composer.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,14 @@
33
"description": "N/A",
44
"require": {
55
"php": "~5.5.0|~5.6.0",
6-
"magento/module-store": "0.74.0-beta4",
7-
"magento/module-backend": "0.74.0-beta4",
8-
"magento/module-cron": "0.74.0-beta4",
9-
"magento/framework": "0.74.0-beta4",
6+
"magento/module-store": "0.74.0-beta5",
7+
"magento/module-backend": "0.74.0-beta5",
8+
"magento/module-cron": "0.74.0-beta5",
9+
"magento/framework": "0.74.0-beta5",
1010
"magento/magento-composer-installer": "*"
1111
},
1212
"type": "magento2-module",
13-
"version": "0.74.0-beta4",
13+
"version": "0.74.0-beta5",
1414
"license": [
1515
"OSL-3.0",
1616
"AFL-3.0"

app/code/Magento/Bundle/composer.json

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -3,28 +3,28 @@
33
"description": "N/A",
44
"require": {
55
"php": "~5.5.0|~5.6.0",
6-
"magento/module-store": "0.74.0-beta4",
7-
"magento/module-catalog": "0.74.0-beta4",
8-
"magento/module-tax": "0.74.0-beta4",
9-
"magento/module-backend": "0.74.0-beta4",
10-
"magento/module-sales": "0.74.0-beta4",
11-
"magento/module-checkout": "0.74.0-beta4",
12-
"magento/module-catalog-inventory": "0.74.0-beta4",
13-
"magento/module-customer": "0.74.0-beta4",
14-
"magento/module-catalog-rule": "0.74.0-beta4",
15-
"magento/module-eav": "0.74.0-beta4",
16-
"magento/module-config": "0.74.0-beta4",
17-
"magento/module-gift-message": "0.74.0-beta4",
18-
"magento/framework": "0.74.0-beta4",
19-
"magento/module-quote": "0.74.0-beta4",
20-
"magento/module-media-storage": "0.74.0-beta4",
6+
"magento/module-store": "0.74.0-beta5",
7+
"magento/module-catalog": "0.74.0-beta5",
8+
"magento/module-tax": "0.74.0-beta5",
9+
"magento/module-backend": "0.74.0-beta5",
10+
"magento/module-sales": "0.74.0-beta5",
11+
"magento/module-checkout": "0.74.0-beta5",
12+
"magento/module-catalog-inventory": "0.74.0-beta5",
13+
"magento/module-customer": "0.74.0-beta5",
14+
"magento/module-catalog-rule": "0.74.0-beta5",
15+
"magento/module-eav": "0.74.0-beta5",
16+
"magento/module-config": "0.74.0-beta5",
17+
"magento/module-gift-message": "0.74.0-beta5",
18+
"magento/framework": "0.74.0-beta5",
19+
"magento/module-quote": "0.74.0-beta5",
20+
"magento/module-media-storage": "0.74.0-beta5",
2121
"magento/magento-composer-installer": "*"
2222
},
2323
"suggest": {
24-
"magento/module-webapi": "0.74.0-beta4"
24+
"magento/module-webapi": "0.74.0-beta5"
2525
},
2626
"type": "magento2-module",
27-
"version": "0.74.0-beta4",
27+
"version": "0.74.0-beta5",
2828
"license": [
2929
"OSL-3.0",
3030
"AFL-3.0"
Lines changed: 99 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,99 @@
1+
<?php
2+
/**
3+
* Copyright © 2015 Magento. All rights reserved.
4+
* See COPYING.txt for license details.
5+
*/
6+
namespace Magento\CacheInvalidate\Model;
7+
8+
/**
9+
* Class Observer
10+
*/
11+
class Observer
12+
{
13+
/**
14+
* Application config object
15+
*
16+
* @var \Magento\Framework\App\Config\ScopeConfigInterface
17+
*/
18+
protected $_config;
19+
20+
/**
21+
* @var \Magento\PageCache\Helper\Data
22+
*/
23+
protected $_helper;
24+
25+
/**
26+
* @var \Magento\Framework\HTTP\Adapter\Curl
27+
*/
28+
protected $_curlAdapter;
29+
30+
/**
31+
* Constructor
32+
*
33+
* @param \Magento\PageCache\Model\Config $config
34+
* @param \Magento\PageCache\Helper\Data $helper
35+
* @param \Magento\Framework\HTTP\Adapter\Curl $curlAdapter
36+
*/
37+
public function __construct(
38+
\Magento\PageCache\Model\Config $config,
39+
\Magento\PageCache\Helper\Data $helper,
40+
\Magento\Framework\HTTP\Adapter\Curl $curlAdapter
41+
) {
42+
$this->_config = $config;
43+
$this->_helper = $helper;
44+
$this->_curlAdapter = $curlAdapter;
45+
}
46+
47+
/**
48+
* If Varnish caching is enabled it collects array of tags
49+
* of incoming object and asks to clean cache.
50+
*
51+
* @param \Magento\Framework\Event\Observer $observer
52+
* @return void
53+
*/
54+
public function invalidateVarnish(\Magento\Framework\Event\Observer $observer)
55+
{
56+
if ($this->_config->getType() == \Magento\PageCache\Model\Config::VARNISH && $this->_config->isEnabled()) {
57+
$object = $observer->getEvent()->getObject();
58+
if ($object instanceof \Magento\Framework\Object\IdentityInterface) {
59+
$tags = [];
60+
$pattern = "((^|,)%s(,|$))";
61+
foreach ($object->getIdentities() as $tag) {
62+
$tags[] = sprintf($pattern, preg_replace("~_\\d+$~", '', $tag));
63+
$tags[] = sprintf($pattern, $tag);
64+
}
65+
$this->sendPurgeRequest(implode('|', array_unique($tags)));
66+
}
67+
}
68+
}
69+
70+
/**
71+
* Flash Varnish cache
72+
*
73+
* @param \Magento\Framework\Event\Observer $observer
74+
* @return void
75+
* @SuppressWarnings(PHPMD.UnusedFormalParameter)
76+
*/
77+
public function flushAllCache(\Magento\Framework\Event\Observer $observer)
78+
{
79+
if ($this->_config->getType() == \Magento\PageCache\Model\Config::VARNISH && $this->_config->isEnabled()) {
80+
$this->sendPurgeRequest('.*');
81+
}
82+
}
83+
84+
/**
85+
* Send curl purge request
86+
* to invalidate cache by tags pattern
87+
*
88+
* @param string $tagsPattern
89+
* @return void
90+
*/
91+
protected function sendPurgeRequest($tagsPattern)
92+
{
93+
$headers = ["X-Magento-Tags-Pattern: {$tagsPattern}"];
94+
$this->_curlAdapter->setOptions([CURLOPT_CUSTOMREQUEST => 'PURGE']);
95+
$this->_curlAdapter->write('', $this->_helper->getUrl('*'), '1.1', $headers);
96+
$this->_curlAdapter->read();
97+
$this->_curlAdapter->close();
98+
}
99+
}
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
The CacheInvalidate module is used to invalidate the Varnish cache if it is configured.
2+
It listens for events that request the cache to be flushed or cause the cache to be invalid, then sends Varnish a purge request using cURL.

0 commit comments

Comments
 (0)