doc-exports/docs/asm/umn/asm_01_0037.html
Dong, Qiu Jian ec0b45029f ASM UMN initial version -20240425
Reviewed-by: Kovács, Zoltán <zkovacs@t-systems.com>
Co-authored-by: Dong, Qiu Jian <qiujiandong1@huawei.com>
Co-committed-by: Dong, Qiu Jian <qiujiandong1@huawei.com>
2024-09-18 09:02:28 +00:00

41 lines
11 KiB
HTML

<a name="asm_01_0037"></a><a name="asm_01_0037"></a>
<h1 class="topictitle1">Basic Operations on a Grayscale Task</h1>
<div id="body0000001083233778"><div class="section" id="asm_01_0037__section1132195261519"><h4 class="sectiontitle">Description</h4><p id="asm_01_0037__p192151613161">Basic operations on a grayscale version are performed by modifying the configuration of the DestinationRule and VirtualService resources of Istio. After the modification is complete, wait for about 10 seconds for the new policy to take effect.</p>
</div>
<div class="section" id="asm_01_0037__section13277131491720"><h4 class="sectiontitle">Modifying the Traffic Policy of a Grayscale Version</h4><p id="asm_01_0037__p103820313582"><strong id="asm_01_0037__b6994123265817">Modifying a grayscale policy that is based on traffic ratio</strong></p>
<p id="asm_01_0037__p954314915568">For such a grayscale policy that is based on traffic ratio, you can gradually increase the traffic ratio of the grayscale version to avoid service risks caused by direct traffic switchover. To change the traffic ratio, perform the following steps:</p>
<ol id="asm_01_0037__ol22602493585"><li id="asm_01_0037__li172608490583"><span>Log in to the ASM console and click the name of the target service mesh to go to its details page.</span></li><li id="asm_01_0037__li1685515685910"><span>In the navigation pane, choose <strong id="asm_01_0037__b1198257152102457">Grayscale Release</strong>. Then click the target canary release task.</span></li><li id="asm_01_0037__li119651731195914"><span>On the <span class="uicontrol" id="asm_01_0037__uicontrol15603542195919"><b>Configure Traffic Policy</b></span> page, set the traffic ratio of the grayscale version.</span><p><p id="asm_01_0037__p204971340517">If the traffic ratio of the grayscale version is set to <strong id="asm_01_0037__b1049686697102457">x</strong>, the traffic ratio of the original version is automatically adjusted to <strong id="asm_01_0037__b1249862318102457">100-x</strong>.</p>
</p></li><li id="asm_01_0037__li1654913119011"><span>Click <strong id="asm_01_0037__b2088803477102457">Deliver Policy</strong>.</span></li></ol>
<p id="asm_01_0037__p229215343582"><strong id="asm_01_0037__b2085653513584">Modifying a grayscale policy that is based on request content</strong></p>
<p id="asm_01_0037__p78315545421">With such a policy, a grayscale version can be accessed only when the traffic meets the rules based on Cookies, Headers, Queries, Allowed Operating Systems, and Allowed Browsers. In real-world use cases, rules may be modified for multiple times to fully verify the performance of the grayscale version.</p>
<ol id="asm_01_0037__ol63435402427"><li id="asm_01_0037__li83431840114212"><span>Log in to the ASM console and click the name of the target service mesh to go to its details page.</span></li><li id="asm_01_0037__li1343134014429"><span>In the navigation pane on the left, choose <strong id="asm_01_0037__b808078738102457">Grayscale Release</strong> and click the target canary release task.</span></li><li id="asm_01_0037__li43433409426"><span>On the <span class="uicontrol" id="asm_01_0037__uicontrol221028061102457"><b>Configure Traffic Policy</b></span> page, reconfigure <strong id="asm_01_0037__b158529202102457">Cookie</strong>, <strong id="asm_01_0037__b1274928578102457">Header</strong>, <strong id="asm_01_0037__b1679842724102457">Query</strong>, <strong id="asm_01_0037__b227798411102457">Allowed OS</strong>, and <strong id="asm_01_0037__b323640813102457">Allowed Browser</strong>.</span></li><li id="asm_01_0037__li134315402422"><span>Click <strong id="asm_01_0037__b1247868421102457">Deliver Policy</strong>.</span></li></ol>
</div>
<div class="section" id="asm_01_0037__section1198719955819"><h4 class="sectiontitle">Switching the Grayscale Policy Type</h4><p id="asm_01_0037__p1938319221655">You can change the type of a grayscale policy from <span class="uicontrol" id="asm_01_0037__uicontrol196956419398"><b>based on request content</b></span> to <span class="uicontrol" id="asm_01_0037__uicontrol8517310113911"><b>based on traffic ratio</b></span> and vice versa. After this operation is complete, all configured rules become invalid and all traffic is redistributed based on the new policy.</p>
<div class="notice" id="asm_01_0037__note084791961611"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="asm_01_0037__p071154481611">Grayscale policies can be changed only for running tasks. After a grayscale version is released (that is, the new version completely takes over the traffic and the old version has been brought offline), its grayscale policy cannot be reconfigured.</p>
</div></div>
<ol id="asm_01_0037__ol1210818591352"><li id="asm_01_0037__li52621017101914"><span>Log in to the ASM console and click the name of the target service mesh to go to its details page.</span></li><li id="asm_01_0037__li46935210529"><span>In the navigation pane on the left, choose <strong id="asm_01_0037__b245738102102457">Grayscale Release</strong> and click the target canary release task.</span></li><li id="asm_01_0037__li196067405229"><span>On the <span class="uicontrol" id="asm_01_0037__uicontrol85896715214"><b>Configure Traffic Policy</b></span> page, change the policy type.</span></li><li id="asm_01_0037__li188191539102411"><span>Click <strong id="asm_01_0037__b1743078927102457">Deliver Policy</strong>.</span></li></ol>
</div>
<div class="section" id="asm_01_0037__section124701017142211"><h4 class="sectiontitle">Taking Over All Traffic</h4><p id="asm_01_0037__p772618508120">After you click <span class="uicontrol" id="asm_01_0037__uicontrol6726125018123"><b>Take Over All Traffic</b></span>, the original version or grayscale version takes over all traffic.</p>
<ol id="asm_01_0037__ol11726175016122"><li id="asm_01_0037__li590412592365"><span>Log in to the ASM console and click the name of the target service mesh to go to its details page.</span></li><li id="asm_01_0037__li167261550131217"><span>In the navigation pane on the left, choose <strong id="asm_01_0037__b2072504440102457">Grayscale Release</strong> and click the target grayscale release task.</span></li><li id="asm_01_0037__li11726450171215"><span>On the <strong id="asm_01_0037__b675106888102457">Monitor and Manage Traffic</strong> page, click <strong id="asm_01_0037__b2027459733102457">Take Over All Traffic</strong> next to the target version.</span></li><li id="asm_01_0037__li107261550141217"><span>In the displayed dialog box, click <strong id="asm_01_0037__b313926256102457">OK</strong>.</span></li></ol>
</div>
<div class="section" id="asm_01_0037__section315312842215"><h4 class="sectiontitle">Terminating a Grayscale Release Task</h4><p id="asm_01_0037__p12870125843218">After the grayscale version takes over all traffic, you can terminate the grayscale task. After the grayscale task is canceled, the original version will be brought offline, and all workloads and Istio configuration resources will be deleted.</p>
<ol id="asm_01_0037__ol758780709"><li id="asm_01_0037__li10929204883211"><span>Log in to the ASM console and click the name of the target service mesh to go to its details page.</span></li><li id="asm_01_0037__li142039178448"><span>In the navigation pane on the left, choose <strong id="asm_01_0037__b2104194791102457">Grayscale Release</strong> and click the target grayscale release task.</span></li><li id="asm_01_0037__li17930204863217"><span>On the <strong id="asm_01_0037__b287496591102457">Monitor and Manage Traffic</strong> page, click <strong id="asm_01_0037__b269083596102457">Take Over All Traffic</strong> next to the grayscale version.</span></li><li id="asm_01_0037__li593017482325"><span>Click <strong id="asm_01_0037__b145186320102457">Terminate Task</strong> in the lower right corner.</span></li><li id="asm_01_0037__li940153111410"><span>In the displayed dialog box, click <strong id="asm_01_0037__b707808679102457">OK</strong>.</span><p><p id="asm_01_0037__p74963681419">You can go to the <strong id="asm_01_0037__b1712159922102457">Terminated Tasks</strong> tab page to view the finished grayscale task. The <strong id="asm_01_0037__b628015301102457">Release Result</strong> is <strong id="asm_01_0037__b686986172102457">Released successfully</strong>.</p>
</p></li></ol>
</div>
<div class="section" id="asm_01_0037__section14397841183619"><h4 class="sectiontitle">Canceling a Grayscale Release Task</h4><p id="asm_01_0037__p172641546103619">After the original version takes over all traffic, you can cancel the grayscale task.</p>
<ol id="asm_01_0037__ol614993610209"><li id="asm_01_0037__li17149203618204"><span>Log in to the ASM console and click the name of the target service mesh to go to its details page.</span></li><li id="asm_01_0037__li9602941162010"><span>In the navigation pane on the left, choose <strong id="asm_01_0037__b758139008102457">Grayscale Release</strong> and click the target grayscale release task.</span></li><li id="asm_01_0037__li68361823123315"><span>On the <strong id="asm_01_0037__b43010898102457">Monitor and Manage Traffic</strong> page, click <strong id="asm_01_0037__b765831614102457">Take Over All Traffic</strong> next to the original version.</span></li><li id="asm_01_0037__li31089354275"><span>Click <strong id="asm_01_0037__b651501629102457">Cancel Task</strong> in the lower right corner. You can also click <span><img id="asm_01_0037__image811561310322" src="en-us_image_0000001209978068.png"></span> in the upper right corner of a task in the grayscale task list.</span></li><li id="asm_01_0037__li133111045142015"><span>In the displayed dialog box, click <strong id="asm_01_0037__b500762591102457">OK</strong>.</span><p><p id="asm_01_0037__p1445312193414">You can go to the <strong id="asm_01_0037__b1319872632102457">Terminated Tasks</strong> tab page to view the finished grayscale task. The <strong id="asm_01_0037__b1291505820102457">Release Result</strong> is <strong id="asm_01_0037__b1932649443102457">Released canceled</strong>.</p>
</p></li></ol>
</div>
<div class="section" id="asm_01_0037__section15383135483517"><h4 class="sectiontitle">Viewing Terminated Grayscale Release Tasks</h4><p id="asm_01_0037__p139585417360">You can view canceled and finished grayscale tasks on the <strong id="asm_01_0037__b1420952114102457">Terminated Tasks</strong> tab page.</p>
<ol id="asm_01_0037__ol499611672411"><li id="asm_01_0037__li599615692414"><span>Log in to the ASM console and click the name of the target service mesh to go to its details page.</span></li><li id="asm_01_0037__li1261451182417"><span>In the navigation pane on the left, choose <strong id="asm_01_0037__b2092000304102457">Grayscale Release</strong> and click the <strong id="asm_01_0037__b850199559102457">Terminated Tasks</strong> tab page.</span><p><p id="asm_01_0037__p8782155210475">You can view the release task name, release result, service, and release time, and delete a terminated task.</p>
</p></li></ol>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="asm_01_0034.html">Grayscale Release</a></div>
</div>
</div>