{"id":36205,"date":"2019-10-31T22:10:16","date_gmt":"2019-10-31T19:10:16","guid":{"rendered":"https:\/\/prohoster.info\/blog\/razbor-zadach-s-konferentsii-hydra-balansirovka-nagruzki-i-in-memory-hranilishha\/"},"modified":"2019-10-31T22:10:16","modified_gmt":"2019-10-31T19:10:16","slug":"razbor-zadach-s-konferentsii-hydra-balansirovka-nagruzki-i-in-memory-hranilishha","status":"publish","type":"post","link":"https:\/\/prohoster.info\/hy\/blog\/administrirovanie\/razbor-zadach-s-konferentsii-hydra-balansirovka-nagruzki-i-in-memory-hranilishha","title":{"rendered":"\u0420\u0430\u0437\u0431\u043e\u0440 \u0437\u0430\u0434\u0430\u0447 \u0441 \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u0438 Hydra \u2014 \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u043a\u0430 \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0438 in-memory \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0430","gt_translate_keys":[{"key":"rendered","format":"text"}]},"content":{"rendered":"<p>\u041d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0434\u043d\u0435\u0439 \u043d\u0430\u0437\u0430\u0434 \u0441\u043b\u0443\u0447\u0438\u043b\u0430\u0441\u044c <noindex><a rel=\"nofollow\" href=\"https:\/\/hydraconf.com\">\u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u044f Hydra<\/a><\/noindex>. \u0420\u0435\u0431\u044f\u0442\u0430 \u0438\u0437 JUG.ru Group \u043f\u0440\u0438\u0433\u043b\u0430\u0441\u0438\u043b\u0438 \u0441\u043f\u0438\u043a\u0435\u0440\u043e\u0432 \u043c\u0435\u0447\u0442\u044b (\u041b\u0435\u0441\u043b\u0438 \u041b\u044d\u043c\u043f\u043e\u0440\u0442! \u041a\u043b\u0438\u0444\u0444 \u041a\u043b\u0438\u043a! \u041c\u0430\u0440\u0442\u0438\u043d \u041a\u043b\u0435\u043f\u043f\u043c\u0430\u043d\u043d!) \u0438 \u043f\u043e\u0441\u0432\u044f\u0442\u0438\u043b\u0438 \u0434\u0432\u0430 \u0434\u043d\u044f \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0451\u043d\u043d\u044b\u043c \u0441\u0438\u0441\u0442\u0435\u043c\u0430\u043c \u0438 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f\u043c. \u041a\u043e\u043d\u0442\u0443\u0440 \u0431\u044b\u043b \u043e\u0434\u043d\u0438\u043c \u0438\u0437 \u0442\u0440\u0451\u0445 \u043f\u0430\u0440\u0442\u043d\u0451\u0440\u043e\u0432 \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u0438. \u041c\u044b \u043e\u0431\u0449\u0430\u043b\u0438\u0441\u044c \u043d\u0430 \u0441\u0442\u0435\u043d\u0434\u0435, \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u044b\u0432\u0430\u043b\u0438 \u043f\u0440\u043e \u043d\u0430\u0448\u0438 \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0451\u043d\u043d\u044b\u0435 \u0445\u0440\u0430\u043d\u0438\u043b\u043a\u0438, \u0438\u0433\u0440\u0430\u043b\u0438 \u0432 \u0431\u0438\u043d\u0433\u043e, \u0440\u0435\u0448\u0430\u043b\u0438 \u0437\u0430\u0434\u0430\u0447\u043a\u0438.<\/p>\n<p><\/p>\n<p>\u042d\u0442\u043e \u043f\u043e\u0441\u0442 \u0441 \u0440\u0430\u0437\u0431\u043e\u0440\u043e\u043c \u0437\u0430\u0434\u0430\u0447 \u043d\u0430 \u0441\u0442\u0435\u043d\u0434\u0435 \u041a\u043e\u043d\u0442\u0443\u0440\u0430 \u043e\u0442 \u0430\u0432\u0442\u043e\u0440\u0430 \u0438\u0445 \u0442\u0435\u043a\u0441\u0442\u0430. \u041a\u0442\u043e \u0431\u044b\u043b \u043d\u0430 \u0413\u0438\u0434\u0440\u0435 \u2014 \u044d\u0442\u043e \u0432\u0430\u0448 \u043f\u043e\u0432\u043e\u0434 \u0432\u0441\u043f\u043e\u043c\u043d\u0438\u0442\u044c \u043f\u0440\u0438\u044f\u0442\u043d\u044b\u0435 \u0432\u043f\u0435\u0447\u0430\u0442\u043b\u0435\u043d\u0438\u044f, \u043a\u0442\u043e \u043d\u0435 \u0431\u044b\u043b \u2014 \u0448\u0430\u043d\u0441 \u0440\u0430\u0437\u043c\u044f\u0442\u044c \u043c\u043e\u0437\u0433\u0438 <em>big O<\/em>-\u043d\u043e\u0442\u0430\u0446\u0438\u0435\u0439. <\/p>\n<p><\/p>\n<p>\u0411\u044b\u043b\u0438 \u0434\u0430\u0436\u0435 \u0443\u0447\u0430\u0441\u0442\u043d\u0438\u043a\u0438, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0440\u0430\u0437\u043e\u0431\u0440\u0430\u043b\u0438 \u0444\u043b\u0438\u043f\u0447\u0430\u0440\u0442 \u043d\u0430 \u0441\u043b\u0430\u0439\u0434\u044b, \u0447\u0442\u043e\u0431\u044b \u0437\u0430\u043f\u0438\u0441\u0430\u0442\u044c \u0441\u0432\u043e\u0451 \u0440\u0435\u0448\u0435\u043d\u0438\u0435. \u042f \u043d\u0435 \u0448\u0443\u0447\u0443 \u2014 \u043e\u043d\u0438 \u0441\u0434\u0430\u043b\u0438 \u043d\u0430 \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0443 \u0432\u043e\u0442 \u0442\u0430\u043a\u0443\u044e \u043f\u0430\u0447\u043a\u0443 \u0431\u0443\u043c\u0430\u0433\u0438:<\/p>\n<p><\/p>\n<p><img decoding=\"async\" alt=\"\u0420\u0430\u0437\u0431\u043e\u0440 \u0437\u0430\u0434\u0430\u0447 \u0441 \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u0438 Hydra &mdash; \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u043a\u0430 \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0438 in-memory \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0430\" src=\"\/wp-content\/uploads\/2019\/07\/4b74e8bc33e390d1f4c4523f9941ed0a.jpeg\" style=\"display:block;margin: 0 auto;\" \/><\/p>\n<p><\/p>\n<p>\u0412\u0441\u0435\u0433\u043e \u0431\u044b\u043b\u043e \u0442\u0440\u0438 \u0437\u0430\u0434\u0430\u0447\u0438:<\/p>\n<p><\/p>\n<ul>\n<li>\u043e \u0432\u044b\u0431\u043e\u0440\u0435 \u0440\u0435\u043f\u043b\u0438\u043a \u043f\u043e \u0432\u0435\u0441\u0430\u043c \u0434\u043b\u044f \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u043a\u0438 \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0438<\/li>\n<li>\u043e \u0441\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u043a\u0435 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u043e\u0432 \u0437\u0430\u043f\u0440\u043e\u0441\u0430 \u043a in-memory \u0431\u0430\u0437\u0435 \u0434\u0430\u043d\u043d\u044b\u0445<\/li>\n<li>\u043e \u043f\u0435\u0440\u0435\u0434\u0430\u0447\u0435 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u0432 \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0451\u043d\u043d\u043e\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u0435 \u0441 \u043a\u043e\u043b\u044c\u0446\u0435\u0432\u043e\u0439 \u0442\u043e\u043f\u043e\u043b\u043e\u0433\u0438\u0435\u0439<\/li>\n<\/ul>\n<p><noindex><a rel=\"nofollow\" name=\"habracut\"><\/a><\/noindex><\/p>\n<h1 id=\"zadacha-1-clusterclient\">\u0417\u0430\u0434\u0430\u0447\u0430 1. ClusterClient<\/h1>\n<p><\/p>\n<p>\u041d\u0443\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0438\u0442\u044c \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c \u044d\u0444\u0444\u0435\u043a\u0442\u0438\u0432\u043d\u043e\u0433\u043e \u0432\u044b\u0431\u043e\u0440\u0430 K \u0438\u0437 N \u0432\u0437\u0432\u0435\u0448\u0435\u043d\u043d\u044b\u0445 \u0440\u0435\u043f\u043b\u0438\u043a \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0451\u043d\u043d\u043e\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u044b:<\/p>\n<p><\/p>\n<blockquote><p>Your team is tasked with developing a client library for a massively distributed cluster of N nodes. The library would keep track of various metadata associated with nodes (e.g., their latencies, 4xx\/5xx response rates, etc.) and assign floating point weights W1..WN to them. In order to support the concurrent execution strategy, the library should be able to pick K of N nodes randomly\u2014a chance of being selected should be proportional to a node\u2019s weight.<\/p>\n<p>Propose an algorithm to select nodes efficiently. Estimate its computational complexity using big O notation.<\/p><\/blockquote>\n<p>\n<b class=\"spoiler_title\">\u041f\u043e\u0447\u0435\u043c\u0443 \u0432\u0441\u0451 \u043d\u0430 \u0430\u043d\u0433\u043b\u0438\u0439\u0441\u043a\u043e\u043c?<\/b><\/p>\n<p>\u041f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0432 \u0442\u0430\u043a\u043e\u043c \u0432\u0438\u0434\u0435 \u0441 \u043d\u0438\u043c\u0438 \u0431\u043e\u0440\u043e\u043b\u0438\u0441\u044c \u0443\u0447\u0430\u0441\u0442\u043d\u0438\u043a\u0438 \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u0438 \u0438 \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0430\u043d\u0433\u043b\u0438\u0439\u0441\u043a\u0438\u0439 \u0431\u044b\u043b \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u043c \u044f\u0437\u044b\u043a\u043e\u043c \u0413\u0438\u0434\u0440\u044b. \u0412\u044b\u0433\u043b\u044f\u0434\u0435\u043b\u0438 \u0437\u0430\u0434\u0430\u0447\u043a\u0438 \u0442\u0430\u043a:<\/p>\n<p><\/p>\n<p><img decoding=\"async\" alt=\"\u0420\u0430\u0437\u0431\u043e\u0440 \u0437\u0430\u0434\u0430\u0447 \u0441 \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u0438 Hydra &mdash; \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u043a\u0430 \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0438 in-memory \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0430\" src=\"\/wp-content\/uploads\/2019\/07\/4bdf7031c82eea4340a5cdef9ad8df0f.jpeg\" style=\"display:block;margin: 0 auto;\" \/><\/p>\n<p><\/p>\n<p>\u0412\u043e\u0437\u044c\u043c\u0438\u0442\u0435 \u0431\u0443\u043c\u0430\u0433\u0443 \u0438 \u043a\u0430\u0440\u0430\u043d\u0434\u0430\u0448, \u043f\u043e\u0434\u0443\u043c\u0430\u0439\u0442\u0435, \u043d\u0435 \u0442\u043e\u0440\u043e\u043f\u0438\u0442\u0435\u0441\u044c \u0441\u0440\u0430\u0437\u0443 \u043e\u0442\u043a\u0440\u044b\u0432\u0430\u0442\u044c \u0441\u043f\u043e\u0439\u043b\u0435\u0440\u044b \ud83d\ude42<\/p>\n<p>\n<b class=\"spoiler_title\">\u0420\u0430\u0437\u0431\u043e\u0440 \u0440\u0435\u0448\u0435\u043d\u0438\u044f (\u0432\u0438\u0434\u0435\u043e)<\/b><\/p>\n<p>\u041d\u0430\u0447\u0430\u043b\u043e \u0432 5:53, \u0432\u0441\u0435\u0433\u043e 4 \u043c\u0438\u043d\u0443\u0442\u044b:<\/p>\n<p>\n<center><div class=\"youtube-placeholder\" data-id=\"HAiQ2llS0bE\" onclick=\"loadVideo(this)\">\r\n        <img decoding=\"async\" src=\"https:\/\/img.youtube.com\/vi\/HAiQ2llS0bE\/hqdefault.jpg\" alt=\"\u0546\u0565\u0580\u056f\u0561\u0575\u0561\u0581\u0576\u0565\u056c \u057f\u0565\u057d\u0561\u0570\u0578\u056c\u0578\u057e\u0561\u056f\" loading=\"lazy\" width=\"480\" height=\"360\" style=\"width:100%;height:auto;\">\r\n        <div class=\"play-button\"><\/div>\r\n    <\/div><\/center><\/p>\n<p>\u0410 \u0432\u043e\u0442 \u043a\u0430\u043a \u043f\u0438\u0442\u0447\u0438\u043b\u0438 \u0441\u0432\u043e\u0451 \u0440\u0435\u0448\u0435\u043d\u0438\u0435 \u0442\u0435 \u0441\u0430\u043c\u044b\u0435 \u0440\u0435\u0431\u044f\u0442\u0430 \u0441 \u0444\u043b\u0438\u043f\u0447\u0430\u0440\u0442\u043e\u043c:<\/p>\n<p>\n<center><div class=\"youtube-placeholder\" data-id=\"U_yfKDwXppg\" onclick=\"loadVideo(this)\">\r\n        <img decoding=\"async\" src=\"https:\/\/img.youtube.com\/vi\/U_yfKDwXppg\/hqdefault.jpg\" alt=\"\u0546\u0565\u0580\u056f\u0561\u0575\u0561\u0581\u0576\u0565\u056c \u057f\u0565\u057d\u0561\u0570\u0578\u056c\u0578\u057e\u0561\u056f\" loading=\"lazy\" width=\"480\" height=\"360\" style=\"width:100%;height:auto;\">\r\n        <div class=\"play-button\"><\/div>\r\n    <\/div><\/center><br \/>\n<b class=\"spoiler_title\">\u0420\u0430\u0437\u0431\u043e\u0440 \u0440\u0435\u0448\u0435\u043d\u0438\u044f (\u0442\u0435\u043a\u0441\u0442)<\/b><\/p>\n<p>\u041d\u0430 \u043f\u043e\u0432\u0435\u0440\u0445\u043d\u043e\u0441\u0442\u0438 \u043b\u0435\u0436\u0438\u0442 \u0442\u0430\u043a\u043e\u0435 \u0440\u0435\u0448\u0435\u043d\u0438\u0435: \u043f\u0440\u043e\u0441\u0443\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0432\u0435\u0441\u0430 \u0432\u0441\u0435\u0445 \u0440\u0435\u043f\u043b\u0438\u043a, \u0441\u0433\u0435\u043d\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u043e\u0435 \u0447\u0438\u0441\u043b\u043e \u043e\u0442 0 \u0434\u043e \u0441\u0443\u043c\u043c\u044b \u0432\u0441\u0435\u0445 \u0432\u0435\u0441\u043e\u0432, \u0437\u0430\u0442\u0435\u043c \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u0442\u0430\u043a\u0443\u044e i-\u0440\u0435\u043f\u043b\u0438\u043a\u0443, \u0447\u0442\u043e \u0441\u0443\u043c\u043c\u0430 \u0432\u0435\u0441\u043e\u0432 \u0440\u0435\u043f\u043b\u0438\u043a \u043e\u0442 0 \u0434\u043e (i-1)-\u043e\u0439 \u043c\u0435\u043d\u044c\u0448\u0435 \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u043e\u0433\u043e \u0447\u0438\u0441\u043b\u0430, \u0430 \u0441\u0443\u043c\u043c\u0430 \u0432\u0435\u0441\u043e\u0432 \u0440\u0435\u043f\u043b\u0438\u043a \u043e\u0442 0 \u0434\u043e i-\u043e\u0439 \u2014 \u0431\u043e\u043b\u044c\u0448\u0435 \u043d\u0435\u0433\u043e. \u0422\u0430\u043a \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u0441\u044f \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u043e\u0434\u043d\u0443 \u0440\u0435\u043f\u043b\u0438\u043a\u0443, \u0430 \u0447\u0442\u043e\u0431\u044b \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0443\u044e, \u043d\u0443\u0436\u043d\u043e \u043f\u043e\u0432\u0442\u043e\u0440\u0438\u0442\u044c \u0432\u0441\u044e \u043f\u0440\u043e\u0446\u0435\u0434\u0443\u0440\u0443, \u043d\u0435 \u0440\u0430\u0441\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u044f \u0432\u044b\u0431\u0440\u0430\u043d\u043d\u0443\u044e \u0440\u0435\u043f\u043b\u0438\u043a\u0443. \u0421 \u0442\u0430\u043a\u0438\u043c \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u043e\u043c \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0432\u044b\u0431\u043e\u0440\u0430 \u043e\u0434\u043d\u043e\u0439 \u0440\u0435\u043f\u043b\u0438\u043a\u0438 \u2014 O(N), \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0432\u044b\u0431\u043e\u0440\u0430 K \u0440\u0435\u043f\u043b\u0438\u043a \u2014 O(N\u00b7K) ~ O(N2).<\/p>\n<p><\/p>\n<p><img decoding=\"async\" alt=\"\u0420\u0430\u0437\u0431\u043e\u0440 \u0437\u0430\u0434\u0430\u0447 \u0441 \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u0438 Hydra &mdash; \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u043a\u0430 \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0438 in-memory \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0430\" src=\"\/wp-content\/uploads\/2019\/07\/0d869f10421f9cf36e501faefc76f209.jpeg\" style=\"display:block;margin: 0 auto;\" \/><\/p>\n<p><\/p>\n<p>\u041a\u0432\u0430\u0434\u0440\u0430\u0442\u0438\u0447\u043d\u0430\u044f \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u2014 \u044d\u0442\u043e \u043f\u043b\u043e\u0445\u043e, \u043e\u0434\u043d\u0430\u043a\u043e \u0435\u0451 \u043c\u043e\u0436\u043d\u043e \u0443\u043b\u0443\u0447\u0448\u0438\u0442\u044c. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043f\u043e\u0441\u0442\u0440\u043e\u0438\u043c <noindex><a rel=\"nofollow\" href=\"http:\/\/brestprog.by\/topics\/segmenttree\/\">\u0434\u0435\u0440\u0435\u0432\u043e \u043e\u0442\u0440\u0435\u0437\u043a\u043e\u0432<\/a><\/noindex> \u0434\u043b\u044f \u0441\u0443\u043c\u043c \u0432\u0435\u0441\u043e\u0432. \u041f\u043e\u043b\u0443\u0447\u0438\u0442\u0441\u044f \u0434\u0435\u0440\u0435\u0432\u043e \u0433\u043b\u0443\u0431\u0438\u043d\u043e\u0439 lg N, \u0432 \u043b\u0438\u0441\u0442\u044c\u044f\u0445 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0431\u0443\u0434\u0443\u0442 \u0432\u0435\u0441\u0430 \u0440\u0435\u043f\u043b\u0438\u043a, \u0430 \u0432 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0445 \u0443\u0437\u043b\u0430\u0445 \u2014 \u0447\u0430\u0441\u0442\u0438\u0447\u043d\u044b\u0435 \u0441\u0443\u043c\u043c\u044b, \u0432\u043f\u043b\u043e\u0442\u044c \u0434\u043e \u0441\u0443\u043c\u043c\u044b \u0432\u0441\u0435\u0445 \u0432\u0435\u0441\u043e\u0432 \u0432 \u043a\u043e\u0440\u043d\u0435 \u0434\u0435\u0440\u0435\u0432\u0430. \u0414\u0430\u043b\u0435\u0435 \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0439\u043d\u043e\u0435 \u0447\u0438\u0441\u043b\u043e \u043e\u0442 0 \u0434\u043e \u0441\u0443\u043c\u043c\u044b \u0432\u0441\u0435\u0445 \u0432\u0435\u0441\u043e\u0432, \u043d\u0430\u0445\u043e\u0434\u0438\u043c i-\u0443\u044e \u0440\u0435\u043f\u043b\u0438\u043a\u0443, \u0443\u0434\u0430\u043b\u044f\u0435\u043c \u0435\u0451 \u0438\u0437 \u0434\u0435\u0440\u0435\u0432\u0430 \u0438 \u043f\u043e\u0432\u0442\u043e\u0440\u044f\u0435\u043c \u043f\u0440\u043e\u0446\u0435\u0434\u0443\u0440\u0443 \u0434\u043b\u044f \u043f\u043e\u0438\u0441\u043a\u0430 \u043e\u0441\u0442\u0430\u0432\u0448\u0438\u0445\u0441\u044f \u0440\u0435\u043f\u043b\u0438\u043a. \u0421 \u0442\u0430\u043a\u0438\u043c \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u043e\u043c \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u043f\u043e\u0441\u0442\u0440\u043e\u0435\u043d\u0438\u044f \u0434\u0435\u0440\u0435\u0432\u0430 \u2014 \u041e(N), \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u043f\u043e\u0438\u0441\u043a\u0430 i-\u043e\u0439 \u0440\u0435\u043f\u043b\u0438\u043a\u0438 \u0438 \u0443\u0434\u0430\u043b\u0435\u043d\u0438\u044f \u0435\u0451 \u0438\u0437 \u0434\u0435\u0440\u0435\u0432\u0430 \u2014 O(lg N), \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0432\u044b\u0431\u043e\u0440\u0430 K \u0440\u0435\u043f\u043b\u0438\u043a \u2014 O(N + K lg N) ~ O(N lg N).<\/p>\n<p><\/p>\n<p><img decoding=\"async\" alt=\"\u0420\u0430\u0437\u0431\u043e\u0440 \u0437\u0430\u0434\u0430\u0447 \u0441 \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u0438 Hydra &mdash; \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u043a\u0430 \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0438 in-memory \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0430\" src=\"\/wp-content\/uploads\/2019\/07\/458c897c3b70c3870a3510f76ec2992f.jpeg\" style=\"display:block;margin: 0 auto;\" \/><\/p>\n<p><\/p>\n<p>\u041b\u0438\u043d\u0435\u0439\u043d\u043e-\u043b\u043e\u0433\u0430\u0440\u0438\u0444\u043c\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u043f\u0440\u0438\u044f\u0442\u043d\u0435\u0435 \u043a\u0432\u0430\u0434\u0440\u0430\u0442\u0438\u0447\u043d\u043e\u0439, \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e \u0434\u043b\u044f \u0431\u043e\u043b\u044c\u0448\u0438\u0445 K.<\/p>\n<p><\/p>\n<p>\u0418\u043c\u0435\u043d\u043d\u043e \u044d\u0442\u043e\u0442 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c <noindex><a rel=\"nofollow\" href=\"https:\/\/github.com\/vostok\/clusterclient.core\/blob\/master\/Vostok.ClusterClient.Core\/Ordering\/Weighed\/WeighedReplicaOrdering.cs\">\u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d \u0432 \u043a\u043e\u0434\u0435<\/a><\/noindex> \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 ClusterClient \u0438\u0437 \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u00ab<noindex><a rel=\"nofollow\" href=\"https:\/\/tech.kontur.ru\/vostok\">\u0412\u043e\u0441\u0442\u043e\u043a<\/a><\/noindex>\u00bb. (\u0422\u0430\u043c \u0434\u0435\u0440\u0435\u0432\u043e \u0441\u0442\u0440\u043e\u0438\u0442\u0441\u044f \u0437\u0430 O(N lg N), \u043d\u043e \u043d\u0430 \u0438\u0442\u043e\u0433\u043e\u0432\u0443\u044e \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u0430 \u044d\u0442\u043e \u043d\u0435 \u0432\u043b\u0438\u044f\u0435\u0442.)<\/p>\n<p><\/p>\n<h1 id=\"zadacha-2-zebra\">\u0417\u0430\u0434\u0430\u0447\u0430 2. Zebra<\/h1>\n<p><\/p>\n<p>\u041d\u0443\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0438\u0442\u044c \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c \u044d\u0444\u0444\u0435\u043a\u0442\u0438\u0432\u043d\u043e\u0439 \u0441\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u043a\u0438 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u0432 \u043f\u0430\u043c\u044f\u0442\u0438 \u043f\u043e \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u043b\u044c\u043d\u043e\u043c\u0443 \u043d\u0435\u0438\u043d\u0434\u0435\u043a\u0441\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u043c\u0443 \u043f\u043e\u043b\u044e:<\/p>\n<p><\/p>\n<blockquote><p>Your team is tasked with developing a sharded in-memory document database. A common workload would be to select top N documents sorted by an arbitrary (non-indexed) numeric field from a collection of size M (usually N &lt; 100 &lt;&lt; M). A slightly less common workload would be to select top N after skipping top S documents (S ~ N).<\/p>\n<p>Propose an algorithm to execute such queries efficiently. Estimate its computational complexity using big O notation in the average case and the worst case scenarios.<\/p><\/blockquote>\n<p>\n<b class=\"spoiler_title\">\u0420\u0430\u0437\u0431\u043e\u0440 \u0440\u0435\u0448\u0435\u043d\u0438\u044f (\u0432\u0438\u0434\u0435\u043e)<\/b><\/p>\n<p>\u041d\u0430\u0447\u0430\u043b\u043e \u0432 34:50, \u0432\u0441\u0435\u0433\u043e 6 \u043c\u0438\u043d\u0443\u0442:<\/p>\n<p>\n<center><div class=\"youtube-placeholder\" data-id=\"HAiQ2llS0bE\" onclick=\"loadVideo(this)\">\r\n        <img decoding=\"async\" src=\"https:\/\/img.youtube.com\/vi\/HAiQ2llS0bE\/hqdefault.jpg\" alt=\"\u0546\u0565\u0580\u056f\u0561\u0575\u0561\u0581\u0576\u0565\u056c \u057f\u0565\u057d\u0561\u0570\u0578\u056c\u0578\u057e\u0561\u056f\" loading=\"lazy\" width=\"480\" height=\"360\" style=\"width:100%;height:auto;\">\r\n        <div class=\"play-button\"><\/div>\r\n    <\/div><\/center><br \/>\n<b class=\"spoiler_title\">\u0420\u0430\u0437\u0431\u043e\u0440 \u0440\u0435\u0448\u0435\u043d\u0438\u044f (\u0442\u0435\u043a\u0441\u0442)<\/b><\/p>\n<p>\u0420\u0435\u0448\u0435\u043d\u0438\u0435 \u043d\u0430 \u043f\u043e\u0432\u0435\u0440\u0445\u043d\u043e\u0441\u0442\u0438: \u043e\u0442\u0441\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0432\u0441\u0435 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u044b (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e <noindex><a rel=\"nofollow\" href=\"https:\/\/ru.wikipedia.org\/wiki\/%D0%91%D1%8B%D1%81%D1%82%D1%80%D0%B0%D1%8F_%D1%81%D0%BE%D1%80%D1%82%D0%B8%D1%80%D0%BE%D0%B2%D0%BA%D0%B0\">quicksort<\/a><\/noindex>), \u0437\u0430\u0442\u0435\u043c \u0432\u0437\u044f\u0442\u044c N+S \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e\u0432. \u0412 \u0442\u0430\u043a\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0441\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u043a\u0438 \u0432 \u0441\u0440\u0435\u0434\u043d\u0435\u043c \u2014 O(M lg M), \u0432 \u0445\u0443\u0434\u0448\u0435\u043c \u2014 O(M2).<\/p>\n<p><\/p>\n<p>\u041e\u0447\u0435\u0432\u0438\u0434\u043d\u043e, \u0447\u0442\u043e \u0441\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0432\u0441\u0435 M \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e\u0432, \u0447\u0442\u043e\u0431\u044b \u0437\u0430\u0442\u0435\u043c \u0432\u0437\u044f\u0442\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u0443\u044e \u0447\u0430\u0441\u0442\u044c \u043e\u0442 \u043d\u0438\u0445 \u2014 \u043d\u0435\u044d\u0444\u0444\u0435\u043a\u0442\u0438\u0432\u043d\u043e. \u0427\u0442\u043e\u0431\u044b \u043d\u0435 \u0441\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0432\u0441\u0435 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u044b, \u043f\u043e\u0434\u043e\u0439\u0434\u0451\u0442 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c <noindex><a rel=\"nofollow\" href=\"https:\/\/en.wikipedia.org\/wiki\/Quickselect\">quickselect<\/a><\/noindex>, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432\u044b\u0431\u0435\u0440\u0435\u0442 N+S \u043d\u0443\u0436\u043d\u044b\u0445 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e\u0432 (\u0438\u0445 \u043c\u043e\u0436\u043d\u043e \u0431\u0443\u0434\u0435\u0442 \u043e\u0442\u0441\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043b\u044e\u0431\u044b\u043c \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u043e\u043c). \u0412 \u044d\u0442\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0432 \u0441\u0440\u0435\u0434\u043d\u0435\u043c \u0443\u043c\u0435\u043d\u044c\u0448\u0438\u0442\u0441\u044f \u0434\u043e O(M), \u0430 \u0445\u0443\u0434\u0448\u0438\u0439 \u0441\u043b\u0443\u0447\u0430\u0439 \u043e\u0441\u0442\u0430\u043d\u0435\u0442\u0441\u044f \u0442\u0435\u043c \u0436\u0435.<\/p>\n<p><\/p>\n<p>\u041e\u0434\u043d\u0430\u043a\u043e, \u043c\u043e\u0436\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0435\u0449\u0451 \u044d\u0444\u0444\u0435\u043a\u0442\u0438\u0432\u043d\u0435\u0435 \u2014 \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u043e\u043c <noindex><a rel=\"nofollow\" href=\"https:\/\/stackoverflow.com\/questions\/30914801\/optimal-algorithm-to-return-largest-k-elements-from-an-array-of-infinite-number\">binary heap streaming<\/a><\/noindex>. \u0412 \u044d\u0442\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043f\u0435\u0440\u0432\u044b\u0435 N+S \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u0441\u043a\u043b\u0430\u0434\u044b\u0432\u0430\u044e\u0442\u0441\u044f \u0432 min- \u0438\u043b\u0438 max-heap (\u0432 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043e\u0442 \u043d\u0430\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0441\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u043a\u0438), \u0430 \u0437\u0430\u0442\u0435\u043c \u043a\u0430\u0436\u0434\u044b\u0439 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442 \u0441\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u0441 \u043a\u043e\u0440\u043d\u0435\u043c \u0434\u0435\u0440\u0435\u0432\u0430, \u0433\u0434\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442\u0441\u044f \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u0439 \u0438\u043b\u0438 \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u0439 \u043d\u0430 \u0442\u0435\u043a\u0443\u0449\u0438\u0439 \u043c\u043e\u043c\u0435\u043d\u0442 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442, \u0438 \u043f\u0440\u0438 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u0438 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0432 \u0434\u0435\u0440\u0435\u0432\u043e. \u0412 \u044d\u0442\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0432 \u0445\u0443\u0434\u0448\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435, \u043a\u043e\u0433\u0434\u0430 \u043f\u0440\u0438\u0434\u0451\u0442\u0441\u044f \u043f\u043e\u0441\u0442\u043e\u044f\u043d\u043d\u043e \u043f\u0435\u0440\u0435\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u0442\u044c \u0434\u0435\u0440\u0435\u0432\u043e \u2014 O(M lg M), \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0432 \u0441\u0440\u0435\u0434\u043d\u0435\u043c \u2014 O(M), \u043a\u0430\u043a \u0438 \u043f\u0440\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 quickselect.<\/p>\n<p><\/p>\n<p>\u041e\u0434\u043d\u0430\u043a\u043e heap streaming \u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u044d\u0444\u0444\u0435\u043a\u0442\u0438\u0432\u043d\u0435\u0435 \u0437\u0430 \u0441\u0447\u0451\u0442 \u0442\u043e\u0433\u043e, \u0447\u0442\u043e \u043d\u0430 \u043f\u0440\u0430\u043a\u0442\u0438\u043a\u0435 \u0431\u043e\u043b\u044c\u0448\u0443\u044e \u0447\u0430\u0441\u0442\u044c \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442\u0441\u044f \u043e\u0442\u0431\u0440\u043e\u0441\u0438\u0442\u044c, \u043d\u0435 \u043f\u0435\u0440\u0435\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u044f \u043a\u0443\u0447\u0443, \u043f\u043e\u0441\u043b\u0435 \u0435\u0434\u0438\u043d\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0433\u043e \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u044f \u0441 \u0435\u0451 \u043a\u043e\u0440\u043d\u0435\u0432\u044b\u043c \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u043c. \u0422\u0430\u043a\u0430\u044f \u0441\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u043a\u0430 \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u043d\u0430 \u0432 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043d\u043e\u0439 in-memory \u0431\u0430\u0437\u0435 \u0434\u0430\u043d\u043d\u044b\u0445 Zebra, \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0430\u043d\u043d\u043e\u0439 \u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u043e\u0439 \u0432 \u041a\u043e\u043d\u0442\u0443\u0440\u0435.<\/p>\n<p><\/p>\n<h1 id=\"zadacha-3-state-swaps\">\u0417\u0430\u0434\u0430\u0447\u0430 3. State swaps<\/h1>\n<p><\/p>\n<p>\u041d\u0443\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0438\u0442\u044c \u0441\u0430\u043c\u044b\u0439 \u044d\u0444\u0444\u0435\u043a\u0442\u0438\u0432\u043d\u044b\u0439 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c \u0434\u043b\u044f \u0441\u0434\u0432\u0438\u0433\u0430 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0439:<\/p>\n<p><\/p>\n<blockquote><p>Your team is tasked with developing a fancy state exchange mechanism for a distributed cluster of N nodes. The i-th node\u2019s state should be transferred to the (i+1)-th node, the N-th node\u2019s state should be transferred to the first node. The only supported operation is the state swap when two nodes exchange their states atomically. It is known that a state swap takes M milliseconds. Every node is able to participate in a single state swap at any given moment.<\/p>\n<p>How long does it take to transfer the states of all nodes in a cluster?<\/p><\/blockquote>\n<p>\n<b class=\"spoiler_title\">\u0420\u0430\u0437\u0431\u043e\u0440 \u0440\u0435\u0448\u0435\u043d\u0438\u044f (\u0442\u0435\u043a\u0441\u0442)<\/b><\/p>\n<p>\u0420\u0435\u0448\u0435\u043d\u0438\u0435 \u043d\u0430 \u043f\u043e\u0432\u0435\u0440\u0445\u043d\u043e\u0441\u0442\u0438: \u043e\u0431\u043c\u0435\u043d\u044f\u0442\u044c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u0438 \u0432\u0442\u043e\u0440\u043e\u0433\u043e \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430, \u0437\u0430\u0442\u0435\u043c \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u0438 \u0442\u0440\u0435\u0442\u044c\u0435\u0433\u043e, \u0437\u0430\u0442\u0435\u043c \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u0438 \u0447\u0435\u0442\u0432\u0451\u0440\u0442\u043e\u0433\u043e \u0438 \u0442\u0430\u043a \u0434\u0430\u043b\u0435\u0435. \u041f\u043e\u0441\u043b\u0435 \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043e\u0431\u043c\u0435\u043d\u0430 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043e\u0434\u043d\u043e\u0433\u043e \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430 \u0431\u0443\u0434\u0435\u0442 \u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c\u0441\u044f \u043d\u0430 \u043d\u0443\u0436\u043d\u043e\u0439 \u043f\u043e\u0437\u0438\u0446\u0438\u0438. \u041f\u0440\u0438\u0434\u0451\u0442\u0441\u044f \u0441\u0434\u0435\u043b\u0430\u0442\u044c O(N) \u043f\u0435\u0440\u0435\u0441\u0442\u0430\u043d\u043e\u0432\u043e\u043a \u0438 \u043f\u043e\u0442\u0440\u0430\u0442\u0438\u0442\u044c O(N\u00b7M) \u0432\u0440\u0435\u043c\u0435\u043d\u0438.<\/p>\n<p><\/p>\n<p><img decoding=\"async\" alt=\"\u0420\u0430\u0437\u0431\u043e\u0440 \u0437\u0430\u0434\u0430\u0447 \u0441 \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u0438 Hydra &mdash; \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u043a\u0430 \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0438 in-memory \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0430\" src=\"\/wp-content\/uploads\/2019\/07\/c0bbdf680f565d790bd64ebcd90bf985.jpeg\" style=\"display:block;margin: 0 auto;\" \/><\/p>\n<p><\/p>\n<p>\u041b\u0438\u043d\u0435\u0439\u043d\u043e\u0435 \u0432\u0440\u0435\u043c\u044f \u2014 \u044d\u0442\u043e \u0434\u043e\u043b\u0433\u043e, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043c\u043e\u0436\u043d\u043e \u043e\u0431\u043c\u0435\u043d\u0438\u0432\u0430\u0442\u044c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u0432 \u043f\u043e\u043f\u0430\u0440\u043d\u043e: \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u0441\u043e \u0432\u0442\u043e\u0440\u044b\u043c, \u0442\u0440\u0435\u0442\u044c\u0435\u0433\u043e \u0441 \u0447\u0435\u0442\u0432\u0451\u0440\u0442\u044b\u043c \u0438 \u0442\u0430\u043a \u0434\u0430\u043b\u0435\u0435. \u041f\u043e\u0441\u043b\u0435 \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043e\u0431\u043c\u0435\u043d\u0430 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u0432\u0442\u043e\u0440\u043e\u0433\u043e \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430 \u0431\u0443\u0434\u0435\u0442 \u043e\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c\u0441\u044f \u043d\u0430 \u043d\u0443\u0436\u043d\u043e\u0439 \u043f\u043e\u0437\u0438\u0446\u0438\u0438. \u041f\u0440\u0438\u0434\u0451\u0442\u0441\u044f \u0441\u0434\u0435\u043b\u0430\u0442\u044c O(lg N) \u043f\u0435\u0440\u0435\u0441\u0442\u0430\u043d\u043e\u0432\u043e\u043a \u0438 \u043f\u043e\u0442\u0440\u0430\u0442\u0438\u0442\u044c O(M lg N) \u0432\u0440\u0435\u043c\u0435\u043d\u0438.<\/p>\n<p><\/p>\n<p><img decoding=\"async\" alt=\"\u0420\u0430\u0437\u0431\u043e\u0440 \u0437\u0430\u0434\u0430\u0447 \u0441 \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u0438 Hydra &mdash; \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u043a\u0430 \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0438 in-memory \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0430\" src=\"\/wp-content\/uploads\/2019\/07\/7d55d4f8b63bf63763e93b5780e02c48.jpeg\" style=\"display:block;margin: 0 auto;\" \/><\/p>\n<p><\/p>\n<p>\u041e\u0434\u043d\u0430\u043a\u043e, \u043c\u043e\u0436\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0441\u0434\u0432\u0438\u0433 \u0435\u0449\u0451 \u044d\u0444\u0444\u0435\u043a\u0442\u0438\u0432\u043d\u0435\u0435 \u2014 \u043d\u0435 \u0437\u0430 \u043b\u0438\u043d\u0435\u0439\u043d\u043e\u0435, \u0430 \u0437\u0430 \u043a\u043e\u043d\u0441\u0442\u0430\u043d\u0442\u043d\u043e\u0435 \u0432\u0440\u0435\u043c\u044f. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043d\u0430 \u043f\u0435\u0440\u0432\u043e\u043c \u0448\u0430\u0433\u0435 \u043d\u0443\u0436\u043d\u043e \u043e\u0431\u043c\u0435\u043d\u044f\u0442\u044c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043f\u0435\u0440\u0432\u043e\u0433\u043e \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430 \u0441 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0438\u043c, \u0432\u0442\u043e\u0440\u043e\u0433\u043e \u0441 \u043f\u0440\u0435\u0434\u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0438\u043c \u0438 \u0442\u0430\u043a \u0434\u0430\u043b\u0435\u0435. \u0421\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0435\u0433\u043e \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430 \u043e\u043a\u0430\u0436\u0435\u0442\u0441\u044f \u043d\u0430 \u043d\u0443\u0436\u043d\u043e\u0439 \u043f\u043e\u0437\u0438\u0446\u0438\u0438. \u0410 \u0442\u0435\u043f\u0435\u0440\u044c \u043d\u0443\u0436\u043d\u043e \u043e\u0431\u043c\u0435\u043d\u044f\u0442\u044c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u0432\u0442\u043e\u0440\u043e\u0433\u043e \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430 \u0441 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0438\u043c, \u0442\u0440\u0435\u0442\u044c\u0435\u0433\u043e \u0441 \u043f\u0440\u0435\u0434\u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0438\u043c \u0438 \u0442\u0430\u043a \u0434\u0430\u043b\u0435\u0435. \u041f\u043e\u0441\u043b\u0435 \u044d\u0442\u043e\u0433\u043e \u0440\u0430\u0443\u043d\u0434\u0430 \u043e\u0431\u043c\u0435\u043d\u043e\u0432 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u0432\u0441\u0435\u0445 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u0432 \u043e\u043a\u0430\u0436\u0443\u0442\u0441\u044f \u043d\u0430 \u043d\u0443\u0436\u043d\u043e\u0439 \u043f\u043e\u0437\u0438\u0446\u0438\u0438. \u0412\u0441\u0435\u0433\u043e \u0431\u0443\u0434\u0435\u0442 \u0441\u0434\u0435\u043b\u0430\u043d\u043e O(2M) ~ O(1) \u043f\u0435\u0440\u0435\u0441\u0442\u0430\u043d\u043e\u0432\u043e\u043a.<\/p>\n<p><\/p>\n<p><img decoding=\"async\" alt=\"\u0420\u0430\u0437\u0431\u043e\u0440 \u0437\u0430\u0434\u0430\u0447 \u0441 \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u0438 Hydra &mdash; \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u043a\u0430 \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0438 in-memory \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0430\" src=\"\/wp-content\/uploads\/2019\/07\/ad5fe5325985af3b280d2dc75c6a1077.jpeg\" style=\"display:block;margin: 0 auto;\" \/><\/p>\n<p><\/p>\n<p>\u0422\u0430\u043a\u043e\u0435 \u0440\u0435\u0448\u0435\u043d\u0438\u0435 \u0441\u043e\u0432\u0435\u0440\u0448\u0435\u043d\u043d\u043e \u043d\u0435 \u0443\u0434\u0438\u0432\u0438\u0442 \u043c\u0430\u0442\u0435\u043c\u0430\u0442\u0438\u043a\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0435\u0449\u0451 \u043f\u043e\u043c\u043d\u0438\u0442, \u0447\u0442\u043e \u043f\u043e\u0432\u043e\u0440\u043e\u0442 \u2014 \u044d\u0442\u043e \u043a\u043e\u043c\u043f\u043e\u0437\u0438\u0446\u0438\u044f \u0434\u0432\u0443\u0445 \u043e\u0441\u0435\u0432\u044b\u0445 \u0441\u0438\u043c\u043c\u0435\u0442\u0440\u0438\u0439. \u041a\u0441\u0442\u0430\u0442\u0438, \u043e\u043d\u043e \u0442\u0440\u0438\u0432\u0438\u0430\u043b\u044c\u043d\u043e \u043e\u0431\u043e\u0431\u0449\u0430\u0435\u0442\u0441\u044f \u0434\u043b\u044f \u0441\u0434\u0432\u0438\u0433\u0430 \u043d\u0435 \u043d\u0430 \u043e\u0434\u043d\u0443, \u0430 \u043d\u0430 K &lt; N \u043f\u043e\u0437\u0438\u0446\u0438\u0439. (\u041d\u0430\u043f\u0438\u0448\u0438\u0442\u0435 \u0432 \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u044f\u0445, \u043a\u0430\u043a \u0438\u043c\u0435\u043d\u043d\u043e.)<\/p>\n<p><\/p>\n<p>\u041f\u043e\u043d\u0440\u0430\u0432\u0438\u043b\u0438\u0441\u044c \u0437\u0430\u0434\u0430\u0447\u043a\u0438? \u0417\u043d\u0430\u0435\u0442\u0435 \u0434\u0440\u0443\u0433\u0438\u0435 \u0440\u0435\u0448\u0435\u043d\u0438\u044f? \u0414\u0435\u043b\u0438\u0442\u0435\u0441\u044c \u0432 \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u044f\u0445.<\/p>\n<p><\/p>\n<p>\u0410 \u0432\u043e\u0442 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043f\u043e\u043b\u0435\u0437\u043d\u044b\u0445 \u0441\u0441\u044b\u043b\u043e\u043a \u043d\u0430\u043f\u043e\u0441\u043b\u0435\u0434\u043e\u043a:<\/p>\n<p><\/p>\n<ul>\n<li>\u0443\u0437\u043d\u0430\u0439\u0442\u0435 \u0431\u043e\u043b\u044c\u0448\u0435 \u043e\u0431 <noindex><a rel=\"nofollow\" href=\"https:\/\/tech.kontur.ru\/infra\">\u0438\u043d\u0444\u0440\u0430\u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u043d\u043e\u0439 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0435<\/a><\/noindex> \u0432 \u041a\u043e\u043d\u0442\u0443\u0440\u0435<\/li>\n<li>\u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u0442\u0435 \u0437\u0430\u043f\u0438\u0441\u0438 \u0432\u043d\u0443\u0442\u0440\u0435\u043d\u043d\u0438\u0445 <noindex><a rel=\"nofollow\" href=\"https:\/\/www.youtube.com\/playlist?list=PLc82OEDeni8TxAybSoENHU-hJ4mRbVQG2\">\u043b\u0435\u0442\u0443\u0447\u0435\u043a \u0441 \u0434\u043e\u043a\u043b\u0430\u0434\u0430\u043c\u0438<\/a><\/noindex> \u043e \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0451\u043d\u043d\u044b\u0445 \u0441\u0438\u0441\u0442\u0435\u043c\u0430\u0445<\/li>\n<li>\u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u0442\u0435 \u0446\u0438\u043a\u043b \u0432\u0438\u0434\u0435\u043e\u043b\u0435\u043a\u0446\u0438\u0439 \u00ab<noindex><a rel=\"nofollow\" href=\"https:\/\/tech.kontur.ru\/algorithms-for-everyone\">\u041d\u0435\u043e\u0431\u044b\u0447\u043d\u044b\u0435 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u044b \u0434\u043b\u044f \u043e\u0431\u044b\u0447\u043d\u044b\u0445 \u043b\u044e\u0434\u0435\u0439<\/a><\/noindex>\u00bb<\/li>\n<li>\u043f\u043e\u0434\u043f\u0438\u0448\u0438\u0442\u0435\u0441\u044c \u043d\u0430 \u043d\u0430\u0448 <noindex><a rel=\"nofollow\" href=\"https:\/\/t.me\/KonturTech\">\u043a\u0430\u043d\u0430\u043b \u0432 \u0422\u0435\u043b\u0435\u0433\u0440\u0430\u043c\u0435<\/a><\/noindex><\/li>\n<\/ul>\n<p>\u0531\u0572\u0562\u0575\u0578\u0582\u0580: <a content=\"nofollow\" rel=\"nofollow\" href=\"https:\/\/habr.com\/ru\/company\/skbkontur\/blog\/459958\/\">habr.com<\/a><\/p>","protected":false,"gt_translate_keys":[{"key":"rendered","format":"html"}]},"excerpt":{"rendered":"<p>\u041d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0434\u043d\u0435\u0439 \u043d\u0430\u0437\u0430\u0434 \u0441\u043b\u0443\u0447\u0438\u043b\u0430\u0441\u044c \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u044f Hydra. \u0420\u0435\u0431\u044f\u0442\u0430 \u0438\u0437 JUG.ru Group \u043f\u0440\u0438\u0433\u043b\u0430\u0441\u0438\u043b\u0438 \u0441\u043f\u0438\u043a\u0435\u0440\u043e\u0432 \u043c\u0435\u0447\u0442\u044b (\u041b\u0435\u0441\u043b\u0438 \u041b\u044d\u043c\u043f\u043e\u0440\u0442! \u041a\u043b\u0438\u0444\u0444 \u041a\u043b\u0438\u043a! \u041c\u0430\u0440\u0442\u0438\u043d \u041a\u043b\u0435\u043f\u043f\u043c\u0430\u043d\u043d!) \u0438 \u043f\u043e\u0441\u0432\u044f\u0442\u0438\u043b\u0438 \u0434\u0432\u0430 \u0434\u043d\u044f \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0451\u043d\u043d\u044b\u043c \u0441\u0438\u0441\u0442\u0435\u043c\u0430\u043c \u0438 \u0432\u044b\u0447\u0438\u0441\u043b\u0435\u043d\u0438\u044f\u043c. \u041a\u043e\u043d\u0442\u0443\u0440 \u0431\u044b\u043b \u043e\u0434\u043d\u0438\u043c \u0438\u0437 \u0442\u0440\u0451\u0445 \u043f\u0430\u0440\u0442\u043d\u0451\u0440\u043e\u0432 \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u0438. \u041c\u044b \u043e\u0431\u0449\u0430\u043b\u0438\u0441\u044c \u043d\u0430 \u0441\u0442\u0435\u043d\u0434\u0435, \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u044b\u0432\u0430\u043b\u0438 \u043f\u0440\u043e \u043d\u0430\u0448\u0438 \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0451\u043d\u043d\u044b\u0435 \u0445\u0440\u0430\u043d\u0438\u043b\u043a\u0438, \u0438\u0433\u0440\u0430\u043b\u0438 \u0432 \u0431\u0438\u043d\u0433\u043e, \u0440\u0435\u0448\u0430\u043b\u0438 \u0437\u0430\u0434\u0430\u0447\u043a\u0438. \u042d\u0442\u043e \u043f\u043e\u0441\u0442 \u0441 \u0440\u0430\u0437\u0431\u043e\u0440\u043e\u043c \u0437\u0430\u0434\u0430\u0447 \u043d\u0430 \u0441\u0442\u0435\u043d\u0434\u0435 [&hellip;]<\/p>\n","protected":false,"gt_translate_keys":[{"key":"rendered","format":"html"}]},"author":1,"featured_media":27083,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[688],"tags":[],"class_list":["post-36205","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-administrirovanie"],"aioseo_notices":[],"aioseo_head":"\n\t\t<!-- All in One SEO 5.0.0.1 - aioseo.com -->\n\t<meta name=\"description\" content=\"\u041d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0434\u043d\u0435\u0439 \u043d\u0430\u0437\u0430\u0434 \u0441\u043b\u0443\u0447\u0438\u043b\u0430\u0441\u044c \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u044f Hydra. \u0420\u0435\u0431\u044f\u0442\u0430 \u0438\u0437 JUG.ru Group \u043f\u0440\u0438\u0433\u043b\u0430\u0441\u0438\u043b\u0438 \u0441\u043f\u0438\u043a\u0435\u0440\u043e\u0432 \u043c\u0435\u0447\u0442\u044b (\u041b\u0435\u0441\u043b\u0438 \u041b\u044d\u043c\u043f\u043e\u0440\u0442!\" \/>\n\t<meta name=\"robots\" content=\"max-image-preview:large\" \/>\n\t<meta name=\"author\" content=\"Yuri Gagarin\"\/>\n\t<link rel=\"canonical\" href=\"https:\/\/prohoster.info\/hy\/blog\/administrirovanie\/razbor-zadach-s-konferentsii-hydra-balansirovka-nagruzki-i-in-memory-hranilishha\" \/>\n\t<meta name=\"generator\" content=\"All in One SEO (AIOSEO) 5.0.0.1\" \/>\n\t\t<meta property=\"og:locale\" content=\"en_US\" \/>\n\t\t<meta property=\"og:site_name\" content=\"ProHoster | \u041a\u0443\u043f\u0438\u0442\u044c \u043d\u0430\u0434\u0435\u0436\u043d\u044b\u0439 \u0445\u043e\u0441\u0442\u0438\u043d\u0433 \u0434\u043b\u044f \u0441\u0430\u0439\u0442\u043e\u0432 \u0441 \u0437\u0430\u0449\u0438\u0442\u043e\u0439 \u043e\u0442 DDoS, VPS VDS \u0441\u0435\u0440\u0432\u0435\u0440\u044b\" \/>\n\t\t<meta property=\"og:type\" content=\"article\" \/>\n\t\t<meta property=\"og:title\" content=\"\ud83e\udd47\u0420\u0430\u0437\u0431\u043e\u0440 \u0437\u0430\u0434\u0430\u0447 \u0441 \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u0438 Hydra \u2014 \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u043a\u0430 \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0438 in-memory \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0430 | ProHoster\" \/>\n\t\t<meta property=\"og:description\" content=\"\u041d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0434\u043d\u0435\u0439 \u043d\u0430\u0437\u0430\u0434 \u0441\u043b\u0443\u0447\u0438\u043b\u0430\u0441\u044c \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u044f Hydra. \u0420\u0435\u0431\u044f\u0442\u0430 \u0438\u0437 JUG.ru Group \u043f\u0440\u0438\u0433\u043b\u0430\u0441\u0438\u043b\u0438 \u0441\u043f\u0438\u043a\u0435\u0440\u043e\u0432 \u043c\u0435\u0447\u0442\u044b (\u041b\u0435\u0441\u043b\u0438 \u041b\u044d\u043c\u043f\u043e\u0440\u0442!\" \/>\n\t\t<meta property=\"og:url\" content=\"https:\/\/prohoster.info\/hy\/blog\/administrirovanie\/razbor-zadach-s-konferentsii-hydra-balansirovka-nagruzki-i-in-memory-hranilishha\" \/>\n\t\t<meta property=\"og:image\" content=\"https:\/\/prohoster.info\/wp-content\/uploads\/2021\/11\/logo-350.jpg\" \/>\n\t\t<meta property=\"og:image:secure_url\" content=\"https:\/\/prohoster.info\/wp-content\/uploads\/2021\/11\/logo-350.jpg\" \/>\n\t\t<meta property=\"og:image:width\" content=\"350\" \/>\n\t\t<meta property=\"og:image:height\" content=\"350\" \/>\n\t\t<meta property=\"article:published_time\" content=\"2019-10-31T19:10:16+00:00\" \/>\n\t\t<meta property=\"article:modified_time\" content=\"2019-10-31T19:10:16+00:00\" \/>\n\t\t<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/prohoster\" \/>\n\t\t<meta property=\"article:author\" content=\"https:\/\/www.facebook.com\/prohoster\" \/>\n\t\t<!-- All in One SEO -->\n\n","aioseo_head_json":{"title":"\ud83e\udd47\u0420\u0430\u0437\u0431\u043e\u0440 \u0437\u0430\u0434\u0430\u0447 \u0441 \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u0438 Hydra \u2014 \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u043a\u0430 \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0438 in-memory \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0430 | ProHoster","description":"\u041d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0434\u043d\u0435\u0439 \u043d\u0430\u0437\u0430\u0434 \u0441\u043b\u0443\u0447\u0438\u043b\u0430\u0441\u044c \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u044f Hydra. \u0420\u0435\u0431\u044f\u0442\u0430 \u0438\u0437 JUG.ru Group \u043f\u0440\u0438\u0433\u043b\u0430\u0441\u0438\u043b\u0438 \u0441\u043f\u0438\u043a\u0435\u0440\u043e\u0432 \u043c\u0435\u0447\u0442\u044b (\u041b\u0435\u0441\u043b\u0438 \u041b\u044d\u043c\u043f\u043e\u0440\u0442!","canonical_url":"https:\/\/prohoster.info\/hy\/blog\/administrirovanie\/razbor-zadach-s-konferentsii-hydra-balansirovka-nagruzki-i-in-memory-hranilishha","robots":"max-image-preview:large","keywords":"","webmasterTools":{"miscellaneous":""},"schema":null,"og:locale":"en_US","og:site_name":"ProHoster | \u041a\u0443\u043f\u0438\u0442\u044c \u043d\u0430\u0434\u0435\u0436\u043d\u044b\u0439 \u0445\u043e\u0441\u0442\u0438\u043d\u0433 \u0434\u043b\u044f \u0441\u0430\u0439\u0442\u043e\u0432 \u0441 \u0437\u0430\u0449\u0438\u0442\u043e\u0439 \u043e\u0442 DDoS, VPS VDS \u0441\u0435\u0440\u0432\u0435\u0440\u044b","og:type":"article","og:title":"\ud83e\udd47\u0420\u0430\u0437\u0431\u043e\u0440 \u0437\u0430\u0434\u0430\u0447 \u0441 \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u0438 Hydra \u2014 \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u043a\u0430 \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0438 in-memory \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0430 | ProHoster","og:description":"\u041d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0434\u043d\u0435\u0439 \u043d\u0430\u0437\u0430\u0434 \u0441\u043b\u0443\u0447\u0438\u043b\u0430\u0441\u044c \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u044f Hydra. \u0420\u0435\u0431\u044f\u0442\u0430 \u0438\u0437 JUG.ru Group \u043f\u0440\u0438\u0433\u043b\u0430\u0441\u0438\u043b\u0438 \u0441\u043f\u0438\u043a\u0435\u0440\u043e\u0432 \u043c\u0435\u0447\u0442\u044b (\u041b\u0435\u0441\u043b\u0438 \u041b\u044d\u043c\u043f\u043e\u0440\u0442!","og:url":"https:\/\/prohoster.info\/hy\/blog\/administrirovanie\/razbor-zadach-s-konferentsii-hydra-balansirovka-nagruzki-i-in-memory-hranilishha","og:image":"https:\/\/prohoster.info\/wp-content\/uploads\/2021\/11\/logo-350.jpg","og:image:secure_url":"https:\/\/prohoster.info\/wp-content\/uploads\/2021\/11\/logo-350.jpg","og:image:width":350,"og:image:height":350,"article:published_time":"2019-10-31T19:10:16+00:00","article:modified_time":"2019-10-31T19:10:16+00:00","article:publisher":"https:\/\/www.facebook.com\/prohoster","article:author":"https:\/\/www.facebook.com\/prohoster"},"aioseo_meta_data":{"post_id":"36205","title":null,"description":null,"keywords":null,"keyphrases":null,"primary_term":null,"canonical_url":null,"og_title":null,"og_description":null,"og_object_type":"default","og_image_type":"default","og_image_url":null,"og_image_width":null,"og_image_height":null,"og_image_custom_url":null,"og_image_custom_fields":null,"og_video":null,"og_custom_url":null,"og_article_section":null,"og_article_tags":null,"twitter_use_og":false,"twitter_card":"default","twitter_image_type":"default","twitter_image_url":null,"twitter_image_custom_url":null,"twitter_image_custom_fields":null,"twitter_title":null,"twitter_description":null,"schema":{"blockGraphs":[],"customGraphs":[],"default":{"data":{"Article":[],"Course":[],"Dataset":[],"FAQPage":[],"Movie":[],"Person":[],"Product":[],"ProductReview":[],"Car":[],"Recipe":[],"Service":[],"SoftwareApplication":[],"WebPage":[]},"graphName":"","isEnabled":true},"graphs":[]},"schema_type":null,"schema_type_options":null,"pillar_content":false,"robots_default":true,"robots_noindex":false,"robots_noarchive":false,"robots_nosnippet":false,"robots_nofollow":false,"robots_noimageindex":false,"robots_noodp":false,"robots_notranslate":false,"robots_max_snippet":null,"robots_max_videopreview":null,"robots_max_imagepreview":"large","priority":null,"frequency":null,"local_seo":null,"seo_analyzer_scan_date":"2026-01-22 02:25:19","breadcrumb_settings":null,"limit_modified_date":false,"reviewed_by":null,"ai":null,"created":"2021-02-28 16:50:57","updated":"2026-01-22 02:25:19","focus_keyword":null,"additional_keywords":null,"truseo_locale":null},"gt_translate_keys":[{"key":"link","format":"url"}],"_links":{"self":[{"href":"https:\/\/prohoster.info\/hy\/wp-json\/wp\/v2\/posts\/36205","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/prohoster.info\/hy\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/prohoster.info\/hy\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/prohoster.info\/hy\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/prohoster.info\/hy\/wp-json\/wp\/v2\/comments?post=36205"}],"version-history":[{"count":0,"href":"https:\/\/prohoster.info\/hy\/wp-json\/wp\/v2\/posts\/36205\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/prohoster.info\/hy\/wp-json\/wp\/v2\/media\/27083"}],"wp:attachment":[{"href":"https:\/\/prohoster.info\/hy\/wp-json\/wp\/v2\/media?parent=36205"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/prohoster.info\/hy\/wp-json\/wp\/v2\/categories?post=36205"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/prohoster.info\/hy\/wp-json\/wp\/v2\/tags?post=36205"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}