{"id":338053,"date":"2022-09-07T09:01:14","date_gmt":"2022-09-07T09:01:14","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=338053"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=338053","title":{"rendered":"<span>PHP: \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u044b vs \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438: \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0438\u0440\u0443\u0435\u043c \u043c\u0435\u0442\u0430\u0434\u0430\u0442\u0443 Doctrine<\/span>"},"content":{"rendered":"<div><\/div>\n<div id=\"post-content-body\">\n<div>\n<div class=\"article-formatted-body article-formatted-body article-formatted-body_version-2\">\n<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<pre><code class=\"php\">&lt;?php  #[ORM\\Entity, ORM\\Table(name: 'item_price')] class ItemPrice {     #[ORM\\Id, ORM\\Column(type: 'integer'), ORM\\GeneratedValue]     private int $id;     #[         ORM\\ManyToOne(targetEntity: Item::class, inversedBy: 'prices'),         ORM\\JoinColumn(name: 'item_id', referencedColumnName: 'id')     ]     private Item $item;     #[ORM\\Column(type: 'string')]     private string $amount;     #[ORM\\Column(type: 'string')]     private string $currency; }<\/code><\/pre>\n<p>\u041e\u0434\u043d\u0438\u043c \u0438\u0437 \u043d\u043e\u0432\u043e\u0432\u0432\u0435\u0434\u0435\u043d\u0438\u0439 PHP 8.0 \u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f <a href=\"https:\/\/www.php.net\/releases\/8.0\/en.php#attributes\" rel=\"noopener noreferrer nofollow\"><u>\u0430\u0442\u0440\u0438\u0431\u0443\u0442\u044b<\/u><\/a>. \u0410\u0442\u0440\u0438\u0431\u0443\u0442\u044b \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442 \u043c\u0435\u0442\u0430\u0434\u0430\u0442\u0443 \u0434\u043b\u044f \u043a\u043b\u0430\u0441\u0441\u043e\u0432, \u043f\u043e\u043b\u0435\u0439, \u0444\u0443\u043d\u043a\u0446\u0438\u0439; \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u0430 \u0447\u0435\u0440\u0435\u0437 Reflection API. \u041a\u0430\u0437\u0430\u043b\u043e\u0441\u044c \u0431\u044b, \u0442\u043e \u0436\u0435 \u0441\u0430\u043c\u043e\u0435, \u0447\u0442\u043e \u0438 \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438, \u0442\u043e\u0433\u0434\u0430 \u0437\u0430\u0447\u0435\u043c \u043e\u0431\u0440\u0430\u0449\u0430\u0442\u044c \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 \u043d\u0430 \u044d\u0442\u0443 \u0444\u0438\u0447\u0443?<\/p>\n<p>\u0412\u0441\u0435 \u043e\u0442\u043b\u0438\u0447\u0438\u0435 \u0432 \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0441\u0442\u0438. \u0410\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438 \u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f \u043f\u0440\u043e\u0441\u0442\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u043e\u0439 <a href=\"https:\/\/github.com\/php-fig\/fig-standards\/blob\/master\/proposed\/phpdoc.md\" rel=\"noopener noreferrer nofollow\"><u>phpDoc<\/u><\/a>, \u0430, \u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e, \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0443 \u043d\u0443\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043a\u0430\u043a\u043e\u0439-\u0442\u043e \u043c\u0435\u0445\u0430\u043d\u0438\u0437\u043c \u0434\u043b\u044f \u0438\u0445 \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u043a\u0438, \u0447\u0442\u043e\u0431\u044b \u0438\u0437\u0432\u043b\u0435\u0447\u044c \u043d\u0443\u0436\u043d\u0443\u044e \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e.<\/p>\n<p>\u041f\u043e\u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u044c \u043f\u0430\u0440\u0441\u0438\u043d\u0433\u0430 \u0432 \u0440\u0430\u043d\u0442\u0430\u0439\u043c\u0435. \u041d\u0430\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u044d\u0442\u043e \u043f\u043b\u043e\u0445\u043e? \u0420\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c, \u043a\u0430\u043a \u044d\u0442\u043e \u0432\u043b\u0438\u044f\u0435\u0442 \u043d\u0430 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u043d\u0430 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 Doctrine.<\/p>\n<hr\/>\n<p><a href=\"https:\/\/www.doctrine-project.org\/\" rel=\"noopener noreferrer nofollow\"><u>Doctrine<\/u><\/a>, \u043a\u0430\u043a \u043b\u044e\u0431\u0430\u044f ORM, \u0448\u0438\u0440\u043e\u043a\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 \u043c\u0435\u0442\u0430\u0434\u0430\u0442\u0443 \u0434\u043b\u044f \u0441\u0432\u043e\u0435\u0439 \u0440\u0430\u0431\u043e\u0442\u044b. \u0412 \u0447\u0430\u0441\u0442\u043d\u043e\u0441\u0442\u0438 &#8212; \u043c\u0430\u043f\u043f\u0438\u043d\u0433\u0438 \u0431\u0438\u0437\u043d\u0435\u0441-\u0441\u0443\u0449\u043d\u043e\u0441\u0442\u0435\u0439 \u043d\u0430 \u0442\u0430\u0431\u043b\u0438\u0446\u044b \u0432 \u0411\u0414. \u0415\u0441\u0442\u044c \u0440\u0430\u0437\u043d\u044b\u0435 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u0441\u043f\u043e\u0441\u043e\u0431\u0430 \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u043c\u0435\u0442\u0430\u0434\u0430\u0442\u044b:<\/p>\n<ul>\n<li>\n<p>\u0414\u0440\u0430\u0439\u0432\u0435\u0440 XML<\/p>\n<\/li>\n<li>\n<p>\u0414\u0440\u0430\u0439\u0432\u0435\u0440 YAML<\/p>\n<\/li>\n<li>\n<p>\u0421\u0442\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0439 PHP \u0434\u0440\u0430\u0439\u0432\u0435\u0440<\/p>\n<\/li>\n<li>\n<p>PHP \u0434\u0440\u0430\u0439\u0432\u0435\u0440<\/p>\n<\/li>\n<li>\n<p>\u0414\u0440\u0430\u0439\u0432\u0435\u0440 \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0439<\/p>\n<\/li>\n<li>\n<p>\u0414\u0440\u0430\u0439\u0432\u0435\u0440 \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u043e\u0432<\/p>\n<\/li>\n<\/ul>\n<p>\u0412 \u0442\u0435\u0441\u0442\u0430\u0445 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438 \u0438 \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u044b. \u0414\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043d\u0430 \u0441\u0442\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u0438 \u043e\u0431\u044b\u0447\u043d\u044b\u0439 PHP \u0434\u0440\u0430\u0439\u0432\u0435\u0440, \u0447\u0442\u043e\u0431\u044b \u0441\u0440\u0430\u0432\u043d\u0438\u0442\u044c, \u043d\u0430\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0438\u0435 \u0441\u043f\u043e\u0441\u043e\u0431\u044b \u0443\u0441\u0442\u0443\u043f\u0430\u044e\u0442 \u0440\u0443\u0447\u043d\u043e\u0439 \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u043c\u0435\u0442\u0430\u0434\u0430\u0442\u044b. \u041d\u0435 \u0437\u0430\u0431\u0443\u0434\u0435\u043c \u0432\u0437\u0433\u043b\u044f\u043d\u0443\u0442\u044c \u043d\u0430 \u0434\u0440\u0430\u0439\u0432\u0435\u0440\u0430 \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0439 \u0441 \u043a\u044d\u0448\u043e\u043c \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0435 APCu \u0438 Redis \u0441 \u0446\u0435\u043b\u044c\u044e \u043f\u043e\u043d\u044f\u0442\u044c, \u0440\u0435\u0448\u0430\u044e\u0442 \u043b\u0438 \u043e\u043d\u0438 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u0443\u044e \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0443 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0438.<\/p>\n<details class=\"spoiler\">\n<summary>\u041f\u0440\u0438\u043c\u0435\u0440 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0434\u0440\u0430\u0439\u0432\u0435\u0440\u0430 \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0439<\/summary>\n<div class=\"spoiler__content\">\n<pre><code class=\"php\">&lt;?php  \/**  * @ORM\\Entity  * @ORM\\Table(name=\"item_price\")  *\/ class ItemPrice {     \/**      * @ORM\\Id      * @ORM\\Column(type=\"integer\")      * @ORM\\GeneratedValue      *\/     private int $id;     \/**      * @ORM\\ManyToOne(targetEntity=\"Item\", inversedBy=\"prices\")      * @ORM\\JoinColumn(name=\"item_id\", referencedColumnName=\"id\")      *\/     private Item $item;     \/**      * @ORM\\Column(type=\"string\")      *\/     private string $amount;     \/**      * @ORM\\Column(type=\"string\")      *\/     private string $currency; }<\/code><\/pre>\n<\/p>\n<\/div>\n<\/details>\n<details class=\"spoiler\">\n<summary>\u041f\u0440\u0438\u043c\u0435\u0440 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0441\u0442\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e PHP \u0434\u0440\u0430\u0439\u0432\u0435\u0440\u0430<\/summary>\n<div class=\"spoiler__content\">\n<pre><code class=\"php\">&lt;?php  class ItemPrice {     public static function loadMetadata(ClassMetadata $metadata): void     {         $metadata->setPrimaryTable([             'table' => 'item_price',         ]);         $metadata->setIdGeneratorType(ClassMetadataInfo::GENERATOR_TYPE_AUTO);          $metadata->mapField([             'fieldName' => 'id',             'type' => 'integer',             'id' => true,         ]);         $metadata->mapManyToOne([             'fieldName' => 'item',             'joinColumns' => [                 [                     'name' => 'item_id',                     'referencedColumnName' => 'id',                 ],             ],             'inversedBy' => 'prices',             'targetEntity' => Item::class,         ]);         $metadata->mapField([             'fieldName' => 'amount',             'type' => 'string',         ]);         $metadata->mapField([             'fieldName' => 'currency',             'type' => 'string',         ]);     }      private int $id;     private Item $item;     private string $amount;     private string $currency; }<\/code><\/pre>\n<\/p>\n<\/div>\n<\/details>\n<p>\u0412 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0442\u0435\u0441\u0442\u0430 \u044f 10 \u043c\u0438\u043d\u0443\u0442 1 \u0430\u043a\u0442\u0438\u0432\u043d\u044b\u043c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u043b \u0437\u0430\u043f\u0440\u043e\u0441\u044b \u043d\u0430 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u043c\u0435\u0442\u0430\u0434\u0430\u0442\u044b \u0432\u0441\u0435\u0445 \u043a\u043b\u0430\u0441\u0441\u043e\u0432. \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b\u0430\u0441\u044c \u0441\u0432\u044f\u0437\u043a\u0430 Nginx + PHP-fpm \u0441 \u0432\u043a\u043b\u044e\u0447\u0435\u043d\u043d\u044b\u043c opcache. \u0418\u0441\u0445\u043e\u0434\u043d\u0438\u043a\u0438 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b <a href=\"https:\/\/github.com\/Aspirin4k\/doctrine-metadata-driver-benchmark\" rel=\"noopener noreferrer nofollow\"><u>\u0437\u0434\u0435\u0441\u044c<\/u><\/a>.<\/p>\n<div>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\"><strong>\u0414\u0440\u0430\u0439\u0432\u0435\u0440<\/strong><\/p>\n<\/td>\n<td data-colwidth=\"140\" width=\"140\">\n<p align=\"left\"><strong>\u0412\u0441\u0435\u0433\u043e \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>\u041c\u0435\u0434\u0438\u0430\u043d\u0430<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>\u041c\u0438\u043d\u0438\u043c\u0443\u043c<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>95-\u043f\u0435\u0440\u0446\u0435\u043d\u0442\u0438\u043b\u044c<\/strong><\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\"><a href=\"https:\/\/github.com\/Aspirin4k\/doctrine-metadata-driver-benchmark\/blob\/master\/src\/Annotation\/Entity\/Item.php\" rel=\"noopener noreferrer nofollow\"><strong><u>AnnotationDriver<\/u><\/strong><\/a><\/p>\n<\/td>\n<td data-colwidth=\"140\" width=\"140\">\n<p align=\"left\"><strong>35044<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>16.81ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>13.8ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>19.16ms<\/strong><\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\"><a href=\"https:\/\/github.com\/Aspirin4k\/doctrine-metadata-driver-benchmark\/blob\/master\/src\/Attribute\/Entity\/Item.php\" rel=\"noopener noreferrer nofollow\"><strong><u>AttributeDriver<\/u><\/strong><\/a><\/p>\n<\/td>\n<td data-colwidth=\"140\" width=\"140\">\n<p align=\"left\"><strong>106016<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>5.5ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>4.02ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>6.64ms<\/strong><\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\"><a href=\"https:\/\/github.com\/Aspirin4k\/doctrine-metadata-driver-benchmark\/blob\/master\/src\/Static\/Entity\/Item.php\" rel=\"noopener noreferrer nofollow\"><strong><u>StaticPHPDriver<\/u><\/strong><\/a><\/p>\n<\/td>\n<td data-colwidth=\"140\" width=\"140\">\n<p align=\"left\"><strong>114089<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>5.08ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>3.63ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>6.23ms<\/strong><\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\"><a href=\"https:\/\/github.com\/Aspirin4k\/doctrine-metadata-driver-benchmark\/blob\/master\/src\/Include\/Metadata\/App.Include.Entity.Item.php\" rel=\"noopener noreferrer nofollow\"><strong><u>PHPDriver<\/u><\/strong><\/a><\/p>\n<\/td>\n<td data-colwidth=\"140\" width=\"140\">\n<p align=\"left\"><strong>98042<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>5.48ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>3.76ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>7.47ms<\/strong><\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\"><strong>Redis Cache<\/strong><\/p>\n<\/td>\n<td data-colwidth=\"140\" width=\"140\">\n<p align=\"left\"><strong>36057<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>16.2ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>11.67ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>19.94ms<\/strong><\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\"><strong>APCu Cache<\/strong><\/p>\n<\/td>\n<td data-colwidth=\"140\" width=\"140\">\n<p align=\"left\"><strong>38943<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>15.06ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>10.83ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>18.51ms<\/strong><\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>\u0410\u0442\u0440\u0438\u0431\u0443\u0442\u044b \u043f\u043e\u043a\u0430\u0437\u0430\u043b\u0438 \u043d\u0435\u043f\u043b\u043e\u0445\u0443\u044e \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u043d\u0430 \u0443\u0440\u043e\u0432\u043d\u0435 \u0434\u0440\u0430\u0439\u0432\u0435\u0440\u043e\u0432, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0449\u0438\u0445 PHP-\u043a\u043e\u0434. \u0420\u0430\u0437\u043d\u0438\u0446\u0443 \u043c\u0435\u0436\u0434\u0443 AttributeDriver, StaticPHPDriver \u0438 PHPDriver, \u0434\u0443\u043c\u0430\u044e, \u043c\u043e\u0436\u043d\u043e \u0441\u0447\u0438\u0442\u0430\u0442\u044c \u043f\u043e\u0433\u0440\u0435\u0448\u043d\u043e\u0441\u0442\u044c\u044e. \u0413\u043b\u0430\u0432\u043d\u043e\u0435, \u0447\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u0443\u0432\u0438\u0434\u0435\u0442\u044c \u043f\u043e \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430\u043c \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f &#8212; <strong>\u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438 \u0432 3 \u0440\u0430\u0437\u0430 \u043c\u0435\u0434\u043b\u0435\u043d\u043d\u0435\u0435!<\/strong> \u0418\u043d\u0442\u0435\u0440\u0435\u0441\u0435\u043d \u0442\u0430\u043a \u0436\u0435 \u0442\u043e\u0442 \u0444\u0430\u043a\u0442, \u0447\u0442\u043e \u043a\u044d\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u043d\u0435 \u0432\u0441\u0435\u0433\u0434\u0430 \u043c\u043e\u0436\u0435\u0442 \u043f\u043e\u043c\u043e\u0447\u044c \u0443\u0441\u043a\u043e\u0440\u0438\u0442\u044c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 &#8212; \u0432 Doctrine \u043c\u0435\u0442\u0430\u0434\u0430\u0442\u0430 \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 \u043a\u044d\u0448\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e\u0439 \u0437\u0430\u043f\u0438\u0441\u044c\u044e. \u042d\u0442\u043e \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442 \u043a \u0442\u043e\u043c\u0443, \u0447\u0442\u043e \u0435\u0435 \u0432\u044b\u0433\u0440\u0443\u0437\u043a\u0430 \u0438 \u0434\u0435\u0441\u0435\u0440\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 \u0432 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0438 \u0432\u044b\u0445\u043e\u0434\u0438\u0442 \u043d\u0435\u043d\u0430\u043c\u043d\u043e\u0433\u043e \u0431\u044b\u0441\u0442\u0440\u0435\u0435.<\/p>\n<hr\/>\n<p>\u0415\u0441\u043b\u0438 \u0432\u044b \u0438\u0449\u0438\u0442\u0435 \u0441\u043f\u043e\u0441\u043e\u0431 \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0432\u0430\u0448\u0435 legacy \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435, \u0438 \u0432\u0441\u0435 \u0437\u0430\u043f\u0440\u043e\u0441\u044b \u043a \u0411\u0414 \u0443\u0436\u0435 \u0434\u0430\u0432\u043d\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u0435\u043d\u044b, \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u043e\u0432 \u0438 \u0441\u0443\u0449\u043d\u043e\u0441\u0442\u0435\u0439 ORM &#8212; \u0432\u0430\u0448\u0430 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0430\u044f \u0446\u0435\u043b\u044c.<\/p>\n<p>\u0422\u0443\u0442 \u043c\u043e\u0436\u043d\u043e \u0441\u0442\u043e\u043b\u043a\u043d\u0443\u0442\u044c\u0441\u044f \u0441 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u043e\u0439: legacy &#8212; \u044d\u0442\u043e \u043a\u043e\u0433\u0434\u0430 \u043a\u0443\u0447\u0430 \u043a\u043e\u0434\u0430, \u0430 \u0442\u0435\u043f\u0435\u0440\u044c \u0435\u0433\u043e \u043d\u0443\u0436\u043d\u043e \u0432\u0435\u0441\u044c \u043f\u0435\u0440\u0435\u043f\u0438\u0441\u044b\u0432\u0430\u0442\u044c? \u042d\u0442\u0443 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0443 \u043c\u043e\u0436\u043d\u043e \u0440\u0435\u0448\u0438\u0442\u044c \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0435\u0449\u0435 \u043e\u0434\u043d\u043e\u0433\u043e \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432\u044b \u043c\u043e\u0433\u043b\u0438 \u0432\u0438\u0434\u0435\u0442\u044c \u0432 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430\u0445 \u0431\u0435\u043d\u0447\u043c\u0430\u0440\u043a\u0430 &#8212; \u043a\u043e\u0434\u043e\u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0438:<\/p>\n<div>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<td data-colwidth=\"147\" width=\"147\">\n<p align=\"left\"><strong>\u0414\u0440\u0430\u0439\u0432\u0435\u0440<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>\u0412\u0441\u0435\u0433\u043e \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432<\/strong><\/p>\n<\/td>\n<td data-colwidth=\"131\" width=\"131\">\n<p align=\"left\"><strong>\u041c\u0435\u0434\u0438\u0430\u043d\u0430<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>\u041c\u0438\u043d\u0438\u043c\u0443\u043c<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>95-\u043f\u0435\u0440\u0446\u0435\u043d\u0442\u0438\u043b\u044c<\/strong><\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"147\" width=\"147\">\n<p align=\"left\"><a href=\"https:\/\/github.com\/Aspirin4k\/doctrine-metadata-driver-benchmark\/blob\/master\/src\/Generator\/cli-generate.php\" rel=\"noopener noreferrer nofollow\"><strong><u>Generated Static<\/u><\/strong><\/a><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>102124<\/strong><\/p>\n<\/td>\n<td data-colwidth=\"131\" width=\"131\">\n<p align=\"left\"><strong>5.59ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>3.7ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>7.38ms<\/strong><\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>\u042d\u0442\u043e\u0442 \u0432\u0430\u0440\u0438\u0430\u043d\u0442 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0430\u0442\u044c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438, \u043d\u0435 \u043f\u0435\u0440\u0435\u043f\u0438\u0441\u044b\u0432\u0430\u044f \u0432\u0435\u0441\u044c \u043f\u0440\u043e\u0435\u043a\u0442, \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u043f\u043e\u043b\u0443\u0447\u0430\u044f \u0431\u043e\u043d\u0443\u0441\u044b \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0438 &#8212; \u0432\u0435\u0434\u044c \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438 \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u044e\u0442\u0441\u044f \u0432 \u043a\u043e\u0434, \u0430 \u043a\u043e\u0434 \u043f\u043e\u043f\u0430\u0434\u0430\u0435\u0442 \u0432 opcache!<\/p>\n<hr\/>\n<p>\u0420\u0435\u0437\u044e\u043c\u0438\u0440\u0443\u044f:<\/p>\n<ul>\n<li>\n<p>\u0421\u0442\u043e\u0438\u0442 \u043b\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0432 \u043d\u043e\u0432\u044b\u0445 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u0445 \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u044b \u0432\u043c\u0435\u0441\u0442\u043e \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0439 \u0432\u0435\u0437\u0434\u0435, \u0433\u0434\u0435 \u044d\u0442\u043e \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u044b\u043c? \u041e\u0434\u043d\u043e\u0437\u043d\u0430\u0447\u043d\u043e \u0434\u0430.<\/p>\n<\/li>\n<li>\n<p>\u041d\u0443\u0436\u043d\u043e \u043b\u0438 \u043f\u0435\u0440\u0435\u043f\u0438\u0441\u044b\u0432\u0430\u0442\u044c \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438 \u0432 legacy \u043f\u0440\u043e\u0435\u043a\u0442\u0435 \u043d\u0430 \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u044b? \u0417\u0430\u0432\u0438\u0441\u0438\u0442 \u043e\u0442 \u043d\u0435\u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u044b\u0445 \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u0439, \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e \u0432\u0430\u043c \u043f\u043e\u043c\u043e\u0436\u0435\u0442 \u043a\u043e\u0434\u043e\u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u044f. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, <a href=\"https:\/\/github.com\/Aspirin4k\/doctrine-annotation-static-reader\" rel=\"noopener noreferrer nofollow\"><u>\u043f\u043e\u0434\u043e\u0431\u043d\u044b\u0439 \u0441\u043a\u0440\u0438\u043f\u0442<\/u><\/a> \u043c\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c \u0443 \u0441\u0435\u0431\u044f \u043d\u0430 \u043f\u0440\u043e\u0434\u0430\u043a\u0448\u0435\u043d\u0435. (\u0415\u0449\u0435 \u0440\u0430\u0431\u043e\u0447\u0438\u043c \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u043e\u043c \u043c\u043e\u0436\u0435\u0442 \u043e\u043a\u0430\u0437\u0430\u0442\u044c\u0441\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u0440\u0435\u0444\u0430\u043a\u0442\u043e\u0440\u0438\u043d\u0433 \u0441\u0440\u0435\u0434\u0441\u0442\u0432\u0430\u043c\u0438 <a href=\"https:\/\/getrector.org\/blog\/how-to-upgrade-annotations-to-attributes\" rel=\"noopener noreferrer nofollow\">rector<\/a>)<\/p>\n<\/li>\n<\/ul>\n<p>\u041d\u0430\u0434\u0435\u044e\u0441\u044c, \u0441\u0442\u0430\u0442\u044c\u044f \u0431\u044b\u043b\u0430 \u043f\u043e\u043b\u0435\u0437\u043d\u0430 \u0438 \u043f\u043e\u0437\u043d\u0430\u043a\u043e\u043c\u0438\u043b\u0430 \u0432\u0430\u0441 \u0441 \u0435\u0449\u0451 \u043e\u0434\u043d\u0438\u043c \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u043e\u043c \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u043e\u0432 \u043f\u0435\u0440\u0435\u0434 \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u044f\u043c\u0438.<\/p>\n<\/p>\n<\/div>\n<\/div>\n<\/div>\n<div class=\"v-portal\" style=\"display:none;\"><\/div>\n<\/div>\n<p> <!----> <!----><br \/> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/post\/686796\/\"> https:\/\/habr.com\/ru\/post\/686796\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<div><\/div>\n<div id=\"post-content-body\">\n<div>\n<div class=\"article-formatted-body article-formatted-body article-formatted-body_version-2\">\n<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<pre><code class=\"php\">&lt;?php  #[ORM\\Entity, ORM\\Table(name: 'item_price')] class ItemPrice {     #[ORM\\Id, ORM\\Column(type: 'integer'), ORM\\GeneratedValue]     private int $id;     #[         ORM\\ManyToOne(targetEntity: Item::class, inversedBy: 'prices'),         ORM\\JoinColumn(name: 'item_id', referencedColumnName: 'id')     ]     private Item $item;     #[ORM\\Column(type: 'string')]     private string $amount;     #[ORM\\Column(type: 'string')]     private string $currency; }<\/code><\/pre>\n<p>\u041e\u0434\u043d\u0438\u043c \u0438\u0437 \u043d\u043e\u0432\u043e\u0432\u0432\u0435\u0434\u0435\u043d\u0438\u0439 PHP 8.0 \u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f <a href=\"https:\/\/www.php.net\/releases\/8.0\/en.php#attributes\" rel=\"noopener noreferrer nofollow\"><u>\u0430\u0442\u0440\u0438\u0431\u0443\u0442\u044b<\/u><\/a>. \u0410\u0442\u0440\u0438\u0431\u0443\u0442\u044b \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442 \u043c\u0435\u0442\u0430\u0434\u0430\u0442\u0443 \u0434\u043b\u044f \u043a\u043b\u0430\u0441\u0441\u043e\u0432, \u043f\u043e\u043b\u0435\u0439, \u0444\u0443\u043d\u043a\u0446\u0438\u0439; \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u0430 \u0447\u0435\u0440\u0435\u0437 Reflection API. \u041a\u0430\u0437\u0430\u043b\u043e\u0441\u044c \u0431\u044b, \u0442\u043e \u0436\u0435 \u0441\u0430\u043c\u043e\u0435, \u0447\u0442\u043e \u0438 \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438, \u0442\u043e\u0433\u0434\u0430 \u0437\u0430\u0447\u0435\u043c \u043e\u0431\u0440\u0430\u0449\u0430\u0442\u044c \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 \u043d\u0430 \u044d\u0442\u0443 \u0444\u0438\u0447\u0443?<\/p>\n<p>\u0412\u0441\u0435 \u043e\u0442\u043b\u0438\u0447\u0438\u0435 \u0432 \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0441\u0442\u0438. \u0410\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438 \u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f \u043f\u0440\u043e\u0441\u0442\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u043e\u0439 <a href=\"https:\/\/github.com\/php-fig\/fig-standards\/blob\/master\/proposed\/phpdoc.md\" rel=\"noopener noreferrer nofollow\"><u>phpDoc<\/u><\/a>, \u0430, \u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e, \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0443 \u043d\u0443\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043a\u0430\u043a\u043e\u0439-\u0442\u043e \u043c\u0435\u0445\u0430\u043d\u0438\u0437\u043c \u0434\u043b\u044f \u0438\u0445 \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u043a\u0438, \u0447\u0442\u043e\u0431\u044b \u0438\u0437\u0432\u043b\u0435\u0447\u044c \u043d\u0443\u0436\u043d\u0443\u044e \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e.<\/p>\n<p>\u041f\u043e\u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u044c \u043f\u0430\u0440\u0441\u0438\u043d\u0433\u0430 \u0432 \u0440\u0430\u043d\u0442\u0430\u0439\u043c\u0435. \u041d\u0430\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u044d\u0442\u043e \u043f\u043b\u043e\u0445\u043e? \u0420\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c, \u043a\u0430\u043a \u044d\u0442\u043e \u0432\u043b\u0438\u044f\u0435\u0442 \u043d\u0430 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u043d\u0430 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 Doctrine.<\/p>\n<hr\/>\n<p><a href=\"https:\/\/www.doctrine-project.org\/\" rel=\"noopener noreferrer nofollow\"><u>Doctrine<\/u><\/a>, \u043a\u0430\u043a \u043b\u044e\u0431\u0430\u044f ORM, \u0448\u0438\u0440\u043e\u043a\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 \u043c\u0435\u0442\u0430\u0434\u0430\u0442\u0443 \u0434\u043b\u044f \u0441\u0432\u043e\u0435\u0439 \u0440\u0430\u0431\u043e\u0442\u044b. \u0412 \u0447\u0430\u0441\u0442\u043d\u043e\u0441\u0442\u0438 &#8212; \u043c\u0430\u043f\u043f\u0438\u043d\u0433\u0438 \u0431\u0438\u0437\u043d\u0435\u0441-\u0441\u0443\u0449\u043d\u043e\u0441\u0442\u0435\u0439 \u043d\u0430 \u0442\u0430\u0431\u043b\u0438\u0446\u044b \u0432 \u0411\u0414. \u0415\u0441\u0442\u044c \u0440\u0430\u0437\u043d\u044b\u0435 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u0441\u043f\u043e\u0441\u043e\u0431\u0430 \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u043c\u0435\u0442\u0430\u0434\u0430\u0442\u044b:<\/p>\n<ul>\n<li>\n<p>\u0414\u0440\u0430\u0439\u0432\u0435\u0440 XML<\/p>\n<\/li>\n<li>\n<p>\u0414\u0440\u0430\u0439\u0432\u0435\u0440 YAML<\/p>\n<\/li>\n<li>\n<p>\u0421\u0442\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0439 PHP \u0434\u0440\u0430\u0439\u0432\u0435\u0440<\/p>\n<\/li>\n<li>\n<p>PHP \u0434\u0440\u0430\u0439\u0432\u0435\u0440<\/p>\n<\/li>\n<li>\n<p>\u0414\u0440\u0430\u0439\u0432\u0435\u0440 \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0439<\/p>\n<\/li>\n<li>\n<p>\u0414\u0440\u0430\u0439\u0432\u0435\u0440 \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u043e\u0432<\/p>\n<\/li>\n<\/ul>\n<p>\u0412 \u0442\u0435\u0441\u0442\u0430\u0445 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438 \u0438 \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u044b. \u0414\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043d\u0430 \u0441\u0442\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u0438 \u043e\u0431\u044b\u0447\u043d\u044b\u0439 PHP \u0434\u0440\u0430\u0439\u0432\u0435\u0440, \u0447\u0442\u043e\u0431\u044b \u0441\u0440\u0430\u0432\u043d\u0438\u0442\u044c, \u043d\u0430\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0438\u0435 \u0441\u043f\u043e\u0441\u043e\u0431\u044b \u0443\u0441\u0442\u0443\u043f\u0430\u044e\u0442 \u0440\u0443\u0447\u043d\u043e\u0439 \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u043c\u0435\u0442\u0430\u0434\u0430\u0442\u044b. \u041d\u0435 \u0437\u0430\u0431\u0443\u0434\u0435\u043c \u0432\u0437\u0433\u043b\u044f\u043d\u0443\u0442\u044c \u043d\u0430 \u0434\u0440\u0430\u0439\u0432\u0435\u0440\u0430 \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0439 \u0441 \u043a\u044d\u0448\u043e\u043c \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0435 APCu \u0438 Redis \u0441 \u0446\u0435\u043b\u044c\u044e \u043f\u043e\u043d\u044f\u0442\u044c, \u0440\u0435\u0448\u0430\u044e\u0442 \u043b\u0438 \u043e\u043d\u0438 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u0443\u044e \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0443 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0438.<\/p>\n<details class=\"spoiler\">\n<summary>\u041f\u0440\u0438\u043c\u0435\u0440 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0434\u0440\u0430\u0439\u0432\u0435\u0440\u0430 \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0439<\/summary>\n<div class=\"spoiler__content\">\n<pre><code class=\"php\">&lt;?php  \/**  * @ORM\\Entity  * @ORM\\Table(name=\"item_price\")  *\/ class ItemPrice {     \/**      * @ORM\\Id      * @ORM\\Column(type=\"integer\")      * @ORM\\GeneratedValue      *\/     private int $id;     \/**      * @ORM\\ManyToOne(targetEntity=\"Item\", inversedBy=\"prices\")      * @ORM\\JoinColumn(name=\"item_id\", referencedColumnName=\"id\")      *\/     private Item $item;     \/**      * @ORM\\Column(type=\"string\")      *\/     private string $amount;     \/**      * @ORM\\Column(type=\"string\")      *\/     private string $currency; }<\/code><\/pre>\n<\/p>\n<\/div>\n<\/details>\n<details class=\"spoiler\">\n<summary>\u041f\u0440\u0438\u043c\u0435\u0440 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0441\u0442\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e PHP \u0434\u0440\u0430\u0439\u0432\u0435\u0440\u0430<\/summary>\n<div class=\"spoiler__content\">\n<pre><code class=\"php\">&lt;?php  class ItemPrice {     public static function loadMetadata(ClassMetadata $metadata): void     {         $metadata->setPrimaryTable([             'table' => 'item_price',         ]);         $metadata->setIdGeneratorType(ClassMetadataInfo::GENERATOR_TYPE_AUTO);          $metadata->mapField([             'fieldName' => 'id',             'type' => 'integer',             'id' => true,         ]);         $metadata->mapManyToOne([             'fieldName' => 'item',             'joinColumns' => [                 [                     'name' => 'item_id',                     'referencedColumnName' => 'id',                 ],             ],             'inversedBy' => 'prices',             'targetEntity' => Item::class,         ]);         $metadata->mapField([             'fieldName' => 'amount',             'type' => 'string',         ]);         $metadata->mapField([             'fieldName' => 'currency',             'type' => 'string',         ]);     }      private int $id;     private Item $item;     private string $amount;     private string $currency; }<\/code><\/pre>\n<\/p>\n<\/div>\n<\/details>\n<p>\u0412 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0442\u0435\u0441\u0442\u0430 \u044f 10 \u043c\u0438\u043d\u0443\u0442 1 \u0430\u043a\u0442\u0438\u0432\u043d\u044b\u043c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u043b \u0437\u0430\u043f\u0440\u043e\u0441\u044b \u043d\u0430 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u043c\u0435\u0442\u0430\u0434\u0430\u0442\u044b \u0432\u0441\u0435\u0445 \u043a\u043b\u0430\u0441\u0441\u043e\u0432. \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b\u0430\u0441\u044c \u0441\u0432\u044f\u0437\u043a\u0430 Nginx + PHP-fpm \u0441 \u0432\u043a\u043b\u044e\u0447\u0435\u043d\u043d\u044b\u043c opcache. \u0418\u0441\u0445\u043e\u0434\u043d\u0438\u043a\u0438 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b <a href=\"https:\/\/github.com\/Aspirin4k\/doctrine-metadata-driver-benchmark\" rel=\"noopener noreferrer nofollow\"><u>\u0437\u0434\u0435\u0441\u044c<\/u><\/a>.<\/p>\n<div>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\"><strong>\u0414\u0440\u0430\u0439\u0432\u0435\u0440<\/strong><\/p>\n<\/td>\n<td data-colwidth=\"140\" width=\"140\">\n<p align=\"left\"><strong>\u0412\u0441\u0435\u0433\u043e \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>\u041c\u0435\u0434\u0438\u0430\u043d\u0430<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>\u041c\u0438\u043d\u0438\u043c\u0443\u043c<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>95-\u043f\u0435\u0440\u0446\u0435\u043d\u0442\u0438\u043b\u044c<\/strong><\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\"><a href=\"https:\/\/github.com\/Aspirin4k\/doctrine-metadata-driver-benchmark\/blob\/master\/src\/Annotation\/Entity\/Item.php\" rel=\"noopener noreferrer nofollow\"><strong><u>AnnotationDriver<\/u><\/strong><\/a><\/p>\n<\/td>\n<td data-colwidth=\"140\" width=\"140\">\n<p align=\"left\"><strong>35044<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>16.81ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>13.8ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>19.16ms<\/strong><\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\"><a href=\"https:\/\/github.com\/Aspirin4k\/doctrine-metadata-driver-benchmark\/blob\/master\/src\/Attribute\/Entity\/Item.php\" rel=\"noopener noreferrer nofollow\"><strong><u>AttributeDriver<\/u><\/strong><\/a><\/p>\n<\/td>\n<td data-colwidth=\"140\" width=\"140\">\n<p align=\"left\"><strong>106016<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>5.5ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>4.02ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>6.64ms<\/strong><\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\"><a href=\"https:\/\/github.com\/Aspirin4k\/doctrine-metadata-driver-benchmark\/blob\/master\/src\/Static\/Entity\/Item.php\" rel=\"noopener noreferrer nofollow\"><strong><u>StaticPHPDriver<\/u><\/strong><\/a><\/p>\n<\/td>\n<td data-colwidth=\"140\" width=\"140\">\n<p align=\"left\"><strong>114089<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>5.08ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>3.63ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>6.23ms<\/strong><\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\"><a href=\"https:\/\/github.com\/Aspirin4k\/doctrine-metadata-driver-benchmark\/blob\/master\/src\/Include\/Metadata\/App.Include.Entity.Item.php\" rel=\"noopener noreferrer nofollow\"><strong><u>PHPDriver<\/u><\/strong><\/a><\/p>\n<\/td>\n<td data-colwidth=\"140\" width=\"140\">\n<p align=\"left\"><strong>98042<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>5.48ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>3.76ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>7.47ms<\/strong><\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\"><strong>Redis Cache<\/strong><\/p>\n<\/td>\n<td data-colwidth=\"140\" width=\"140\">\n<p align=\"left\"><strong>36057<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>16.2ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>11.67ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>19.94ms<\/strong><\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"148\" width=\"148\">\n<p align=\"left\"><strong>APCu Cache<\/strong><\/p>\n<\/td>\n<td data-colwidth=\"140\" width=\"140\">\n<p align=\"left\"><strong>38943<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>15.06ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>10.83ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>18.51ms<\/strong><\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>\u0410\u0442\u0440\u0438\u0431\u0443\u0442\u044b \u043f\u043e\u043a\u0430\u0437\u0430\u043b\u0438 \u043d\u0435\u043f\u043b\u043e\u0445\u0443\u044e \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u043d\u0430 \u0443\u0440\u043e\u0432\u043d\u0435 \u0434\u0440\u0430\u0439\u0432\u0435\u0440\u043e\u0432, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0449\u0438\u0445 PHP-\u043a\u043e\u0434. \u0420\u0430\u0437\u043d\u0438\u0446\u0443 \u043c\u0435\u0436\u0434\u0443 AttributeDriver, StaticPHPDriver \u0438 PHPDriver, \u0434\u0443\u043c\u0430\u044e, \u043c\u043e\u0436\u043d\u043e \u0441\u0447\u0438\u0442\u0430\u0442\u044c \u043f\u043e\u0433\u0440\u0435\u0448\u043d\u043e\u0441\u0442\u044c\u044e. \u0413\u043b\u0430\u0432\u043d\u043e\u0435, \u0447\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u0443\u0432\u0438\u0434\u0435\u0442\u044c \u043f\u043e \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430\u043c \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f &#8212; <strong>\u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438 \u0432 3 \u0440\u0430\u0437\u0430 \u043c\u0435\u0434\u043b\u0435\u043d\u043d\u0435\u0435!<\/strong> \u0418\u043d\u0442\u0435\u0440\u0435\u0441\u0435\u043d \u0442\u0430\u043a \u0436\u0435 \u0442\u043e\u0442 \u0444\u0430\u043a\u0442, \u0447\u0442\u043e \u043a\u044d\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u043d\u0435 \u0432\u0441\u0435\u0433\u0434\u0430 \u043c\u043e\u0436\u0435\u0442 \u043f\u043e\u043c\u043e\u0447\u044c \u0443\u0441\u043a\u043e\u0440\u0438\u0442\u044c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 &#8212; \u0432 Doctrine \u043c\u0435\u0442\u0430\u0434\u0430\u0442\u0430 \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 \u043a\u044d\u0448\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e\u0439 \u0437\u0430\u043f\u0438\u0441\u044c\u044e. \u042d\u0442\u043e \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442 \u043a \u0442\u043e\u043c\u0443, \u0447\u0442\u043e \u0435\u0435 \u0432\u044b\u0433\u0440\u0443\u0437\u043a\u0430 \u0438 \u0434\u0435\u0441\u0435\u0440\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 \u0432 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0438 \u0432\u044b\u0445\u043e\u0434\u0438\u0442 \u043d\u0435\u043d\u0430\u043c\u043d\u043e\u0433\u043e \u0431\u044b\u0441\u0442\u0440\u0435\u0435.<\/p>\n<hr\/>\n<p>\u0415\u0441\u043b\u0438 \u0432\u044b \u0438\u0449\u0438\u0442\u0435 \u0441\u043f\u043e\u0441\u043e\u0431 \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0432\u0430\u0448\u0435 legacy \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435, \u0438 \u0432\u0441\u0435 \u0437\u0430\u043f\u0440\u043e\u0441\u044b \u043a \u0411\u0414 \u0443\u0436\u0435 \u0434\u0430\u0432\u043d\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u0435\u043d\u044b, \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u043e\u0432 \u0438 \u0441\u0443\u0449\u043d\u043e\u0441\u0442\u0435\u0439 ORM &#8212; \u0432\u0430\u0448\u0430 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0430\u044f \u0446\u0435\u043b\u044c.<\/p>\n<p>\u0422\u0443\u0442 \u043c\u043e\u0436\u043d\u043e \u0441\u0442\u043e\u043b\u043a\u043d\u0443\u0442\u044c\u0441\u044f \u0441 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u043e\u0439: legacy &#8212; \u044d\u0442\u043e \u043a\u043e\u0433\u0434\u0430 \u043a\u0443\u0447\u0430 \u043a\u043e\u0434\u0430, \u0430 \u0442\u0435\u043f\u0435\u0440\u044c \u0435\u0433\u043e \u043d\u0443\u0436\u043d\u043e \u0432\u0435\u0441\u044c \u043f\u0435\u0440\u0435\u043f\u0438\u0441\u044b\u0432\u0430\u0442\u044c? \u042d\u0442\u0443 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0443 \u043c\u043e\u0436\u043d\u043e \u0440\u0435\u0448\u0438\u0442\u044c \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0435\u0449\u0435 \u043e\u0434\u043d\u043e\u0433\u043e \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432\u044b \u043c\u043e\u0433\u043b\u0438 \u0432\u0438\u0434\u0435\u0442\u044c \u0432 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430\u0445 \u0431\u0435\u043d\u0447\u043c\u0430\u0440\u043a\u0430 &#8212; \u043a\u043e\u0434\u043e\u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0438:<\/p>\n<div>\n<div class=\"table\">\n<table>\n<tbody>\n<tr>\n<td data-colwidth=\"147\" width=\"147\">\n<p align=\"left\"><strong>\u0414\u0440\u0430\u0439\u0432\u0435\u0440<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>\u0412\u0441\u0435\u0433\u043e \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432<\/strong><\/p>\n<\/td>\n<td data-colwidth=\"131\" width=\"131\">\n<p align=\"left\"><strong>\u041c\u0435\u0434\u0438\u0430\u043d\u0430<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>\u041c\u0438\u043d\u0438\u043c\u0443\u043c<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>95-\u043f\u0435\u0440\u0446\u0435\u043d\u0442\u0438\u043b\u044c<\/strong><\/p>\n<\/td>\n<\/tr>\n<tr>\n<td data-colwidth=\"147\" width=\"147\">\n<p align=\"left\"><a href=\"https:\/\/github.com\/Aspirin4k\/doctrine-metadata-driver-benchmark\/blob\/master\/src\/Generator\/cli-generate.php\" rel=\"noopener noreferrer nofollow\"><strong><u>Generated Static<\/u><\/strong><\/a><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>102124<\/strong><\/p>\n<\/td>\n<td data-colwidth=\"131\" width=\"131\">\n<p align=\"left\"><strong>5.59ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>3.7ms<\/strong><\/p>\n<\/td>\n<td>\n<p align=\"left\"><strong>7.38ms<\/strong><\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>\u042d\u0442\u043e\u0442 \u0432\u0430\u0440\u0438\u0430\u043d\u0442 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0430\u0442\u044c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438, \u043d\u0435 \u043f\u0435\u0440\u0435\u043f\u0438\u0441\u044b\u0432\u0430\u044f \u0432\u0435\u0441\u044c \u043f\u0440\u043e\u0435\u043a\u0442, \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u043f\u043e\u043b\u0443\u0447\u0430\u044f \u0431\u043e\u043d\u0443\u0441\u044b \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0438 &#8212; \u0432\u0435\u0434\u044c \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438 \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u044e\u0442\u0441\u044f \u0432 \u043a\u043e\u0434, \u0430 \u043a\u043e\u0434 \u043f\u043e\u043f\u0430\u0434\u0430\u0435\u0442 \u0432 opcache!<\/p>\n<hr\/>\n<p>\u0420\u0435\u0437\u044e\u043c\u0438\u0440\u0443\u044f:<\/p>\n<ul>\n<li>\n<p>\u0421\u0442\u043e\u0438\u0442 \u043b\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0432 \u043d\u043e\u0432\u044b\u0445 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u0445 \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u044b \u0432\u043c\u0435\u0441\u0442\u043e \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0439 \u0432\u0435\u0437\u0434\u0435, \u0433\u0434\u0435 \u044d\u0442\u043e \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u044b\u043c? \u041e\u0434\u043d\u043e\u0437\u043d\u0430\u0447\u043d\u043e \u0434\u0430.<\/p>\n<\/li>\n<li>\n<p>\u041d\u0443\u0436\u043d\u043e \u043b\u0438 \u043f\u0435\u0440\u0435\u043f\u0438\u0441\u044b\u0432\u0430\u0442\u044c \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438 \u0432 legacy \u043f\u0440\u043e\u0435\u043a\u0442\u0435 \u043d\u0430 \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u044b? \u0417\u0430\u0432\u0438\u0441\u0438\u0442 \u043e\u0442 \u043d\u0435\u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u044b\u0445 \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u0439, \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e \u0432\u0430\u043c \u043f\u043e\u043c\u043e\u0436\u0435\u0442 \u043a\u043e\u0434\u043e\u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u044f. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, <a href=\"https:\/\/github.com\/Aspirin4k\/doctrine-annotation-static-reader\" rel=\"noopener noreferrer nofollow\"><u>\u043f\u043e\u0434\u043e\u0431\u043d\u044b\u0439 \u0441\u043a\u0440\u0438\u043f\u0442<\/u><\/a> \u043c\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c \u0443 \u0441\u0435\u0431\u044f \u043d\u0430 \u043f\u0440\u043e\u0434\u0430\u043a\u0448\u0435\u043d\u0435. (\u0415\u0449\u0435 \u0440\u0430\u0431\u043e\u0447\u0438\u043c \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u043e\u043c \u043c\u043e\u0436\u0435\u0442 \u043e\u043a\u0430\u0437\u0430\u0442\u044c\u0441\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u0440\u0435\u0444\u0430\u043a\u0442\u043e\u0440\u0438\u043d\u0433 \u0441\u0440\u0435\u0434\u0441\u0442\u0432\u0430\u043c\u0438 <a href=\"https:\/\/getrector.org\/blog\/how-to-upgrade-annotations-to-attributes\" rel=\"noopener noreferrer nofollow\">rector<\/a>)<\/p>\n<\/li>\n<\/ul>\n<p>\u041d\u0430\u0434\u0435\u044e\u0441\u044c, \u0441\u0442\u0430\u0442\u044c\u044f \u0431\u044b\u043b\u0430 \u043f\u043e\u043b\u0435\u0437\u043d\u0430 \u0438 \u043f\u043e\u0437\u043d\u0430\u043a\u043e\u043c\u0438\u043b\u0430 \u0432\u0430\u0441 \u0441 \u0435\u0449\u0451 \u043e\u0434\u043d\u0438\u043c \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u043e\u043c \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u043e\u0432 \u043f\u0435\u0440\u0435\u0434 \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u044f\u043c\u0438.<\/p>\n<\/p>\n<\/div>\n<\/div>\n<\/div>\n<div class=\"v-portal\" style=\"display:none;\"><\/div>\n<\/div>\n<p> <!----> <!----><br \/> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/post\/686796\/\"> https:\/\/habr.com\/ru\/post\/686796\/<\/a><br \/><\/br><\/br><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-338053","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/338053","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=338053"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/338053\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=338053"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=338053"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=338053"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}