1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470 2471 2472 2473 2474 2475 2476 2477 2478 2479 2480 2481 2482 2483 2484 2485 2486 2487 2488 2489 2490 2491 2492 2493 2494 2495 2496 2497 2498 2499 2500 2501 2502 2503 2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 2515 2516 2517 2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 2551 2552 2553 2554 2555 2556 2557 2558 2559 2560 2561 2562 2563 2564 2565 2566 2567 2568 2569 2570 2571 2572 2573 2574 2575 2576 2577 2578 2579 2580 2581 2582 2583 2584 2585 2586 2587 2588 2589 2590 2591 2592 2593 2594 2595 2596 2597 2598 2599 2600 2601 2602 2603 2604 2605 2606 2607 2608 2609 2610 2611 2612 2613 2614 2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 2625 2626 2627 2628 2629 2630 2631 2632 2633 2634 2635 2636 2637 2638 2639 2640 2641 2642 2643 2644 2645 2646 2647 2648 2649 2650 2651 2652 2653 2654 2655 2656 2657 2658 2659 2660 2661 2662 2663 2664 2665 2666 2667 2668 2669 2670 2671 2672 2673 2674 2675 2676 2677 2678 2679 2680 2681 2682 2683 2684 2685 2686 2687 2688 2689 2690 2691 2692 2693 2694 2695 2696 2697 2698 2699 2700 2701 2702 2703 2704 2705 2706 2707 2708 2709 2710 2711 2712 2713 2714 2715 2716 2717 2718 2719 2720 2721 2722 2723 2724 2725 2726 2727 2728 2729 2730 2731 2732 2733 2734 2735 2736 2737 2738 2739 2740 2741 2742 2743 2744 2745 2746 2747 2748 2749 2750 2751 2752 2753 2754 2755 2756 2757 2758 2759 2760 2761 2762 2763 2764 2765 2766 2767 2768 2769 2770 2771 2772 2773 2774 2775 2776 2777 2778 2779 2780 2781 2782 2783 2784 2785 2786 2787 2788 2789 2790 2791 2792 2793 2794 2795 2796 2797 2798 2799 2800 2801 2802 2803 2804 2805 2806 2807 2808 2809 2810 2811 2812 2813 2814 2815 2816 2817 2818 2819 2820 2821 2822 2823 2824 2825 2826 2827 2828 2829 2830 2831 2832 2833 2834 2835 2836 2837 2838 2839 2840 2841 2842 2843 2844 2845 2846 2847 2848 2849 2850 2851 2852 2853 2854 2855 2856 2857 2858 2859 2860 2861 2862 2863 2864 2865 2866 2867 2868 2869 2870 2871 2872 2873 2874 2875 2876 2877 2878 2879 2880 2881 2882 2883 2884 2885 2886 2887 2888 2889 2890 2891 2892 2893 2894 2895 2896 2897 2898 2899 2900 2901 2902 2903 2904 2905 2906 2907 2908 2909 2910 2911 2912 2913 2914 2915 2916 2917 2918 2919 2920 2921 2922 2923 2924 2925 2926 2927 2928 2929 2930 2931 2932 2933 2934 2935 2936 2937 2938 2939 2940 2941 2942 2943 2944 2945 2946 2947 2948 2949 2950 2951 2952 2953 2954 2955 2956 2957 2958 2959 2960 2961 2962 2963 2964 2965 2966 2967 2968 2969 2970 2971 2972 2973 2974 2975 2976 2977 2978 2979 2980 2981 2982 2983 2984 2985 2986 2987 2988 2989 2990 2991 2992 2993 2994 2995 2996 2997 2998 2999 3000 3001 3002 3003 3004 3005 3006 3007 3008 3009 3010 3011 3012 3013 3014 3015 3016 3017 3018 3019 3020 3021 3022 3023 3024 3025 3026 3027 3028 3029 3030 3031 3032 3033 3034 3035 3036 3037 3038 3039 3040 3041 3042 3043 3044 3045 3046 3047 3048 3049 3050 3051 3052 3053 3054 3055 3056 3057 3058 3059 3060 3061 3062 3063 3064 3065 3066 3067 3068 3069 3070 3071 3072 3073 3074 3075 3076 3077 3078 3079 3080 3081 3082 3083 3084 3085 3086 3087 3088 3089 3090 3091 3092 3093 3094 3095 3096 3097 3098 3099 3100 3101 3102 3103 3104 3105 3106 3107 3108 3109 3110 3111 3112 3113 3114 3115 3116 3117 3118 3119 3120 3121 3122 3123 3124 3125 3126 3127 3128 3129 3130 3131 3132 3133 3134 3135 3136 3137 3138 3139 3140 3141 3142 3143 3144 3145 3146 3147 3148 3149 3150 3151 3152 3153 3154 3155 3156 3157 3158 3159 3160 3161 3162 3163 3164 3165 3166 3167 3168 3169 3170 3171 3172 3173 3174 3175 3176 3177 3178 3179 3180 3181 3182 3183 3184 3185 3186 3187 3188 3189 3190 3191 3192 3193 3194 3195 3196 3197 3198 3199 3200 3201 3202 3203 3204 3205 3206 3207 3208 3209 3210 3211 3212 3213 3214 3215 3216 3217 3218 3219 3220 3221 3222 3223 3224 3225 3226 3227 3228 3229 3230 3231 3232 3233 3234 3235 3236 3237 3238 3239 3240 3241 3242 3243 3244 3245 3246 3247 3248 3249 3250 3251 3252 3253 3254 3255 3256 3257 3258 3259 3260 3261 3262 3263 3264 3265 3266 3267 3268 3269 3270 3271 3272 3273 3274 3275 3276 3277 3278 3279 3280 3281 3282 3283 3284 3285 3286 3287 3288 3289 3290 3291 3292 3293 3294 3295 3296 3297 3298 3299 3300 3301 3302 3303 3304 3305 3306 3307 3308 3309 3310 3311 3312 3313 3314 3315 3316 3317 3318 3319 3320 3321 3322 3323 3324 3325 3326 3327 3328 3329 3330 3331 3332 3333 3334 3335 3336 3337 3338 3339 3340 3341 3342 3343 3344 3345 3346 3347 3348 3349 3350 3351 3352 3353 3354 3355 3356 3357 3358 3359 3360 3361 3362 3363 3364 3365 3366 3367 3368 3369 3370 3371 3372 3373 3374 3375 3376 3377 3378 3379 3380 3381 3382 3383 3384 3385 3386 3387 3388 3389 3390 3391 3392 3393 3394 3395 3396 3397 3398 3399 3400 3401 3402 3403 3404 3405 3406 3407 3408 3409 3410 3411 3412 3413 3414 3415 3416 3417 3418 3419 3420 3421 3422 3423 3424 3425 3426 3427 3428 3429 3430 3431 3432 3433 3434 3435 3436 3437 3438 3439 3440 3441 3442 3443 3444 3445 3446 3447 3448 3449 3450 3451 3452 3453 3454 3455 3456 3457 3458 3459 3460 3461 3462 3463 3464 3465 3466 3467 3468 3469 3470 3471 3472 3473 3474 3475 3476 3477 3478 3479 3480 3481 3482 3483 3484 3485 3486 3487 3488 3489 3490 3491 3492 3493 3494 3495 3496 3497 3498 3499 3500 3501 3502 3503 3504 3505 3506 3507 3508 3509 3510 3511 3512 3513 3514 3515 3516 3517 3518 3519 3520 3521 3522 3523 3524 3525 3526 3527 3528 3529 3530 3531 3532 3533 3534 3535 3536 3537 3538 3539 3540 3541 3542 3543 3544 3545 3546 3547 3548 3549 3550 3551 3552 3553 3554 3555 3556 3557 3558 3559 3560 3561 3562 3563 3564 3565 3566 3567 3568 3569 3570 3571 3572 3573 3574 3575 3576 3577 3578 3579 3580 3581 3582 3583 3584 3585 3586 3587 3588 3589 3590 3591 3592 3593 3594 3595 3596 3597 3598 3599 3600 3601 3602 3603 3604 3605 3606 3607 3608 3609 3610 3611 3612 3613 3614 3615 3616 3617 3618 3619 3620 3621 3622 3623 3624 3625 3626 3627 3628 3629 3630 3631 3632 3633 3634 3635 3636 3637 3638 3639 3640 3641 3642 3643 3644 3645 3646 3647 3648 3649 3650 3651 3652 3653 3654 3655 3656 3657 3658 3659 3660 3661 3662 3663 3664 3665 3666 3667 3668 3669 3670 3671 3672 3673 3674 3675 3676 3677 3678 3679 3680 3681 3682 3683 3684 3685 3686 3687 3688 3689 3690 3691 3692 3693 3694 3695 3696 3697 3698 3699 3700 3701 3702 3703 3704 3705 3706 3707 3708 3709 3710 3711 3712 3713 3714 3715 3716 3717 3718 3719 3720 3721 3722 3723 3724 3725 3726 3727 3728 3729 3730 3731 3732 3733 3734 3735 3736 3737 3738 3739 3740 3741 3742 3743 3744 3745 3746 3747 3748 3749 3750 3751 3752 3753 3754 3755 3756 3757 3758 3759 3760 3761 3762 3763 3764 3765 3766 3767 3768 3769 3770 3771 3772 3773 3774 3775 3776 3777 3778 3779 3780 3781 3782 3783 3784 3785 3786 3787 3788 3789 3790 3791 3792 3793 3794 3795 3796 3797 3798 3799 3800 3801 3802 3803 3804 3805 3806 3807 3808 3809 3810 3811 3812 3813 3814 3815 3816 3817 3818 3819 3820 3821 3822 3823 3824 3825 3826 3827 3828 3829 3830 3831 3832 3833 3834 3835 3836 3837 3838 3839 3840 3841 3842 3843 3844 3845 3846 3847 3848 3849 3850 3851 3852 3853 3854 3855 3856 3857 3858 3859 3860 3861 3862 3863 3864 3865 3866 3867 3868 3869 3870 3871 3872 3873 3874 3875 3876 3877 3878 3879 3880 3881 3882 3883 3884 3885 3886 3887 3888 3889 3890 3891 3892 3893 3894 3895 3896 3897 3898 3899 3900 3901 3902 3903 3904 3905 3906 3907 3908 3909 3910 3911 3912 3913 3914 3915 3916 3917 3918 3919 3920 3921 3922 3923 3924 3925 3926 3927 3928 3929 3930 3931 3932 3933 3934 3935 3936 3937 3938 3939 3940 3941 3942 3943 3944 3945 3946 3947 3948 3949 3950 3951 3952 3953 3954 3955 3956 3957 3958 3959 3960 3961 3962 3963 3964 3965 3966 3967 3968 3969 3970 3971 3972 3973 3974 3975 3976 3977 3978 3979 3980 3981 3982 3983 3984 3985 3986 3987 3988 3989 3990 3991 3992 3993 3994 3995 3996 3997 3998 3999 4000 4001 4002 4003 4004 4005 4006 4007 4008 4009 4010 4011 4012 4013 4014 4015 4016 4017 4018 4019 4020 4021 4022 4023 4024 4025 4026 4027 4028 4029 4030 4031 4032 4033 4034 4035 4036 4037 4038 4039 4040 4041 4042 4043 4044 4045 4046 4047 4048 4049 4050 4051 4052 4053 4054 4055 4056 4057 4058 4059 4060 4061 4062 4063 4064 4065 4066 4067 4068 4069 4070 4071 4072 4073 4074 4075 4076 4077 4078 4079 4080 4081 4082 4083 4084 4085 4086 4087 4088 4089 4090 4091 4092 4093 4094 4095 4096 4097 4098 4099 4100 4101 4102 4103 4104 4105 4106 4107 4108 4109 4110 4111 4112 4113 4114 4115 4116 4117 4118 4119 4120 4121 4122 4123 4124 4125 4126 4127 4128 4129 4130 4131 4132 4133 4134 4135 4136 4137 4138 4139 4140 4141 4142 4143 4144 4145 4146 4147 4148 4149 4150 4151 4152 4153 4154 4155 4156 4157 4158 4159 4160 4161 4162 4163 4164 4165 4166 4167 4168 4169 4170 4171 4172 4173 4174 4175 4176 4177 4178 4179 4180 4181 4182 4183 4184 4185 4186 4187 4188 4189 4190 4191 4192 4193 4194 4195 4196 4197 4198 4199 4200 4201 4202 4203 4204 4205 4206 4207 4208 4209 4210 4211 4212 4213 4214 4215 4216 4217 4218 4219 4220 4221 4222 4223 4224 4225 4226 4227 4228 4229 4230 4231 4232 4233 4234 4235 4236 4237 4238 4239 4240 4241 4242 4243 4244 4245 4246 4247 4248 4249 4250 4251 4252 4253 4254 4255 4256 4257 4258 4259 4260 4261 4262 4263 4264 4265 4266 4267 4268 4269 4270 4271 4272 4273 4274 4275 4276 4277 4278 4279 4280 4281 4282 4283 4284 4285 4286 4287 4288 4289 4290 4291 4292 4293 4294 4295 4296 4297 4298 4299 4300 4301 4302 4303 4304 4305 4306 4307 4308 4309 4310 4311 4312 4313 4314 4315 4316 4317 4318 4319 4320 4321 4322 4323 4324 4325 4326 4327 4328 4329 4330 4331 4332 4333 4334 4335 4336 4337 4338 4339 4340 4341 4342 4343 4344 4345 4346 4347 4348 4349 4350 4351 4352 4353 4354 4355 4356 4357 4358 4359 4360 4361 4362 4363 4364 4365 4366 4367 4368 4369 4370 4371 4372 4373 4374 4375 4376 4377 4378 4379 4380 4381 4382 4383 4384 4385 4386 4387 4388 4389 4390 4391 4392 4393 4394 4395 4396 4397 4398 4399 4400 4401 4402 4403 4404 4405 4406 4407 4408 4409 4410 4411 4412 4413 4414 4415 4416 4417 4418 4419 4420 4421 4422 4423 4424 4425 4426 4427 4428 4429 4430 4431 4432 4433 4434 4435 4436 4437 4438 4439 4440 4441 4442 4443 4444 4445 4446 4447 4448 4449 4450 4451 4452 4453 4454 4455 4456 4457 4458 4459 4460 4461 4462 4463 4464 4465 4466 4467 4468 4469 4470 4471 4472 4473 4474 4475 4476 4477 4478 4479 4480 4481 4482 4483 4484 4485 4486 4487 4488 4489 4490 4491 4492 4493 4494 4495 4496 4497 4498 4499 4500 4501 4502 4503 4504 4505 4506 4507 4508 4509 4510 4511 4512 4513 4514 4515 4516 4517 4518 4519 4520 4521 4522 4523 4524 4525 4526 4527 4528 4529 4530 4531 4532 4533 4534 4535 4536 4537 4538 4539 4540 4541 4542 4543 4544 4545 4546 4547 4548 4549 4550 4551 4552 4553 4554 4555 4556 4557 4558 4559 4560 4561 4562 4563 4564 4565 4566 4567 4568 4569 4570 4571 4572 4573 4574 4575 4576 4577 4578 4579 4580 4581 4582 4583 4584 4585 4586 4587 4588 4589 4590 4591 4592 4593 4594 4595 4596 4597 4598 4599 4600 4601 4602 4603 4604 4605 4606 4607 4608 4609 4610 4611 4612 4613 4614 4615 4616 4617 4618 4619 4620 4621 4622 4623 4624 4625 4626 4627 4628 4629 4630 4631 4632 4633 4634 4635 4636 4637 4638 4639 4640 4641 4642 4643 4644 4645 4646 4647 4648 4649 4650 4651 4652 4653 4654 4655 4656 4657 4658 4659 4660 4661 4662 4663 4664 4665 4666 4667 4668 4669 4670 4671 4672 4673 4674 4675 4676 4677 4678 4679 4680 4681 4682 4683 4684 4685 4686 4687 4688 4689 4690 4691 4692 4693 4694 4695 4696 4697 4698 4699 4700 4701 4702 4703 4704 4705 4706 4707 4708 4709 4710 4711 4712 4713 4714 4715 4716 4717 4718 4719 4720 4721 4722 4723 4724 4725 4726 4727 4728 4729 4730 4731 4732 4733 4734 4735 4736 4737 4738 4739 4740 4741 4742 4743 4744 4745 4746 4747 4748 4749 4750 4751 4752 4753 4754 4755 4756 4757 4758 4759 4760 4761 4762 4763 4764 4765 4766 4767 4768 4769 4770 4771 4772 4773 4774 4775 4776 4777 4778 4779 4780 4781 4782 4783 4784 4785 4786 4787 4788 4789 4790 4791 4792 4793 4794 4795 4796 4797 4798 4799 4800 4801 4802 4803 4804 4805 4806 4807 4808 4809 4810 4811 4812 4813 4814 4815 4816 4817 4818 4819 4820 4821 4822 4823 4824 4825 4826 4827 4828 4829 4830 4831 4832 4833 4834 4835 4836 4837 4838 4839 4840 4841 4842 4843 4844 4845 4846 4847 4848 4849 4850 4851 4852 4853 4854 4855 4856 4857 4858 4859 4860 4861 4862 4863 4864 4865 4866 4867 4868 4869 4870 4871 4872 4873 4874 4875 4876 4877 4878 4879 4880 4881 4882 4883 4884 4885 4886 4887 4888 4889 4890 4891 4892 4893 4894 4895 4896 4897 4898 4899 4900 4901 4902 4903 4904 4905 4906 4907 4908 4909 4910 4911 4912 4913 4914 4915 4916 4917 4918 4919 4920 4921 4922 4923 4924 4925 4926 4927 4928 4929 4930 4931 4932 4933 4934 4935 4936 4937 4938 4939 4940 4941 4942 4943 4944 4945 4946 4947 4948 4949 4950 4951 4952 4953 4954 4955 4956 4957 4958 4959 4960 4961 4962 4963 4964 4965 4966 4967 4968 4969 4970 4971 4972 4973 4974 4975 4976 4977 4978 4979 4980 4981 4982 4983 4984 4985 4986 4987 4988 4989 4990 4991 4992 4993 4994 4995 4996 4997 4998 4999 5000 5001 5002 5003 5004 5005 5006 5007 5008 5009 5010 5011 5012 5013 5014 5015 5016 5017 5018 5019 5020 5021 5022 5023 5024 5025 5026 5027 5028 5029 5030 5031 5032 5033 5034 5035 5036 5037 5038 5039 5040 5041 5042 5043 5044 5045 5046 5047 5048 5049 5050 5051 5052 5053 5054 5055 5056 5057 5058 5059 5060 5061 5062 5063 5064 5065 5066 5067 5068 5069 5070 5071 5072 5073 5074 5075 5076 5077 5078 5079 5080 5081 5082 5083 5084 5085 5086 5087 5088 5089 5090 5091 5092 5093 5094 5095 5096 5097 5098 5099 5100 5101 5102 5103 5104 5105 5106 5107 5108 5109 5110 5111 5112 5113 5114 5115 5116 5117 5118 5119 5120 5121 5122 5123 5124 5125 5126 5127 5128 5129 5130 5131 5132 5133 5134 5135 5136 5137 5138 5139 5140 5141 5142 5143 5144 5145 5146 5147 5148 5149 5150 5151 5152 5153 5154 5155 5156 5157 5158 5159 5160 5161 5162 5163 5164 5165 5166 5167 5168 5169 5170 5171 5172 5173 5174 5175 5176 5177 5178 5179 5180 5181 5182 5183 5184 5185 5186 5187 5188 5189 5190 5191 5192 5193 5194 5195 5196 5197 5198 5199 5200 5201 5202 5203 5204 5205 5206 5207 5208 5209 5210 5211 5212 5213 5214 5215 5216 5217 5218 5219 5220 5221 5222 5223 5224 5225 5226 5227 5228 5229 5230 5231 5232 5233 5234 5235 5236 5237 5238 5239 5240 5241 5242 5243 5244 5245 5246 5247 5248 5249 5250 5251 5252 5253 5254 5255 5256 5257 5258 5259 5260 5261 5262 5263 5264 5265 5266 5267 5268 5269 5270 5271 5272 5273 5274 5275 5276 5277 5278 5279 5280 5281 5282 5283 5284 5285 5286 5287 5288 5289 5290 5291 5292 5293 5294 5295 5296 5297 5298 5299 5300 5301 5302 5303 5304 5305 5306 5307 5308 5309 5310 5311 5312 5313 5314 5315 5316 5317 5318 5319 5320 5321 5322 5323 5324 5325 5326 5327 5328 5329 5330 5331 5332 5333 5334 5335 5336 5337 5338 5339 5340 5341 5342 5343 5344 5345 5346 5347 5348 5349 5350 5351 5352 5353 5354 5355 5356 5357 5358 5359 5360 5361 5362 5363 5364 5365 5366 5367 5368 5369 5370 5371 5372 5373 5374 5375 5376 5377 5378 5379 5380 5381 5382 5383 5384 5385 5386 5387 5388 5389 5390 5391 5392 5393 5394 5395 5396 5397 5398 5399 5400 5401 5402 5403 5404 5405 5406 5407 5408 5409 5410 5411 5412 5413 5414 5415 5416 5417 5418 5419 5420 5421 5422 5423 5424 5425 5426 5427 5428 5429 5430 5431 5432 5433 5434 5435 5436 5437 5438 5439 5440 5441 5442 5443 5444 5445 5446 5447 5448 5449 5450 5451 5452 5453 5454 5455 5456 5457 5458 5459 5460 5461 5462 5463 5464 5465 5466 5467 5468 5469 5470 5471 5472 5473 5474 5475 5476 5477 5478 5479 5480 5481 5482 5483 5484 5485 5486 5487 5488 5489 5490 5491 5492 5493 5494 5495 5496 5497 5498 5499 5500 5501 5502 5503 5504 5505 5506 5507 5508 5509 5510 5511 5512 5513 5514 5515 5516 5517 5518 5519 5520 5521 5522 5523 5524 5525 5526 5527 5528 5529 5530 5531 5532 5533 5534 5535 5536 5537 5538 5539 5540 5541 5542 5543 5544 5545 5546 5547 5548 5549 5550 5551 5552 5553 5554 5555 5556 5557 5558 5559 5560 5561 5562 5563 5564 5565 5566 5567 5568 5569 5570 5571 5572 5573 5574 5575 5576 5577 5578 5579 5580 5581 5582 5583 5584 5585 5586 5587 5588 5589 5590 5591 5592 5593 5594 5595 5596 5597 5598 5599 5600 5601 5602 5603 5604 5605 5606 5607 5608 5609 5610 5611 5612 5613 5614 5615 5616 5617 5618 5619 5620 5621 5622 5623 5624 5625 5626 5627 5628 5629 5630 5631 5632 5633 5634 5635 5636 5637 5638 5639 5640 5641 5642 5643 5644 5645 5646 5647 5648 5649 5650 5651 5652 5653 5654 5655 5656 5657 5658 5659 5660 5661 5662 5663 5664 5665 5666 5667 5668 5669 5670 5671 5672 5673 5674 5675 5676 5677 5678 5679 5680 5681 5682 5683 5684 5685 5686 5687 5688 5689 5690 5691 5692 5693 5694 5695 5696 5697 5698 5699 5700 5701 5702 5703 5704 5705 5706 5707 5708 5709 5710 5711 5712 5713 5714 5715 5716 5717 5718 5719 5720 5721 5722 5723 5724 5725 5726 5727 5728 5729 5730 5731 5732 5733 5734 5735 5736 5737 5738 5739 5740 5741 5742 5743 5744 5745 5746 5747 5748 5749 5750 5751 5752 5753 5754 5755 5756 5757 5758 5759 5760 5761 5762 5763 5764 5765 5766 5767 5768 5769 5770 5771 5772 5773 5774 5775 5776 5777 5778 5779 5780 5781 5782 5783 5784 5785 5786 5787 5788 5789 5790 5791 5792 5793 5794 5795 5796 5797 5798 5799 5800 5801 5802 5803 5804 5805 5806 5807 5808 5809 5810 5811 5812 5813 5814 5815 5816 5817 5818 5819 5820 5821 5822 5823 5824 5825 5826 5827 5828 5829 5830 5831 5832 5833 5834 5835 5836 5837 5838 5839 5840 5841 5842 5843 5844 5845 5846 5847 5848 5849 5850 5851 5852 5853 5854 5855 5856 5857 5858 5859 5860 5861 5862 5863 5864 5865 5866 5867 5868 5869 5870 5871 5872 5873 5874 5875 5876 5877 5878 5879 5880 5881 5882 5883 5884 5885 5886 5887 5888 5889 5890 5891 5892 5893 5894 5895 5896 5897 5898 5899 5900 5901 5902 5903 5904 5905 5906 5907 5908 5909 5910 5911 5912 5913 5914 5915 5916 5917 5918 5919 5920 5921 5922 5923 5924 5925 5926 5927 5928 5929 5930 5931 5932 5933 5934 5935 5936 5937 5938 5939 5940 5941 5942 5943 5944 5945 5946 5947 5948 5949 5950 5951 5952 5953 5954 5955 5956 5957 5958 5959 5960 5961 5962 5963 5964 5965 5966 5967 5968 5969 5970 5971 5972 5973 5974 5975 5976 5977 5978 5979 5980 5981 5982 5983 5984 5985 5986 5987 5988 5989 5990 5991 5992 5993 5994 5995 5996 5997 5998 5999 6000 6001 6002 6003 6004 6005 6006 6007 6008 6009 6010 6011 6012 6013 6014 6015 6016 6017 6018 6019 6020 6021 6022 6023 6024 6025 6026 6027 6028 6029 6030 6031 6032 6033 6034 6035 6036 6037 6038 6039 6040 6041 6042 6043 6044 6045 6046 6047 6048 6049 6050 6051 6052 6053 6054 6055 6056 6057 6058 6059 6060 6061 6062 6063 6064 6065 6066 6067 6068 6069 6070 6071 6072 6073 6074 6075 6076 6077 6078 6079 6080 6081 6082 6083 6084 6085 6086 6087 6088 6089 6090 6091 6092 6093 6094 6095 6096 6097 6098 6099 6100 6101 6102 6103 6104 6105 6106 6107 6108 6109 6110 6111 6112 6113 6114 6115 6116 6117 6118 6119 6120 6121 6122 6123 6124 6125 6126 6127 6128 6129 6130 6131 6132 6133 6134 6135 6136 6137 6138 6139 6140 6141 6142 6143 6144 6145 6146 6147 6148 6149 6150 6151 6152 6153 6154 6155 6156 6157 6158 6159 6160 6161 6162 6163 6164 6165 6166 6167 6168 6169 6170 6171 6172 6173 6174 6175 6176 6177 6178 6179 6180 6181 6182 6183 6184 6185 6186 6187 6188 6189 6190 6191 6192 6193 6194 6195 6196 6197 6198 6199 6200 6201 6202 6203 6204 6205 6206 6207 6208 6209 6210 6211 6212 6213 6214 6215 6216 6217 6218 6219 6220 6221 6222 6223 6224 6225 6226 6227 6228 6229 6230 6231 6232 6233 6234 6235 6236 6237 6238 6239 6240 6241 6242 6243 6244 6245 6246 6247 6248 6249 6250 6251 6252 6253 6254 6255 6256 6257 6258 6259 6260 6261 6262 6263 6264 6265 6266 6267 6268 6269 6270 6271 6272 6273 6274 6275 6276 6277 6278 6279 6280 6281 6282 6283 6284 6285 6286 6287 6288 6289 6290 6291 6292 6293 6294 6295 6296 6297 6298 6299 6300 6301 6302 6303 6304 6305 6306 6307 6308 6309 6310 6311 6312 6313 6314 6315 6316 6317 6318 6319 6320 6321 6322 6323 6324 6325 6326 6327 6328 6329 6330 6331 6332 6333 6334 6335 6336 6337 6338 6339 6340 6341 6342 6343 6344 6345 6346 6347 6348 6349 6350 6351 6352 6353 6354 6355 6356 6357 6358 6359 6360 6361 6362 6363 6364 6365 6366 6367 6368 6369 6370 6371 6372 6373 6374 6375 6376 6377 6378 6379 6380 6381 6382 6383 6384 6385 6386 6387 6388 6389 6390 6391 6392 6393 6394 6395 6396 6397 6398 6399 6400 6401 6402 6403 6404 6405 6406 6407 6408 6409 6410 6411 6412 6413 6414 6415 6416 6417 6418 6419 6420 6421 6422 6423 6424 6425 6426 6427 6428 6429 6430 6431 6432 6433 6434 6435 6436 6437 6438 6439 6440 6441 6442 6443 6444 6445 6446 6447 6448 6449 6450 6451 6452 6453 6454 6455 6456 6457 6458 6459 6460 6461 6462 6463 6464 6465 6466 6467 6468 6469 6470 6471 6472 6473 6474 6475 6476 6477 6478 6479 6480 6481 6482 6483 6484 6485 6486 6487 6488 6489 6490 6491 6492 6493 6494 6495 6496 6497 6498 6499 6500 6501 6502 6503 6504 6505 6506 6507 6508 6509 6510 6511 6512 6513 6514 6515 6516 6517 6518 6519 6520 6521 6522 6523 6524 6525 6526 6527 6528 6529 6530 6531 6532 6533 6534 6535 6536 6537 6538 6539 6540 6541 6542 6543 6544 6545 6546 6547 6548 6549 6550 6551 6552 6553 6554 6555 6556 6557 6558 6559 6560 6561 6562 6563 6564 6565 6566 6567 6568 6569 6570 6571 6572 6573 6574 6575 6576 6577 6578 6579 6580 6581 6582 6583 6584 6585 6586 6587 6588 6589 6590 6591 6592 6593 6594 6595 6596 6597 6598 6599 6600 6601 6602 6603 6604 6605 6606 6607 6608 6609 6610 6611 6612 6613 6614 6615 6616 6617 6618 6619 6620 6621 6622 6623 6624 6625 6626 6627 6628 6629 6630 6631 6632 6633 6634 6635 6636 6637 6638 6639 6640 6641 6642 6643 6644 6645 6646 6647 6648 6649 6650 6651 6652 6653 6654 6655 6656 6657 6658 6659 6660 6661 6662 6663 6664 6665 6666 6667 6668 6669 6670 6671 6672 6673 6674 6675 6676 6677 6678 6679 6680 6681 6682 6683 6684 6685 6686 6687 6688 6689 6690 6691 6692 6693 6694 6695 6696 6697 6698 6699 6700 6701 6702 6703 6704 6705 6706 6707 6708 6709 6710 6711 6712 6713 6714 6715 6716 6717 6718 6719 6720 6721 6722 6723 6724 6725 6726 6727 6728 6729 6730 6731 6732 6733 6734 6735 6736 6737 6738 6739 6740 6741 6742 6743 6744 6745 6746 6747 6748 6749 6750 6751 6752 6753 6754 6755 6756 6757 6758 6759 6760 6761 6762 6763 6764 6765 6766 6767 6768 6769 6770 6771 6772 6773 6774 6775 6776 6777 6778 6779 6780 6781 6782 6783 6784 6785 6786 6787 6788 6789 6790 6791 6792 6793 6794 6795 6796 6797 6798 6799 6800 6801 6802 6803 6804 6805 6806 6807 6808 6809 6810 6811 6812 6813 6814 6815 6816 6817 6818 6819 6820 6821 6822 6823 6824 6825 6826 6827 6828 6829 6830 6831 6832 6833 6834 6835 6836 6837 6838 6839 6840 6841 6842 6843 6844 6845 6846 6847 6848 6849 6850 6851 6852 6853 6854 6855 6856 6857 6858 6859 6860 6861 6862 6863 6864 6865 6866 6867 6868 6869 6870 6871 6872 6873 6874 6875 6876 6877 6878 6879 6880 6881 6882 6883 6884 6885 6886 6887 6888 6889 6890 6891 6892 6893 6894 6895 6896 6897 6898 6899 6900 6901 6902 6903 6904 6905 6906 6907 6908 6909 6910 6911 6912 6913 6914 6915 6916 6917 6918 6919 6920 6921 6922 6923 6924 6925 6926 6927 6928 6929 6930 6931 6932 6933 6934 6935 6936 6937 6938 6939 6940 6941 6942 6943 6944 6945 6946 6947 6948 6949 6950 6951 6952 6953 6954 6955 6956 6957 6958 6959 6960 6961 6962 6963 6964 6965 6966 6967 6968 6969 6970 6971 6972 6973 6974 6975 6976 6977 6978 6979 6980 6981 6982 6983 6984 6985 6986 6987 6988 6989 6990 6991 6992 6993 6994 6995 6996 6997 6998 6999 7000 7001 7002 7003 7004 7005 7006 7007 7008 7009 7010 7011 7012 7013 7014 7015 7016 7017 7018 7019 7020 7021 7022 7023 7024 7025 7026 7027 7028 7029 7030 7031 7032 7033 7034 7035 7036 7037 7038 7039 7040 7041 7042 7043 7044 7045 7046 7047 7048 7049 7050 7051 7052 7053 7054 7055 7056 7057 7058 7059 7060 7061 7062 7063 7064 7065 7066 7067 7068 7069 7070 7071 7072 7073 7074 7075 7076 7077 7078 7079 7080 7081 7082 7083 7084 7085 7086 7087 7088 7089 7090 7091 7092 7093 7094 7095 7096 7097 7098 7099 7100 7101 7102 7103 7104 7105 7106 7107 7108 7109 7110 7111 7112 7113 7114 7115 7116 7117 7118 7119 7120 7121 7122 7123 7124 7125 7126 7127 7128 7129 7130 7131 7132 7133 7134 7135 7136 7137 7138 7139 7140 7141 7142 7143 7144 7145 7146 7147 7148 7149 7150 7151 7152 7153 7154 7155 7156 7157 7158 7159 7160 7161 7162 7163 7164 7165 7166 7167 7168 7169 7170 7171 7172 7173 7174 7175 7176 7177 7178 7179 7180 7181 7182 7183 7184 7185 7186 7187 7188 7189 7190 7191 7192 7193 7194 7195 7196 7197 7198 7199 7200 7201 7202 7203 7204 7205 7206 7207 7208 7209 7210 7211 7212 7213 7214 7215 7216 7217 7218 7219 7220 7221 7222 7223 7224 7225 7226 7227 7228 7229 7230 7231 7232 7233 7234 7235 7236 7237 7238 7239 7240 7241 7242 7243 7244 7245 7246 7247 7248 7249 7250 7251 7252 7253 7254 7255 7256 7257 7258 7259 7260 7261 7262 7263 7264 7265 7266 7267 7268 7269 7270 7271 7272 7273 7274 7275 7276 7277 7278 7279 7280 7281 7282 7283 7284 7285 7286 7287 7288 7289 7290 7291 7292 7293 7294 7295 7296 7297 7298 7299 7300 7301 7302 7303 7304 7305 7306 7307 7308 7309 7310 7311 7312 7313 7314 7315 7316 7317 7318 7319 7320 7321 7322 7323 7324 7325 7326 7327 7328 7329 7330 7331 7332 7333 7334 7335 7336 7337 7338 7339 7340 7341 7342 7343 7344 7345 7346 7347 7348 7349 7350 7351 7352 7353 7354 7355 7356 7357 7358 7359 7360 7361 7362 7363 7364 7365 7366 7367 7368 7369 7370 7371 7372 7373 7374 7375 7376 7377 7378 7379 7380 7381 7382 7383 7384 7385 7386 7387 7388 7389 7390 7391 7392 7393 7394 7395 7396 7397 7398 7399 7400 7401 7402 7403 7404 7405 7406 7407 7408 7409 7410 7411 7412 7413 7414 7415 7416 7417 7418 7419 7420 7421 7422 7423 7424 7425 7426 7427 7428 7429 7430 7431 7432 7433 7434 7435 7436 7437 7438 7439 7440 7441 7442 7443 7444 7445 7446 7447 7448 7449 7450 7451 7452 7453 7454 7455 7456 7457 7458 7459 7460 7461 7462 7463 7464 7465 7466 7467 7468 7469 7470 7471 7472 7473 7474 7475 7476 7477 7478 7479 7480 7481 7482 7483 7484 7485 7486 7487 7488 7489 7490 7491 7492 7493 7494 7495 7496 7497 7498 7499 7500 7501 7502 7503 7504 7505 7506 7507 7508 7509 7510 7511 7512 7513 7514 7515 7516 7517 7518 7519 7520 7521 7522 7523 7524 7525 7526 7527 7528 7529 7530 7531 7532 7533 7534 7535 7536 7537 7538 7539 7540 7541 7542 7543 7544 7545 7546 7547 7548 7549 7550 7551 7552 7553 7554 7555 7556 7557 7558 7559 7560 7561 7562 7563 7564 7565 7566 7567 7568 7569 7570 7571 7572 7573 7574 7575 7576 7577 7578 7579 7580 7581 7582 7583 7584 7585 7586 7587 7588 7589 7590 7591 7592 7593 7594 7595 7596 7597 7598 7599 7600 7601 7602 7603 7604 7605 7606 7607 7608 7609 7610 7611 7612 7613 7614 7615 7616 7617 7618 7619 7620 7621 7622 7623 7624 7625 7626 7627 7628 7629 7630 7631 7632 7633 7634 7635 7636 7637 7638 7639 7640 7641 7642 7643 7644 7645 7646 7647 7648 7649 7650 7651 7652 7653 7654 7655 7656 7657 7658 7659 7660 7661 7662 7663 7664 7665 7666 7667 7668 7669 7670 7671 7672 7673 7674 7675 7676 7677 7678 7679 7680 7681 7682 7683 7684 7685 7686 7687 7688 7689 7690 7691 7692 7693 7694 7695 7696 7697 7698 7699 7700 7701 7702 7703 7704 7705 7706 7707 7708 7709 7710 7711 7712 7713 7714 7715 7716 7717 7718 7719 7720 7721 7722 7723 7724 7725 7726 7727 7728 7729 7730 7731 7732 7733 7734 7735 7736 7737 7738 7739 7740 7741 7742 7743 7744 7745 7746 7747 7748 7749 7750 7751 7752 7753 7754 7755 7756 7757 7758 7759 7760 7761 7762 7763 7764 7765 7766 7767 7768 7769 7770 7771 7772 7773 7774 7775 7776 7777 7778 7779 7780 7781 7782 7783 7784 7785 7786 7787 7788 7789 7790 7791 7792 7793 7794 7795 7796 7797 7798 7799 7800 7801 7802 7803 7804 7805 7806 7807 7808 7809 7810 7811 7812 7813 7814 7815 7816 7817 7818 7819 7820 7821 7822 7823 7824 7825 7826 7827 7828 7829 7830 7831 7832 7833 7834 7835 7836 7837 7838 7839 7840 7841 7842 7843 7844 7845 7846 7847 7848 7849 7850 7851 7852 7853 7854 7855 7856 7857 7858 7859 7860 7861 7862 7863 7864 7865 7866 7867 7868 7869 7870 7871 7872 7873 7874 7875 7876 7877 7878 7879 7880 7881 7882 7883 7884 7885 7886 7887 7888 7889 7890 7891 7892 7893 7894 7895 7896 7897 7898 7899 7900 7901 7902 7903 7904 7905 7906 7907 7908 7909 7910 7911 7912 7913 7914 7915 7916 7917 7918 7919 7920 7921 7922 7923 7924 7925 7926 7927 7928 7929 7930 7931 7932 7933 7934 7935 7936 7937 7938 7939 7940 7941 7942 7943 7944 7945 7946 7947 7948 7949 7950 7951 7952 7953 7954 7955 7956 7957 7958 7959 7960 7961 7962 7963 7964 7965 7966 7967 7968 7969 7970 7971 7972 7973 7974 7975 7976 7977 7978 7979 7980 7981 7982 7983 7984 7985 7986 7987 7988 7989 7990 7991 7992 7993 7994 7995 7996 7997 7998 7999 8000 8001 8002 8003 8004 8005 8006 8007 8008 8009 8010 8011 8012 8013 8014 8015 8016 8017 8018 8019 8020 8021 8022 8023 8024 8025 8026 8027 8028 8029 8030 8031 8032 8033 8034 8035 8036 8037 8038 8039 8040 8041 8042 8043 8044 8045 8046 8047 8048 8049 8050 8051 8052 8053 8054 8055 8056 8057 8058 8059 8060 8061 8062 8063 8064 8065 8066 8067 8068 8069 8070 8071 8072 8073 8074 8075 8076 8077 8078 8079 8080 8081 8082 8083 8084 8085 8086 8087 8088 8089 8090 8091 8092 8093 8094 8095 8096 8097 8098 8099 8100 8101 8102 8103 8104 8105 8106 8107 8108 8109 8110 8111 8112 8113 8114 8115 8116 8117 8118 8119 8120 8121 8122 8123 8124 8125 8126
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
/// <p>A complex type that contains settings for the new traffic policy instance.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct TrafficPolicyInstance {
/// <p>The ID that Amazon Route 53 assigned to the new traffic policy instance.</p>
pub id: std::option::Option<std::string::String>,
/// <p>The ID of the hosted zone that Amazon Route 53 created resource record sets in.</p>
pub hosted_zone_id: std::option::Option<std::string::String>,
/// <p>The DNS name, such as www.example.com, for which Amazon Route 53 responds to queries by using the resource record sets that are associated with this traffic policy instance. </p>
pub name: std::option::Option<std::string::String>,
/// <p>The TTL that Amazon Route 53 assigned to all of the resource record sets that it created in the specified hosted zone.</p>
pub ttl: std::option::Option<i64>,
/// <p>The value of <code>State</code> is one of the following values:</p>
/// <dl>
/// <dt>
/// Applied
/// </dt>
/// <dd>
/// <p>Amazon Route 53 has finished creating resource record sets, and changes have propagated to all Route 53 edge locations.</p>
/// </dd>
/// <dt>
/// Creating
/// </dt>
/// <dd>
/// <p>Route 53 is creating the resource record sets. Use <code>GetTrafficPolicyInstance</code> to confirm that the <code>CreateTrafficPolicyInstance</code> request completed successfully.</p>
/// </dd>
/// <dt>
/// Failed
/// </dt>
/// <dd>
/// <p>Route 53 wasn't able to create or update the resource record sets. When the value of <code>State</code> is <code>Failed</code>, see <code>Message</code> for an explanation of what caused the request to fail.</p>
/// </dd>
/// </dl>
pub state: std::option::Option<std::string::String>,
/// <p>If <code>State</code> is <code>Failed</code>, an explanation of the reason for the failure. If <code>State</code> is another value, <code>Message</code> is empty.</p>
pub message: std::option::Option<std::string::String>,
/// <p>The ID of the traffic policy that Amazon Route 53 used to create resource record sets in the specified hosted zone.</p>
pub traffic_policy_id: std::option::Option<std::string::String>,
/// <p>The version of the traffic policy that Amazon Route 53 used to create resource record sets in the specified hosted zone.</p>
pub traffic_policy_version: std::option::Option<i32>,
/// <p>The DNS type that Amazon Route 53 assigned to all of the resource record sets that it created for this traffic policy instance. </p>
pub traffic_policy_type: std::option::Option<crate::model::RrType>,
}
impl TrafficPolicyInstance {
/// <p>The ID that Amazon Route 53 assigned to the new traffic policy instance.</p>
pub fn id(&self) -> std::option::Option<&str> {
self.id.as_deref()
}
/// <p>The ID of the hosted zone that Amazon Route 53 created resource record sets in.</p>
pub fn hosted_zone_id(&self) -> std::option::Option<&str> {
self.hosted_zone_id.as_deref()
}
/// <p>The DNS name, such as www.example.com, for which Amazon Route 53 responds to queries by using the resource record sets that are associated with this traffic policy instance. </p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>The TTL that Amazon Route 53 assigned to all of the resource record sets that it created in the specified hosted zone.</p>
pub fn ttl(&self) -> std::option::Option<i64> {
self.ttl
}
/// <p>The value of <code>State</code> is one of the following values:</p>
/// <dl>
/// <dt>
/// Applied
/// </dt>
/// <dd>
/// <p>Amazon Route 53 has finished creating resource record sets, and changes have propagated to all Route 53 edge locations.</p>
/// </dd>
/// <dt>
/// Creating
/// </dt>
/// <dd>
/// <p>Route 53 is creating the resource record sets. Use <code>GetTrafficPolicyInstance</code> to confirm that the <code>CreateTrafficPolicyInstance</code> request completed successfully.</p>
/// </dd>
/// <dt>
/// Failed
/// </dt>
/// <dd>
/// <p>Route 53 wasn't able to create or update the resource record sets. When the value of <code>State</code> is <code>Failed</code>, see <code>Message</code> for an explanation of what caused the request to fail.</p>
/// </dd>
/// </dl>
pub fn state(&self) -> std::option::Option<&str> {
self.state.as_deref()
}
/// <p>If <code>State</code> is <code>Failed</code>, an explanation of the reason for the failure. If <code>State</code> is another value, <code>Message</code> is empty.</p>
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
/// <p>The ID of the traffic policy that Amazon Route 53 used to create resource record sets in the specified hosted zone.</p>
pub fn traffic_policy_id(&self) -> std::option::Option<&str> {
self.traffic_policy_id.as_deref()
}
/// <p>The version of the traffic policy that Amazon Route 53 used to create resource record sets in the specified hosted zone.</p>
pub fn traffic_policy_version(&self) -> std::option::Option<i32> {
self.traffic_policy_version
}
/// <p>The DNS type that Amazon Route 53 assigned to all of the resource record sets that it created for this traffic policy instance. </p>
pub fn traffic_policy_type(&self) -> std::option::Option<&crate::model::RrType> {
self.traffic_policy_type.as_ref()
}
}
impl std::fmt::Debug for TrafficPolicyInstance {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("TrafficPolicyInstance");
formatter.field("id", &self.id);
formatter.field("hosted_zone_id", &self.hosted_zone_id);
formatter.field("name", &self.name);
formatter.field("ttl", &self.ttl);
formatter.field("state", &self.state);
formatter.field("message", &self.message);
formatter.field("traffic_policy_id", &self.traffic_policy_id);
formatter.field("traffic_policy_version", &self.traffic_policy_version);
formatter.field("traffic_policy_type", &self.traffic_policy_type);
formatter.finish()
}
}
/// See [`TrafficPolicyInstance`](crate::model::TrafficPolicyInstance)
pub mod traffic_policy_instance {
/// A builder for [`TrafficPolicyInstance`](crate::model::TrafficPolicyInstance)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) id: std::option::Option<std::string::String>,
pub(crate) hosted_zone_id: std::option::Option<std::string::String>,
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) ttl: std::option::Option<i64>,
pub(crate) state: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) traffic_policy_id: std::option::Option<std::string::String>,
pub(crate) traffic_policy_version: std::option::Option<i32>,
pub(crate) traffic_policy_type: std::option::Option<crate::model::RrType>,
}
impl Builder {
/// <p>The ID that Amazon Route 53 assigned to the new traffic policy instance.</p>
pub fn id(mut self, input: impl Into<std::string::String>) -> Self {
self.id = Some(input.into());
self
}
/// <p>The ID that Amazon Route 53 assigned to the new traffic policy instance.</p>
pub fn set_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.id = input;
self
}
/// <p>The ID of the hosted zone that Amazon Route 53 created resource record sets in.</p>
pub fn hosted_zone_id(mut self, input: impl Into<std::string::String>) -> Self {
self.hosted_zone_id = Some(input.into());
self
}
/// <p>The ID of the hosted zone that Amazon Route 53 created resource record sets in.</p>
pub fn set_hosted_zone_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.hosted_zone_id = input;
self
}
/// <p>The DNS name, such as www.example.com, for which Amazon Route 53 responds to queries by using the resource record sets that are associated with this traffic policy instance. </p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The DNS name, such as www.example.com, for which Amazon Route 53 responds to queries by using the resource record sets that are associated with this traffic policy instance. </p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// <p>The TTL that Amazon Route 53 assigned to all of the resource record sets that it created in the specified hosted zone.</p>
pub fn ttl(mut self, input: i64) -> Self {
self.ttl = Some(input);
self
}
/// <p>The TTL that Amazon Route 53 assigned to all of the resource record sets that it created in the specified hosted zone.</p>
pub fn set_ttl(mut self, input: std::option::Option<i64>) -> Self {
self.ttl = input;
self
}
/// <p>The value of <code>State</code> is one of the following values:</p>
/// <dl>
/// <dt>
/// Applied
/// </dt>
/// <dd>
/// <p>Amazon Route 53 has finished creating resource record sets, and changes have propagated to all Route 53 edge locations.</p>
/// </dd>
/// <dt>
/// Creating
/// </dt>
/// <dd>
/// <p>Route 53 is creating the resource record sets. Use <code>GetTrafficPolicyInstance</code> to confirm that the <code>CreateTrafficPolicyInstance</code> request completed successfully.</p>
/// </dd>
/// <dt>
/// Failed
/// </dt>
/// <dd>
/// <p>Route 53 wasn't able to create or update the resource record sets. When the value of <code>State</code> is <code>Failed</code>, see <code>Message</code> for an explanation of what caused the request to fail.</p>
/// </dd>
/// </dl>
pub fn state(mut self, input: impl Into<std::string::String>) -> Self {
self.state = Some(input.into());
self
}
/// <p>The value of <code>State</code> is one of the following values:</p>
/// <dl>
/// <dt>
/// Applied
/// </dt>
/// <dd>
/// <p>Amazon Route 53 has finished creating resource record sets, and changes have propagated to all Route 53 edge locations.</p>
/// </dd>
/// <dt>
/// Creating
/// </dt>
/// <dd>
/// <p>Route 53 is creating the resource record sets. Use <code>GetTrafficPolicyInstance</code> to confirm that the <code>CreateTrafficPolicyInstance</code> request completed successfully.</p>
/// </dd>
/// <dt>
/// Failed
/// </dt>
/// <dd>
/// <p>Route 53 wasn't able to create or update the resource record sets. When the value of <code>State</code> is <code>Failed</code>, see <code>Message</code> for an explanation of what caused the request to fail.</p>
/// </dd>
/// </dl>
pub fn set_state(mut self, input: std::option::Option<std::string::String>) -> Self {
self.state = input;
self
}
/// <p>If <code>State</code> is <code>Failed</code>, an explanation of the reason for the failure. If <code>State</code> is another value, <code>Message</code> is empty.</p>
pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
self.message = Some(input.into());
self
}
/// <p>If <code>State</code> is <code>Failed</code>, an explanation of the reason for the failure. If <code>State</code> is another value, <code>Message</code> is empty.</p>
pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
self.message = input;
self
}
/// <p>The ID of the traffic policy that Amazon Route 53 used to create resource record sets in the specified hosted zone.</p>
pub fn traffic_policy_id(mut self, input: impl Into<std::string::String>) -> Self {
self.traffic_policy_id = Some(input.into());
self
}
/// <p>The ID of the traffic policy that Amazon Route 53 used to create resource record sets in the specified hosted zone.</p>
pub fn set_traffic_policy_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.traffic_policy_id = input;
self
}
/// <p>The version of the traffic policy that Amazon Route 53 used to create resource record sets in the specified hosted zone.</p>
pub fn traffic_policy_version(mut self, input: i32) -> Self {
self.traffic_policy_version = Some(input);
self
}
/// <p>The version of the traffic policy that Amazon Route 53 used to create resource record sets in the specified hosted zone.</p>
pub fn set_traffic_policy_version(mut self, input: std::option::Option<i32>) -> Self {
self.traffic_policy_version = input;
self
}
/// <p>The DNS type that Amazon Route 53 assigned to all of the resource record sets that it created for this traffic policy instance. </p>
pub fn traffic_policy_type(mut self, input: crate::model::RrType) -> Self {
self.traffic_policy_type = Some(input);
self
}
/// <p>The DNS type that Amazon Route 53 assigned to all of the resource record sets that it created for this traffic policy instance. </p>
pub fn set_traffic_policy_type(
mut self,
input: std::option::Option<crate::model::RrType>,
) -> Self {
self.traffic_policy_type = input;
self
}
/// Consumes the builder and constructs a [`TrafficPolicyInstance`](crate::model::TrafficPolicyInstance)
pub fn build(self) -> crate::model::TrafficPolicyInstance {
crate::model::TrafficPolicyInstance {
id: self.id,
hosted_zone_id: self.hosted_zone_id,
name: self.name,
ttl: self.ttl,
state: self.state,
message: self.message,
traffic_policy_id: self.traffic_policy_id,
traffic_policy_version: self.traffic_policy_version,
traffic_policy_type: self.traffic_policy_type,
}
}
}
}
impl TrafficPolicyInstance {
/// Creates a new builder-style object to manufacture [`TrafficPolicyInstance`](crate::model::TrafficPolicyInstance)
pub fn builder() -> crate::model::traffic_policy_instance::Builder {
crate::model::traffic_policy_instance::Builder::default()
}
}
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum RrType {
#[allow(missing_docs)] // documentation missing in model
A,
#[allow(missing_docs)] // documentation missing in model
Aaaa,
#[allow(missing_docs)] // documentation missing in model
Caa,
#[allow(missing_docs)] // documentation missing in model
Cname,
#[allow(missing_docs)] // documentation missing in model
Ds,
#[allow(missing_docs)] // documentation missing in model
Mx,
#[allow(missing_docs)] // documentation missing in model
Naptr,
#[allow(missing_docs)] // documentation missing in model
Ns,
#[allow(missing_docs)] // documentation missing in model
Ptr,
#[allow(missing_docs)] // documentation missing in model
Soa,
#[allow(missing_docs)] // documentation missing in model
Spf,
#[allow(missing_docs)] // documentation missing in model
Srv,
#[allow(missing_docs)] // documentation missing in model
Txt,
/// Unknown contains new variants that have been added since this code was generated.
Unknown(String),
}
impl std::convert::From<&str> for RrType {
fn from(s: &str) -> Self {
match s {
"A" => RrType::A,
"AAAA" => RrType::Aaaa,
"CAA" => RrType::Caa,
"CNAME" => RrType::Cname,
"DS" => RrType::Ds,
"MX" => RrType::Mx,
"NAPTR" => RrType::Naptr,
"NS" => RrType::Ns,
"PTR" => RrType::Ptr,
"SOA" => RrType::Soa,
"SPF" => RrType::Spf,
"SRV" => RrType::Srv,
"TXT" => RrType::Txt,
other => RrType::Unknown(other.to_owned()),
}
}
}
impl std::str::FromStr for RrType {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(RrType::from(s))
}
}
impl RrType {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
RrType::A => "A",
RrType::Aaaa => "AAAA",
RrType::Caa => "CAA",
RrType::Cname => "CNAME",
RrType::Ds => "DS",
RrType::Mx => "MX",
RrType::Naptr => "NAPTR",
RrType::Ns => "NS",
RrType::Ptr => "PTR",
RrType::Soa => "SOA",
RrType::Spf => "SPF",
RrType::Srv => "SRV",
RrType::Txt => "TXT",
RrType::Unknown(s) => s.as_ref(),
}
}
/// Returns all the `&str` values of the enum members.
pub fn values() -> &'static [&'static str] {
&[
"A", "AAAA", "CAA", "CNAME", "DS", "MX", "NAPTR", "NS", "PTR", "SOA", "SPF", "SRV",
"TXT",
]
}
}
impl AsRef<str> for RrType {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>A complex type that contains settings for a traffic policy.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct TrafficPolicy {
/// <p>The ID that Amazon Route 53 assigned to a traffic policy when you created it.</p>
pub id: std::option::Option<std::string::String>,
/// <p>The version number that Amazon Route 53 assigns to a traffic policy. For a new traffic policy, the value of <code>Version</code> is always 1.</p>
pub version: std::option::Option<i32>,
/// <p>The name that you specified when you created the traffic policy.</p>
pub name: std::option::Option<std::string::String>,
/// <p>The DNS type of the resource record sets that Amazon Route 53 creates when you use a traffic policy to create a traffic policy instance.</p>
pub r#type: std::option::Option<crate::model::RrType>,
/// <p>The definition of a traffic policy in JSON format. You specify the JSON document to use for a new traffic policy in the <code>CreateTrafficPolicy</code> request. For more information about the JSON format, see <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/api-policies-traffic-policy-document-format.html">Traffic Policy Document Format</a>.</p>
pub document: std::option::Option<std::string::String>,
/// <p>The comment that you specify in the <code>CreateTrafficPolicy</code> request, if any.</p>
pub comment: std::option::Option<std::string::String>,
}
impl TrafficPolicy {
/// <p>The ID that Amazon Route 53 assigned to a traffic policy when you created it.</p>
pub fn id(&self) -> std::option::Option<&str> {
self.id.as_deref()
}
/// <p>The version number that Amazon Route 53 assigns to a traffic policy. For a new traffic policy, the value of <code>Version</code> is always 1.</p>
pub fn version(&self) -> std::option::Option<i32> {
self.version
}
/// <p>The name that you specified when you created the traffic policy.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>The DNS type of the resource record sets that Amazon Route 53 creates when you use a traffic policy to create a traffic policy instance.</p>
pub fn r#type(&self) -> std::option::Option<&crate::model::RrType> {
self.r#type.as_ref()
}
/// <p>The definition of a traffic policy in JSON format. You specify the JSON document to use for a new traffic policy in the <code>CreateTrafficPolicy</code> request. For more information about the JSON format, see <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/api-policies-traffic-policy-document-format.html">Traffic Policy Document Format</a>.</p>
pub fn document(&self) -> std::option::Option<&str> {
self.document.as_deref()
}
/// <p>The comment that you specify in the <code>CreateTrafficPolicy</code> request, if any.</p>
pub fn comment(&self) -> std::option::Option<&str> {
self.comment.as_deref()
}
}
impl std::fmt::Debug for TrafficPolicy {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("TrafficPolicy");
formatter.field("id", &self.id);
formatter.field("version", &self.version);
formatter.field("name", &self.name);
formatter.field("r#type", &self.r#type);
formatter.field("document", &self.document);
formatter.field("comment", &self.comment);
formatter.finish()
}
}
/// See [`TrafficPolicy`](crate::model::TrafficPolicy)
pub mod traffic_policy {
/// A builder for [`TrafficPolicy`](crate::model::TrafficPolicy)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) id: std::option::Option<std::string::String>,
pub(crate) version: std::option::Option<i32>,
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) r#type: std::option::Option<crate::model::RrType>,
pub(crate) document: std::option::Option<std::string::String>,
pub(crate) comment: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The ID that Amazon Route 53 assigned to a traffic policy when you created it.</p>
pub fn id(mut self, input: impl Into<std::string::String>) -> Self {
self.id = Some(input.into());
self
}
/// <p>The ID that Amazon Route 53 assigned to a traffic policy when you created it.</p>
pub fn set_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.id = input;
self
}
/// <p>The version number that Amazon Route 53 assigns to a traffic policy. For a new traffic policy, the value of <code>Version</code> is always 1.</p>
pub fn version(mut self, input: i32) -> Self {
self.version = Some(input);
self
}
/// <p>The version number that Amazon Route 53 assigns to a traffic policy. For a new traffic policy, the value of <code>Version</code> is always 1.</p>
pub fn set_version(mut self, input: std::option::Option<i32>) -> Self {
self.version = input;
self
}
/// <p>The name that you specified when you created the traffic policy.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The name that you specified when you created the traffic policy.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// <p>The DNS type of the resource record sets that Amazon Route 53 creates when you use a traffic policy to create a traffic policy instance.</p>
pub fn r#type(mut self, input: crate::model::RrType) -> Self {
self.r#type = Some(input);
self
}
/// <p>The DNS type of the resource record sets that Amazon Route 53 creates when you use a traffic policy to create a traffic policy instance.</p>
pub fn set_type(mut self, input: std::option::Option<crate::model::RrType>) -> Self {
self.r#type = input;
self
}
/// <p>The definition of a traffic policy in JSON format. You specify the JSON document to use for a new traffic policy in the <code>CreateTrafficPolicy</code> request. For more information about the JSON format, see <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/api-policies-traffic-policy-document-format.html">Traffic Policy Document Format</a>.</p>
pub fn document(mut self, input: impl Into<std::string::String>) -> Self {
self.document = Some(input.into());
self
}
/// <p>The definition of a traffic policy in JSON format. You specify the JSON document to use for a new traffic policy in the <code>CreateTrafficPolicy</code> request. For more information about the JSON format, see <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/api-policies-traffic-policy-document-format.html">Traffic Policy Document Format</a>.</p>
pub fn set_document(mut self, input: std::option::Option<std::string::String>) -> Self {
self.document = input;
self
}
/// <p>The comment that you specify in the <code>CreateTrafficPolicy</code> request, if any.</p>
pub fn comment(mut self, input: impl Into<std::string::String>) -> Self {
self.comment = Some(input.into());
self
}
/// <p>The comment that you specify in the <code>CreateTrafficPolicy</code> request, if any.</p>
pub fn set_comment(mut self, input: std::option::Option<std::string::String>) -> Self {
self.comment = input;
self
}
/// Consumes the builder and constructs a [`TrafficPolicy`](crate::model::TrafficPolicy)
pub fn build(self) -> crate::model::TrafficPolicy {
crate::model::TrafficPolicy {
id: self.id,
version: self.version,
name: self.name,
r#type: self.r#type,
document: self.document,
comment: self.comment,
}
}
}
}
impl TrafficPolicy {
/// Creates a new builder-style object to manufacture [`TrafficPolicy`](crate::model::TrafficPolicy)
pub fn builder() -> crate::model::traffic_policy::Builder {
crate::model::traffic_policy::Builder::default()
}
}
/// <p>A complex type that contains general information about the hosted zone.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct HostedZone {
/// <p>The ID that Amazon Route 53 assigned to the hosted zone when you created it.</p>
pub id: std::option::Option<std::string::String>,
/// <p>The name of the domain. For public hosted zones, this is the name that you have registered with your DNS registrar.</p>
/// <p>For information about how to specify characters other than <code>a-z</code>, <code>0-9</code>, and <code>-</code> (hyphen) and how to specify internationalized domain names, see <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_CreateHostedZone.html">CreateHostedZone</a>.</p>
pub name: std::option::Option<std::string::String>,
/// <p>The value that you specified for <code>CallerReference</code> when you created the hosted zone.</p>
pub caller_reference: std::option::Option<std::string::String>,
/// <p>A complex type that includes the <code>Comment</code> and <code>PrivateZone</code> elements. If you omitted the <code>HostedZoneConfig</code> and <code>Comment</code> elements from the request, the <code>Config</code> and <code>Comment</code> elements don't appear in the response.</p>
pub config: std::option::Option<crate::model::HostedZoneConfig>,
/// <p>The number of resource record sets in the hosted zone.</p>
pub resource_record_set_count: std::option::Option<i64>,
/// <p>If the hosted zone was created by another service, the service that created the hosted zone. When a hosted zone is created by another service, you can't edit or delete it using Route 53. </p>
pub linked_service: std::option::Option<crate::model::LinkedService>,
}
impl HostedZone {
/// <p>The ID that Amazon Route 53 assigned to the hosted zone when you created it.</p>
pub fn id(&self) -> std::option::Option<&str> {
self.id.as_deref()
}
/// <p>The name of the domain. For public hosted zones, this is the name that you have registered with your DNS registrar.</p>
/// <p>For information about how to specify characters other than <code>a-z</code>, <code>0-9</code>, and <code>-</code> (hyphen) and how to specify internationalized domain names, see <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_CreateHostedZone.html">CreateHostedZone</a>.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>The value that you specified for <code>CallerReference</code> when you created the hosted zone.</p>
pub fn caller_reference(&self) -> std::option::Option<&str> {
self.caller_reference.as_deref()
}
/// <p>A complex type that includes the <code>Comment</code> and <code>PrivateZone</code> elements. If you omitted the <code>HostedZoneConfig</code> and <code>Comment</code> elements from the request, the <code>Config</code> and <code>Comment</code> elements don't appear in the response.</p>
pub fn config(&self) -> std::option::Option<&crate::model::HostedZoneConfig> {
self.config.as_ref()
}
/// <p>The number of resource record sets in the hosted zone.</p>
pub fn resource_record_set_count(&self) -> std::option::Option<i64> {
self.resource_record_set_count
}
/// <p>If the hosted zone was created by another service, the service that created the hosted zone. When a hosted zone is created by another service, you can't edit or delete it using Route 53. </p>
pub fn linked_service(&self) -> std::option::Option<&crate::model::LinkedService> {
self.linked_service.as_ref()
}
}
impl std::fmt::Debug for HostedZone {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("HostedZone");
formatter.field("id", &self.id);
formatter.field("name", &self.name);
formatter.field("caller_reference", &self.caller_reference);
formatter.field("config", &self.config);
formatter.field("resource_record_set_count", &self.resource_record_set_count);
formatter.field("linked_service", &self.linked_service);
formatter.finish()
}
}
/// See [`HostedZone`](crate::model::HostedZone)
pub mod hosted_zone {
/// A builder for [`HostedZone`](crate::model::HostedZone)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) id: std::option::Option<std::string::String>,
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) caller_reference: std::option::Option<std::string::String>,
pub(crate) config: std::option::Option<crate::model::HostedZoneConfig>,
pub(crate) resource_record_set_count: std::option::Option<i64>,
pub(crate) linked_service: std::option::Option<crate::model::LinkedService>,
}
impl Builder {
/// <p>The ID that Amazon Route 53 assigned to the hosted zone when you created it.</p>
pub fn id(mut self, input: impl Into<std::string::String>) -> Self {
self.id = Some(input.into());
self
}
/// <p>The ID that Amazon Route 53 assigned to the hosted zone when you created it.</p>
pub fn set_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.id = input;
self
}
/// <p>The name of the domain. For public hosted zones, this is the name that you have registered with your DNS registrar.</p>
/// <p>For information about how to specify characters other than <code>a-z</code>, <code>0-9</code>, and <code>-</code> (hyphen) and how to specify internationalized domain names, see <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_CreateHostedZone.html">CreateHostedZone</a>.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The name of the domain. For public hosted zones, this is the name that you have registered with your DNS registrar.</p>
/// <p>For information about how to specify characters other than <code>a-z</code>, <code>0-9</code>, and <code>-</code> (hyphen) and how to specify internationalized domain names, see <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_CreateHostedZone.html">CreateHostedZone</a>.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// <p>The value that you specified for <code>CallerReference</code> when you created the hosted zone.</p>
pub fn caller_reference(mut self, input: impl Into<std::string::String>) -> Self {
self.caller_reference = Some(input.into());
self
}
/// <p>The value that you specified for <code>CallerReference</code> when you created the hosted zone.</p>
pub fn set_caller_reference(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.caller_reference = input;
self
}
/// <p>A complex type that includes the <code>Comment</code> and <code>PrivateZone</code> elements. If you omitted the <code>HostedZoneConfig</code> and <code>Comment</code> elements from the request, the <code>Config</code> and <code>Comment</code> elements don't appear in the response.</p>
pub fn config(mut self, input: crate::model::HostedZoneConfig) -> Self {
self.config = Some(input);
self
}
/// <p>A complex type that includes the <code>Comment</code> and <code>PrivateZone</code> elements. If you omitted the <code>HostedZoneConfig</code> and <code>Comment</code> elements from the request, the <code>Config</code> and <code>Comment</code> elements don't appear in the response.</p>
pub fn set_config(
mut self,
input: std::option::Option<crate::model::HostedZoneConfig>,
) -> Self {
self.config = input;
self
}
/// <p>The number of resource record sets in the hosted zone.</p>
pub fn resource_record_set_count(mut self, input: i64) -> Self {
self.resource_record_set_count = Some(input);
self
}
/// <p>The number of resource record sets in the hosted zone.</p>
pub fn set_resource_record_set_count(mut self, input: std::option::Option<i64>) -> Self {
self.resource_record_set_count = input;
self
}
/// <p>If the hosted zone was created by another service, the service that created the hosted zone. When a hosted zone is created by another service, you can't edit or delete it using Route 53. </p>
pub fn linked_service(mut self, input: crate::model::LinkedService) -> Self {
self.linked_service = Some(input);
self
}
/// <p>If the hosted zone was created by another service, the service that created the hosted zone. When a hosted zone is created by another service, you can't edit or delete it using Route 53. </p>
pub fn set_linked_service(
mut self,
input: std::option::Option<crate::model::LinkedService>,
) -> Self {
self.linked_service = input;
self
}
/// Consumes the builder and constructs a [`HostedZone`](crate::model::HostedZone)
pub fn build(self) -> crate::model::HostedZone {
crate::model::HostedZone {
id: self.id,
name: self.name,
caller_reference: self.caller_reference,
config: self.config,
resource_record_set_count: self.resource_record_set_count,
linked_service: self.linked_service,
}
}
}
}
impl HostedZone {
/// Creates a new builder-style object to manufacture [`HostedZone`](crate::model::HostedZone)
pub fn builder() -> crate::model::hosted_zone::Builder {
crate::model::hosted_zone::Builder::default()
}
}
/// <p>If a health check or hosted zone was created by another service, <code>LinkedService</code> is a complex type that describes the service that created the resource. When a resource is created by another service, you can't edit or delete it using Amazon Route 53. </p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct LinkedService {
/// <p>If the health check or hosted zone was created by another service, the service that created the resource. When a resource is created by another service, you can't edit or delete it using Amazon Route 53. </p>
pub service_principal: std::option::Option<std::string::String>,
/// <p>If the health check or hosted zone was created by another service, an optional description that can be provided by the other service. When a resource is created by another service, you can't edit or delete it using Amazon Route 53. </p>
pub description: std::option::Option<std::string::String>,
}
impl LinkedService {
/// <p>If the health check or hosted zone was created by another service, the service that created the resource. When a resource is created by another service, you can't edit or delete it using Amazon Route 53. </p>
pub fn service_principal(&self) -> std::option::Option<&str> {
self.service_principal.as_deref()
}
/// <p>If the health check or hosted zone was created by another service, an optional description that can be provided by the other service. When a resource is created by another service, you can't edit or delete it using Amazon Route 53. </p>
pub fn description(&self) -> std::option::Option<&str> {
self.description.as_deref()
}
}
impl std::fmt::Debug for LinkedService {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("LinkedService");
formatter.field("service_principal", &self.service_principal);
formatter.field("description", &self.description);
formatter.finish()
}
}
/// See [`LinkedService`](crate::model::LinkedService)
pub mod linked_service {
/// A builder for [`LinkedService`](crate::model::LinkedService)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) service_principal: std::option::Option<std::string::String>,
pub(crate) description: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>If the health check or hosted zone was created by another service, the service that created the resource. When a resource is created by another service, you can't edit or delete it using Amazon Route 53. </p>
pub fn service_principal(mut self, input: impl Into<std::string::String>) -> Self {
self.service_principal = Some(input.into());
self
}
/// <p>If the health check or hosted zone was created by another service, the service that created the resource. When a resource is created by another service, you can't edit or delete it using Amazon Route 53. </p>
pub fn set_service_principal(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.service_principal = input;
self
}
/// <p>If the health check or hosted zone was created by another service, an optional description that can be provided by the other service. When a resource is created by another service, you can't edit or delete it using Amazon Route 53. </p>
pub fn description(mut self, input: impl Into<std::string::String>) -> Self {
self.description = Some(input.into());
self
}
/// <p>If the health check or hosted zone was created by another service, an optional description that can be provided by the other service. When a resource is created by another service, you can't edit or delete it using Amazon Route 53. </p>
pub fn set_description(mut self, input: std::option::Option<std::string::String>) -> Self {
self.description = input;
self
}
/// Consumes the builder and constructs a [`LinkedService`](crate::model::LinkedService)
pub fn build(self) -> crate::model::LinkedService {
crate::model::LinkedService {
service_principal: self.service_principal,
description: self.description,
}
}
}
}
impl LinkedService {
/// Creates a new builder-style object to manufacture [`LinkedService`](crate::model::LinkedService)
pub fn builder() -> crate::model::linked_service::Builder {
crate::model::linked_service::Builder::default()
}
}
/// <p>A complex type that contains an optional comment about your hosted zone. If you don't want to specify a comment, omit both the <code>HostedZoneConfig</code> and <code>Comment</code> elements.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct HostedZoneConfig {
/// <p>Any comments that you want to include about the hosted zone.</p>
pub comment: std::option::Option<std::string::String>,
/// <p>A value that indicates whether this is a private hosted zone.</p>
pub private_zone: bool,
}
impl HostedZoneConfig {
/// <p>Any comments that you want to include about the hosted zone.</p>
pub fn comment(&self) -> std::option::Option<&str> {
self.comment.as_deref()
}
/// <p>A value that indicates whether this is a private hosted zone.</p>
pub fn private_zone(&self) -> bool {
self.private_zone
}
}
impl std::fmt::Debug for HostedZoneConfig {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("HostedZoneConfig");
formatter.field("comment", &self.comment);
formatter.field("private_zone", &self.private_zone);
formatter.finish()
}
}
/// See [`HostedZoneConfig`](crate::model::HostedZoneConfig)
pub mod hosted_zone_config {
/// A builder for [`HostedZoneConfig`](crate::model::HostedZoneConfig)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) comment: std::option::Option<std::string::String>,
pub(crate) private_zone: std::option::Option<bool>,
}
impl Builder {
/// <p>Any comments that you want to include about the hosted zone.</p>
pub fn comment(mut self, input: impl Into<std::string::String>) -> Self {
self.comment = Some(input.into());
self
}
/// <p>Any comments that you want to include about the hosted zone.</p>
pub fn set_comment(mut self, input: std::option::Option<std::string::String>) -> Self {
self.comment = input;
self
}
/// <p>A value that indicates whether this is a private hosted zone.</p>
pub fn private_zone(mut self, input: bool) -> Self {
self.private_zone = Some(input);
self
}
/// <p>A value that indicates whether this is a private hosted zone.</p>
pub fn set_private_zone(mut self, input: std::option::Option<bool>) -> Self {
self.private_zone = input;
self
}
/// Consumes the builder and constructs a [`HostedZoneConfig`](crate::model::HostedZoneConfig)
pub fn build(self) -> crate::model::HostedZoneConfig {
crate::model::HostedZoneConfig {
comment: self.comment,
private_zone: self.private_zone.unwrap_or_default(),
}
}
}
}
impl HostedZoneConfig {
/// Creates a new builder-style object to manufacture [`HostedZoneConfig`](crate::model::HostedZoneConfig)
pub fn builder() -> crate::model::hosted_zone_config::Builder {
crate::model::hosted_zone_config::Builder::default()
}
}
/// <p>A complex type that contains information about one health check that is associated with the current Amazon Web Services account.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct HealthCheck {
/// <p>The identifier that Amazon Route 53 assigned to the health check when you created it. When you add or update a resource record set, you use this value to specify which health check to use. The value can be up to 64 characters long. </p>
pub id: std::option::Option<std::string::String>,
/// <p>A unique string that you specified when you created the health check.</p>
pub caller_reference: std::option::Option<std::string::String>,
/// <p>If the health check was created by another service, the service that created the health check. When a health check is created by another service, you can't edit or delete it using Amazon Route 53. </p>
pub linked_service: std::option::Option<crate::model::LinkedService>,
/// <p>A complex type that contains detailed information about one health check.</p>
pub health_check_config: std::option::Option<crate::model::HealthCheckConfig>,
/// <p>The version of the health check. You can optionally pass this value in a call to <code>UpdateHealthCheck</code> to prevent overwriting another change to the health check.</p>
pub health_check_version: std::option::Option<i64>,
/// <p>A complex type that contains information about the CloudWatch alarm that Amazon Route 53 is monitoring for this health check.</p>
pub cloud_watch_alarm_configuration:
std::option::Option<crate::model::CloudWatchAlarmConfiguration>,
}
impl HealthCheck {
/// <p>The identifier that Amazon Route 53 assigned to the health check when you created it. When you add or update a resource record set, you use this value to specify which health check to use. The value can be up to 64 characters long. </p>
pub fn id(&self) -> std::option::Option<&str> {
self.id.as_deref()
}
/// <p>A unique string that you specified when you created the health check.</p>
pub fn caller_reference(&self) -> std::option::Option<&str> {
self.caller_reference.as_deref()
}
/// <p>If the health check was created by another service, the service that created the health check. When a health check is created by another service, you can't edit or delete it using Amazon Route 53. </p>
pub fn linked_service(&self) -> std::option::Option<&crate::model::LinkedService> {
self.linked_service.as_ref()
}
/// <p>A complex type that contains detailed information about one health check.</p>
pub fn health_check_config(&self) -> std::option::Option<&crate::model::HealthCheckConfig> {
self.health_check_config.as_ref()
}
/// <p>The version of the health check. You can optionally pass this value in a call to <code>UpdateHealthCheck</code> to prevent overwriting another change to the health check.</p>
pub fn health_check_version(&self) -> std::option::Option<i64> {
self.health_check_version
}
/// <p>A complex type that contains information about the CloudWatch alarm that Amazon Route 53 is monitoring for this health check.</p>
pub fn cloud_watch_alarm_configuration(
&self,
) -> std::option::Option<&crate::model::CloudWatchAlarmConfiguration> {
self.cloud_watch_alarm_configuration.as_ref()
}
}
impl std::fmt::Debug for HealthCheck {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("HealthCheck");
formatter.field("id", &self.id);
formatter.field("caller_reference", &self.caller_reference);
formatter.field("linked_service", &self.linked_service);
formatter.field("health_check_config", &self.health_check_config);
formatter.field("health_check_version", &self.health_check_version);
formatter.field(
"cloud_watch_alarm_configuration",
&self.cloud_watch_alarm_configuration,
);
formatter.finish()
}
}
/// See [`HealthCheck`](crate::model::HealthCheck)
pub mod health_check {
/// A builder for [`HealthCheck`](crate::model::HealthCheck)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) id: std::option::Option<std::string::String>,
pub(crate) caller_reference: std::option::Option<std::string::String>,
pub(crate) linked_service: std::option::Option<crate::model::LinkedService>,
pub(crate) health_check_config: std::option::Option<crate::model::HealthCheckConfig>,
pub(crate) health_check_version: std::option::Option<i64>,
pub(crate) cloud_watch_alarm_configuration:
std::option::Option<crate::model::CloudWatchAlarmConfiguration>,
}
impl Builder {
/// <p>The identifier that Amazon Route 53 assigned to the health check when you created it. When you add or update a resource record set, you use this value to specify which health check to use. The value can be up to 64 characters long. </p>
pub fn id(mut self, input: impl Into<std::string::String>) -> Self {
self.id = Some(input.into());
self
}
/// <p>The identifier that Amazon Route 53 assigned to the health check when you created it. When you add or update a resource record set, you use this value to specify which health check to use. The value can be up to 64 characters long. </p>
pub fn set_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.id = input;
self
}
/// <p>A unique string that you specified when you created the health check.</p>
pub fn caller_reference(mut self, input: impl Into<std::string::String>) -> Self {
self.caller_reference = Some(input.into());
self
}
/// <p>A unique string that you specified when you created the health check.</p>
pub fn set_caller_reference(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.caller_reference = input;
self
}
/// <p>If the health check was created by another service, the service that created the health check. When a health check is created by another service, you can't edit or delete it using Amazon Route 53. </p>
pub fn linked_service(mut self, input: crate::model::LinkedService) -> Self {
self.linked_service = Some(input);
self
}
/// <p>If the health check was created by another service, the service that created the health check. When a health check is created by another service, you can't edit or delete it using Amazon Route 53. </p>
pub fn set_linked_service(
mut self,
input: std::option::Option<crate::model::LinkedService>,
) -> Self {
self.linked_service = input;
self
}
/// <p>A complex type that contains detailed information about one health check.</p>
pub fn health_check_config(mut self, input: crate::model::HealthCheckConfig) -> Self {
self.health_check_config = Some(input);
self
}
/// <p>A complex type that contains detailed information about one health check.</p>
pub fn set_health_check_config(
mut self,
input: std::option::Option<crate::model::HealthCheckConfig>,
) -> Self {
self.health_check_config = input;
self
}
/// <p>The version of the health check. You can optionally pass this value in a call to <code>UpdateHealthCheck</code> to prevent overwriting another change to the health check.</p>
pub fn health_check_version(mut self, input: i64) -> Self {
self.health_check_version = Some(input);
self
}
/// <p>The version of the health check. You can optionally pass this value in a call to <code>UpdateHealthCheck</code> to prevent overwriting another change to the health check.</p>
pub fn set_health_check_version(mut self, input: std::option::Option<i64>) -> Self {
self.health_check_version = input;
self
}
/// <p>A complex type that contains information about the CloudWatch alarm that Amazon Route 53 is monitoring for this health check.</p>
pub fn cloud_watch_alarm_configuration(
mut self,
input: crate::model::CloudWatchAlarmConfiguration,
) -> Self {
self.cloud_watch_alarm_configuration = Some(input);
self
}
/// <p>A complex type that contains information about the CloudWatch alarm that Amazon Route 53 is monitoring for this health check.</p>
pub fn set_cloud_watch_alarm_configuration(
mut self,
input: std::option::Option<crate::model::CloudWatchAlarmConfiguration>,
) -> Self {
self.cloud_watch_alarm_configuration = input;
self
}
/// Consumes the builder and constructs a [`HealthCheck`](crate::model::HealthCheck)
pub fn build(self) -> crate::model::HealthCheck {
crate::model::HealthCheck {
id: self.id,
caller_reference: self.caller_reference,
linked_service: self.linked_service,
health_check_config: self.health_check_config,
health_check_version: self.health_check_version,
cloud_watch_alarm_configuration: self.cloud_watch_alarm_configuration,
}
}
}
}
impl HealthCheck {
/// Creates a new builder-style object to manufacture [`HealthCheck`](crate::model::HealthCheck)
pub fn builder() -> crate::model::health_check::Builder {
crate::model::health_check::Builder::default()
}
}
/// <p>A complex type that contains information about the CloudWatch alarm that Amazon Route 53 is monitoring for this health check.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct CloudWatchAlarmConfiguration {
/// <p>For the metric that the CloudWatch alarm is associated with, the number of periods that the metric is compared to the threshold.</p>
pub evaluation_periods: std::option::Option<i32>,
/// <p>For the metric that the CloudWatch alarm is associated with, the value the metric is compared with.</p>
pub threshold: std::option::Option<f64>,
/// <p>For the metric that the CloudWatch alarm is associated with, the arithmetic operation that is used for the comparison.</p>
pub comparison_operator: std::option::Option<crate::model::ComparisonOperator>,
/// <p>For the metric that the CloudWatch alarm is associated with, the duration of one evaluation period in seconds.</p>
pub period: std::option::Option<i32>,
/// <p>The name of the CloudWatch metric that the alarm is associated with.</p>
pub metric_name: std::option::Option<std::string::String>,
/// <p>The namespace of the metric that the alarm is associated with. For more information, see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/CW_Support_For_AWS.html">Amazon CloudWatch Namespaces, Dimensions, and Metrics Reference</a> in the <i>Amazon CloudWatch User Guide</i>.</p>
pub namespace: std::option::Option<std::string::String>,
/// <p>For the metric that the CloudWatch alarm is associated with, the statistic that is applied to the metric.</p>
pub statistic: std::option::Option<crate::model::Statistic>,
/// <p>For the metric that the CloudWatch alarm is associated with, a complex type that contains information about the dimensions for the metric. For information, see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/CW_Support_For_AWS.html">Amazon CloudWatch Namespaces, Dimensions, and Metrics Reference</a> in the <i>Amazon CloudWatch User Guide</i>.</p>
pub dimensions: std::option::Option<std::vec::Vec<crate::model::Dimension>>,
}
impl CloudWatchAlarmConfiguration {
/// <p>For the metric that the CloudWatch alarm is associated with, the number of periods that the metric is compared to the threshold.</p>
pub fn evaluation_periods(&self) -> std::option::Option<i32> {
self.evaluation_periods
}
/// <p>For the metric that the CloudWatch alarm is associated with, the value the metric is compared with.</p>
pub fn threshold(&self) -> std::option::Option<f64> {
self.threshold
}
/// <p>For the metric that the CloudWatch alarm is associated with, the arithmetic operation that is used for the comparison.</p>
pub fn comparison_operator(&self) -> std::option::Option<&crate::model::ComparisonOperator> {
self.comparison_operator.as_ref()
}
/// <p>For the metric that the CloudWatch alarm is associated with, the duration of one evaluation period in seconds.</p>
pub fn period(&self) -> std::option::Option<i32> {
self.period
}
/// <p>The name of the CloudWatch metric that the alarm is associated with.</p>
pub fn metric_name(&self) -> std::option::Option<&str> {
self.metric_name.as_deref()
}
/// <p>The namespace of the metric that the alarm is associated with. For more information, see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/CW_Support_For_AWS.html">Amazon CloudWatch Namespaces, Dimensions, and Metrics Reference</a> in the <i>Amazon CloudWatch User Guide</i>.</p>
pub fn namespace(&self) -> std::option::Option<&str> {
self.namespace.as_deref()
}
/// <p>For the metric that the CloudWatch alarm is associated with, the statistic that is applied to the metric.</p>
pub fn statistic(&self) -> std::option::Option<&crate::model::Statistic> {
self.statistic.as_ref()
}
/// <p>For the metric that the CloudWatch alarm is associated with, a complex type that contains information about the dimensions for the metric. For information, see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/CW_Support_For_AWS.html">Amazon CloudWatch Namespaces, Dimensions, and Metrics Reference</a> in the <i>Amazon CloudWatch User Guide</i>.</p>
pub fn dimensions(&self) -> std::option::Option<&[crate::model::Dimension]> {
self.dimensions.as_deref()
}
}
impl std::fmt::Debug for CloudWatchAlarmConfiguration {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("CloudWatchAlarmConfiguration");
formatter.field("evaluation_periods", &self.evaluation_periods);
formatter.field("threshold", &self.threshold);
formatter.field("comparison_operator", &self.comparison_operator);
formatter.field("period", &self.period);
formatter.field("metric_name", &self.metric_name);
formatter.field("namespace", &self.namespace);
formatter.field("statistic", &self.statistic);
formatter.field("dimensions", &self.dimensions);
formatter.finish()
}
}
/// See [`CloudWatchAlarmConfiguration`](crate::model::CloudWatchAlarmConfiguration)
pub mod cloud_watch_alarm_configuration {
/// A builder for [`CloudWatchAlarmConfiguration`](crate::model::CloudWatchAlarmConfiguration)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) evaluation_periods: std::option::Option<i32>,
pub(crate) threshold: std::option::Option<f64>,
pub(crate) comparison_operator: std::option::Option<crate::model::ComparisonOperator>,
pub(crate) period: std::option::Option<i32>,
pub(crate) metric_name: std::option::Option<std::string::String>,
pub(crate) namespace: std::option::Option<std::string::String>,
pub(crate) statistic: std::option::Option<crate::model::Statistic>,
pub(crate) dimensions: std::option::Option<std::vec::Vec<crate::model::Dimension>>,
}
impl Builder {
/// <p>For the metric that the CloudWatch alarm is associated with, the number of periods that the metric is compared to the threshold.</p>
pub fn evaluation_periods(mut self, input: i32) -> Self {
self.evaluation_periods = Some(input);
self
}
/// <p>For the metric that the CloudWatch alarm is associated with, the number of periods that the metric is compared to the threshold.</p>
pub fn set_evaluation_periods(mut self, input: std::option::Option<i32>) -> Self {
self.evaluation_periods = input;
self
}
/// <p>For the metric that the CloudWatch alarm is associated with, the value the metric is compared with.</p>
pub fn threshold(mut self, input: f64) -> Self {
self.threshold = Some(input);
self
}
/// <p>For the metric that the CloudWatch alarm is associated with, the value the metric is compared with.</p>
pub fn set_threshold(mut self, input: std::option::Option<f64>) -> Self {
self.threshold = input;
self
}
/// <p>For the metric that the CloudWatch alarm is associated with, the arithmetic operation that is used for the comparison.</p>
pub fn comparison_operator(mut self, input: crate::model::ComparisonOperator) -> Self {
self.comparison_operator = Some(input);
self
}
/// <p>For the metric that the CloudWatch alarm is associated with, the arithmetic operation that is used for the comparison.</p>
pub fn set_comparison_operator(
mut self,
input: std::option::Option<crate::model::ComparisonOperator>,
) -> Self {
self.comparison_operator = input;
self
}
/// <p>For the metric that the CloudWatch alarm is associated with, the duration of one evaluation period in seconds.</p>
pub fn period(mut self, input: i32) -> Self {
self.period = Some(input);
self
}
/// <p>For the metric that the CloudWatch alarm is associated with, the duration of one evaluation period in seconds.</p>
pub fn set_period(mut self, input: std::option::Option<i32>) -> Self {
self.period = input;
self
}
/// <p>The name of the CloudWatch metric that the alarm is associated with.</p>
pub fn metric_name(mut self, input: impl Into<std::string::String>) -> Self {
self.metric_name = Some(input.into());
self
}
/// <p>The name of the CloudWatch metric that the alarm is associated with.</p>
pub fn set_metric_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.metric_name = input;
self
}
/// <p>The namespace of the metric that the alarm is associated with. For more information, see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/CW_Support_For_AWS.html">Amazon CloudWatch Namespaces, Dimensions, and Metrics Reference</a> in the <i>Amazon CloudWatch User Guide</i>.</p>
pub fn namespace(mut self, input: impl Into<std::string::String>) -> Self {
self.namespace = Some(input.into());
self
}
/// <p>The namespace of the metric that the alarm is associated with. For more information, see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/CW_Support_For_AWS.html">Amazon CloudWatch Namespaces, Dimensions, and Metrics Reference</a> in the <i>Amazon CloudWatch User Guide</i>.</p>
pub fn set_namespace(mut self, input: std::option::Option<std::string::String>) -> Self {
self.namespace = input;
self
}
/// <p>For the metric that the CloudWatch alarm is associated with, the statistic that is applied to the metric.</p>
pub fn statistic(mut self, input: crate::model::Statistic) -> Self {
self.statistic = Some(input);
self
}
/// <p>For the metric that the CloudWatch alarm is associated with, the statistic that is applied to the metric.</p>
pub fn set_statistic(
mut self,
input: std::option::Option<crate::model::Statistic>,
) -> Self {
self.statistic = input;
self
}
/// Appends an item to `dimensions`.
///
/// To override the contents of this collection use [`set_dimensions`](Self::set_dimensions).
///
/// <p>For the metric that the CloudWatch alarm is associated with, a complex type that contains information about the dimensions for the metric. For information, see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/CW_Support_For_AWS.html">Amazon CloudWatch Namespaces, Dimensions, and Metrics Reference</a> in the <i>Amazon CloudWatch User Guide</i>.</p>
pub fn dimensions(mut self, input: crate::model::Dimension) -> Self {
let mut v = self.dimensions.unwrap_or_default();
v.push(input);
self.dimensions = Some(v);
self
}
/// <p>For the metric that the CloudWatch alarm is associated with, a complex type that contains information about the dimensions for the metric. For information, see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/CW_Support_For_AWS.html">Amazon CloudWatch Namespaces, Dimensions, and Metrics Reference</a> in the <i>Amazon CloudWatch User Guide</i>.</p>
pub fn set_dimensions(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::Dimension>>,
) -> Self {
self.dimensions = input;
self
}
/// Consumes the builder and constructs a [`CloudWatchAlarmConfiguration`](crate::model::CloudWatchAlarmConfiguration)
pub fn build(self) -> crate::model::CloudWatchAlarmConfiguration {
crate::model::CloudWatchAlarmConfiguration {
evaluation_periods: self.evaluation_periods,
threshold: self.threshold,
comparison_operator: self.comparison_operator,
period: self.period,
metric_name: self.metric_name,
namespace: self.namespace,
statistic: self.statistic,
dimensions: self.dimensions,
}
}
}
}
impl CloudWatchAlarmConfiguration {
/// Creates a new builder-style object to manufacture [`CloudWatchAlarmConfiguration`](crate::model::CloudWatchAlarmConfiguration)
pub fn builder() -> crate::model::cloud_watch_alarm_configuration::Builder {
crate::model::cloud_watch_alarm_configuration::Builder::default()
}
}
/// <p>For the metric that the CloudWatch alarm is associated with, a complex type that contains information about one dimension.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct Dimension {
/// <p>For the metric that the CloudWatch alarm is associated with, the name of one dimension.</p>
pub name: std::option::Option<std::string::String>,
/// <p>For the metric that the CloudWatch alarm is associated with, the value of one dimension.</p>
pub value: std::option::Option<std::string::String>,
}
impl Dimension {
/// <p>For the metric that the CloudWatch alarm is associated with, the name of one dimension.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>For the metric that the CloudWatch alarm is associated with, the value of one dimension.</p>
pub fn value(&self) -> std::option::Option<&str> {
self.value.as_deref()
}
}
impl std::fmt::Debug for Dimension {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("Dimension");
formatter.field("name", &self.name);
formatter.field("value", &self.value);
formatter.finish()
}
}
/// See [`Dimension`](crate::model::Dimension)
pub mod dimension {
/// A builder for [`Dimension`](crate::model::Dimension)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) value: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>For the metric that the CloudWatch alarm is associated with, the name of one dimension.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>For the metric that the CloudWatch alarm is associated with, the name of one dimension.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// <p>For the metric that the CloudWatch alarm is associated with, the value of one dimension.</p>
pub fn value(mut self, input: impl Into<std::string::String>) -> Self {
self.value = Some(input.into());
self
}
/// <p>For the metric that the CloudWatch alarm is associated with, the value of one dimension.</p>
pub fn set_value(mut self, input: std::option::Option<std::string::String>) -> Self {
self.value = input;
self
}
/// Consumes the builder and constructs a [`Dimension`](crate::model::Dimension)
pub fn build(self) -> crate::model::Dimension {
crate::model::Dimension {
name: self.name,
value: self.value,
}
}
}
}
impl Dimension {
/// Creates a new builder-style object to manufacture [`Dimension`](crate::model::Dimension)
pub fn builder() -> crate::model::dimension::Builder {
crate::model::dimension::Builder::default()
}
}
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum Statistic {
#[allow(missing_docs)] // documentation missing in model
Average,
#[allow(missing_docs)] // documentation missing in model
Maximum,
#[allow(missing_docs)] // documentation missing in model
Minimum,
#[allow(missing_docs)] // documentation missing in model
SampleCount,
#[allow(missing_docs)] // documentation missing in model
Sum,
/// Unknown contains new variants that have been added since this code was generated.
Unknown(String),
}
impl std::convert::From<&str> for Statistic {
fn from(s: &str) -> Self {
match s {
"Average" => Statistic::Average,
"Maximum" => Statistic::Maximum,
"Minimum" => Statistic::Minimum,
"SampleCount" => Statistic::SampleCount,
"Sum" => Statistic::Sum,
other => Statistic::Unknown(other.to_owned()),
}
}
}
impl std::str::FromStr for Statistic {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(Statistic::from(s))
}
}
impl Statistic {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
Statistic::Average => "Average",
Statistic::Maximum => "Maximum",
Statistic::Minimum => "Minimum",
Statistic::SampleCount => "SampleCount",
Statistic::Sum => "Sum",
Statistic::Unknown(s) => s.as_ref(),
}
}
/// Returns all the `&str` values of the enum members.
pub fn values() -> &'static [&'static str] {
&["Average", "Maximum", "Minimum", "SampleCount", "Sum"]
}
}
impl AsRef<str> for Statistic {
fn as_ref(&self) -> &str {
self.as_str()
}
}
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum ComparisonOperator {
#[allow(missing_docs)] // documentation missing in model
GreaterThanOrEqualToThreshold,
#[allow(missing_docs)] // documentation missing in model
GreaterThanThreshold,
#[allow(missing_docs)] // documentation missing in model
LessThanOrEqualToThreshold,
#[allow(missing_docs)] // documentation missing in model
LessThanThreshold,
/// Unknown contains new variants that have been added since this code was generated.
Unknown(String),
}
impl std::convert::From<&str> for ComparisonOperator {
fn from(s: &str) -> Self {
match s {
"GreaterThanOrEqualToThreshold" => ComparisonOperator::GreaterThanOrEqualToThreshold,
"GreaterThanThreshold" => ComparisonOperator::GreaterThanThreshold,
"LessThanOrEqualToThreshold" => ComparisonOperator::LessThanOrEqualToThreshold,
"LessThanThreshold" => ComparisonOperator::LessThanThreshold,
other => ComparisonOperator::Unknown(other.to_owned()),
}
}
}
impl std::str::FromStr for ComparisonOperator {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(ComparisonOperator::from(s))
}
}
impl ComparisonOperator {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
ComparisonOperator::GreaterThanOrEqualToThreshold => "GreaterThanOrEqualToThreshold",
ComparisonOperator::GreaterThanThreshold => "GreaterThanThreshold",
ComparisonOperator::LessThanOrEqualToThreshold => "LessThanOrEqualToThreshold",
ComparisonOperator::LessThanThreshold => "LessThanThreshold",
ComparisonOperator::Unknown(s) => s.as_ref(),
}
}
/// Returns all the `&str` values of the enum members.
pub fn values() -> &'static [&'static str] {
&[
"GreaterThanOrEqualToThreshold",
"GreaterThanThreshold",
"LessThanOrEqualToThreshold",
"LessThanThreshold",
]
}
}
impl AsRef<str> for ComparisonOperator {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>A complex type that contains information about the health check.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct HealthCheckConfig {
/// <p>The IPv4 or IPv6 IP address of the endpoint that you want Amazon Route 53 to perform health checks on. If you don't specify a value for <code>IPAddress</code>, Route 53 sends a DNS request to resolve the domain name that you specify in <code>FullyQualifiedDomainName</code> at the interval that you specify in <code>RequestInterval</code>. Using an IP address returned by DNS, Route 53 then checks the health of the endpoint.</p>
/// <p>Use one of the following formats for the value of <code>IPAddress</code>: </p>
/// <ul>
/// <li> <p> <b>IPv4 address</b>: four values between 0 and 255, separated by periods (.), for example, <code>192.0.2.44</code>.</p> </li>
/// <li> <p> <b>IPv6 address</b>: eight groups of four hexadecimal values, separated by colons (:), for example, <code>2001:0db8:85a3:0000:0000:abcd:0001:2345</code>. You can also shorten IPv6 addresses as described in RFC 5952, for example, <code>2001:db8:85a3::abcd:1:2345</code>.</p> </li>
/// </ul>
/// <p>If the endpoint is an EC2 instance, we recommend that you create an Elastic IP address, associate it with your EC2 instance, and specify the Elastic IP address for <code>IPAddress</code>. This ensures that the IP address of your instance will never change.</p>
/// <p>For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_UpdateHealthCheck.html#Route53-UpdateHealthCheck-request-FullyQualifiedDomainName">FullyQualifiedDomainName</a>. </p>
/// <p>Constraints: Route 53 can't check the health of endpoints for which the IP address is in local, private, non-routable, or multicast ranges. For more information about IP addresses for which you can't create health checks, see the following documents:</p>
/// <ul>
/// <li> <p> <a href="https://tools.ietf.org/html/rfc5735">RFC 5735, Special Use IPv4 Addresses</a> </p> </li>
/// <li> <p> <a href="https://tools.ietf.org/html/rfc6598">RFC 6598, IANA-Reserved IPv4 Prefix for Shared Address Space</a> </p> </li>
/// <li> <p> <a href="https://tools.ietf.org/html/rfc5156">RFC 5156, Special-Use IPv6 Addresses</a> </p> </li>
/// </ul>
/// <p>When the value of <code>Type</code> is <code>CALCULATED</code> or <code>CLOUDWATCH_METRIC</code>, omit <code>IPAddress</code>.</p>
pub ip_address: std::option::Option<std::string::String>,
/// <p>The port on the endpoint that you want Amazon Route 53 to perform health checks on.</p> <note>
/// <p>Don't specify a value for <code>Port</code> when you specify a value for <code>Type</code> of <code>CLOUDWATCH_METRIC</code> or <code>CALCULATED</code>.</p>
/// </note>
pub port: std::option::Option<i32>,
/// <p>The type of health check that you want to create, which indicates how Amazon Route 53 determines whether an endpoint is healthy.</p> <important>
/// <p>You can't change the value of <code>Type</code> after you create a health check.</p>
/// </important>
/// <p>You can create the following types of health checks:</p>
/// <ul>
/// <li> <p> <b>HTTP</b>: Route 53 tries to establish a TCP connection. If successful, Route 53 submits an HTTP request and waits for an HTTP status code of 200 or greater and less than 400.</p> </li>
/// <li> <p> <b>HTTPS</b>: Route 53 tries to establish a TCP connection. If successful, Route 53 submits an HTTPS request and waits for an HTTP status code of 200 or greater and less than 400.</p> <important>
/// <p>If you specify <code>HTTPS</code> for the value of <code>Type</code>, the endpoint must support TLS v1.0 or later.</p>
/// </important> </li>
/// <li> <p> <b>HTTP_STR_MATCH</b>: Route 53 tries to establish a TCP connection. If successful, Route 53 submits an HTTP request and searches the first 5,120 bytes of the response body for the string that you specify in <code>SearchString</code>.</p> </li>
/// <li> <p> <b>HTTPS_STR_MATCH</b>: Route 53 tries to establish a TCP connection. If successful, Route 53 submits an <code>HTTPS</code> request and searches the first 5,120 bytes of the response body for the string that you specify in <code>SearchString</code>.</p> </li>
/// <li> <p> <b>TCP</b>: Route 53 tries to establish a TCP connection.</p> </li>
/// <li> <p> <b>CLOUDWATCH_METRIC</b>: The health check is associated with a CloudWatch alarm. If the state of the alarm is <code>OK</code>, the health check is considered healthy. If the state is <code>ALARM</code>, the health check is considered unhealthy. If CloudWatch doesn't have sufficient data to determine whether the state is <code>OK</code> or <code>ALARM</code>, the health check status depends on the setting for <code>InsufficientDataHealthStatus</code>: <code>Healthy</code>, <code>Unhealthy</code>, or <code>LastKnownStatus</code>. </p> </li>
/// <li> <p> <b>CALCULATED</b>: For health checks that monitor the status of other health checks, Route 53 adds up the number of health checks that Route 53 health checkers consider to be healthy and compares that number with the value of <code>HealthThreshold</code>. </p> </li>
/// <li> <p> <b>RECOVERY_CONTROL</b>: The health check is assocated with a Route53 Application Recovery Controller routing control. If the routing control state is <code>ON</code>, the health check is considered healthy. If the state is <code>OFF</code>, the health check is considered unhealthy. </p> </li>
/// </ul>
/// <p>For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-determining-health-of-endpoints.html">How Route 53 Determines Whether an Endpoint Is Healthy</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
pub r#type: std::option::Option<crate::model::HealthCheckType>,
/// <p>The path, if any, that you want Amazon Route 53 to request when performing health checks. The path can be any value for which your endpoint will return an HTTP status code of 2xx or 3xx when the endpoint is healthy, for example, the file /docs/route53-health-check.html. You can also include query string parameters, for example, <code>/welcome.html?language=jp&login=y</code>. </p>
pub resource_path: std::option::Option<std::string::String>,
/// <p>Amazon Route 53 behavior depends on whether you specify a value for <code>IPAddress</code>.</p>
/// <p> <b>If you specify a value for</b> <code>IPAddress</code>:</p>
/// <p>Amazon Route 53 sends health check requests to the specified IPv4 or IPv6 address and passes the value of <code>FullyQualifiedDomainName</code> in the <code>Host</code> header for all health checks except TCP health checks. This is typically the fully qualified DNS name of the endpoint on which you want Route 53 to perform health checks.</p>
/// <p>When Route 53 checks the health of an endpoint, here is how it constructs the <code>Host</code> header:</p>
/// <ul>
/// <li> <p>If you specify a value of <code>80</code> for <code>Port</code> and <code>HTTP</code> or <code>HTTP_STR_MATCH</code> for <code>Type</code>, Route 53 passes the value of <code>FullyQualifiedDomainName</code> to the endpoint in the Host header. </p> </li>
/// <li> <p>If you specify a value of <code>443</code> for <code>Port</code> and <code>HTTPS</code> or <code>HTTPS_STR_MATCH</code> for <code>Type</code>, Route 53 passes the value of <code>FullyQualifiedDomainName</code> to the endpoint in the <code>Host</code> header.</p> </li>
/// <li> <p>If you specify another value for <code>Port</code> and any value except <code>TCP</code> for <code>Type</code>, Route 53 passes <code>FullyQualifiedDomainName:Port</code> to the endpoint in the <code>Host</code> header.</p> </li>
/// </ul>
/// <p>If you don't specify a value for <code>FullyQualifiedDomainName</code>, Route 53 substitutes the value of <code>IPAddress</code> in the <code>Host</code> header in each of the preceding cases.</p>
/// <p> <b>If you don't specify a value for</b> <code>IPAddress</code>:</p>
/// <p>Route 53 sends a DNS request to the domain that you specify for <code>FullyQualifiedDomainName</code> at the interval that you specify for <code>RequestInterval</code>. Using an IPv4 address that DNS returns, Route 53 then checks the health of the endpoint.</p> <note>
/// <p>If you don't specify a value for <code>IPAddress</code>, Route 53 uses only IPv4 to send health checks to the endpoint. If there's no resource record set with a type of A for the name that you specify for <code>FullyQualifiedDomainName</code>, the health check fails with a "DNS resolution failed" error.</p>
/// </note>
/// <p>If you want to check the health of weighted, latency, or failover resource record sets and you choose to specify the endpoint only by <code>FullyQualifiedDomainName</code>, we recommend that you create a separate health check for each endpoint. For example, create a health check for each HTTP server that is serving content for www.example.com. For the value of <code>FullyQualifiedDomainName</code>, specify the domain name of the server (such as us-east-2-www.example.com), not the name of the resource record sets (www.example.com).</p> <important>
/// <p>In this configuration, if you create a health check for which the value of <code>FullyQualifiedDomainName</code> matches the name of the resource record sets and you then associate the health check with those resource record sets, health check results will be unpredictable.</p>
/// </important>
/// <p>In addition, if the value that you specify for <code>Type</code> is <code>HTTP</code>, <code>HTTPS</code>, <code>HTTP_STR_MATCH</code>, or <code>HTTPS_STR_MATCH</code>, Route 53 passes the value of <code>FullyQualifiedDomainName</code> in the <code>Host</code> header, as it does when you specify a value for <code>IPAddress</code>. If the value of <code>Type</code> is <code>TCP</code>, Route 53 doesn't pass a <code>Host</code> header.</p>
pub fully_qualified_domain_name: std::option::Option<std::string::String>,
/// <p>If the value of Type is <code>HTTP_STR_MATCH</code> or <code>HTTPS_STR_MATCH</code>, the string that you want Amazon Route 53 to search for in the response body from the specified resource. If the string appears in the response body, Route 53 considers the resource healthy.</p>
/// <p>Route 53 considers case when searching for <code>SearchString</code> in the response body. </p>
pub search_string: std::option::Option<std::string::String>,
/// <p>The number of seconds between the time that Amazon Route 53 gets a response from your endpoint and the time that it sends the next health check request. Each Route 53 health checker makes requests at this interval.</p> <important>
/// <p>You can't change the value of <code>RequestInterval</code> after you create a health check.</p>
/// </important>
/// <p>If you don't specify a value for <code>RequestInterval</code>, the default value is <code>30</code> seconds.</p>
pub request_interval: std::option::Option<i32>,
/// <p>The number of consecutive health checks that an endpoint must pass or fail for Amazon Route 53 to change the current status of the endpoint from unhealthy to healthy or vice versa. For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-determining-health-of-endpoints.html">How Amazon Route 53 Determines Whether an Endpoint Is Healthy</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// <p>If you don't specify a value for <code>FailureThreshold</code>, the default value is three health checks.</p>
pub failure_threshold: std::option::Option<i32>,
/// <p>Specify whether you want Amazon Route 53 to measure the latency between health checkers in multiple Amazon Web Services regions and your endpoint, and to display CloudWatch latency graphs on the <b>Health Checks</b> page in the Route 53 console.</p> <important>
/// <p>You can't change the value of <code>MeasureLatency</code> after you create a health check.</p>
/// </important>
pub measure_latency: std::option::Option<bool>,
/// <p>Specify whether you want Amazon Route 53 to invert the status of a health check, for example, to consider a health check unhealthy when it otherwise would be considered healthy.</p>
pub inverted: std::option::Option<bool>,
/// <p>Stops Route 53 from performing health checks. When you disable a health check, here's what happens:</p>
/// <ul>
/// <li> <p> <b>Health checks that check the health of endpoints:</b> Route 53 stops submitting requests to your application, server, or other resource.</p> </li>
/// <li> <p> <b>Calculated health checks:</b> Route 53 stops aggregating the status of the referenced health checks.</p> </li>
/// <li> <p> <b>Health checks that monitor CloudWatch alarms:</b> Route 53 stops monitoring the corresponding CloudWatch metrics.</p> </li>
/// </ul>
/// <p>After you disable a health check, Route 53 considers the status of the health check to always be healthy. If you configured DNS failover, Route 53 continues to route traffic to the corresponding resources. If you want to stop routing traffic to a resource, change the value of <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_UpdateHealthCheck.html#Route53-UpdateHealthCheck-request-Inverted">Inverted</a>. </p>
/// <p>Charges for a health check still apply when the health check is disabled. For more information, see <a href="http://aws.amazon.com/route53/pricing/">Amazon Route 53 Pricing</a>.</p>
pub disabled: std::option::Option<bool>,
/// <p>The number of child health checks that are associated with a <code>CALCULATED</code> health check that Amazon Route 53 must consider healthy for the <code>CALCULATED</code> health check to be considered healthy. To specify the child health checks that you want to associate with a <code>CALCULATED</code> health check, use the <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_UpdateHealthCheck.html#Route53-UpdateHealthCheck-request-ChildHealthChecks">ChildHealthChecks</a> element.</p>
/// <p>Note the following:</p>
/// <ul>
/// <li> <p>If you specify a number greater than the number of child health checks, Route 53 always considers this health check to be unhealthy.</p> </li>
/// <li> <p>If you specify <code>0</code>, Route 53 always considers this health check to be healthy.</p> </li>
/// </ul>
pub health_threshold: std::option::Option<i32>,
/// <p>(CALCULATED Health Checks Only) A complex type that contains one <code>ChildHealthCheck</code> element for each health check that you want to associate with a <code>CALCULATED</code> health check.</p>
pub child_health_checks: std::option::Option<std::vec::Vec<std::string::String>>,
/// <p>Specify whether you want Amazon Route 53 to send the value of <code>FullyQualifiedDomainName</code> to the endpoint in the <code>client_hello</code> message during TLS negotiation. This allows the endpoint to respond to <code>HTTPS</code> health check requests with the applicable SSL/TLS certificate.</p>
/// <p>Some endpoints require that <code>HTTPS</code> requests include the host name in the <code>client_hello</code> message. If you don't enable SNI, the status of the health check will be <code>SSL alert handshake_failure</code>. A health check can also have that status for other reasons. If SNI is enabled and you're still getting the error, check the SSL/TLS configuration on your endpoint and confirm that your certificate is valid.</p>
/// <p>The SSL/TLS certificate on your endpoint includes a domain name in the <code>Common Name</code> field and possibly several more in the <code>Subject Alternative Names</code> field. One of the domain names in the certificate should match the value that you specify for <code>FullyQualifiedDomainName</code>. If the endpoint responds to the <code>client_hello</code> message with a certificate that does not include the domain name that you specified in <code>FullyQualifiedDomainName</code>, a health checker will retry the handshake. In the second attempt, the health checker will omit <code>FullyQualifiedDomainName</code> from the <code>client_hello</code> message.</p>
pub enable_sni: std::option::Option<bool>,
/// <p>A complex type that contains one <code>Region</code> element for each region from which you want Amazon Route 53 health checkers to check the specified endpoint.</p>
/// <p>If you don't specify any regions, Route 53 health checkers automatically performs checks from all of the regions that are listed under <b>Valid Values</b>.</p>
/// <p>If you update a health check to remove a region that has been performing health checks, Route 53 will briefly continue to perform checks from that region to ensure that some health checkers are always checking the endpoint (for example, if you replace three regions with four different regions). </p>
pub regions: std::option::Option<std::vec::Vec<crate::model::HealthCheckRegion>>,
/// <p>A complex type that identifies the CloudWatch alarm that you want Amazon Route 53 health checkers to use to determine whether the specified health check is healthy.</p>
pub alarm_identifier: std::option::Option<crate::model::AlarmIdentifier>,
/// <p>When CloudWatch has insufficient data about the metric to determine the alarm state, the status that you want Amazon Route 53 to assign to the health check:</p>
/// <ul>
/// <li> <p> <code>Healthy</code>: Route 53 considers the health check to be healthy.</p> </li>
/// <li> <p> <code>Unhealthy</code>: Route 53 considers the health check to be unhealthy.</p> </li>
/// <li> <p> <code>LastKnownStatus</code>: Route 53 uses the status of the health check from the last time that CloudWatch had sufficient data to determine the alarm state. For new health checks that have no last known status, the default status for the health check is healthy.</p> </li>
/// </ul>
pub insufficient_data_health_status:
std::option::Option<crate::model::InsufficientDataHealthStatus>,
/// <p>The Amazon Resource Name (ARN) for the Route 53 Application Recovery Controller routing control.</p>
/// <p>For more information about Route 53 Application Recovery Controller, see <a href="https://docs.aws.amazon.com/r53recovery/latest/dg/what-is-route-53-recovery.html">Route 53 Application Recovery Controller Developer Guide.</a>.</p>
pub routing_control_arn: std::option::Option<std::string::String>,
}
impl HealthCheckConfig {
/// <p>The IPv4 or IPv6 IP address of the endpoint that you want Amazon Route 53 to perform health checks on. If you don't specify a value for <code>IPAddress</code>, Route 53 sends a DNS request to resolve the domain name that you specify in <code>FullyQualifiedDomainName</code> at the interval that you specify in <code>RequestInterval</code>. Using an IP address returned by DNS, Route 53 then checks the health of the endpoint.</p>
/// <p>Use one of the following formats for the value of <code>IPAddress</code>: </p>
/// <ul>
/// <li> <p> <b>IPv4 address</b>: four values between 0 and 255, separated by periods (.), for example, <code>192.0.2.44</code>.</p> </li>
/// <li> <p> <b>IPv6 address</b>: eight groups of four hexadecimal values, separated by colons (:), for example, <code>2001:0db8:85a3:0000:0000:abcd:0001:2345</code>. You can also shorten IPv6 addresses as described in RFC 5952, for example, <code>2001:db8:85a3::abcd:1:2345</code>.</p> </li>
/// </ul>
/// <p>If the endpoint is an EC2 instance, we recommend that you create an Elastic IP address, associate it with your EC2 instance, and specify the Elastic IP address for <code>IPAddress</code>. This ensures that the IP address of your instance will never change.</p>
/// <p>For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_UpdateHealthCheck.html#Route53-UpdateHealthCheck-request-FullyQualifiedDomainName">FullyQualifiedDomainName</a>. </p>
/// <p>Constraints: Route 53 can't check the health of endpoints for which the IP address is in local, private, non-routable, or multicast ranges. For more information about IP addresses for which you can't create health checks, see the following documents:</p>
/// <ul>
/// <li> <p> <a href="https://tools.ietf.org/html/rfc5735">RFC 5735, Special Use IPv4 Addresses</a> </p> </li>
/// <li> <p> <a href="https://tools.ietf.org/html/rfc6598">RFC 6598, IANA-Reserved IPv4 Prefix for Shared Address Space</a> </p> </li>
/// <li> <p> <a href="https://tools.ietf.org/html/rfc5156">RFC 5156, Special-Use IPv6 Addresses</a> </p> </li>
/// </ul>
/// <p>When the value of <code>Type</code> is <code>CALCULATED</code> or <code>CLOUDWATCH_METRIC</code>, omit <code>IPAddress</code>.</p>
pub fn ip_address(&self) -> std::option::Option<&str> {
self.ip_address.as_deref()
}
/// <p>The port on the endpoint that you want Amazon Route 53 to perform health checks on.</p> <note>
/// <p>Don't specify a value for <code>Port</code> when you specify a value for <code>Type</code> of <code>CLOUDWATCH_METRIC</code> or <code>CALCULATED</code>.</p>
/// </note>
pub fn port(&self) -> std::option::Option<i32> {
self.port
}
/// <p>The type of health check that you want to create, which indicates how Amazon Route 53 determines whether an endpoint is healthy.</p> <important>
/// <p>You can't change the value of <code>Type</code> after you create a health check.</p>
/// </important>
/// <p>You can create the following types of health checks:</p>
/// <ul>
/// <li> <p> <b>HTTP</b>: Route 53 tries to establish a TCP connection. If successful, Route 53 submits an HTTP request and waits for an HTTP status code of 200 or greater and less than 400.</p> </li>
/// <li> <p> <b>HTTPS</b>: Route 53 tries to establish a TCP connection. If successful, Route 53 submits an HTTPS request and waits for an HTTP status code of 200 or greater and less than 400.</p> <important>
/// <p>If you specify <code>HTTPS</code> for the value of <code>Type</code>, the endpoint must support TLS v1.0 or later.</p>
/// </important> </li>
/// <li> <p> <b>HTTP_STR_MATCH</b>: Route 53 tries to establish a TCP connection. If successful, Route 53 submits an HTTP request and searches the first 5,120 bytes of the response body for the string that you specify in <code>SearchString</code>.</p> </li>
/// <li> <p> <b>HTTPS_STR_MATCH</b>: Route 53 tries to establish a TCP connection. If successful, Route 53 submits an <code>HTTPS</code> request and searches the first 5,120 bytes of the response body for the string that you specify in <code>SearchString</code>.</p> </li>
/// <li> <p> <b>TCP</b>: Route 53 tries to establish a TCP connection.</p> </li>
/// <li> <p> <b>CLOUDWATCH_METRIC</b>: The health check is associated with a CloudWatch alarm. If the state of the alarm is <code>OK</code>, the health check is considered healthy. If the state is <code>ALARM</code>, the health check is considered unhealthy. If CloudWatch doesn't have sufficient data to determine whether the state is <code>OK</code> or <code>ALARM</code>, the health check status depends on the setting for <code>InsufficientDataHealthStatus</code>: <code>Healthy</code>, <code>Unhealthy</code>, or <code>LastKnownStatus</code>. </p> </li>
/// <li> <p> <b>CALCULATED</b>: For health checks that monitor the status of other health checks, Route 53 adds up the number of health checks that Route 53 health checkers consider to be healthy and compares that number with the value of <code>HealthThreshold</code>. </p> </li>
/// <li> <p> <b>RECOVERY_CONTROL</b>: The health check is assocated with a Route53 Application Recovery Controller routing control. If the routing control state is <code>ON</code>, the health check is considered healthy. If the state is <code>OFF</code>, the health check is considered unhealthy. </p> </li>
/// </ul>
/// <p>For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-determining-health-of-endpoints.html">How Route 53 Determines Whether an Endpoint Is Healthy</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
pub fn r#type(&self) -> std::option::Option<&crate::model::HealthCheckType> {
self.r#type.as_ref()
}
/// <p>The path, if any, that you want Amazon Route 53 to request when performing health checks. The path can be any value for which your endpoint will return an HTTP status code of 2xx or 3xx when the endpoint is healthy, for example, the file /docs/route53-health-check.html. You can also include query string parameters, for example, <code>/welcome.html?language=jp&login=y</code>. </p>
pub fn resource_path(&self) -> std::option::Option<&str> {
self.resource_path.as_deref()
}
/// <p>Amazon Route 53 behavior depends on whether you specify a value for <code>IPAddress</code>.</p>
/// <p> <b>If you specify a value for</b> <code>IPAddress</code>:</p>
/// <p>Amazon Route 53 sends health check requests to the specified IPv4 or IPv6 address and passes the value of <code>FullyQualifiedDomainName</code> in the <code>Host</code> header for all health checks except TCP health checks. This is typically the fully qualified DNS name of the endpoint on which you want Route 53 to perform health checks.</p>
/// <p>When Route 53 checks the health of an endpoint, here is how it constructs the <code>Host</code> header:</p>
/// <ul>
/// <li> <p>If you specify a value of <code>80</code> for <code>Port</code> and <code>HTTP</code> or <code>HTTP_STR_MATCH</code> for <code>Type</code>, Route 53 passes the value of <code>FullyQualifiedDomainName</code> to the endpoint in the Host header. </p> </li>
/// <li> <p>If you specify a value of <code>443</code> for <code>Port</code> and <code>HTTPS</code> or <code>HTTPS_STR_MATCH</code> for <code>Type</code>, Route 53 passes the value of <code>FullyQualifiedDomainName</code> to the endpoint in the <code>Host</code> header.</p> </li>
/// <li> <p>If you specify another value for <code>Port</code> and any value except <code>TCP</code> for <code>Type</code>, Route 53 passes <code>FullyQualifiedDomainName:Port</code> to the endpoint in the <code>Host</code> header.</p> </li>
/// </ul>
/// <p>If you don't specify a value for <code>FullyQualifiedDomainName</code>, Route 53 substitutes the value of <code>IPAddress</code> in the <code>Host</code> header in each of the preceding cases.</p>
/// <p> <b>If you don't specify a value for</b> <code>IPAddress</code>:</p>
/// <p>Route 53 sends a DNS request to the domain that you specify for <code>FullyQualifiedDomainName</code> at the interval that you specify for <code>RequestInterval</code>. Using an IPv4 address that DNS returns, Route 53 then checks the health of the endpoint.</p> <note>
/// <p>If you don't specify a value for <code>IPAddress</code>, Route 53 uses only IPv4 to send health checks to the endpoint. If there's no resource record set with a type of A for the name that you specify for <code>FullyQualifiedDomainName</code>, the health check fails with a "DNS resolution failed" error.</p>
/// </note>
/// <p>If you want to check the health of weighted, latency, or failover resource record sets and you choose to specify the endpoint only by <code>FullyQualifiedDomainName</code>, we recommend that you create a separate health check for each endpoint. For example, create a health check for each HTTP server that is serving content for www.example.com. For the value of <code>FullyQualifiedDomainName</code>, specify the domain name of the server (such as us-east-2-www.example.com), not the name of the resource record sets (www.example.com).</p> <important>
/// <p>In this configuration, if you create a health check for which the value of <code>FullyQualifiedDomainName</code> matches the name of the resource record sets and you then associate the health check with those resource record sets, health check results will be unpredictable.</p>
/// </important>
/// <p>In addition, if the value that you specify for <code>Type</code> is <code>HTTP</code>, <code>HTTPS</code>, <code>HTTP_STR_MATCH</code>, or <code>HTTPS_STR_MATCH</code>, Route 53 passes the value of <code>FullyQualifiedDomainName</code> in the <code>Host</code> header, as it does when you specify a value for <code>IPAddress</code>. If the value of <code>Type</code> is <code>TCP</code>, Route 53 doesn't pass a <code>Host</code> header.</p>
pub fn fully_qualified_domain_name(&self) -> std::option::Option<&str> {
self.fully_qualified_domain_name.as_deref()
}
/// <p>If the value of Type is <code>HTTP_STR_MATCH</code> or <code>HTTPS_STR_MATCH</code>, the string that you want Amazon Route 53 to search for in the response body from the specified resource. If the string appears in the response body, Route 53 considers the resource healthy.</p>
/// <p>Route 53 considers case when searching for <code>SearchString</code> in the response body. </p>
pub fn search_string(&self) -> std::option::Option<&str> {
self.search_string.as_deref()
}
/// <p>The number of seconds between the time that Amazon Route 53 gets a response from your endpoint and the time that it sends the next health check request. Each Route 53 health checker makes requests at this interval.</p> <important>
/// <p>You can't change the value of <code>RequestInterval</code> after you create a health check.</p>
/// </important>
/// <p>If you don't specify a value for <code>RequestInterval</code>, the default value is <code>30</code> seconds.</p>
pub fn request_interval(&self) -> std::option::Option<i32> {
self.request_interval
}
/// <p>The number of consecutive health checks that an endpoint must pass or fail for Amazon Route 53 to change the current status of the endpoint from unhealthy to healthy or vice versa. For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-determining-health-of-endpoints.html">How Amazon Route 53 Determines Whether an Endpoint Is Healthy</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// <p>If you don't specify a value for <code>FailureThreshold</code>, the default value is three health checks.</p>
pub fn failure_threshold(&self) -> std::option::Option<i32> {
self.failure_threshold
}
/// <p>Specify whether you want Amazon Route 53 to measure the latency between health checkers in multiple Amazon Web Services regions and your endpoint, and to display CloudWatch latency graphs on the <b>Health Checks</b> page in the Route 53 console.</p> <important>
/// <p>You can't change the value of <code>MeasureLatency</code> after you create a health check.</p>
/// </important>
pub fn measure_latency(&self) -> std::option::Option<bool> {
self.measure_latency
}
/// <p>Specify whether you want Amazon Route 53 to invert the status of a health check, for example, to consider a health check unhealthy when it otherwise would be considered healthy.</p>
pub fn inverted(&self) -> std::option::Option<bool> {
self.inverted
}
/// <p>Stops Route 53 from performing health checks. When you disable a health check, here's what happens:</p>
/// <ul>
/// <li> <p> <b>Health checks that check the health of endpoints:</b> Route 53 stops submitting requests to your application, server, or other resource.</p> </li>
/// <li> <p> <b>Calculated health checks:</b> Route 53 stops aggregating the status of the referenced health checks.</p> </li>
/// <li> <p> <b>Health checks that monitor CloudWatch alarms:</b> Route 53 stops monitoring the corresponding CloudWatch metrics.</p> </li>
/// </ul>
/// <p>After you disable a health check, Route 53 considers the status of the health check to always be healthy. If you configured DNS failover, Route 53 continues to route traffic to the corresponding resources. If you want to stop routing traffic to a resource, change the value of <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_UpdateHealthCheck.html#Route53-UpdateHealthCheck-request-Inverted">Inverted</a>. </p>
/// <p>Charges for a health check still apply when the health check is disabled. For more information, see <a href="http://aws.amazon.com/route53/pricing/">Amazon Route 53 Pricing</a>.</p>
pub fn disabled(&self) -> std::option::Option<bool> {
self.disabled
}
/// <p>The number of child health checks that are associated with a <code>CALCULATED</code> health check that Amazon Route 53 must consider healthy for the <code>CALCULATED</code> health check to be considered healthy. To specify the child health checks that you want to associate with a <code>CALCULATED</code> health check, use the <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_UpdateHealthCheck.html#Route53-UpdateHealthCheck-request-ChildHealthChecks">ChildHealthChecks</a> element.</p>
/// <p>Note the following:</p>
/// <ul>
/// <li> <p>If you specify a number greater than the number of child health checks, Route 53 always considers this health check to be unhealthy.</p> </li>
/// <li> <p>If you specify <code>0</code>, Route 53 always considers this health check to be healthy.</p> </li>
/// </ul>
pub fn health_threshold(&self) -> std::option::Option<i32> {
self.health_threshold
}
/// <p>(CALCULATED Health Checks Only) A complex type that contains one <code>ChildHealthCheck</code> element for each health check that you want to associate with a <code>CALCULATED</code> health check.</p>
pub fn child_health_checks(&self) -> std::option::Option<&[std::string::String]> {
self.child_health_checks.as_deref()
}
/// <p>Specify whether you want Amazon Route 53 to send the value of <code>FullyQualifiedDomainName</code> to the endpoint in the <code>client_hello</code> message during TLS negotiation. This allows the endpoint to respond to <code>HTTPS</code> health check requests with the applicable SSL/TLS certificate.</p>
/// <p>Some endpoints require that <code>HTTPS</code> requests include the host name in the <code>client_hello</code> message. If you don't enable SNI, the status of the health check will be <code>SSL alert handshake_failure</code>. A health check can also have that status for other reasons. If SNI is enabled and you're still getting the error, check the SSL/TLS configuration on your endpoint and confirm that your certificate is valid.</p>
/// <p>The SSL/TLS certificate on your endpoint includes a domain name in the <code>Common Name</code> field and possibly several more in the <code>Subject Alternative Names</code> field. One of the domain names in the certificate should match the value that you specify for <code>FullyQualifiedDomainName</code>. If the endpoint responds to the <code>client_hello</code> message with a certificate that does not include the domain name that you specified in <code>FullyQualifiedDomainName</code>, a health checker will retry the handshake. In the second attempt, the health checker will omit <code>FullyQualifiedDomainName</code> from the <code>client_hello</code> message.</p>
pub fn enable_sni(&self) -> std::option::Option<bool> {
self.enable_sni
}
/// <p>A complex type that contains one <code>Region</code> element for each region from which you want Amazon Route 53 health checkers to check the specified endpoint.</p>
/// <p>If you don't specify any regions, Route 53 health checkers automatically performs checks from all of the regions that are listed under <b>Valid Values</b>.</p>
/// <p>If you update a health check to remove a region that has been performing health checks, Route 53 will briefly continue to perform checks from that region to ensure that some health checkers are always checking the endpoint (for example, if you replace three regions with four different regions). </p>
pub fn regions(&self) -> std::option::Option<&[crate::model::HealthCheckRegion]> {
self.regions.as_deref()
}
/// <p>A complex type that identifies the CloudWatch alarm that you want Amazon Route 53 health checkers to use to determine whether the specified health check is healthy.</p>
pub fn alarm_identifier(&self) -> std::option::Option<&crate::model::AlarmIdentifier> {
self.alarm_identifier.as_ref()
}
/// <p>When CloudWatch has insufficient data about the metric to determine the alarm state, the status that you want Amazon Route 53 to assign to the health check:</p>
/// <ul>
/// <li> <p> <code>Healthy</code>: Route 53 considers the health check to be healthy.</p> </li>
/// <li> <p> <code>Unhealthy</code>: Route 53 considers the health check to be unhealthy.</p> </li>
/// <li> <p> <code>LastKnownStatus</code>: Route 53 uses the status of the health check from the last time that CloudWatch had sufficient data to determine the alarm state. For new health checks that have no last known status, the default status for the health check is healthy.</p> </li>
/// </ul>
pub fn insufficient_data_health_status(
&self,
) -> std::option::Option<&crate::model::InsufficientDataHealthStatus> {
self.insufficient_data_health_status.as_ref()
}
/// <p>The Amazon Resource Name (ARN) for the Route 53 Application Recovery Controller routing control.</p>
/// <p>For more information about Route 53 Application Recovery Controller, see <a href="https://docs.aws.amazon.com/r53recovery/latest/dg/what-is-route-53-recovery.html">Route 53 Application Recovery Controller Developer Guide.</a>.</p>
pub fn routing_control_arn(&self) -> std::option::Option<&str> {
self.routing_control_arn.as_deref()
}
}
impl std::fmt::Debug for HealthCheckConfig {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("HealthCheckConfig");
formatter.field("ip_address", &self.ip_address);
formatter.field("port", &self.port);
formatter.field("r#type", &self.r#type);
formatter.field("resource_path", &self.resource_path);
formatter.field(
"fully_qualified_domain_name",
&self.fully_qualified_domain_name,
);
formatter.field("search_string", &self.search_string);
formatter.field("request_interval", &self.request_interval);
formatter.field("failure_threshold", &self.failure_threshold);
formatter.field("measure_latency", &self.measure_latency);
formatter.field("inverted", &self.inverted);
formatter.field("disabled", &self.disabled);
formatter.field("health_threshold", &self.health_threshold);
formatter.field("child_health_checks", &self.child_health_checks);
formatter.field("enable_sni", &self.enable_sni);
formatter.field("regions", &self.regions);
formatter.field("alarm_identifier", &self.alarm_identifier);
formatter.field(
"insufficient_data_health_status",
&self.insufficient_data_health_status,
);
formatter.field("routing_control_arn", &self.routing_control_arn);
formatter.finish()
}
}
/// See [`HealthCheckConfig`](crate::model::HealthCheckConfig)
pub mod health_check_config {
/// A builder for [`HealthCheckConfig`](crate::model::HealthCheckConfig)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) ip_address: std::option::Option<std::string::String>,
pub(crate) port: std::option::Option<i32>,
pub(crate) r#type: std::option::Option<crate::model::HealthCheckType>,
pub(crate) resource_path: std::option::Option<std::string::String>,
pub(crate) fully_qualified_domain_name: std::option::Option<std::string::String>,
pub(crate) search_string: std::option::Option<std::string::String>,
pub(crate) request_interval: std::option::Option<i32>,
pub(crate) failure_threshold: std::option::Option<i32>,
pub(crate) measure_latency: std::option::Option<bool>,
pub(crate) inverted: std::option::Option<bool>,
pub(crate) disabled: std::option::Option<bool>,
pub(crate) health_threshold: std::option::Option<i32>,
pub(crate) child_health_checks: std::option::Option<std::vec::Vec<std::string::String>>,
pub(crate) enable_sni: std::option::Option<bool>,
pub(crate) regions: std::option::Option<std::vec::Vec<crate::model::HealthCheckRegion>>,
pub(crate) alarm_identifier: std::option::Option<crate::model::AlarmIdentifier>,
pub(crate) insufficient_data_health_status:
std::option::Option<crate::model::InsufficientDataHealthStatus>,
pub(crate) routing_control_arn: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The IPv4 or IPv6 IP address of the endpoint that you want Amazon Route 53 to perform health checks on. If you don't specify a value for <code>IPAddress</code>, Route 53 sends a DNS request to resolve the domain name that you specify in <code>FullyQualifiedDomainName</code> at the interval that you specify in <code>RequestInterval</code>. Using an IP address returned by DNS, Route 53 then checks the health of the endpoint.</p>
/// <p>Use one of the following formats for the value of <code>IPAddress</code>: </p>
/// <ul>
/// <li> <p> <b>IPv4 address</b>: four values between 0 and 255, separated by periods (.), for example, <code>192.0.2.44</code>.</p> </li>
/// <li> <p> <b>IPv6 address</b>: eight groups of four hexadecimal values, separated by colons (:), for example, <code>2001:0db8:85a3:0000:0000:abcd:0001:2345</code>. You can also shorten IPv6 addresses as described in RFC 5952, for example, <code>2001:db8:85a3::abcd:1:2345</code>.</p> </li>
/// </ul>
/// <p>If the endpoint is an EC2 instance, we recommend that you create an Elastic IP address, associate it with your EC2 instance, and specify the Elastic IP address for <code>IPAddress</code>. This ensures that the IP address of your instance will never change.</p>
/// <p>For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_UpdateHealthCheck.html#Route53-UpdateHealthCheck-request-FullyQualifiedDomainName">FullyQualifiedDomainName</a>. </p>
/// <p>Constraints: Route 53 can't check the health of endpoints for which the IP address is in local, private, non-routable, or multicast ranges. For more information about IP addresses for which you can't create health checks, see the following documents:</p>
/// <ul>
/// <li> <p> <a href="https://tools.ietf.org/html/rfc5735">RFC 5735, Special Use IPv4 Addresses</a> </p> </li>
/// <li> <p> <a href="https://tools.ietf.org/html/rfc6598">RFC 6598, IANA-Reserved IPv4 Prefix for Shared Address Space</a> </p> </li>
/// <li> <p> <a href="https://tools.ietf.org/html/rfc5156">RFC 5156, Special-Use IPv6 Addresses</a> </p> </li>
/// </ul>
/// <p>When the value of <code>Type</code> is <code>CALCULATED</code> or <code>CLOUDWATCH_METRIC</code>, omit <code>IPAddress</code>.</p>
pub fn ip_address(mut self, input: impl Into<std::string::String>) -> Self {
self.ip_address = Some(input.into());
self
}
/// <p>The IPv4 or IPv6 IP address of the endpoint that you want Amazon Route 53 to perform health checks on. If you don't specify a value for <code>IPAddress</code>, Route 53 sends a DNS request to resolve the domain name that you specify in <code>FullyQualifiedDomainName</code> at the interval that you specify in <code>RequestInterval</code>. Using an IP address returned by DNS, Route 53 then checks the health of the endpoint.</p>
/// <p>Use one of the following formats for the value of <code>IPAddress</code>: </p>
/// <ul>
/// <li> <p> <b>IPv4 address</b>: four values between 0 and 255, separated by periods (.), for example, <code>192.0.2.44</code>.</p> </li>
/// <li> <p> <b>IPv6 address</b>: eight groups of four hexadecimal values, separated by colons (:), for example, <code>2001:0db8:85a3:0000:0000:abcd:0001:2345</code>. You can also shorten IPv6 addresses as described in RFC 5952, for example, <code>2001:db8:85a3::abcd:1:2345</code>.</p> </li>
/// </ul>
/// <p>If the endpoint is an EC2 instance, we recommend that you create an Elastic IP address, associate it with your EC2 instance, and specify the Elastic IP address for <code>IPAddress</code>. This ensures that the IP address of your instance will never change.</p>
/// <p>For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_UpdateHealthCheck.html#Route53-UpdateHealthCheck-request-FullyQualifiedDomainName">FullyQualifiedDomainName</a>. </p>
/// <p>Constraints: Route 53 can't check the health of endpoints for which the IP address is in local, private, non-routable, or multicast ranges. For more information about IP addresses for which you can't create health checks, see the following documents:</p>
/// <ul>
/// <li> <p> <a href="https://tools.ietf.org/html/rfc5735">RFC 5735, Special Use IPv4 Addresses</a> </p> </li>
/// <li> <p> <a href="https://tools.ietf.org/html/rfc6598">RFC 6598, IANA-Reserved IPv4 Prefix for Shared Address Space</a> </p> </li>
/// <li> <p> <a href="https://tools.ietf.org/html/rfc5156">RFC 5156, Special-Use IPv6 Addresses</a> </p> </li>
/// </ul>
/// <p>When the value of <code>Type</code> is <code>CALCULATED</code> or <code>CLOUDWATCH_METRIC</code>, omit <code>IPAddress</code>.</p>
pub fn set_ip_address(mut self, input: std::option::Option<std::string::String>) -> Self {
self.ip_address = input;
self
}
/// <p>The port on the endpoint that you want Amazon Route 53 to perform health checks on.</p> <note>
/// <p>Don't specify a value for <code>Port</code> when you specify a value for <code>Type</code> of <code>CLOUDWATCH_METRIC</code> or <code>CALCULATED</code>.</p>
/// </note>
pub fn port(mut self, input: i32) -> Self {
self.port = Some(input);
self
}
/// <p>The port on the endpoint that you want Amazon Route 53 to perform health checks on.</p> <note>
/// <p>Don't specify a value for <code>Port</code> when you specify a value for <code>Type</code> of <code>CLOUDWATCH_METRIC</code> or <code>CALCULATED</code>.</p>
/// </note>
pub fn set_port(mut self, input: std::option::Option<i32>) -> Self {
self.port = input;
self
}
/// <p>The type of health check that you want to create, which indicates how Amazon Route 53 determines whether an endpoint is healthy.</p> <important>
/// <p>You can't change the value of <code>Type</code> after you create a health check.</p>
/// </important>
/// <p>You can create the following types of health checks:</p>
/// <ul>
/// <li> <p> <b>HTTP</b>: Route 53 tries to establish a TCP connection. If successful, Route 53 submits an HTTP request and waits for an HTTP status code of 200 or greater and less than 400.</p> </li>
/// <li> <p> <b>HTTPS</b>: Route 53 tries to establish a TCP connection. If successful, Route 53 submits an HTTPS request and waits for an HTTP status code of 200 or greater and less than 400.</p> <important>
/// <p>If you specify <code>HTTPS</code> for the value of <code>Type</code>, the endpoint must support TLS v1.0 or later.</p>
/// </important> </li>
/// <li> <p> <b>HTTP_STR_MATCH</b>: Route 53 tries to establish a TCP connection. If successful, Route 53 submits an HTTP request and searches the first 5,120 bytes of the response body for the string that you specify in <code>SearchString</code>.</p> </li>
/// <li> <p> <b>HTTPS_STR_MATCH</b>: Route 53 tries to establish a TCP connection. If successful, Route 53 submits an <code>HTTPS</code> request and searches the first 5,120 bytes of the response body for the string that you specify in <code>SearchString</code>.</p> </li>
/// <li> <p> <b>TCP</b>: Route 53 tries to establish a TCP connection.</p> </li>
/// <li> <p> <b>CLOUDWATCH_METRIC</b>: The health check is associated with a CloudWatch alarm. If the state of the alarm is <code>OK</code>, the health check is considered healthy. If the state is <code>ALARM</code>, the health check is considered unhealthy. If CloudWatch doesn't have sufficient data to determine whether the state is <code>OK</code> or <code>ALARM</code>, the health check status depends on the setting for <code>InsufficientDataHealthStatus</code>: <code>Healthy</code>, <code>Unhealthy</code>, or <code>LastKnownStatus</code>. </p> </li>
/// <li> <p> <b>CALCULATED</b>: For health checks that monitor the status of other health checks, Route 53 adds up the number of health checks that Route 53 health checkers consider to be healthy and compares that number with the value of <code>HealthThreshold</code>. </p> </li>
/// <li> <p> <b>RECOVERY_CONTROL</b>: The health check is assocated with a Route53 Application Recovery Controller routing control. If the routing control state is <code>ON</code>, the health check is considered healthy. If the state is <code>OFF</code>, the health check is considered unhealthy. </p> </li>
/// </ul>
/// <p>For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-determining-health-of-endpoints.html">How Route 53 Determines Whether an Endpoint Is Healthy</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
pub fn r#type(mut self, input: crate::model::HealthCheckType) -> Self {
self.r#type = Some(input);
self
}
/// <p>The type of health check that you want to create, which indicates how Amazon Route 53 determines whether an endpoint is healthy.</p> <important>
/// <p>You can't change the value of <code>Type</code> after you create a health check.</p>
/// </important>
/// <p>You can create the following types of health checks:</p>
/// <ul>
/// <li> <p> <b>HTTP</b>: Route 53 tries to establish a TCP connection. If successful, Route 53 submits an HTTP request and waits for an HTTP status code of 200 or greater and less than 400.</p> </li>
/// <li> <p> <b>HTTPS</b>: Route 53 tries to establish a TCP connection. If successful, Route 53 submits an HTTPS request and waits for an HTTP status code of 200 or greater and less than 400.</p> <important>
/// <p>If you specify <code>HTTPS</code> for the value of <code>Type</code>, the endpoint must support TLS v1.0 or later.</p>
/// </important> </li>
/// <li> <p> <b>HTTP_STR_MATCH</b>: Route 53 tries to establish a TCP connection. If successful, Route 53 submits an HTTP request and searches the first 5,120 bytes of the response body for the string that you specify in <code>SearchString</code>.</p> </li>
/// <li> <p> <b>HTTPS_STR_MATCH</b>: Route 53 tries to establish a TCP connection. If successful, Route 53 submits an <code>HTTPS</code> request and searches the first 5,120 bytes of the response body for the string that you specify in <code>SearchString</code>.</p> </li>
/// <li> <p> <b>TCP</b>: Route 53 tries to establish a TCP connection.</p> </li>
/// <li> <p> <b>CLOUDWATCH_METRIC</b>: The health check is associated with a CloudWatch alarm. If the state of the alarm is <code>OK</code>, the health check is considered healthy. If the state is <code>ALARM</code>, the health check is considered unhealthy. If CloudWatch doesn't have sufficient data to determine whether the state is <code>OK</code> or <code>ALARM</code>, the health check status depends on the setting for <code>InsufficientDataHealthStatus</code>: <code>Healthy</code>, <code>Unhealthy</code>, or <code>LastKnownStatus</code>. </p> </li>
/// <li> <p> <b>CALCULATED</b>: For health checks that monitor the status of other health checks, Route 53 adds up the number of health checks that Route 53 health checkers consider to be healthy and compares that number with the value of <code>HealthThreshold</code>. </p> </li>
/// <li> <p> <b>RECOVERY_CONTROL</b>: The health check is assocated with a Route53 Application Recovery Controller routing control. If the routing control state is <code>ON</code>, the health check is considered healthy. If the state is <code>OFF</code>, the health check is considered unhealthy. </p> </li>
/// </ul>
/// <p>For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-determining-health-of-endpoints.html">How Route 53 Determines Whether an Endpoint Is Healthy</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
pub fn set_type(
mut self,
input: std::option::Option<crate::model::HealthCheckType>,
) -> Self {
self.r#type = input;
self
}
/// <p>The path, if any, that you want Amazon Route 53 to request when performing health checks. The path can be any value for which your endpoint will return an HTTP status code of 2xx or 3xx when the endpoint is healthy, for example, the file /docs/route53-health-check.html. You can also include query string parameters, for example, <code>/welcome.html?language=jp&login=y</code>. </p>
pub fn resource_path(mut self, input: impl Into<std::string::String>) -> Self {
self.resource_path = Some(input.into());
self
}
/// <p>The path, if any, that you want Amazon Route 53 to request when performing health checks. The path can be any value for which your endpoint will return an HTTP status code of 2xx or 3xx when the endpoint is healthy, for example, the file /docs/route53-health-check.html. You can also include query string parameters, for example, <code>/welcome.html?language=jp&login=y</code>. </p>
pub fn set_resource_path(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.resource_path = input;
self
}
/// <p>Amazon Route 53 behavior depends on whether you specify a value for <code>IPAddress</code>.</p>
/// <p> <b>If you specify a value for</b> <code>IPAddress</code>:</p>
/// <p>Amazon Route 53 sends health check requests to the specified IPv4 or IPv6 address and passes the value of <code>FullyQualifiedDomainName</code> in the <code>Host</code> header for all health checks except TCP health checks. This is typically the fully qualified DNS name of the endpoint on which you want Route 53 to perform health checks.</p>
/// <p>When Route 53 checks the health of an endpoint, here is how it constructs the <code>Host</code> header:</p>
/// <ul>
/// <li> <p>If you specify a value of <code>80</code> for <code>Port</code> and <code>HTTP</code> or <code>HTTP_STR_MATCH</code> for <code>Type</code>, Route 53 passes the value of <code>FullyQualifiedDomainName</code> to the endpoint in the Host header. </p> </li>
/// <li> <p>If you specify a value of <code>443</code> for <code>Port</code> and <code>HTTPS</code> or <code>HTTPS_STR_MATCH</code> for <code>Type</code>, Route 53 passes the value of <code>FullyQualifiedDomainName</code> to the endpoint in the <code>Host</code> header.</p> </li>
/// <li> <p>If you specify another value for <code>Port</code> and any value except <code>TCP</code> for <code>Type</code>, Route 53 passes <code>FullyQualifiedDomainName:Port</code> to the endpoint in the <code>Host</code> header.</p> </li>
/// </ul>
/// <p>If you don't specify a value for <code>FullyQualifiedDomainName</code>, Route 53 substitutes the value of <code>IPAddress</code> in the <code>Host</code> header in each of the preceding cases.</p>
/// <p> <b>If you don't specify a value for</b> <code>IPAddress</code>:</p>
/// <p>Route 53 sends a DNS request to the domain that you specify for <code>FullyQualifiedDomainName</code> at the interval that you specify for <code>RequestInterval</code>. Using an IPv4 address that DNS returns, Route 53 then checks the health of the endpoint.</p> <note>
/// <p>If you don't specify a value for <code>IPAddress</code>, Route 53 uses only IPv4 to send health checks to the endpoint. If there's no resource record set with a type of A for the name that you specify for <code>FullyQualifiedDomainName</code>, the health check fails with a "DNS resolution failed" error.</p>
/// </note>
/// <p>If you want to check the health of weighted, latency, or failover resource record sets and you choose to specify the endpoint only by <code>FullyQualifiedDomainName</code>, we recommend that you create a separate health check for each endpoint. For example, create a health check for each HTTP server that is serving content for www.example.com. For the value of <code>FullyQualifiedDomainName</code>, specify the domain name of the server (such as us-east-2-www.example.com), not the name of the resource record sets (www.example.com).</p> <important>
/// <p>In this configuration, if you create a health check for which the value of <code>FullyQualifiedDomainName</code> matches the name of the resource record sets and you then associate the health check with those resource record sets, health check results will be unpredictable.</p>
/// </important>
/// <p>In addition, if the value that you specify for <code>Type</code> is <code>HTTP</code>, <code>HTTPS</code>, <code>HTTP_STR_MATCH</code>, or <code>HTTPS_STR_MATCH</code>, Route 53 passes the value of <code>FullyQualifiedDomainName</code> in the <code>Host</code> header, as it does when you specify a value for <code>IPAddress</code>. If the value of <code>Type</code> is <code>TCP</code>, Route 53 doesn't pass a <code>Host</code> header.</p>
pub fn fully_qualified_domain_name(
mut self,
input: impl Into<std::string::String>,
) -> Self {
self.fully_qualified_domain_name = Some(input.into());
self
}
/// <p>Amazon Route 53 behavior depends on whether you specify a value for <code>IPAddress</code>.</p>
/// <p> <b>If you specify a value for</b> <code>IPAddress</code>:</p>
/// <p>Amazon Route 53 sends health check requests to the specified IPv4 or IPv6 address and passes the value of <code>FullyQualifiedDomainName</code> in the <code>Host</code> header for all health checks except TCP health checks. This is typically the fully qualified DNS name of the endpoint on which you want Route 53 to perform health checks.</p>
/// <p>When Route 53 checks the health of an endpoint, here is how it constructs the <code>Host</code> header:</p>
/// <ul>
/// <li> <p>If you specify a value of <code>80</code> for <code>Port</code> and <code>HTTP</code> or <code>HTTP_STR_MATCH</code> for <code>Type</code>, Route 53 passes the value of <code>FullyQualifiedDomainName</code> to the endpoint in the Host header. </p> </li>
/// <li> <p>If you specify a value of <code>443</code> for <code>Port</code> and <code>HTTPS</code> or <code>HTTPS_STR_MATCH</code> for <code>Type</code>, Route 53 passes the value of <code>FullyQualifiedDomainName</code> to the endpoint in the <code>Host</code> header.</p> </li>
/// <li> <p>If you specify another value for <code>Port</code> and any value except <code>TCP</code> for <code>Type</code>, Route 53 passes <code>FullyQualifiedDomainName:Port</code> to the endpoint in the <code>Host</code> header.</p> </li>
/// </ul>
/// <p>If you don't specify a value for <code>FullyQualifiedDomainName</code>, Route 53 substitutes the value of <code>IPAddress</code> in the <code>Host</code> header in each of the preceding cases.</p>
/// <p> <b>If you don't specify a value for</b> <code>IPAddress</code>:</p>
/// <p>Route 53 sends a DNS request to the domain that you specify for <code>FullyQualifiedDomainName</code> at the interval that you specify for <code>RequestInterval</code>. Using an IPv4 address that DNS returns, Route 53 then checks the health of the endpoint.</p> <note>
/// <p>If you don't specify a value for <code>IPAddress</code>, Route 53 uses only IPv4 to send health checks to the endpoint. If there's no resource record set with a type of A for the name that you specify for <code>FullyQualifiedDomainName</code>, the health check fails with a "DNS resolution failed" error.</p>
/// </note>
/// <p>If you want to check the health of weighted, latency, or failover resource record sets and you choose to specify the endpoint only by <code>FullyQualifiedDomainName</code>, we recommend that you create a separate health check for each endpoint. For example, create a health check for each HTTP server that is serving content for www.example.com. For the value of <code>FullyQualifiedDomainName</code>, specify the domain name of the server (such as us-east-2-www.example.com), not the name of the resource record sets (www.example.com).</p> <important>
/// <p>In this configuration, if you create a health check for which the value of <code>FullyQualifiedDomainName</code> matches the name of the resource record sets and you then associate the health check with those resource record sets, health check results will be unpredictable.</p>
/// </important>
/// <p>In addition, if the value that you specify for <code>Type</code> is <code>HTTP</code>, <code>HTTPS</code>, <code>HTTP_STR_MATCH</code>, or <code>HTTPS_STR_MATCH</code>, Route 53 passes the value of <code>FullyQualifiedDomainName</code> in the <code>Host</code> header, as it does when you specify a value for <code>IPAddress</code>. If the value of <code>Type</code> is <code>TCP</code>, Route 53 doesn't pass a <code>Host</code> header.</p>
pub fn set_fully_qualified_domain_name(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.fully_qualified_domain_name = input;
self
}
/// <p>If the value of Type is <code>HTTP_STR_MATCH</code> or <code>HTTPS_STR_MATCH</code>, the string that you want Amazon Route 53 to search for in the response body from the specified resource. If the string appears in the response body, Route 53 considers the resource healthy.</p>
/// <p>Route 53 considers case when searching for <code>SearchString</code> in the response body. </p>
pub fn search_string(mut self, input: impl Into<std::string::String>) -> Self {
self.search_string = Some(input.into());
self
}
/// <p>If the value of Type is <code>HTTP_STR_MATCH</code> or <code>HTTPS_STR_MATCH</code>, the string that you want Amazon Route 53 to search for in the response body from the specified resource. If the string appears in the response body, Route 53 considers the resource healthy.</p>
/// <p>Route 53 considers case when searching for <code>SearchString</code> in the response body. </p>
pub fn set_search_string(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.search_string = input;
self
}
/// <p>The number of seconds between the time that Amazon Route 53 gets a response from your endpoint and the time that it sends the next health check request. Each Route 53 health checker makes requests at this interval.</p> <important>
/// <p>You can't change the value of <code>RequestInterval</code> after you create a health check.</p>
/// </important>
/// <p>If you don't specify a value for <code>RequestInterval</code>, the default value is <code>30</code> seconds.</p>
pub fn request_interval(mut self, input: i32) -> Self {
self.request_interval = Some(input);
self
}
/// <p>The number of seconds between the time that Amazon Route 53 gets a response from your endpoint and the time that it sends the next health check request. Each Route 53 health checker makes requests at this interval.</p> <important>
/// <p>You can't change the value of <code>RequestInterval</code> after you create a health check.</p>
/// </important>
/// <p>If you don't specify a value for <code>RequestInterval</code>, the default value is <code>30</code> seconds.</p>
pub fn set_request_interval(mut self, input: std::option::Option<i32>) -> Self {
self.request_interval = input;
self
}
/// <p>The number of consecutive health checks that an endpoint must pass or fail for Amazon Route 53 to change the current status of the endpoint from unhealthy to healthy or vice versa. For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-determining-health-of-endpoints.html">How Amazon Route 53 Determines Whether an Endpoint Is Healthy</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// <p>If you don't specify a value for <code>FailureThreshold</code>, the default value is three health checks.</p>
pub fn failure_threshold(mut self, input: i32) -> Self {
self.failure_threshold = Some(input);
self
}
/// <p>The number of consecutive health checks that an endpoint must pass or fail for Amazon Route 53 to change the current status of the endpoint from unhealthy to healthy or vice versa. For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-determining-health-of-endpoints.html">How Amazon Route 53 Determines Whether an Endpoint Is Healthy</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// <p>If you don't specify a value for <code>FailureThreshold</code>, the default value is three health checks.</p>
pub fn set_failure_threshold(mut self, input: std::option::Option<i32>) -> Self {
self.failure_threshold = input;
self
}
/// <p>Specify whether you want Amazon Route 53 to measure the latency between health checkers in multiple Amazon Web Services regions and your endpoint, and to display CloudWatch latency graphs on the <b>Health Checks</b> page in the Route 53 console.</p> <important>
/// <p>You can't change the value of <code>MeasureLatency</code> after you create a health check.</p>
/// </important>
pub fn measure_latency(mut self, input: bool) -> Self {
self.measure_latency = Some(input);
self
}
/// <p>Specify whether you want Amazon Route 53 to measure the latency between health checkers in multiple Amazon Web Services regions and your endpoint, and to display CloudWatch latency graphs on the <b>Health Checks</b> page in the Route 53 console.</p> <important>
/// <p>You can't change the value of <code>MeasureLatency</code> after you create a health check.</p>
/// </important>
pub fn set_measure_latency(mut self, input: std::option::Option<bool>) -> Self {
self.measure_latency = input;
self
}
/// <p>Specify whether you want Amazon Route 53 to invert the status of a health check, for example, to consider a health check unhealthy when it otherwise would be considered healthy.</p>
pub fn inverted(mut self, input: bool) -> Self {
self.inverted = Some(input);
self
}
/// <p>Specify whether you want Amazon Route 53 to invert the status of a health check, for example, to consider a health check unhealthy when it otherwise would be considered healthy.</p>
pub fn set_inverted(mut self, input: std::option::Option<bool>) -> Self {
self.inverted = input;
self
}
/// <p>Stops Route 53 from performing health checks. When you disable a health check, here's what happens:</p>
/// <ul>
/// <li> <p> <b>Health checks that check the health of endpoints:</b> Route 53 stops submitting requests to your application, server, or other resource.</p> </li>
/// <li> <p> <b>Calculated health checks:</b> Route 53 stops aggregating the status of the referenced health checks.</p> </li>
/// <li> <p> <b>Health checks that monitor CloudWatch alarms:</b> Route 53 stops monitoring the corresponding CloudWatch metrics.</p> </li>
/// </ul>
/// <p>After you disable a health check, Route 53 considers the status of the health check to always be healthy. If you configured DNS failover, Route 53 continues to route traffic to the corresponding resources. If you want to stop routing traffic to a resource, change the value of <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_UpdateHealthCheck.html#Route53-UpdateHealthCheck-request-Inverted">Inverted</a>. </p>
/// <p>Charges for a health check still apply when the health check is disabled. For more information, see <a href="http://aws.amazon.com/route53/pricing/">Amazon Route 53 Pricing</a>.</p>
pub fn disabled(mut self, input: bool) -> Self {
self.disabled = Some(input);
self
}
/// <p>Stops Route 53 from performing health checks. When you disable a health check, here's what happens:</p>
/// <ul>
/// <li> <p> <b>Health checks that check the health of endpoints:</b> Route 53 stops submitting requests to your application, server, or other resource.</p> </li>
/// <li> <p> <b>Calculated health checks:</b> Route 53 stops aggregating the status of the referenced health checks.</p> </li>
/// <li> <p> <b>Health checks that monitor CloudWatch alarms:</b> Route 53 stops monitoring the corresponding CloudWatch metrics.</p> </li>
/// </ul>
/// <p>After you disable a health check, Route 53 considers the status of the health check to always be healthy. If you configured DNS failover, Route 53 continues to route traffic to the corresponding resources. If you want to stop routing traffic to a resource, change the value of <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_UpdateHealthCheck.html#Route53-UpdateHealthCheck-request-Inverted">Inverted</a>. </p>
/// <p>Charges for a health check still apply when the health check is disabled. For more information, see <a href="http://aws.amazon.com/route53/pricing/">Amazon Route 53 Pricing</a>.</p>
pub fn set_disabled(mut self, input: std::option::Option<bool>) -> Self {
self.disabled = input;
self
}
/// <p>The number of child health checks that are associated with a <code>CALCULATED</code> health check that Amazon Route 53 must consider healthy for the <code>CALCULATED</code> health check to be considered healthy. To specify the child health checks that you want to associate with a <code>CALCULATED</code> health check, use the <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_UpdateHealthCheck.html#Route53-UpdateHealthCheck-request-ChildHealthChecks">ChildHealthChecks</a> element.</p>
/// <p>Note the following:</p>
/// <ul>
/// <li> <p>If you specify a number greater than the number of child health checks, Route 53 always considers this health check to be unhealthy.</p> </li>
/// <li> <p>If you specify <code>0</code>, Route 53 always considers this health check to be healthy.</p> </li>
/// </ul>
pub fn health_threshold(mut self, input: i32) -> Self {
self.health_threshold = Some(input);
self
}
/// <p>The number of child health checks that are associated with a <code>CALCULATED</code> health check that Amazon Route 53 must consider healthy for the <code>CALCULATED</code> health check to be considered healthy. To specify the child health checks that you want to associate with a <code>CALCULATED</code> health check, use the <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_UpdateHealthCheck.html#Route53-UpdateHealthCheck-request-ChildHealthChecks">ChildHealthChecks</a> element.</p>
/// <p>Note the following:</p>
/// <ul>
/// <li> <p>If you specify a number greater than the number of child health checks, Route 53 always considers this health check to be unhealthy.</p> </li>
/// <li> <p>If you specify <code>0</code>, Route 53 always considers this health check to be healthy.</p> </li>
/// </ul>
pub fn set_health_threshold(mut self, input: std::option::Option<i32>) -> Self {
self.health_threshold = input;
self
}
/// Appends an item to `child_health_checks`.
///
/// To override the contents of this collection use [`set_child_health_checks`](Self::set_child_health_checks).
///
/// <p>(CALCULATED Health Checks Only) A complex type that contains one <code>ChildHealthCheck</code> element for each health check that you want to associate with a <code>CALCULATED</code> health check.</p>
pub fn child_health_checks(mut self, input: impl Into<std::string::String>) -> Self {
let mut v = self.child_health_checks.unwrap_or_default();
v.push(input.into());
self.child_health_checks = Some(v);
self
}
/// <p>(CALCULATED Health Checks Only) A complex type that contains one <code>ChildHealthCheck</code> element for each health check that you want to associate with a <code>CALCULATED</code> health check.</p>
pub fn set_child_health_checks(
mut self,
input: std::option::Option<std::vec::Vec<std::string::String>>,
) -> Self {
self.child_health_checks = input;
self
}
/// <p>Specify whether you want Amazon Route 53 to send the value of <code>FullyQualifiedDomainName</code> to the endpoint in the <code>client_hello</code> message during TLS negotiation. This allows the endpoint to respond to <code>HTTPS</code> health check requests with the applicable SSL/TLS certificate.</p>
/// <p>Some endpoints require that <code>HTTPS</code> requests include the host name in the <code>client_hello</code> message. If you don't enable SNI, the status of the health check will be <code>SSL alert handshake_failure</code>. A health check can also have that status for other reasons. If SNI is enabled and you're still getting the error, check the SSL/TLS configuration on your endpoint and confirm that your certificate is valid.</p>
/// <p>The SSL/TLS certificate on your endpoint includes a domain name in the <code>Common Name</code> field and possibly several more in the <code>Subject Alternative Names</code> field. One of the domain names in the certificate should match the value that you specify for <code>FullyQualifiedDomainName</code>. If the endpoint responds to the <code>client_hello</code> message with a certificate that does not include the domain name that you specified in <code>FullyQualifiedDomainName</code>, a health checker will retry the handshake. In the second attempt, the health checker will omit <code>FullyQualifiedDomainName</code> from the <code>client_hello</code> message.</p>
pub fn enable_sni(mut self, input: bool) -> Self {
self.enable_sni = Some(input);
self
}
/// <p>Specify whether you want Amazon Route 53 to send the value of <code>FullyQualifiedDomainName</code> to the endpoint in the <code>client_hello</code> message during TLS negotiation. This allows the endpoint to respond to <code>HTTPS</code> health check requests with the applicable SSL/TLS certificate.</p>
/// <p>Some endpoints require that <code>HTTPS</code> requests include the host name in the <code>client_hello</code> message. If you don't enable SNI, the status of the health check will be <code>SSL alert handshake_failure</code>. A health check can also have that status for other reasons. If SNI is enabled and you're still getting the error, check the SSL/TLS configuration on your endpoint and confirm that your certificate is valid.</p>
/// <p>The SSL/TLS certificate on your endpoint includes a domain name in the <code>Common Name</code> field and possibly several more in the <code>Subject Alternative Names</code> field. One of the domain names in the certificate should match the value that you specify for <code>FullyQualifiedDomainName</code>. If the endpoint responds to the <code>client_hello</code> message with a certificate that does not include the domain name that you specified in <code>FullyQualifiedDomainName</code>, a health checker will retry the handshake. In the second attempt, the health checker will omit <code>FullyQualifiedDomainName</code> from the <code>client_hello</code> message.</p>
pub fn set_enable_sni(mut self, input: std::option::Option<bool>) -> Self {
self.enable_sni = input;
self
}
/// Appends an item to `regions`.
///
/// To override the contents of this collection use [`set_regions`](Self::set_regions).
///
/// <p>A complex type that contains one <code>Region</code> element for each region from which you want Amazon Route 53 health checkers to check the specified endpoint.</p>
/// <p>If you don't specify any regions, Route 53 health checkers automatically performs checks from all of the regions that are listed under <b>Valid Values</b>.</p>
/// <p>If you update a health check to remove a region that has been performing health checks, Route 53 will briefly continue to perform checks from that region to ensure that some health checkers are always checking the endpoint (for example, if you replace three regions with four different regions). </p>
pub fn regions(mut self, input: crate::model::HealthCheckRegion) -> Self {
let mut v = self.regions.unwrap_or_default();
v.push(input);
self.regions = Some(v);
self
}
/// <p>A complex type that contains one <code>Region</code> element for each region from which you want Amazon Route 53 health checkers to check the specified endpoint.</p>
/// <p>If you don't specify any regions, Route 53 health checkers automatically performs checks from all of the regions that are listed under <b>Valid Values</b>.</p>
/// <p>If you update a health check to remove a region that has been performing health checks, Route 53 will briefly continue to perform checks from that region to ensure that some health checkers are always checking the endpoint (for example, if you replace three regions with four different regions). </p>
pub fn set_regions(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::HealthCheckRegion>>,
) -> Self {
self.regions = input;
self
}
/// <p>A complex type that identifies the CloudWatch alarm that you want Amazon Route 53 health checkers to use to determine whether the specified health check is healthy.</p>
pub fn alarm_identifier(mut self, input: crate::model::AlarmIdentifier) -> Self {
self.alarm_identifier = Some(input);
self
}
/// <p>A complex type that identifies the CloudWatch alarm that you want Amazon Route 53 health checkers to use to determine whether the specified health check is healthy.</p>
pub fn set_alarm_identifier(
mut self,
input: std::option::Option<crate::model::AlarmIdentifier>,
) -> Self {
self.alarm_identifier = input;
self
}
/// <p>When CloudWatch has insufficient data about the metric to determine the alarm state, the status that you want Amazon Route 53 to assign to the health check:</p>
/// <ul>
/// <li> <p> <code>Healthy</code>: Route 53 considers the health check to be healthy.</p> </li>
/// <li> <p> <code>Unhealthy</code>: Route 53 considers the health check to be unhealthy.</p> </li>
/// <li> <p> <code>LastKnownStatus</code>: Route 53 uses the status of the health check from the last time that CloudWatch had sufficient data to determine the alarm state. For new health checks that have no last known status, the default status for the health check is healthy.</p> </li>
/// </ul>
pub fn insufficient_data_health_status(
mut self,
input: crate::model::InsufficientDataHealthStatus,
) -> Self {
self.insufficient_data_health_status = Some(input);
self
}
/// <p>When CloudWatch has insufficient data about the metric to determine the alarm state, the status that you want Amazon Route 53 to assign to the health check:</p>
/// <ul>
/// <li> <p> <code>Healthy</code>: Route 53 considers the health check to be healthy.</p> </li>
/// <li> <p> <code>Unhealthy</code>: Route 53 considers the health check to be unhealthy.</p> </li>
/// <li> <p> <code>LastKnownStatus</code>: Route 53 uses the status of the health check from the last time that CloudWatch had sufficient data to determine the alarm state. For new health checks that have no last known status, the default status for the health check is healthy.</p> </li>
/// </ul>
pub fn set_insufficient_data_health_status(
mut self,
input: std::option::Option<crate::model::InsufficientDataHealthStatus>,
) -> Self {
self.insufficient_data_health_status = input;
self
}
/// <p>The Amazon Resource Name (ARN) for the Route 53 Application Recovery Controller routing control.</p>
/// <p>For more information about Route 53 Application Recovery Controller, see <a href="https://docs.aws.amazon.com/r53recovery/latest/dg/what-is-route-53-recovery.html">Route 53 Application Recovery Controller Developer Guide.</a>.</p>
pub fn routing_control_arn(mut self, input: impl Into<std::string::String>) -> Self {
self.routing_control_arn = Some(input.into());
self
}
/// <p>The Amazon Resource Name (ARN) for the Route 53 Application Recovery Controller routing control.</p>
/// <p>For more information about Route 53 Application Recovery Controller, see <a href="https://docs.aws.amazon.com/r53recovery/latest/dg/what-is-route-53-recovery.html">Route 53 Application Recovery Controller Developer Guide.</a>.</p>
pub fn set_routing_control_arn(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.routing_control_arn = input;
self
}
/// Consumes the builder and constructs a [`HealthCheckConfig`](crate::model::HealthCheckConfig)
pub fn build(self) -> crate::model::HealthCheckConfig {
crate::model::HealthCheckConfig {
ip_address: self.ip_address,
port: self.port,
r#type: self.r#type,
resource_path: self.resource_path,
fully_qualified_domain_name: self.fully_qualified_domain_name,
search_string: self.search_string,
request_interval: self.request_interval,
failure_threshold: self.failure_threshold,
measure_latency: self.measure_latency,
inverted: self.inverted,
disabled: self.disabled,
health_threshold: self.health_threshold,
child_health_checks: self.child_health_checks,
enable_sni: self.enable_sni,
regions: self.regions,
alarm_identifier: self.alarm_identifier,
insufficient_data_health_status: self.insufficient_data_health_status,
routing_control_arn: self.routing_control_arn,
}
}
}
}
impl HealthCheckConfig {
/// Creates a new builder-style object to manufacture [`HealthCheckConfig`](crate::model::HealthCheckConfig)
pub fn builder() -> crate::model::health_check_config::Builder {
crate::model::health_check_config::Builder::default()
}
}
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum InsufficientDataHealthStatus {
#[allow(missing_docs)] // documentation missing in model
Healthy,
#[allow(missing_docs)] // documentation missing in model
LastKnownStatus,
#[allow(missing_docs)] // documentation missing in model
Unhealthy,
/// Unknown contains new variants that have been added since this code was generated.
Unknown(String),
}
impl std::convert::From<&str> for InsufficientDataHealthStatus {
fn from(s: &str) -> Self {
match s {
"Healthy" => InsufficientDataHealthStatus::Healthy,
"LastKnownStatus" => InsufficientDataHealthStatus::LastKnownStatus,
"Unhealthy" => InsufficientDataHealthStatus::Unhealthy,
other => InsufficientDataHealthStatus::Unknown(other.to_owned()),
}
}
}
impl std::str::FromStr for InsufficientDataHealthStatus {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(InsufficientDataHealthStatus::from(s))
}
}
impl InsufficientDataHealthStatus {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
InsufficientDataHealthStatus::Healthy => "Healthy",
InsufficientDataHealthStatus::LastKnownStatus => "LastKnownStatus",
InsufficientDataHealthStatus::Unhealthy => "Unhealthy",
InsufficientDataHealthStatus::Unknown(s) => s.as_ref(),
}
}
/// Returns all the `&str` values of the enum members.
pub fn values() -> &'static [&'static str] {
&["Healthy", "LastKnownStatus", "Unhealthy"]
}
}
impl AsRef<str> for InsufficientDataHealthStatus {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>A complex type that identifies the CloudWatch alarm that you want Amazon Route 53 health checkers to use to determine whether the specified health check is healthy.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct AlarmIdentifier {
/// <p>For the CloudWatch alarm that you want Route 53 health checkers to use to determine whether this health check is healthy, the region that the alarm was created in.</p>
/// <p>For the current list of CloudWatch regions, see <a href="https://docs.aws.amazon.com/general/latest/gr/cw_region.html">Amazon CloudWatch endpoints and quotas</a> in the <i>Amazon Web Services General Reference</i>.</p>
pub region: std::option::Option<crate::model::CloudWatchRegion>,
/// <p>The name of the CloudWatch alarm that you want Amazon Route 53 health checkers to use to determine whether this health check is healthy.</p> <note>
/// <p>Route 53 supports CloudWatch alarms with the following features:</p>
/// <ul>
/// <li> <p>Standard-resolution metrics. High-resolution metrics aren't supported. For more information, see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/publishingMetrics.html#high-resolution-metrics">High-Resolution Metrics</a> in the <i>Amazon CloudWatch User Guide</i>.</p> </li>
/// <li> <p>Statistics: Average, Minimum, Maximum, Sum, and SampleCount. Extended statistics aren't supported.</p> </li>
/// </ul>
/// </note>
pub name: std::option::Option<std::string::String>,
}
impl AlarmIdentifier {
/// <p>For the CloudWatch alarm that you want Route 53 health checkers to use to determine whether this health check is healthy, the region that the alarm was created in.</p>
/// <p>For the current list of CloudWatch regions, see <a href="https://docs.aws.amazon.com/general/latest/gr/cw_region.html">Amazon CloudWatch endpoints and quotas</a> in the <i>Amazon Web Services General Reference</i>.</p>
pub fn region(&self) -> std::option::Option<&crate::model::CloudWatchRegion> {
self.region.as_ref()
}
/// <p>The name of the CloudWatch alarm that you want Amazon Route 53 health checkers to use to determine whether this health check is healthy.</p> <note>
/// <p>Route 53 supports CloudWatch alarms with the following features:</p>
/// <ul>
/// <li> <p>Standard-resolution metrics. High-resolution metrics aren't supported. For more information, see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/publishingMetrics.html#high-resolution-metrics">High-Resolution Metrics</a> in the <i>Amazon CloudWatch User Guide</i>.</p> </li>
/// <li> <p>Statistics: Average, Minimum, Maximum, Sum, and SampleCount. Extended statistics aren't supported.</p> </li>
/// </ul>
/// </note>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
}
impl std::fmt::Debug for AlarmIdentifier {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("AlarmIdentifier");
formatter.field("region", &self.region);
formatter.field("name", &self.name);
formatter.finish()
}
}
/// See [`AlarmIdentifier`](crate::model::AlarmIdentifier)
pub mod alarm_identifier {
/// A builder for [`AlarmIdentifier`](crate::model::AlarmIdentifier)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) region: std::option::Option<crate::model::CloudWatchRegion>,
pub(crate) name: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>For the CloudWatch alarm that you want Route 53 health checkers to use to determine whether this health check is healthy, the region that the alarm was created in.</p>
/// <p>For the current list of CloudWatch regions, see <a href="https://docs.aws.amazon.com/general/latest/gr/cw_region.html">Amazon CloudWatch endpoints and quotas</a> in the <i>Amazon Web Services General Reference</i>.</p>
pub fn region(mut self, input: crate::model::CloudWatchRegion) -> Self {
self.region = Some(input);
self
}
/// <p>For the CloudWatch alarm that you want Route 53 health checkers to use to determine whether this health check is healthy, the region that the alarm was created in.</p>
/// <p>For the current list of CloudWatch regions, see <a href="https://docs.aws.amazon.com/general/latest/gr/cw_region.html">Amazon CloudWatch endpoints and quotas</a> in the <i>Amazon Web Services General Reference</i>.</p>
pub fn set_region(
mut self,
input: std::option::Option<crate::model::CloudWatchRegion>,
) -> Self {
self.region = input;
self
}
/// <p>The name of the CloudWatch alarm that you want Amazon Route 53 health checkers to use to determine whether this health check is healthy.</p> <note>
/// <p>Route 53 supports CloudWatch alarms with the following features:</p>
/// <ul>
/// <li> <p>Standard-resolution metrics. High-resolution metrics aren't supported. For more information, see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/publishingMetrics.html#high-resolution-metrics">High-Resolution Metrics</a> in the <i>Amazon CloudWatch User Guide</i>.</p> </li>
/// <li> <p>Statistics: Average, Minimum, Maximum, Sum, and SampleCount. Extended statistics aren't supported.</p> </li>
/// </ul>
/// </note>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The name of the CloudWatch alarm that you want Amazon Route 53 health checkers to use to determine whether this health check is healthy.</p> <note>
/// <p>Route 53 supports CloudWatch alarms with the following features:</p>
/// <ul>
/// <li> <p>Standard-resolution metrics. High-resolution metrics aren't supported. For more information, see <a href="https://docs.aws.amazon.com/AmazonCloudWatch/latest/DeveloperGuide/publishingMetrics.html#high-resolution-metrics">High-Resolution Metrics</a> in the <i>Amazon CloudWatch User Guide</i>.</p> </li>
/// <li> <p>Statistics: Average, Minimum, Maximum, Sum, and SampleCount. Extended statistics aren't supported.</p> </li>
/// </ul>
/// </note>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// Consumes the builder and constructs a [`AlarmIdentifier`](crate::model::AlarmIdentifier)
pub fn build(self) -> crate::model::AlarmIdentifier {
crate::model::AlarmIdentifier {
region: self.region,
name: self.name,
}
}
}
}
impl AlarmIdentifier {
/// Creates a new builder-style object to manufacture [`AlarmIdentifier`](crate::model::AlarmIdentifier)
pub fn builder() -> crate::model::alarm_identifier::Builder {
crate::model::alarm_identifier::Builder::default()
}
}
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum CloudWatchRegion {
#[allow(missing_docs)] // documentation missing in model
AfSouth1,
#[allow(missing_docs)] // documentation missing in model
ApEast1,
#[allow(missing_docs)] // documentation missing in model
ApNortheast1,
#[allow(missing_docs)] // documentation missing in model
ApNortheast2,
#[allow(missing_docs)] // documentation missing in model
ApNortheast3,
#[allow(missing_docs)] // documentation missing in model
ApSouth1,
#[allow(missing_docs)] // documentation missing in model
ApSoutheast1,
#[allow(missing_docs)] // documentation missing in model
ApSoutheast2,
#[allow(missing_docs)] // documentation missing in model
ApSoutheast3,
#[allow(missing_docs)] // documentation missing in model
CaCentral1,
#[allow(missing_docs)] // documentation missing in model
CnNorth1,
#[allow(missing_docs)] // documentation missing in model
CnNorthwest1,
#[allow(missing_docs)] // documentation missing in model
EuCentral1,
#[allow(missing_docs)] // documentation missing in model
EuNorth1,
#[allow(missing_docs)] // documentation missing in model
EuSouth1,
#[allow(missing_docs)] // documentation missing in model
EuWest1,
#[allow(missing_docs)] // documentation missing in model
EuWest2,
#[allow(missing_docs)] // documentation missing in model
EuWest3,
#[allow(missing_docs)] // documentation missing in model
MeSouth1,
#[allow(missing_docs)] // documentation missing in model
SaEast1,
#[allow(missing_docs)] // documentation missing in model
UsEast1,
#[allow(missing_docs)] // documentation missing in model
UsEast2,
#[allow(missing_docs)] // documentation missing in model
UsGovEast1,
#[allow(missing_docs)] // documentation missing in model
UsGovWest1,
#[allow(missing_docs)] // documentation missing in model
UsIsoEast1,
#[allow(missing_docs)] // documentation missing in model
UsIsoWest1,
#[allow(missing_docs)] // documentation missing in model
UsIsobEast1,
#[allow(missing_docs)] // documentation missing in model
UsWest1,
#[allow(missing_docs)] // documentation missing in model
UsWest2,
/// Unknown contains new variants that have been added since this code was generated.
Unknown(String),
}
impl std::convert::From<&str> for CloudWatchRegion {
fn from(s: &str) -> Self {
match s {
"af-south-1" => CloudWatchRegion::AfSouth1,
"ap-east-1" => CloudWatchRegion::ApEast1,
"ap-northeast-1" => CloudWatchRegion::ApNortheast1,
"ap-northeast-2" => CloudWatchRegion::ApNortheast2,
"ap-northeast-3" => CloudWatchRegion::ApNortheast3,
"ap-south-1" => CloudWatchRegion::ApSouth1,
"ap-southeast-1" => CloudWatchRegion::ApSoutheast1,
"ap-southeast-2" => CloudWatchRegion::ApSoutheast2,
"ap-southeast-3" => CloudWatchRegion::ApSoutheast3,
"ca-central-1" => CloudWatchRegion::CaCentral1,
"cn-north-1" => CloudWatchRegion::CnNorth1,
"cn-northwest-1" => CloudWatchRegion::CnNorthwest1,
"eu-central-1" => CloudWatchRegion::EuCentral1,
"eu-north-1" => CloudWatchRegion::EuNorth1,
"eu-south-1" => CloudWatchRegion::EuSouth1,
"eu-west-1" => CloudWatchRegion::EuWest1,
"eu-west-2" => CloudWatchRegion::EuWest2,
"eu-west-3" => CloudWatchRegion::EuWest3,
"me-south-1" => CloudWatchRegion::MeSouth1,
"sa-east-1" => CloudWatchRegion::SaEast1,
"us-east-1" => CloudWatchRegion::UsEast1,
"us-east-2" => CloudWatchRegion::UsEast2,
"us-gov-east-1" => CloudWatchRegion::UsGovEast1,
"us-gov-west-1" => CloudWatchRegion::UsGovWest1,
"us-iso-east-1" => CloudWatchRegion::UsIsoEast1,
"us-iso-west-1" => CloudWatchRegion::UsIsoWest1,
"us-isob-east-1" => CloudWatchRegion::UsIsobEast1,
"us-west-1" => CloudWatchRegion::UsWest1,
"us-west-2" => CloudWatchRegion::UsWest2,
other => CloudWatchRegion::Unknown(other.to_owned()),
}
}
}
impl std::str::FromStr for CloudWatchRegion {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(CloudWatchRegion::from(s))
}
}
impl CloudWatchRegion {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
CloudWatchRegion::AfSouth1 => "af-south-1",
CloudWatchRegion::ApEast1 => "ap-east-1",
CloudWatchRegion::ApNortheast1 => "ap-northeast-1",
CloudWatchRegion::ApNortheast2 => "ap-northeast-2",
CloudWatchRegion::ApNortheast3 => "ap-northeast-3",
CloudWatchRegion::ApSouth1 => "ap-south-1",
CloudWatchRegion::ApSoutheast1 => "ap-southeast-1",
CloudWatchRegion::ApSoutheast2 => "ap-southeast-2",
CloudWatchRegion::ApSoutheast3 => "ap-southeast-3",
CloudWatchRegion::CaCentral1 => "ca-central-1",
CloudWatchRegion::CnNorth1 => "cn-north-1",
CloudWatchRegion::CnNorthwest1 => "cn-northwest-1",
CloudWatchRegion::EuCentral1 => "eu-central-1",
CloudWatchRegion::EuNorth1 => "eu-north-1",
CloudWatchRegion::EuSouth1 => "eu-south-1",
CloudWatchRegion::EuWest1 => "eu-west-1",
CloudWatchRegion::EuWest2 => "eu-west-2",
CloudWatchRegion::EuWest3 => "eu-west-3",
CloudWatchRegion::MeSouth1 => "me-south-1",
CloudWatchRegion::SaEast1 => "sa-east-1",
CloudWatchRegion::UsEast1 => "us-east-1",
CloudWatchRegion::UsEast2 => "us-east-2",
CloudWatchRegion::UsGovEast1 => "us-gov-east-1",
CloudWatchRegion::UsGovWest1 => "us-gov-west-1",
CloudWatchRegion::UsIsoEast1 => "us-iso-east-1",
CloudWatchRegion::UsIsoWest1 => "us-iso-west-1",
CloudWatchRegion::UsIsobEast1 => "us-isob-east-1",
CloudWatchRegion::UsWest1 => "us-west-1",
CloudWatchRegion::UsWest2 => "us-west-2",
CloudWatchRegion::Unknown(s) => s.as_ref(),
}
}
/// Returns all the `&str` values of the enum members.
pub fn values() -> &'static [&'static str] {
&[
"af-south-1",
"ap-east-1",
"ap-northeast-1",
"ap-northeast-2",
"ap-northeast-3",
"ap-south-1",
"ap-southeast-1",
"ap-southeast-2",
"ap-southeast-3",
"ca-central-1",
"cn-north-1",
"cn-northwest-1",
"eu-central-1",
"eu-north-1",
"eu-south-1",
"eu-west-1",
"eu-west-2",
"eu-west-3",
"me-south-1",
"sa-east-1",
"us-east-1",
"us-east-2",
"us-gov-east-1",
"us-gov-west-1",
"us-iso-east-1",
"us-iso-west-1",
"us-isob-east-1",
"us-west-1",
"us-west-2",
]
}
}
impl AsRef<str> for CloudWatchRegion {
fn as_ref(&self) -> &str {
self.as_str()
}
}
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum HealthCheckRegion {
#[allow(missing_docs)] // documentation missing in model
ApNortheast1,
#[allow(missing_docs)] // documentation missing in model
ApSoutheast1,
#[allow(missing_docs)] // documentation missing in model
ApSoutheast2,
#[allow(missing_docs)] // documentation missing in model
EuWest1,
#[allow(missing_docs)] // documentation missing in model
SaEast1,
#[allow(missing_docs)] // documentation missing in model
UsEast1,
#[allow(missing_docs)] // documentation missing in model
UsWest1,
#[allow(missing_docs)] // documentation missing in model
UsWest2,
/// Unknown contains new variants that have been added since this code was generated.
Unknown(String),
}
impl std::convert::From<&str> for HealthCheckRegion {
fn from(s: &str) -> Self {
match s {
"ap-northeast-1" => HealthCheckRegion::ApNortheast1,
"ap-southeast-1" => HealthCheckRegion::ApSoutheast1,
"ap-southeast-2" => HealthCheckRegion::ApSoutheast2,
"eu-west-1" => HealthCheckRegion::EuWest1,
"sa-east-1" => HealthCheckRegion::SaEast1,
"us-east-1" => HealthCheckRegion::UsEast1,
"us-west-1" => HealthCheckRegion::UsWest1,
"us-west-2" => HealthCheckRegion::UsWest2,
other => HealthCheckRegion::Unknown(other.to_owned()),
}
}
}
impl std::str::FromStr for HealthCheckRegion {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(HealthCheckRegion::from(s))
}
}
impl HealthCheckRegion {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
HealthCheckRegion::ApNortheast1 => "ap-northeast-1",
HealthCheckRegion::ApSoutheast1 => "ap-southeast-1",
HealthCheckRegion::ApSoutheast2 => "ap-southeast-2",
HealthCheckRegion::EuWest1 => "eu-west-1",
HealthCheckRegion::SaEast1 => "sa-east-1",
HealthCheckRegion::UsEast1 => "us-east-1",
HealthCheckRegion::UsWest1 => "us-west-1",
HealthCheckRegion::UsWest2 => "us-west-2",
HealthCheckRegion::Unknown(s) => s.as_ref(),
}
}
/// Returns all the `&str` values of the enum members.
pub fn values() -> &'static [&'static str] {
&[
"ap-northeast-1",
"ap-southeast-1",
"ap-southeast-2",
"eu-west-1",
"sa-east-1",
"us-east-1",
"us-west-1",
"us-west-2",
]
}
}
impl AsRef<str> for HealthCheckRegion {
fn as_ref(&self) -> &str {
self.as_str()
}
}
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum HealthCheckType {
#[allow(missing_docs)] // documentation missing in model
Calculated,
#[allow(missing_docs)] // documentation missing in model
CloudwatchMetric,
#[allow(missing_docs)] // documentation missing in model
Http,
#[allow(missing_docs)] // documentation missing in model
Https,
#[allow(missing_docs)] // documentation missing in model
HttpsStrMatch,
#[allow(missing_docs)] // documentation missing in model
HttpStrMatch,
#[allow(missing_docs)] // documentation missing in model
RecoveryControl,
#[allow(missing_docs)] // documentation missing in model
Tcp,
/// Unknown contains new variants that have been added since this code was generated.
Unknown(String),
}
impl std::convert::From<&str> for HealthCheckType {
fn from(s: &str) -> Self {
match s {
"CALCULATED" => HealthCheckType::Calculated,
"CLOUDWATCH_METRIC" => HealthCheckType::CloudwatchMetric,
"HTTP" => HealthCheckType::Http,
"HTTPS" => HealthCheckType::Https,
"HTTPS_STR_MATCH" => HealthCheckType::HttpsStrMatch,
"HTTP_STR_MATCH" => HealthCheckType::HttpStrMatch,
"RECOVERY_CONTROL" => HealthCheckType::RecoveryControl,
"TCP" => HealthCheckType::Tcp,
other => HealthCheckType::Unknown(other.to_owned()),
}
}
}
impl std::str::FromStr for HealthCheckType {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(HealthCheckType::from(s))
}
}
impl HealthCheckType {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
HealthCheckType::Calculated => "CALCULATED",
HealthCheckType::CloudwatchMetric => "CLOUDWATCH_METRIC",
HealthCheckType::Http => "HTTP",
HealthCheckType::Https => "HTTPS",
HealthCheckType::HttpsStrMatch => "HTTPS_STR_MATCH",
HealthCheckType::HttpStrMatch => "HTTP_STR_MATCH",
HealthCheckType::RecoveryControl => "RECOVERY_CONTROL",
HealthCheckType::Tcp => "TCP",
HealthCheckType::Unknown(s) => s.as_ref(),
}
}
/// Returns all the `&str` values of the enum members.
pub fn values() -> &'static [&'static str] {
&[
"CALCULATED",
"CLOUDWATCH_METRIC",
"HTTP",
"HTTPS",
"HTTPS_STR_MATCH",
"HTTP_STR_MATCH",
"RECOVERY_CONTROL",
"TCP",
]
}
}
impl AsRef<str> for HealthCheckType {
fn as_ref(&self) -> &str {
self.as_str()
}
}
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum ResettableElementName {
#[allow(missing_docs)] // documentation missing in model
ChildHealthChecks,
#[allow(missing_docs)] // documentation missing in model
FullyQualifiedDomainName,
#[allow(missing_docs)] // documentation missing in model
Regions,
#[allow(missing_docs)] // documentation missing in model
ResourcePath,
/// Unknown contains new variants that have been added since this code was generated.
Unknown(String),
}
impl std::convert::From<&str> for ResettableElementName {
fn from(s: &str) -> Self {
match s {
"ChildHealthChecks" => ResettableElementName::ChildHealthChecks,
"FullyQualifiedDomainName" => ResettableElementName::FullyQualifiedDomainName,
"Regions" => ResettableElementName::Regions,
"ResourcePath" => ResettableElementName::ResourcePath,
other => ResettableElementName::Unknown(other.to_owned()),
}
}
}
impl std::str::FromStr for ResettableElementName {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(ResettableElementName::from(s))
}
}
impl ResettableElementName {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
ResettableElementName::ChildHealthChecks => "ChildHealthChecks",
ResettableElementName::FullyQualifiedDomainName => "FullyQualifiedDomainName",
ResettableElementName::Regions => "Regions",
ResettableElementName::ResourcePath => "ResourcePath",
ResettableElementName::Unknown(s) => s.as_ref(),
}
}
/// Returns all the `&str` values of the enum members.
pub fn values() -> &'static [&'static str] {
&[
"ChildHealthChecks",
"FullyQualifiedDomainName",
"Regions",
"ResourcePath",
]
}
}
impl AsRef<str> for ResettableElementName {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>(Private hosted zones only) A complex type that contains information about an Amazon VPC.</p>
/// <p>If you associate a private hosted zone with an Amazon VPC when you make a <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_CreateHostedZone.html">CreateHostedZone</a> request, the following parameters are also required.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct Vpc {
/// <p>(Private hosted zones only) The region that an Amazon VPC was created in.</p>
pub vpc_region: std::option::Option<crate::model::VpcRegion>,
/// <p>(Private hosted zones only) The ID of an Amazon VPC. </p>
pub vpc_id: std::option::Option<std::string::String>,
}
impl Vpc {
/// <p>(Private hosted zones only) The region that an Amazon VPC was created in.</p>
pub fn vpc_region(&self) -> std::option::Option<&crate::model::VpcRegion> {
self.vpc_region.as_ref()
}
/// <p>(Private hosted zones only) The ID of an Amazon VPC. </p>
pub fn vpc_id(&self) -> std::option::Option<&str> {
self.vpc_id.as_deref()
}
}
impl std::fmt::Debug for Vpc {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("Vpc");
formatter.field("vpc_region", &self.vpc_region);
formatter.field("vpc_id", &self.vpc_id);
formatter.finish()
}
}
/// See [`Vpc`](crate::model::Vpc)
pub mod vpc {
/// A builder for [`Vpc`](crate::model::Vpc)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) vpc_region: std::option::Option<crate::model::VpcRegion>,
pub(crate) vpc_id: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>(Private hosted zones only) The region that an Amazon VPC was created in.</p>
pub fn vpc_region(mut self, input: crate::model::VpcRegion) -> Self {
self.vpc_region = Some(input);
self
}
/// <p>(Private hosted zones only) The region that an Amazon VPC was created in.</p>
pub fn set_vpc_region(
mut self,
input: std::option::Option<crate::model::VpcRegion>,
) -> Self {
self.vpc_region = input;
self
}
/// <p>(Private hosted zones only) The ID of an Amazon VPC. </p>
pub fn vpc_id(mut self, input: impl Into<std::string::String>) -> Self {
self.vpc_id = Some(input.into());
self
}
/// <p>(Private hosted zones only) The ID of an Amazon VPC. </p>
pub fn set_vpc_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.vpc_id = input;
self
}
/// Consumes the builder and constructs a [`Vpc`](crate::model::Vpc)
pub fn build(self) -> crate::model::Vpc {
crate::model::Vpc {
vpc_region: self.vpc_region,
vpc_id: self.vpc_id,
}
}
}
}
impl Vpc {
/// Creates a new builder-style object to manufacture [`Vpc`](crate::model::Vpc)
pub fn builder() -> crate::model::vpc::Builder {
crate::model::vpc::Builder::default()
}
}
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum VpcRegion {
#[allow(missing_docs)] // documentation missing in model
AfSouth1,
#[allow(missing_docs)] // documentation missing in model
ApEast1,
#[allow(missing_docs)] // documentation missing in model
ApNortheast1,
#[allow(missing_docs)] // documentation missing in model
ApNortheast2,
#[allow(missing_docs)] // documentation missing in model
ApNortheast3,
#[allow(missing_docs)] // documentation missing in model
ApSouth1,
#[allow(missing_docs)] // documentation missing in model
ApSoutheast1,
#[allow(missing_docs)] // documentation missing in model
ApSoutheast2,
#[allow(missing_docs)] // documentation missing in model
ApSoutheast3,
#[allow(missing_docs)] // documentation missing in model
CaCentral1,
#[allow(missing_docs)] // documentation missing in model
CnNorth1,
#[allow(missing_docs)] // documentation missing in model
EuCentral1,
#[allow(missing_docs)] // documentation missing in model
EuNorth1,
#[allow(missing_docs)] // documentation missing in model
EuSouth1,
#[allow(missing_docs)] // documentation missing in model
EuWest1,
#[allow(missing_docs)] // documentation missing in model
EuWest2,
#[allow(missing_docs)] // documentation missing in model
EuWest3,
#[allow(missing_docs)] // documentation missing in model
MeSouth1,
#[allow(missing_docs)] // documentation missing in model
SaEast1,
#[allow(missing_docs)] // documentation missing in model
UsEast1,
#[allow(missing_docs)] // documentation missing in model
UsEast2,
#[allow(missing_docs)] // documentation missing in model
UsGovEast1,
#[allow(missing_docs)] // documentation missing in model
UsGovWest1,
#[allow(missing_docs)] // documentation missing in model
UsIsoEast1,
#[allow(missing_docs)] // documentation missing in model
UsIsoWest1,
#[allow(missing_docs)] // documentation missing in model
UsIsobEast1,
#[allow(missing_docs)] // documentation missing in model
UsWest1,
#[allow(missing_docs)] // documentation missing in model
UsWest2,
/// Unknown contains new variants that have been added since this code was generated.
Unknown(String),
}
impl std::convert::From<&str> for VpcRegion {
fn from(s: &str) -> Self {
match s {
"af-south-1" => VpcRegion::AfSouth1,
"ap-east-1" => VpcRegion::ApEast1,
"ap-northeast-1" => VpcRegion::ApNortheast1,
"ap-northeast-2" => VpcRegion::ApNortheast2,
"ap-northeast-3" => VpcRegion::ApNortheast3,
"ap-south-1" => VpcRegion::ApSouth1,
"ap-southeast-1" => VpcRegion::ApSoutheast1,
"ap-southeast-2" => VpcRegion::ApSoutheast2,
"ap-southeast-3" => VpcRegion::ApSoutheast3,
"ca-central-1" => VpcRegion::CaCentral1,
"cn-north-1" => VpcRegion::CnNorth1,
"eu-central-1" => VpcRegion::EuCentral1,
"eu-north-1" => VpcRegion::EuNorth1,
"eu-south-1" => VpcRegion::EuSouth1,
"eu-west-1" => VpcRegion::EuWest1,
"eu-west-2" => VpcRegion::EuWest2,
"eu-west-3" => VpcRegion::EuWest3,
"me-south-1" => VpcRegion::MeSouth1,
"sa-east-1" => VpcRegion::SaEast1,
"us-east-1" => VpcRegion::UsEast1,
"us-east-2" => VpcRegion::UsEast2,
"us-gov-east-1" => VpcRegion::UsGovEast1,
"us-gov-west-1" => VpcRegion::UsGovWest1,
"us-iso-east-1" => VpcRegion::UsIsoEast1,
"us-iso-west-1" => VpcRegion::UsIsoWest1,
"us-isob-east-1" => VpcRegion::UsIsobEast1,
"us-west-1" => VpcRegion::UsWest1,
"us-west-2" => VpcRegion::UsWest2,
other => VpcRegion::Unknown(other.to_owned()),
}
}
}
impl std::str::FromStr for VpcRegion {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(VpcRegion::from(s))
}
}
impl VpcRegion {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
VpcRegion::AfSouth1 => "af-south-1",
VpcRegion::ApEast1 => "ap-east-1",
VpcRegion::ApNortheast1 => "ap-northeast-1",
VpcRegion::ApNortheast2 => "ap-northeast-2",
VpcRegion::ApNortheast3 => "ap-northeast-3",
VpcRegion::ApSouth1 => "ap-south-1",
VpcRegion::ApSoutheast1 => "ap-southeast-1",
VpcRegion::ApSoutheast2 => "ap-southeast-2",
VpcRegion::ApSoutheast3 => "ap-southeast-3",
VpcRegion::CaCentral1 => "ca-central-1",
VpcRegion::CnNorth1 => "cn-north-1",
VpcRegion::EuCentral1 => "eu-central-1",
VpcRegion::EuNorth1 => "eu-north-1",
VpcRegion::EuSouth1 => "eu-south-1",
VpcRegion::EuWest1 => "eu-west-1",
VpcRegion::EuWest2 => "eu-west-2",
VpcRegion::EuWest3 => "eu-west-3",
VpcRegion::MeSouth1 => "me-south-1",
VpcRegion::SaEast1 => "sa-east-1",
VpcRegion::UsEast1 => "us-east-1",
VpcRegion::UsEast2 => "us-east-2",
VpcRegion::UsGovEast1 => "us-gov-east-1",
VpcRegion::UsGovWest1 => "us-gov-west-1",
VpcRegion::UsIsoEast1 => "us-iso-east-1",
VpcRegion::UsIsoWest1 => "us-iso-west-1",
VpcRegion::UsIsobEast1 => "us-isob-east-1",
VpcRegion::UsWest1 => "us-west-1",
VpcRegion::UsWest2 => "us-west-2",
VpcRegion::Unknown(s) => s.as_ref(),
}
}
/// Returns all the `&str` values of the enum members.
pub fn values() -> &'static [&'static str] {
&[
"af-south-1",
"ap-east-1",
"ap-northeast-1",
"ap-northeast-2",
"ap-northeast-3",
"ap-south-1",
"ap-southeast-1",
"ap-southeast-2",
"ap-southeast-3",
"ca-central-1",
"cn-north-1",
"eu-central-1",
"eu-north-1",
"eu-south-1",
"eu-west-1",
"eu-west-2",
"eu-west-3",
"me-south-1",
"sa-east-1",
"us-east-1",
"us-east-2",
"us-gov-east-1",
"us-gov-west-1",
"us-iso-east-1",
"us-iso-west-1",
"us-isob-east-1",
"us-west-1",
"us-west-2",
]
}
}
impl AsRef<str> for VpcRegion {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>A complex type that contains information about the latest version of one traffic policy that is associated with the current Amazon Web Services account.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct TrafficPolicySummary {
/// <p>The ID that Amazon Route 53 assigned to the traffic policy when you created it.</p>
pub id: std::option::Option<std::string::String>,
/// <p>The name that you specified for the traffic policy when you created it.</p>
pub name: std::option::Option<std::string::String>,
/// <p>The DNS type of the resource record sets that Amazon Route 53 creates when you use a traffic policy to create a traffic policy instance.</p>
pub r#type: std::option::Option<crate::model::RrType>,
/// <p>The version number of the latest version of the traffic policy.</p>
pub latest_version: std::option::Option<i32>,
/// <p>The number of traffic policies that are associated with the current Amazon Web Services account.</p>
pub traffic_policy_count: std::option::Option<i32>,
}
impl TrafficPolicySummary {
/// <p>The ID that Amazon Route 53 assigned to the traffic policy when you created it.</p>
pub fn id(&self) -> std::option::Option<&str> {
self.id.as_deref()
}
/// <p>The name that you specified for the traffic policy when you created it.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>The DNS type of the resource record sets that Amazon Route 53 creates when you use a traffic policy to create a traffic policy instance.</p>
pub fn r#type(&self) -> std::option::Option<&crate::model::RrType> {
self.r#type.as_ref()
}
/// <p>The version number of the latest version of the traffic policy.</p>
pub fn latest_version(&self) -> std::option::Option<i32> {
self.latest_version
}
/// <p>The number of traffic policies that are associated with the current Amazon Web Services account.</p>
pub fn traffic_policy_count(&self) -> std::option::Option<i32> {
self.traffic_policy_count
}
}
impl std::fmt::Debug for TrafficPolicySummary {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("TrafficPolicySummary");
formatter.field("id", &self.id);
formatter.field("name", &self.name);
formatter.field("r#type", &self.r#type);
formatter.field("latest_version", &self.latest_version);
formatter.field("traffic_policy_count", &self.traffic_policy_count);
formatter.finish()
}
}
/// See [`TrafficPolicySummary`](crate::model::TrafficPolicySummary)
pub mod traffic_policy_summary {
/// A builder for [`TrafficPolicySummary`](crate::model::TrafficPolicySummary)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) id: std::option::Option<std::string::String>,
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) r#type: std::option::Option<crate::model::RrType>,
pub(crate) latest_version: std::option::Option<i32>,
pub(crate) traffic_policy_count: std::option::Option<i32>,
}
impl Builder {
/// <p>The ID that Amazon Route 53 assigned to the traffic policy when you created it.</p>
pub fn id(mut self, input: impl Into<std::string::String>) -> Self {
self.id = Some(input.into());
self
}
/// <p>The ID that Amazon Route 53 assigned to the traffic policy when you created it.</p>
pub fn set_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.id = input;
self
}
/// <p>The name that you specified for the traffic policy when you created it.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The name that you specified for the traffic policy when you created it.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// <p>The DNS type of the resource record sets that Amazon Route 53 creates when you use a traffic policy to create a traffic policy instance.</p>
pub fn r#type(mut self, input: crate::model::RrType) -> Self {
self.r#type = Some(input);
self
}
/// <p>The DNS type of the resource record sets that Amazon Route 53 creates when you use a traffic policy to create a traffic policy instance.</p>
pub fn set_type(mut self, input: std::option::Option<crate::model::RrType>) -> Self {
self.r#type = input;
self
}
/// <p>The version number of the latest version of the traffic policy.</p>
pub fn latest_version(mut self, input: i32) -> Self {
self.latest_version = Some(input);
self
}
/// <p>The version number of the latest version of the traffic policy.</p>
pub fn set_latest_version(mut self, input: std::option::Option<i32>) -> Self {
self.latest_version = input;
self
}
/// <p>The number of traffic policies that are associated with the current Amazon Web Services account.</p>
pub fn traffic_policy_count(mut self, input: i32) -> Self {
self.traffic_policy_count = Some(input);
self
}
/// <p>The number of traffic policies that are associated with the current Amazon Web Services account.</p>
pub fn set_traffic_policy_count(mut self, input: std::option::Option<i32>) -> Self {
self.traffic_policy_count = input;
self
}
/// Consumes the builder and constructs a [`TrafficPolicySummary`](crate::model::TrafficPolicySummary)
pub fn build(self) -> crate::model::TrafficPolicySummary {
crate::model::TrafficPolicySummary {
id: self.id,
name: self.name,
r#type: self.r#type,
latest_version: self.latest_version,
traffic_policy_count: self.traffic_policy_count,
}
}
}
}
impl TrafficPolicySummary {
/// Creates a new builder-style object to manufacture [`TrafficPolicySummary`](crate::model::TrafficPolicySummary)
pub fn builder() -> crate::model::traffic_policy_summary::Builder {
crate::model::traffic_policy_summary::Builder::default()
}
}
/// <p>A complex type containing a resource and its associated tags.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct ResourceTagSet {
/// <p>The type of the resource.</p>
/// <ul>
/// <li> <p>The resource type for health checks is <code>healthcheck</code>.</p> </li>
/// <li> <p>The resource type for hosted zones is <code>hostedzone</code>.</p> </li>
/// </ul>
pub resource_type: std::option::Option<crate::model::TagResourceType>,
/// <p>The ID for the specified resource.</p>
pub resource_id: std::option::Option<std::string::String>,
/// <p>The tags associated with the specified resource.</p>
pub tags: std::option::Option<std::vec::Vec<crate::model::Tag>>,
}
impl ResourceTagSet {
/// <p>The type of the resource.</p>
/// <ul>
/// <li> <p>The resource type for health checks is <code>healthcheck</code>.</p> </li>
/// <li> <p>The resource type for hosted zones is <code>hostedzone</code>.</p> </li>
/// </ul>
pub fn resource_type(&self) -> std::option::Option<&crate::model::TagResourceType> {
self.resource_type.as_ref()
}
/// <p>The ID for the specified resource.</p>
pub fn resource_id(&self) -> std::option::Option<&str> {
self.resource_id.as_deref()
}
/// <p>The tags associated with the specified resource.</p>
pub fn tags(&self) -> std::option::Option<&[crate::model::Tag]> {
self.tags.as_deref()
}
}
impl std::fmt::Debug for ResourceTagSet {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("ResourceTagSet");
formatter.field("resource_type", &self.resource_type);
formatter.field("resource_id", &self.resource_id);
formatter.field("tags", &self.tags);
formatter.finish()
}
}
/// See [`ResourceTagSet`](crate::model::ResourceTagSet)
pub mod resource_tag_set {
/// A builder for [`ResourceTagSet`](crate::model::ResourceTagSet)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) resource_type: std::option::Option<crate::model::TagResourceType>,
pub(crate) resource_id: std::option::Option<std::string::String>,
pub(crate) tags: std::option::Option<std::vec::Vec<crate::model::Tag>>,
}
impl Builder {
/// <p>The type of the resource.</p>
/// <ul>
/// <li> <p>The resource type for health checks is <code>healthcheck</code>.</p> </li>
/// <li> <p>The resource type for hosted zones is <code>hostedzone</code>.</p> </li>
/// </ul>
pub fn resource_type(mut self, input: crate::model::TagResourceType) -> Self {
self.resource_type = Some(input);
self
}
/// <p>The type of the resource.</p>
/// <ul>
/// <li> <p>The resource type for health checks is <code>healthcheck</code>.</p> </li>
/// <li> <p>The resource type for hosted zones is <code>hostedzone</code>.</p> </li>
/// </ul>
pub fn set_resource_type(
mut self,
input: std::option::Option<crate::model::TagResourceType>,
) -> Self {
self.resource_type = input;
self
}
/// <p>The ID for the specified resource.</p>
pub fn resource_id(mut self, input: impl Into<std::string::String>) -> Self {
self.resource_id = Some(input.into());
self
}
/// <p>The ID for the specified resource.</p>
pub fn set_resource_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.resource_id = input;
self
}
/// Appends an item to `tags`.
///
/// To override the contents of this collection use [`set_tags`](Self::set_tags).
///
/// <p>The tags associated with the specified resource.</p>
pub fn tags(mut self, input: crate::model::Tag) -> Self {
let mut v = self.tags.unwrap_or_default();
v.push(input);
self.tags = Some(v);
self
}
/// <p>The tags associated with the specified resource.</p>
pub fn set_tags(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::Tag>>,
) -> Self {
self.tags = input;
self
}
/// Consumes the builder and constructs a [`ResourceTagSet`](crate::model::ResourceTagSet)
pub fn build(self) -> crate::model::ResourceTagSet {
crate::model::ResourceTagSet {
resource_type: self.resource_type,
resource_id: self.resource_id,
tags: self.tags,
}
}
}
}
impl ResourceTagSet {
/// Creates a new builder-style object to manufacture [`ResourceTagSet`](crate::model::ResourceTagSet)
pub fn builder() -> crate::model::resource_tag_set::Builder {
crate::model::resource_tag_set::Builder::default()
}
}
/// <p>A complex type that contains information about a tag that you want to add or edit for the specified health check or hosted zone.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct Tag {
/// <p>The value of <code>Key</code> depends on the operation that you want to perform:</p>
/// <ul>
/// <li> <p> <b>Add a tag to a health check or hosted zone</b>: <code>Key</code> is the name that you want to give the new tag.</p> </li>
/// <li> <p> <b>Edit a tag</b>: <code>Key</code> is the name of the tag that you want to change the <code>Value</code> for.</p> </li>
/// <li> <p> <b> Delete a key</b>: <code>Key</code> is the name of the tag you want to remove.</p> </li>
/// <li> <p> <b>Give a name to a health check</b>: Edit the default <code>Name</code> tag. In the Amazon Route 53 console, the list of your health checks includes a <b>Name</b> column that lets you see the name that you've given to each health check.</p> </li>
/// </ul>
pub key: std::option::Option<std::string::String>,
/// <p>The value of <code>Value</code> depends on the operation that you want to perform:</p>
/// <ul>
/// <li> <p> <b>Add a tag to a health check or hosted zone</b>: <code>Value</code> is the value that you want to give the new tag.</p> </li>
/// <li> <p> <b>Edit a tag</b>: <code>Value</code> is the new value that you want to assign the tag.</p> </li>
/// </ul>
pub value: std::option::Option<std::string::String>,
}
impl Tag {
/// <p>The value of <code>Key</code> depends on the operation that you want to perform:</p>
/// <ul>
/// <li> <p> <b>Add a tag to a health check or hosted zone</b>: <code>Key</code> is the name that you want to give the new tag.</p> </li>
/// <li> <p> <b>Edit a tag</b>: <code>Key</code> is the name of the tag that you want to change the <code>Value</code> for.</p> </li>
/// <li> <p> <b> Delete a key</b>: <code>Key</code> is the name of the tag you want to remove.</p> </li>
/// <li> <p> <b>Give a name to a health check</b>: Edit the default <code>Name</code> tag. In the Amazon Route 53 console, the list of your health checks includes a <b>Name</b> column that lets you see the name that you've given to each health check.</p> </li>
/// </ul>
pub fn key(&self) -> std::option::Option<&str> {
self.key.as_deref()
}
/// <p>The value of <code>Value</code> depends on the operation that you want to perform:</p>
/// <ul>
/// <li> <p> <b>Add a tag to a health check or hosted zone</b>: <code>Value</code> is the value that you want to give the new tag.</p> </li>
/// <li> <p> <b>Edit a tag</b>: <code>Value</code> is the new value that you want to assign the tag.</p> </li>
/// </ul>
pub fn value(&self) -> std::option::Option<&str> {
self.value.as_deref()
}
}
impl std::fmt::Debug for Tag {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("Tag");
formatter.field("key", &self.key);
formatter.field("value", &self.value);
formatter.finish()
}
}
/// See [`Tag`](crate::model::Tag)
pub mod tag {
/// A builder for [`Tag`](crate::model::Tag)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) key: std::option::Option<std::string::String>,
pub(crate) value: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The value of <code>Key</code> depends on the operation that you want to perform:</p>
/// <ul>
/// <li> <p> <b>Add a tag to a health check or hosted zone</b>: <code>Key</code> is the name that you want to give the new tag.</p> </li>
/// <li> <p> <b>Edit a tag</b>: <code>Key</code> is the name of the tag that you want to change the <code>Value</code> for.</p> </li>
/// <li> <p> <b> Delete a key</b>: <code>Key</code> is the name of the tag you want to remove.</p> </li>
/// <li> <p> <b>Give a name to a health check</b>: Edit the default <code>Name</code> tag. In the Amazon Route 53 console, the list of your health checks includes a <b>Name</b> column that lets you see the name that you've given to each health check.</p> </li>
/// </ul>
pub fn key(mut self, input: impl Into<std::string::String>) -> Self {
self.key = Some(input.into());
self
}
/// <p>The value of <code>Key</code> depends on the operation that you want to perform:</p>
/// <ul>
/// <li> <p> <b>Add a tag to a health check or hosted zone</b>: <code>Key</code> is the name that you want to give the new tag.</p> </li>
/// <li> <p> <b>Edit a tag</b>: <code>Key</code> is the name of the tag that you want to change the <code>Value</code> for.</p> </li>
/// <li> <p> <b> Delete a key</b>: <code>Key</code> is the name of the tag you want to remove.</p> </li>
/// <li> <p> <b>Give a name to a health check</b>: Edit the default <code>Name</code> tag. In the Amazon Route 53 console, the list of your health checks includes a <b>Name</b> column that lets you see the name that you've given to each health check.</p> </li>
/// </ul>
pub fn set_key(mut self, input: std::option::Option<std::string::String>) -> Self {
self.key = input;
self
}
/// <p>The value of <code>Value</code> depends on the operation that you want to perform:</p>
/// <ul>
/// <li> <p> <b>Add a tag to a health check or hosted zone</b>: <code>Value</code> is the value that you want to give the new tag.</p> </li>
/// <li> <p> <b>Edit a tag</b>: <code>Value</code> is the new value that you want to assign the tag.</p> </li>
/// </ul>
pub fn value(mut self, input: impl Into<std::string::String>) -> Self {
self.value = Some(input.into());
self
}
/// <p>The value of <code>Value</code> depends on the operation that you want to perform:</p>
/// <ul>
/// <li> <p> <b>Add a tag to a health check or hosted zone</b>: <code>Value</code> is the value that you want to give the new tag.</p> </li>
/// <li> <p> <b>Edit a tag</b>: <code>Value</code> is the new value that you want to assign the tag.</p> </li>
/// </ul>
pub fn set_value(mut self, input: std::option::Option<std::string::String>) -> Self {
self.value = input;
self
}
/// Consumes the builder and constructs a [`Tag`](crate::model::Tag)
pub fn build(self) -> crate::model::Tag {
crate::model::Tag {
key: self.key,
value: self.value,
}
}
}
}
impl Tag {
/// Creates a new builder-style object to manufacture [`Tag`](crate::model::Tag)
pub fn builder() -> crate::model::tag::Builder {
crate::model::tag::Builder::default()
}
}
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum TagResourceType {
#[allow(missing_docs)] // documentation missing in model
Healthcheck,
#[allow(missing_docs)] // documentation missing in model
Hostedzone,
/// Unknown contains new variants that have been added since this code was generated.
Unknown(String),
}
impl std::convert::From<&str> for TagResourceType {
fn from(s: &str) -> Self {
match s {
"healthcheck" => TagResourceType::Healthcheck,
"hostedzone" => TagResourceType::Hostedzone,
other => TagResourceType::Unknown(other.to_owned()),
}
}
}
impl std::str::FromStr for TagResourceType {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(TagResourceType::from(s))
}
}
impl TagResourceType {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
TagResourceType::Healthcheck => "healthcheck",
TagResourceType::Hostedzone => "hostedzone",
TagResourceType::Unknown(s) => s.as_ref(),
}
}
/// Returns all the `&str` values of the enum members.
pub fn values() -> &'static [&'static str] {
&["healthcheck", "hostedzone"]
}
}
impl AsRef<str> for TagResourceType {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>A complex type that lists the name servers in a delegation set, as well as the <code>CallerReference</code> and the <code>ID</code> for the delegation set.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct DelegationSet {
/// <p>The ID that Amazon Route 53 assigns to a reusable delegation set.</p>
pub id: std::option::Option<std::string::String>,
/// <p>The value that you specified for <code>CallerReference</code> when you created the reusable delegation set.</p>
pub caller_reference: std::option::Option<std::string::String>,
/// <p>A complex type that contains a list of the authoritative name servers for a hosted zone or for a reusable delegation set.</p>
pub name_servers: std::option::Option<std::vec::Vec<std::string::String>>,
}
impl DelegationSet {
/// <p>The ID that Amazon Route 53 assigns to a reusable delegation set.</p>
pub fn id(&self) -> std::option::Option<&str> {
self.id.as_deref()
}
/// <p>The value that you specified for <code>CallerReference</code> when you created the reusable delegation set.</p>
pub fn caller_reference(&self) -> std::option::Option<&str> {
self.caller_reference.as_deref()
}
/// <p>A complex type that contains a list of the authoritative name servers for a hosted zone or for a reusable delegation set.</p>
pub fn name_servers(&self) -> std::option::Option<&[std::string::String]> {
self.name_servers.as_deref()
}
}
impl std::fmt::Debug for DelegationSet {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("DelegationSet");
formatter.field("id", &self.id);
formatter.field("caller_reference", &self.caller_reference);
formatter.field("name_servers", &self.name_servers);
formatter.finish()
}
}
/// See [`DelegationSet`](crate::model::DelegationSet)
pub mod delegation_set {
/// A builder for [`DelegationSet`](crate::model::DelegationSet)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) id: std::option::Option<std::string::String>,
pub(crate) caller_reference: std::option::Option<std::string::String>,
pub(crate) name_servers: std::option::Option<std::vec::Vec<std::string::String>>,
}
impl Builder {
/// <p>The ID that Amazon Route 53 assigns to a reusable delegation set.</p>
pub fn id(mut self, input: impl Into<std::string::String>) -> Self {
self.id = Some(input.into());
self
}
/// <p>The ID that Amazon Route 53 assigns to a reusable delegation set.</p>
pub fn set_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.id = input;
self
}
/// <p>The value that you specified for <code>CallerReference</code> when you created the reusable delegation set.</p>
pub fn caller_reference(mut self, input: impl Into<std::string::String>) -> Self {
self.caller_reference = Some(input.into());
self
}
/// <p>The value that you specified for <code>CallerReference</code> when you created the reusable delegation set.</p>
pub fn set_caller_reference(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.caller_reference = input;
self
}
/// Appends an item to `name_servers`.
///
/// To override the contents of this collection use [`set_name_servers`](Self::set_name_servers).
///
/// <p>A complex type that contains a list of the authoritative name servers for a hosted zone or for a reusable delegation set.</p>
pub fn name_servers(mut self, input: impl Into<std::string::String>) -> Self {
let mut v = self.name_servers.unwrap_or_default();
v.push(input.into());
self.name_servers = Some(v);
self
}
/// <p>A complex type that contains a list of the authoritative name servers for a hosted zone or for a reusable delegation set.</p>
pub fn set_name_servers(
mut self,
input: std::option::Option<std::vec::Vec<std::string::String>>,
) -> Self {
self.name_servers = input;
self
}
/// Consumes the builder and constructs a [`DelegationSet`](crate::model::DelegationSet)
pub fn build(self) -> crate::model::DelegationSet {
crate::model::DelegationSet {
id: self.id,
caller_reference: self.caller_reference,
name_servers: self.name_servers,
}
}
}
}
impl DelegationSet {
/// Creates a new builder-style object to manufacture [`DelegationSet`](crate::model::DelegationSet)
pub fn builder() -> crate::model::delegation_set::Builder {
crate::model::delegation_set::Builder::default()
}
}
/// <p>Information about the resource record set to create or delete.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct ResourceRecordSet {
/// <p>For <code>ChangeResourceRecordSets</code> requests, the name of the record that you want to create, update, or delete. For <code>ListResourceRecordSets</code> responses, the name of a record in the specified hosted zone.</p>
/// <p> <b>ChangeResourceRecordSets Only</b> </p>
/// <p>Enter a fully qualified domain name, for example, <code>www.example.com</code>. You can optionally include a trailing dot. If you omit the trailing dot, Amazon Route 53 assumes that the domain name that you specify is fully qualified. This means that Route 53 treats <code>www.example.com</code> (without a trailing dot) and <code>www.example.com.</code> (with a trailing dot) as identical.</p>
/// <p>For information about how to specify characters other than <code>a-z</code>, <code>0-9</code>, and <code>-</code> (hyphen) and how to specify internationalized domain names, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/DomainNameFormat.html">DNS Domain Name Format</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// <p>You can use the asterisk (*) wildcard to replace the leftmost label in a domain name, for example, <code>*.example.com</code>. Note the following:</p>
/// <ul>
/// <li> <p>The * must replace the entire label. For example, you can't specify <code>*prod.example.com</code> or <code>prod*.example.com</code>.</p> </li>
/// <li> <p>The * can't replace any of the middle labels, for example, marketing.*.example.com.</p> </li>
/// <li> <p>If you include * in any position other than the leftmost label in a domain name, DNS treats it as an * character (ASCII 42), not as a wildcard.</p> <important>
/// <p>You can't use the * wildcard for resource records sets that have a type of NS.</p>
/// </important> </li>
/// </ul>
/// <p>You can use the * wildcard as the leftmost label in a domain name, for example, <code>*.example.com</code>. You can't use an * for one of the middle labels, for example, <code>marketing.*.example.com</code>. In addition, the * must replace the entire label; for example, you can't specify <code>prod*.example.com</code>.</p>
pub name: std::option::Option<std::string::String>,
/// <p>The DNS record type. For information about different record types and how data is encoded for them, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/ResourceRecordTypes.html">Supported DNS Resource Record Types</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// <p>Valid values for basic resource record sets: <code>A</code> | <code>AAAA</code> | <code>CAA</code> | <code>CNAME</code> | <code>DS</code> |<code>MX</code> | <code>NAPTR</code> | <code>NS</code> | <code>PTR</code> | <code>SOA</code> | <code>SPF</code> | <code>SRV</code> | <code>TXT</code> </p>
/// <p>Values for weighted, latency, geolocation, and failover resource record sets: <code>A</code> | <code>AAAA</code> | <code>CAA</code> | <code>CNAME</code> | <code>MX</code> | <code>NAPTR</code> | <code>PTR</code> | <code>SPF</code> | <code>SRV</code> | <code>TXT</code>. When creating a group of weighted, latency, geolocation, or failover resource record sets, specify the same value for all of the resource record sets in the group.</p>
/// <p>Valid values for multivalue answer resource record sets: <code>A</code> | <code>AAAA</code> | <code>MX</code> | <code>NAPTR</code> | <code>PTR</code> | <code>SPF</code> | <code>SRV</code> | <code>TXT</code> </p> <note>
/// <p>SPF records were formerly used to verify the identity of the sender of email messages. However, we no longer recommend that you create resource record sets for which the value of <code>Type</code> is <code>SPF</code>. RFC 7208, <i>Sender Policy Framework (SPF) for Authorizing Use of Domains in Email, Version 1</i>, has been updated to say, "...[I]ts existence and mechanism defined in [RFC4408] have led to some interoperability issues. Accordingly, its use is no longer appropriate for SPF version 1; implementations are not to use it." In RFC 7208, see section 14.1, <a href="http://tools.ietf.org/html/rfc7208#section-14.1">The SPF DNS Record Type</a>.</p>
/// </note>
/// <p>Values for alias resource record sets:</p>
/// <ul>
/// <li> <p> <b>Amazon API Gateway custom regional APIs and edge-optimized APIs:</b> <code>A</code> </p> </li>
/// <li> <p> <b>CloudFront distributions:</b> <code>A</code> </p> <p>If IPv6 is enabled for the distribution, create two resource record sets to route traffic to your distribution, one with a value of <code>A</code> and one with a value of <code>AAAA</code>. </p> </li>
/// <li> <p> <b>Amazon API Gateway environment that has a regionalized subdomain</b>: <code>A</code> </p> </li>
/// <li> <p> <b>ELB load balancers:</b> <code>A</code> | <code>AAAA</code> </p> </li>
/// <li> <p> <b>Amazon S3 buckets:</b> <code>A</code> </p> </li>
/// <li> <p> <b>Amazon Virtual Private Cloud interface VPC endpoints</b> <code>A</code> </p> </li>
/// <li> <p> <b>Another resource record set in this hosted zone:</b> Specify the type of the resource record set that you're creating the alias for. All values are supported except <code>NS</code> and <code>SOA</code>.</p> <note>
/// <p>If you're creating an alias record that has the same name as the hosted zone (known as the zone apex), you can't route traffic to a record for which the value of <code>Type</code> is <code>CNAME</code>. This is because the alias record must have the same type as the record you're routing traffic to, and creating a CNAME record for the zone apex isn't supported even for an alias record.</p>
/// </note> </li>
/// </ul>
pub r#type: std::option::Option<crate::model::RrType>,
/// <p> <i>Resource record sets that have a routing policy other than simple:</i> An identifier that differentiates among multiple resource record sets that have the same combination of name and type, such as multiple weighted resource record sets named acme.example.com that have a type of A. In a group of resource record sets that have the same name and type, the value of <code>SetIdentifier</code> must be unique for each resource record set. </p>
/// <p>For information about routing policies, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/routing-policy.html">Choosing a Routing Policy</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
pub set_identifier: std::option::Option<std::string::String>,
/// <p> <i>Weighted resource record sets only:</i> Among resource record sets that have the same combination of DNS name and type, a value that determines the proportion of DNS queries that Amazon Route 53 responds to using the current resource record set. Route 53 calculates the sum of the weights for the resource record sets that have the same combination of DNS name and type. Route 53 then responds to queries based on the ratio of a resource's weight to the total. Note the following:</p>
/// <ul>
/// <li> <p>You must specify a value for the <code>Weight</code> element for every weighted resource record set.</p> </li>
/// <li> <p>You can only specify one <code>ResourceRecord</code> per weighted resource record set.</p> </li>
/// <li> <p>You can't create latency, failover, or geolocation resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements as weighted resource record sets.</p> </li>
/// <li> <p>You can create a maximum of 100 weighted resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements.</p> </li>
/// <li> <p>For weighted (but not weighted alias) resource record sets, if you set <code>Weight</code> to <code>0</code> for a resource record set, Route 53 never responds to queries with the applicable value for that resource record set. However, if you set <code>Weight</code> to <code>0</code> for all resource record sets that have the same combination of DNS name and type, traffic is routed to all resources with equal probability.</p> <p>The effect of setting <code>Weight</code> to <code>0</code> is different when you associate health checks with weighted resource record sets. For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-configuring-options.html">Options for Configuring Route 53 Active-Active and Active-Passive Failover</a> in the <i>Amazon Route 53 Developer Guide</i>.</p> </li>
/// </ul>
pub weight: std::option::Option<i64>,
/// <p> <i>Latency-based resource record sets only:</i> The Amazon EC2 Region where you created the resource that this resource record set refers to. The resource typically is an Amazon Web Services resource, such as an EC2 instance or an ELB load balancer, and is referred to by an IP address or a DNS domain name, depending on the record type.</p> <note>
/// <p>Although creating latency and latency alias resource record sets in a private hosted zone is allowed, it's not supported.</p>
/// </note>
/// <p>When Amazon Route 53 receives a DNS query for a domain name and type for which you have created latency resource record sets, Route 53 selects the latency resource record set that has the lowest latency between the end user and the associated Amazon EC2 Region. Route 53 then returns the value that is associated with the selected resource record set.</p>
/// <p>Note the following:</p>
/// <ul>
/// <li> <p>You can only specify one <code>ResourceRecord</code> per latency resource record set.</p> </li>
/// <li> <p>You can only create one latency resource record set for each Amazon EC2 Region.</p> </li>
/// <li> <p>You aren't required to create latency resource record sets for all Amazon EC2 Regions. Route 53 will choose the region with the best latency from among the regions that you create latency resource record sets for.</p> </li>
/// <li> <p>You can't create non-latency resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements as latency resource record sets.</p> </li>
/// </ul>
pub region: std::option::Option<crate::model::ResourceRecordSetRegion>,
/// <p> <i>Geolocation resource record sets only:</i> A complex type that lets you control how Amazon Route 53 responds to DNS queries based on the geographic origin of the query. For example, if you want all queries from Africa to be routed to a web server with an IP address of <code>192.0.2.111</code>, create a resource record set with a <code>Type</code> of <code>A</code> and a <code>ContinentCode</code> of <code>AF</code>.</p> <note>
/// <p>Although creating geolocation and geolocation alias resource record sets in a private hosted zone is allowed, it's not supported.</p>
/// </note>
/// <p>If you create separate resource record sets for overlapping geographic regions (for example, one resource record set for a continent and one for a country on the same continent), priority goes to the smallest geographic region. This allows you to route most queries for a continent to one resource and to route queries for a country on that continent to a different resource.</p>
/// <p>You can't create two geolocation resource record sets that specify the same geographic location.</p>
/// <p>The value <code>*</code> in the <code>CountryCode</code> element matches all geographic locations that aren't specified in other geolocation resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements.</p> <important>
/// <p>Geolocation works by mapping IP addresses to locations. However, some IP addresses aren't mapped to geographic locations, so even if you create geolocation resource record sets that cover all seven continents, Route 53 will receive some DNS queries from locations that it can't identify. We recommend that you create a resource record set for which the value of <code>CountryCode</code> is <code>*</code>. Two groups of queries are routed to the resource that you specify in this record: queries that come from locations for which you haven't created geolocation resource record sets and queries from IP addresses that aren't mapped to a location. If you don't create a <code>*</code> resource record set, Route 53 returns a "no answer" response for queries from those locations.</p>
/// </important>
/// <p>You can't create non-geolocation resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements as geolocation resource record sets.</p>
pub geo_location: std::option::Option<crate::model::GeoLocation>,
/// <p> <i>Failover resource record sets only:</i> To configure failover, you add the <code>Failover</code> element to two resource record sets. For one resource record set, you specify <code>PRIMARY</code> as the value for <code>Failover</code>; for the other resource record set, you specify <code>SECONDARY</code>. In addition, you include the <code>HealthCheckId</code> element and specify the health check that you want Amazon Route 53 to perform for each resource record set.</p>
/// <p>Except where noted, the following failover behaviors assume that you have included the <code>HealthCheckId</code> element in both resource record sets:</p>
/// <ul>
/// <li> <p>When the primary resource record set is healthy, Route 53 responds to DNS queries with the applicable value from the primary resource record set regardless of the health of the secondary resource record set.</p> </li>
/// <li> <p>When the primary resource record set is unhealthy and the secondary resource record set is healthy, Route 53 responds to DNS queries with the applicable value from the secondary resource record set.</p> </li>
/// <li> <p>When the secondary resource record set is unhealthy, Route 53 responds to DNS queries with the applicable value from the primary resource record set regardless of the health of the primary resource record set.</p> </li>
/// <li> <p>If you omit the <code>HealthCheckId</code> element for the secondary resource record set, and if the primary resource record set is unhealthy, Route 53 always responds to DNS queries with the applicable value from the secondary resource record set. This is true regardless of the health of the associated endpoint.</p> </li>
/// </ul>
/// <p>You can't create non-failover resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements as failover resource record sets.</p>
/// <p>For failover alias resource record sets, you must also include the <code>EvaluateTargetHealth</code> element and set the value to true.</p>
/// <p>For more information about configuring failover for Route 53, see the following topics in the <i>Amazon Route 53 Developer Guide</i>: </p>
/// <ul>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover.html">Route 53 Health Checks and DNS Failover</a> </p> </li>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-private-hosted-zones.html">Configuring Failover in a Private Hosted Zone</a> </p> </li>
/// </ul>
pub failover: std::option::Option<crate::model::ResourceRecordSetFailover>,
/// <p> <i>Multivalue answer resource record sets only</i>: To route traffic approximately randomly to multiple resources, such as web servers, create one multivalue answer record for each resource and specify <code>true</code> for <code>MultiValueAnswer</code>. Note the following:</p>
/// <ul>
/// <li> <p>If you associate a health check with a multivalue answer resource record set, Amazon Route 53 responds to DNS queries with the corresponding IP address only when the health check is healthy.</p> </li>
/// <li> <p>If you don't associate a health check with a multivalue answer record, Route 53 always considers the record to be healthy.</p> </li>
/// <li> <p>Route 53 responds to DNS queries with up to eight healthy records; if you have eight or fewer healthy records, Route 53 responds to all DNS queries with all the healthy records.</p> </li>
/// <li> <p>If you have more than eight healthy records, Route 53 responds to different DNS resolvers with different combinations of healthy records.</p> </li>
/// <li> <p>When all records are unhealthy, Route 53 responds to DNS queries with up to eight unhealthy records.</p> </li>
/// <li> <p>If a resource becomes unavailable after a resolver caches a response, client software typically tries another of the IP addresses in the response.</p> </li>
/// </ul>
/// <p>You can't create multivalue answer alias records.</p>
pub multi_value_answer: std::option::Option<bool>,
/// <p>The resource record cache time to live (TTL), in seconds. Note the following:</p>
/// <ul>
/// <li> <p>If you're creating or updating an alias resource record set, omit <code>TTL</code>. Amazon Route 53 uses the value of <code>TTL</code> for the alias target. </p> </li>
/// <li> <p>If you're associating this resource record set with a health check (if you're adding a <code>HealthCheckId</code> element), we recommend that you specify a <code>TTL</code> of 60 seconds or less so clients respond quickly to changes in health status.</p> </li>
/// <li> <p>All of the resource record sets in a group of weighted resource record sets must have the same value for <code>TTL</code>.</p> </li>
/// <li> <p>If a group of weighted resource record sets includes one or more weighted alias resource record sets for which the alias target is an ELB load balancer, we recommend that you specify a <code>TTL</code> of 60 seconds for all of the non-alias weighted resource record sets that have the same name and type. Values other than 60 seconds (the TTL for load balancers) will change the effect of the values that you specify for <code>Weight</code>.</p> </li>
/// </ul>
pub ttl: std::option::Option<i64>,
/// <p>Information about the resource records to act upon.</p> <note>
/// <p>If you're creating an alias resource record set, omit <code>ResourceRecords</code>.</p>
/// </note>
pub resource_records: std::option::Option<std::vec::Vec<crate::model::ResourceRecord>>,
/// <p> <i>Alias resource record sets only:</i> Information about the Amazon Web Services resource, such as a CloudFront distribution or an Amazon S3 bucket, that you want to route traffic to. </p>
/// <p>If you're creating resource records sets for a private hosted zone, note the following:</p>
/// <ul>
/// <li> <p>You can't create an alias resource record set in a private hosted zone to route traffic to a CloudFront distribution.</p> </li>
/// <li> <p>Creating geolocation alias resource record sets or latency alias resource record sets in a private hosted zone is unsupported.</p> </li>
/// <li> <p>For information about creating failover resource record sets in a private hosted zone, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-private-hosted-zones.html">Configuring Failover in a Private Hosted Zone</a> in the <i>Amazon Route 53 Developer Guide</i>.</p> </li>
/// </ul>
pub alias_target: std::option::Option<crate::model::AliasTarget>,
/// <p>If you want Amazon Route 53 to return this resource record set in response to a DNS query only when the status of a health check is healthy, include the <code>HealthCheckId</code> element and specify the ID of the applicable health check.</p>
/// <p>Route 53 determines whether a resource record set is healthy based on one of the following:</p>
/// <ul>
/// <li> <p>By periodically sending a request to the endpoint that is specified in the health check</p> </li>
/// <li> <p>By aggregating the status of a specified group of health checks (calculated health checks)</p> </li>
/// <li> <p>By determining the current state of a CloudWatch alarm (CloudWatch metric health checks)</p> </li>
/// </ul> <important>
/// <p>Route 53 doesn't check the health of the endpoint that is specified in the resource record set, for example, the endpoint specified by the IP address in the <code>Value</code> element. When you add a <code>HealthCheckId</code> element to a resource record set, Route 53 checks the health of the endpoint that you specified in the health check. </p>
/// </important>
/// <p>For more information, see the following topics in the <i>Amazon Route 53 Developer Guide</i>:</p>
/// <ul>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-determining-health-of-endpoints.html">How Amazon Route 53 Determines Whether an Endpoint Is Healthy</a> </p> </li>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover.html">Route 53 Health Checks and DNS Failover</a> </p> </li>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-private-hosted-zones.html">Configuring Failover in a Private Hosted Zone</a> </p> </li>
/// </ul>
/// <p> <b>When to Specify HealthCheckId</b> </p>
/// <p>Specifying a value for <code>HealthCheckId</code> is useful only when Route 53 is choosing between two or more resource record sets to respond to a DNS query, and you want Route 53 to base the choice in part on the status of a health check. Configuring health checks makes sense only in the following configurations:</p>
/// <ul>
/// <li> <p> <b>Non-alias resource record sets</b>: You're checking the health of a group of non-alias resource record sets that have the same routing policy, name, and type (such as multiple weighted records named www.example.com with a type of A) and you specify health check IDs for all the resource record sets. </p> <p>If the health check status for a resource record set is healthy, Route 53 includes the record among the records that it responds to DNS queries with.</p> <p>If the health check status for a resource record set is unhealthy, Route 53 stops responding to DNS queries using the value for that resource record set.</p> <p>If the health check status for all resource record sets in the group is unhealthy, Route 53 considers all resource record sets in the group healthy and responds to DNS queries accordingly. </p> </li>
/// <li> <p> <b>Alias resource record sets</b>: You specify the following settings:</p>
/// <ul>
/// <li> <p>You set <code>EvaluateTargetHealth</code> to true for an alias resource record set in a group of resource record sets that have the same routing policy, name, and type (such as multiple weighted records named www.example.com with a type of A). </p> </li>
/// <li> <p>You configure the alias resource record set to route traffic to a non-alias resource record set in the same hosted zone.</p> </li>
/// <li> <p>You specify a health check ID for the non-alias resource record set. </p> </li>
/// </ul> <p>If the health check status is healthy, Route 53 considers the alias resource record set to be healthy and includes the alias record among the records that it responds to DNS queries with.</p> <p>If the health check status is unhealthy, Route 53 stops responding to DNS queries using the alias resource record set.</p> <note>
/// <p>The alias resource record set can also route traffic to a <i>group</i> of non-alias resource record sets that have the same routing policy, name, and type. In that configuration, associate health checks with all of the resource record sets in the group of non-alias resource record sets.</p>
/// </note> </li>
/// </ul>
/// <p> <b>Geolocation Routing</b> </p>
/// <p>For geolocation resource record sets, if an endpoint is unhealthy, Route 53 looks for a resource record set for the larger, associated geographic region. For example, suppose you have resource record sets for a state in the United States, for the entire United States, for North America, and a resource record set that has <code>*</code> for <code>CountryCode</code> is <code>*</code>, which applies to all locations. If the endpoint for the state resource record set is unhealthy, Route 53 checks for healthy resource record sets in the following order until it finds a resource record set for which the endpoint is healthy:</p>
/// <ul>
/// <li> <p>The United States</p> </li>
/// <li> <p>North America</p> </li>
/// <li> <p>The default resource record set</p> </li>
/// </ul>
/// <p> <b>Specifying the Health Check Endpoint by Domain Name</b> </p>
/// <p>If your health checks specify the endpoint only by domain name, we recommend that you create a separate health check for each endpoint. For example, create a health check for each <code>HTTP</code> server that is serving content for <code>www.example.com</code>. For the value of <code>FullyQualifiedDomainName</code>, specify the domain name of the server (such as <code>us-east-2-www.example.com</code>), not the name of the resource record sets (<code>www.example.com</code>).</p> <important>
/// <p>Health check results will be unpredictable if you do the following:</p>
/// <ul>
/// <li> <p>Create a health check that has the same value for <code>FullyQualifiedDomainName</code> as the name of a resource record set.</p> </li>
/// <li> <p>Associate that health check with the resource record set.</p> </li>
/// </ul>
/// </important>
pub health_check_id: std::option::Option<std::string::String>,
/// <p>When you create a traffic policy instance, Amazon Route 53 automatically creates a resource record set. <code>TrafficPolicyInstanceId</code> is the ID of the traffic policy instance that Route 53 created this resource record set for.</p> <important>
/// <p>To delete the resource record set that is associated with a traffic policy instance, use <code>DeleteTrafficPolicyInstance</code>. Route 53 will delete the resource record set automatically. If you delete the resource record set by using <code>ChangeResourceRecordSets</code>, Route 53 doesn't automatically delete the traffic policy instance, and you'll continue to be charged for it even though it's no longer in use. </p>
/// </important>
pub traffic_policy_instance_id: std::option::Option<std::string::String>,
}
impl ResourceRecordSet {
/// <p>For <code>ChangeResourceRecordSets</code> requests, the name of the record that you want to create, update, or delete. For <code>ListResourceRecordSets</code> responses, the name of a record in the specified hosted zone.</p>
/// <p> <b>ChangeResourceRecordSets Only</b> </p>
/// <p>Enter a fully qualified domain name, for example, <code>www.example.com</code>. You can optionally include a trailing dot. If you omit the trailing dot, Amazon Route 53 assumes that the domain name that you specify is fully qualified. This means that Route 53 treats <code>www.example.com</code> (without a trailing dot) and <code>www.example.com.</code> (with a trailing dot) as identical.</p>
/// <p>For information about how to specify characters other than <code>a-z</code>, <code>0-9</code>, and <code>-</code> (hyphen) and how to specify internationalized domain names, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/DomainNameFormat.html">DNS Domain Name Format</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// <p>You can use the asterisk (*) wildcard to replace the leftmost label in a domain name, for example, <code>*.example.com</code>. Note the following:</p>
/// <ul>
/// <li> <p>The * must replace the entire label. For example, you can't specify <code>*prod.example.com</code> or <code>prod*.example.com</code>.</p> </li>
/// <li> <p>The * can't replace any of the middle labels, for example, marketing.*.example.com.</p> </li>
/// <li> <p>If you include * in any position other than the leftmost label in a domain name, DNS treats it as an * character (ASCII 42), not as a wildcard.</p> <important>
/// <p>You can't use the * wildcard for resource records sets that have a type of NS.</p>
/// </important> </li>
/// </ul>
/// <p>You can use the * wildcard as the leftmost label in a domain name, for example, <code>*.example.com</code>. You can't use an * for one of the middle labels, for example, <code>marketing.*.example.com</code>. In addition, the * must replace the entire label; for example, you can't specify <code>prod*.example.com</code>.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>The DNS record type. For information about different record types and how data is encoded for them, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/ResourceRecordTypes.html">Supported DNS Resource Record Types</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// <p>Valid values for basic resource record sets: <code>A</code> | <code>AAAA</code> | <code>CAA</code> | <code>CNAME</code> | <code>DS</code> |<code>MX</code> | <code>NAPTR</code> | <code>NS</code> | <code>PTR</code> | <code>SOA</code> | <code>SPF</code> | <code>SRV</code> | <code>TXT</code> </p>
/// <p>Values for weighted, latency, geolocation, and failover resource record sets: <code>A</code> | <code>AAAA</code> | <code>CAA</code> | <code>CNAME</code> | <code>MX</code> | <code>NAPTR</code> | <code>PTR</code> | <code>SPF</code> | <code>SRV</code> | <code>TXT</code>. When creating a group of weighted, latency, geolocation, or failover resource record sets, specify the same value for all of the resource record sets in the group.</p>
/// <p>Valid values for multivalue answer resource record sets: <code>A</code> | <code>AAAA</code> | <code>MX</code> | <code>NAPTR</code> | <code>PTR</code> | <code>SPF</code> | <code>SRV</code> | <code>TXT</code> </p> <note>
/// <p>SPF records were formerly used to verify the identity of the sender of email messages. However, we no longer recommend that you create resource record sets for which the value of <code>Type</code> is <code>SPF</code>. RFC 7208, <i>Sender Policy Framework (SPF) for Authorizing Use of Domains in Email, Version 1</i>, has been updated to say, "...[I]ts existence and mechanism defined in [RFC4408] have led to some interoperability issues. Accordingly, its use is no longer appropriate for SPF version 1; implementations are not to use it." In RFC 7208, see section 14.1, <a href="http://tools.ietf.org/html/rfc7208#section-14.1">The SPF DNS Record Type</a>.</p>
/// </note>
/// <p>Values for alias resource record sets:</p>
/// <ul>
/// <li> <p> <b>Amazon API Gateway custom regional APIs and edge-optimized APIs:</b> <code>A</code> </p> </li>
/// <li> <p> <b>CloudFront distributions:</b> <code>A</code> </p> <p>If IPv6 is enabled for the distribution, create two resource record sets to route traffic to your distribution, one with a value of <code>A</code> and one with a value of <code>AAAA</code>. </p> </li>
/// <li> <p> <b>Amazon API Gateway environment that has a regionalized subdomain</b>: <code>A</code> </p> </li>
/// <li> <p> <b>ELB load balancers:</b> <code>A</code> | <code>AAAA</code> </p> </li>
/// <li> <p> <b>Amazon S3 buckets:</b> <code>A</code> </p> </li>
/// <li> <p> <b>Amazon Virtual Private Cloud interface VPC endpoints</b> <code>A</code> </p> </li>
/// <li> <p> <b>Another resource record set in this hosted zone:</b> Specify the type of the resource record set that you're creating the alias for. All values are supported except <code>NS</code> and <code>SOA</code>.</p> <note>
/// <p>If you're creating an alias record that has the same name as the hosted zone (known as the zone apex), you can't route traffic to a record for which the value of <code>Type</code> is <code>CNAME</code>. This is because the alias record must have the same type as the record you're routing traffic to, and creating a CNAME record for the zone apex isn't supported even for an alias record.</p>
/// </note> </li>
/// </ul>
pub fn r#type(&self) -> std::option::Option<&crate::model::RrType> {
self.r#type.as_ref()
}
/// <p> <i>Resource record sets that have a routing policy other than simple:</i> An identifier that differentiates among multiple resource record sets that have the same combination of name and type, such as multiple weighted resource record sets named acme.example.com that have a type of A. In a group of resource record sets that have the same name and type, the value of <code>SetIdentifier</code> must be unique for each resource record set. </p>
/// <p>For information about routing policies, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/routing-policy.html">Choosing a Routing Policy</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
pub fn set_identifier(&self) -> std::option::Option<&str> {
self.set_identifier.as_deref()
}
/// <p> <i>Weighted resource record sets only:</i> Among resource record sets that have the same combination of DNS name and type, a value that determines the proportion of DNS queries that Amazon Route 53 responds to using the current resource record set. Route 53 calculates the sum of the weights for the resource record sets that have the same combination of DNS name and type. Route 53 then responds to queries based on the ratio of a resource's weight to the total. Note the following:</p>
/// <ul>
/// <li> <p>You must specify a value for the <code>Weight</code> element for every weighted resource record set.</p> </li>
/// <li> <p>You can only specify one <code>ResourceRecord</code> per weighted resource record set.</p> </li>
/// <li> <p>You can't create latency, failover, or geolocation resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements as weighted resource record sets.</p> </li>
/// <li> <p>You can create a maximum of 100 weighted resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements.</p> </li>
/// <li> <p>For weighted (but not weighted alias) resource record sets, if you set <code>Weight</code> to <code>0</code> for a resource record set, Route 53 never responds to queries with the applicable value for that resource record set. However, if you set <code>Weight</code> to <code>0</code> for all resource record sets that have the same combination of DNS name and type, traffic is routed to all resources with equal probability.</p> <p>The effect of setting <code>Weight</code> to <code>0</code> is different when you associate health checks with weighted resource record sets. For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-configuring-options.html">Options for Configuring Route 53 Active-Active and Active-Passive Failover</a> in the <i>Amazon Route 53 Developer Guide</i>.</p> </li>
/// </ul>
pub fn weight(&self) -> std::option::Option<i64> {
self.weight
}
/// <p> <i>Latency-based resource record sets only:</i> The Amazon EC2 Region where you created the resource that this resource record set refers to. The resource typically is an Amazon Web Services resource, such as an EC2 instance or an ELB load balancer, and is referred to by an IP address or a DNS domain name, depending on the record type.</p> <note>
/// <p>Although creating latency and latency alias resource record sets in a private hosted zone is allowed, it's not supported.</p>
/// </note>
/// <p>When Amazon Route 53 receives a DNS query for a domain name and type for which you have created latency resource record sets, Route 53 selects the latency resource record set that has the lowest latency between the end user and the associated Amazon EC2 Region. Route 53 then returns the value that is associated with the selected resource record set.</p>
/// <p>Note the following:</p>
/// <ul>
/// <li> <p>You can only specify one <code>ResourceRecord</code> per latency resource record set.</p> </li>
/// <li> <p>You can only create one latency resource record set for each Amazon EC2 Region.</p> </li>
/// <li> <p>You aren't required to create latency resource record sets for all Amazon EC2 Regions. Route 53 will choose the region with the best latency from among the regions that you create latency resource record sets for.</p> </li>
/// <li> <p>You can't create non-latency resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements as latency resource record sets.</p> </li>
/// </ul>
pub fn region(&self) -> std::option::Option<&crate::model::ResourceRecordSetRegion> {
self.region.as_ref()
}
/// <p> <i>Geolocation resource record sets only:</i> A complex type that lets you control how Amazon Route 53 responds to DNS queries based on the geographic origin of the query. For example, if you want all queries from Africa to be routed to a web server with an IP address of <code>192.0.2.111</code>, create a resource record set with a <code>Type</code> of <code>A</code> and a <code>ContinentCode</code> of <code>AF</code>.</p> <note>
/// <p>Although creating geolocation and geolocation alias resource record sets in a private hosted zone is allowed, it's not supported.</p>
/// </note>
/// <p>If you create separate resource record sets for overlapping geographic regions (for example, one resource record set for a continent and one for a country on the same continent), priority goes to the smallest geographic region. This allows you to route most queries for a continent to one resource and to route queries for a country on that continent to a different resource.</p>
/// <p>You can't create two geolocation resource record sets that specify the same geographic location.</p>
/// <p>The value <code>*</code> in the <code>CountryCode</code> element matches all geographic locations that aren't specified in other geolocation resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements.</p> <important>
/// <p>Geolocation works by mapping IP addresses to locations. However, some IP addresses aren't mapped to geographic locations, so even if you create geolocation resource record sets that cover all seven continents, Route 53 will receive some DNS queries from locations that it can't identify. We recommend that you create a resource record set for which the value of <code>CountryCode</code> is <code>*</code>. Two groups of queries are routed to the resource that you specify in this record: queries that come from locations for which you haven't created geolocation resource record sets and queries from IP addresses that aren't mapped to a location. If you don't create a <code>*</code> resource record set, Route 53 returns a "no answer" response for queries from those locations.</p>
/// </important>
/// <p>You can't create non-geolocation resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements as geolocation resource record sets.</p>
pub fn geo_location(&self) -> std::option::Option<&crate::model::GeoLocation> {
self.geo_location.as_ref()
}
/// <p> <i>Failover resource record sets only:</i> To configure failover, you add the <code>Failover</code> element to two resource record sets. For one resource record set, you specify <code>PRIMARY</code> as the value for <code>Failover</code>; for the other resource record set, you specify <code>SECONDARY</code>. In addition, you include the <code>HealthCheckId</code> element and specify the health check that you want Amazon Route 53 to perform for each resource record set.</p>
/// <p>Except where noted, the following failover behaviors assume that you have included the <code>HealthCheckId</code> element in both resource record sets:</p>
/// <ul>
/// <li> <p>When the primary resource record set is healthy, Route 53 responds to DNS queries with the applicable value from the primary resource record set regardless of the health of the secondary resource record set.</p> </li>
/// <li> <p>When the primary resource record set is unhealthy and the secondary resource record set is healthy, Route 53 responds to DNS queries with the applicable value from the secondary resource record set.</p> </li>
/// <li> <p>When the secondary resource record set is unhealthy, Route 53 responds to DNS queries with the applicable value from the primary resource record set regardless of the health of the primary resource record set.</p> </li>
/// <li> <p>If you omit the <code>HealthCheckId</code> element for the secondary resource record set, and if the primary resource record set is unhealthy, Route 53 always responds to DNS queries with the applicable value from the secondary resource record set. This is true regardless of the health of the associated endpoint.</p> </li>
/// </ul>
/// <p>You can't create non-failover resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements as failover resource record sets.</p>
/// <p>For failover alias resource record sets, you must also include the <code>EvaluateTargetHealth</code> element and set the value to true.</p>
/// <p>For more information about configuring failover for Route 53, see the following topics in the <i>Amazon Route 53 Developer Guide</i>: </p>
/// <ul>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover.html">Route 53 Health Checks and DNS Failover</a> </p> </li>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-private-hosted-zones.html">Configuring Failover in a Private Hosted Zone</a> </p> </li>
/// </ul>
pub fn failover(&self) -> std::option::Option<&crate::model::ResourceRecordSetFailover> {
self.failover.as_ref()
}
/// <p> <i>Multivalue answer resource record sets only</i>: To route traffic approximately randomly to multiple resources, such as web servers, create one multivalue answer record for each resource and specify <code>true</code> for <code>MultiValueAnswer</code>. Note the following:</p>
/// <ul>
/// <li> <p>If you associate a health check with a multivalue answer resource record set, Amazon Route 53 responds to DNS queries with the corresponding IP address only when the health check is healthy.</p> </li>
/// <li> <p>If you don't associate a health check with a multivalue answer record, Route 53 always considers the record to be healthy.</p> </li>
/// <li> <p>Route 53 responds to DNS queries with up to eight healthy records; if you have eight or fewer healthy records, Route 53 responds to all DNS queries with all the healthy records.</p> </li>
/// <li> <p>If you have more than eight healthy records, Route 53 responds to different DNS resolvers with different combinations of healthy records.</p> </li>
/// <li> <p>When all records are unhealthy, Route 53 responds to DNS queries with up to eight unhealthy records.</p> </li>
/// <li> <p>If a resource becomes unavailable after a resolver caches a response, client software typically tries another of the IP addresses in the response.</p> </li>
/// </ul>
/// <p>You can't create multivalue answer alias records.</p>
pub fn multi_value_answer(&self) -> std::option::Option<bool> {
self.multi_value_answer
}
/// <p>The resource record cache time to live (TTL), in seconds. Note the following:</p>
/// <ul>
/// <li> <p>If you're creating or updating an alias resource record set, omit <code>TTL</code>. Amazon Route 53 uses the value of <code>TTL</code> for the alias target. </p> </li>
/// <li> <p>If you're associating this resource record set with a health check (if you're adding a <code>HealthCheckId</code> element), we recommend that you specify a <code>TTL</code> of 60 seconds or less so clients respond quickly to changes in health status.</p> </li>
/// <li> <p>All of the resource record sets in a group of weighted resource record sets must have the same value for <code>TTL</code>.</p> </li>
/// <li> <p>If a group of weighted resource record sets includes one or more weighted alias resource record sets for which the alias target is an ELB load balancer, we recommend that you specify a <code>TTL</code> of 60 seconds for all of the non-alias weighted resource record sets that have the same name and type. Values other than 60 seconds (the TTL for load balancers) will change the effect of the values that you specify for <code>Weight</code>.</p> </li>
/// </ul>
pub fn ttl(&self) -> std::option::Option<i64> {
self.ttl
}
/// <p>Information about the resource records to act upon.</p> <note>
/// <p>If you're creating an alias resource record set, omit <code>ResourceRecords</code>.</p>
/// </note>
pub fn resource_records(&self) -> std::option::Option<&[crate::model::ResourceRecord]> {
self.resource_records.as_deref()
}
/// <p> <i>Alias resource record sets only:</i> Information about the Amazon Web Services resource, such as a CloudFront distribution or an Amazon S3 bucket, that you want to route traffic to. </p>
/// <p>If you're creating resource records sets for a private hosted zone, note the following:</p>
/// <ul>
/// <li> <p>You can't create an alias resource record set in a private hosted zone to route traffic to a CloudFront distribution.</p> </li>
/// <li> <p>Creating geolocation alias resource record sets or latency alias resource record sets in a private hosted zone is unsupported.</p> </li>
/// <li> <p>For information about creating failover resource record sets in a private hosted zone, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-private-hosted-zones.html">Configuring Failover in a Private Hosted Zone</a> in the <i>Amazon Route 53 Developer Guide</i>.</p> </li>
/// </ul>
pub fn alias_target(&self) -> std::option::Option<&crate::model::AliasTarget> {
self.alias_target.as_ref()
}
/// <p>If you want Amazon Route 53 to return this resource record set in response to a DNS query only when the status of a health check is healthy, include the <code>HealthCheckId</code> element and specify the ID of the applicable health check.</p>
/// <p>Route 53 determines whether a resource record set is healthy based on one of the following:</p>
/// <ul>
/// <li> <p>By periodically sending a request to the endpoint that is specified in the health check</p> </li>
/// <li> <p>By aggregating the status of a specified group of health checks (calculated health checks)</p> </li>
/// <li> <p>By determining the current state of a CloudWatch alarm (CloudWatch metric health checks)</p> </li>
/// </ul> <important>
/// <p>Route 53 doesn't check the health of the endpoint that is specified in the resource record set, for example, the endpoint specified by the IP address in the <code>Value</code> element. When you add a <code>HealthCheckId</code> element to a resource record set, Route 53 checks the health of the endpoint that you specified in the health check. </p>
/// </important>
/// <p>For more information, see the following topics in the <i>Amazon Route 53 Developer Guide</i>:</p>
/// <ul>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-determining-health-of-endpoints.html">How Amazon Route 53 Determines Whether an Endpoint Is Healthy</a> </p> </li>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover.html">Route 53 Health Checks and DNS Failover</a> </p> </li>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-private-hosted-zones.html">Configuring Failover in a Private Hosted Zone</a> </p> </li>
/// </ul>
/// <p> <b>When to Specify HealthCheckId</b> </p>
/// <p>Specifying a value for <code>HealthCheckId</code> is useful only when Route 53 is choosing between two or more resource record sets to respond to a DNS query, and you want Route 53 to base the choice in part on the status of a health check. Configuring health checks makes sense only in the following configurations:</p>
/// <ul>
/// <li> <p> <b>Non-alias resource record sets</b>: You're checking the health of a group of non-alias resource record sets that have the same routing policy, name, and type (such as multiple weighted records named www.example.com with a type of A) and you specify health check IDs for all the resource record sets. </p> <p>If the health check status for a resource record set is healthy, Route 53 includes the record among the records that it responds to DNS queries with.</p> <p>If the health check status for a resource record set is unhealthy, Route 53 stops responding to DNS queries using the value for that resource record set.</p> <p>If the health check status for all resource record sets in the group is unhealthy, Route 53 considers all resource record sets in the group healthy and responds to DNS queries accordingly. </p> </li>
/// <li> <p> <b>Alias resource record sets</b>: You specify the following settings:</p>
/// <ul>
/// <li> <p>You set <code>EvaluateTargetHealth</code> to true for an alias resource record set in a group of resource record sets that have the same routing policy, name, and type (such as multiple weighted records named www.example.com with a type of A). </p> </li>
/// <li> <p>You configure the alias resource record set to route traffic to a non-alias resource record set in the same hosted zone.</p> </li>
/// <li> <p>You specify a health check ID for the non-alias resource record set. </p> </li>
/// </ul> <p>If the health check status is healthy, Route 53 considers the alias resource record set to be healthy and includes the alias record among the records that it responds to DNS queries with.</p> <p>If the health check status is unhealthy, Route 53 stops responding to DNS queries using the alias resource record set.</p> <note>
/// <p>The alias resource record set can also route traffic to a <i>group</i> of non-alias resource record sets that have the same routing policy, name, and type. In that configuration, associate health checks with all of the resource record sets in the group of non-alias resource record sets.</p>
/// </note> </li>
/// </ul>
/// <p> <b>Geolocation Routing</b> </p>
/// <p>For geolocation resource record sets, if an endpoint is unhealthy, Route 53 looks for a resource record set for the larger, associated geographic region. For example, suppose you have resource record sets for a state in the United States, for the entire United States, for North America, and a resource record set that has <code>*</code> for <code>CountryCode</code> is <code>*</code>, which applies to all locations. If the endpoint for the state resource record set is unhealthy, Route 53 checks for healthy resource record sets in the following order until it finds a resource record set for which the endpoint is healthy:</p>
/// <ul>
/// <li> <p>The United States</p> </li>
/// <li> <p>North America</p> </li>
/// <li> <p>The default resource record set</p> </li>
/// </ul>
/// <p> <b>Specifying the Health Check Endpoint by Domain Name</b> </p>
/// <p>If your health checks specify the endpoint only by domain name, we recommend that you create a separate health check for each endpoint. For example, create a health check for each <code>HTTP</code> server that is serving content for <code>www.example.com</code>. For the value of <code>FullyQualifiedDomainName</code>, specify the domain name of the server (such as <code>us-east-2-www.example.com</code>), not the name of the resource record sets (<code>www.example.com</code>).</p> <important>
/// <p>Health check results will be unpredictable if you do the following:</p>
/// <ul>
/// <li> <p>Create a health check that has the same value for <code>FullyQualifiedDomainName</code> as the name of a resource record set.</p> </li>
/// <li> <p>Associate that health check with the resource record set.</p> </li>
/// </ul>
/// </important>
pub fn health_check_id(&self) -> std::option::Option<&str> {
self.health_check_id.as_deref()
}
/// <p>When you create a traffic policy instance, Amazon Route 53 automatically creates a resource record set. <code>TrafficPolicyInstanceId</code> is the ID of the traffic policy instance that Route 53 created this resource record set for.</p> <important>
/// <p>To delete the resource record set that is associated with a traffic policy instance, use <code>DeleteTrafficPolicyInstance</code>. Route 53 will delete the resource record set automatically. If you delete the resource record set by using <code>ChangeResourceRecordSets</code>, Route 53 doesn't automatically delete the traffic policy instance, and you'll continue to be charged for it even though it's no longer in use. </p>
/// </important>
pub fn traffic_policy_instance_id(&self) -> std::option::Option<&str> {
self.traffic_policy_instance_id.as_deref()
}
}
impl std::fmt::Debug for ResourceRecordSet {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("ResourceRecordSet");
formatter.field("name", &self.name);
formatter.field("r#type", &self.r#type);
formatter.field("set_identifier", &self.set_identifier);
formatter.field("weight", &self.weight);
formatter.field("region", &self.region);
formatter.field("geo_location", &self.geo_location);
formatter.field("failover", &self.failover);
formatter.field("multi_value_answer", &self.multi_value_answer);
formatter.field("ttl", &self.ttl);
formatter.field("resource_records", &self.resource_records);
formatter.field("alias_target", &self.alias_target);
formatter.field("health_check_id", &self.health_check_id);
formatter.field(
"traffic_policy_instance_id",
&self.traffic_policy_instance_id,
);
formatter.finish()
}
}
/// See [`ResourceRecordSet`](crate::model::ResourceRecordSet)
pub mod resource_record_set {
/// A builder for [`ResourceRecordSet`](crate::model::ResourceRecordSet)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) r#type: std::option::Option<crate::model::RrType>,
pub(crate) set_identifier: std::option::Option<std::string::String>,
pub(crate) weight: std::option::Option<i64>,
pub(crate) region: std::option::Option<crate::model::ResourceRecordSetRegion>,
pub(crate) geo_location: std::option::Option<crate::model::GeoLocation>,
pub(crate) failover: std::option::Option<crate::model::ResourceRecordSetFailover>,
pub(crate) multi_value_answer: std::option::Option<bool>,
pub(crate) ttl: std::option::Option<i64>,
pub(crate) resource_records:
std::option::Option<std::vec::Vec<crate::model::ResourceRecord>>,
pub(crate) alias_target: std::option::Option<crate::model::AliasTarget>,
pub(crate) health_check_id: std::option::Option<std::string::String>,
pub(crate) traffic_policy_instance_id: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>For <code>ChangeResourceRecordSets</code> requests, the name of the record that you want to create, update, or delete. For <code>ListResourceRecordSets</code> responses, the name of a record in the specified hosted zone.</p>
/// <p> <b>ChangeResourceRecordSets Only</b> </p>
/// <p>Enter a fully qualified domain name, for example, <code>www.example.com</code>. You can optionally include a trailing dot. If you omit the trailing dot, Amazon Route 53 assumes that the domain name that you specify is fully qualified. This means that Route 53 treats <code>www.example.com</code> (without a trailing dot) and <code>www.example.com.</code> (with a trailing dot) as identical.</p>
/// <p>For information about how to specify characters other than <code>a-z</code>, <code>0-9</code>, and <code>-</code> (hyphen) and how to specify internationalized domain names, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/DomainNameFormat.html">DNS Domain Name Format</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// <p>You can use the asterisk (*) wildcard to replace the leftmost label in a domain name, for example, <code>*.example.com</code>. Note the following:</p>
/// <ul>
/// <li> <p>The * must replace the entire label. For example, you can't specify <code>*prod.example.com</code> or <code>prod*.example.com</code>.</p> </li>
/// <li> <p>The * can't replace any of the middle labels, for example, marketing.*.example.com.</p> </li>
/// <li> <p>If you include * in any position other than the leftmost label in a domain name, DNS treats it as an * character (ASCII 42), not as a wildcard.</p> <important>
/// <p>You can't use the * wildcard for resource records sets that have a type of NS.</p>
/// </important> </li>
/// </ul>
/// <p>You can use the * wildcard as the leftmost label in a domain name, for example, <code>*.example.com</code>. You can't use an * for one of the middle labels, for example, <code>marketing.*.example.com</code>. In addition, the * must replace the entire label; for example, you can't specify <code>prod*.example.com</code>.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>For <code>ChangeResourceRecordSets</code> requests, the name of the record that you want to create, update, or delete. For <code>ListResourceRecordSets</code> responses, the name of a record in the specified hosted zone.</p>
/// <p> <b>ChangeResourceRecordSets Only</b> </p>
/// <p>Enter a fully qualified domain name, for example, <code>www.example.com</code>. You can optionally include a trailing dot. If you omit the trailing dot, Amazon Route 53 assumes that the domain name that you specify is fully qualified. This means that Route 53 treats <code>www.example.com</code> (without a trailing dot) and <code>www.example.com.</code> (with a trailing dot) as identical.</p>
/// <p>For information about how to specify characters other than <code>a-z</code>, <code>0-9</code>, and <code>-</code> (hyphen) and how to specify internationalized domain names, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/DomainNameFormat.html">DNS Domain Name Format</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// <p>You can use the asterisk (*) wildcard to replace the leftmost label in a domain name, for example, <code>*.example.com</code>. Note the following:</p>
/// <ul>
/// <li> <p>The * must replace the entire label. For example, you can't specify <code>*prod.example.com</code> or <code>prod*.example.com</code>.</p> </li>
/// <li> <p>The * can't replace any of the middle labels, for example, marketing.*.example.com.</p> </li>
/// <li> <p>If you include * in any position other than the leftmost label in a domain name, DNS treats it as an * character (ASCII 42), not as a wildcard.</p> <important>
/// <p>You can't use the * wildcard for resource records sets that have a type of NS.</p>
/// </important> </li>
/// </ul>
/// <p>You can use the * wildcard as the leftmost label in a domain name, for example, <code>*.example.com</code>. You can't use an * for one of the middle labels, for example, <code>marketing.*.example.com</code>. In addition, the * must replace the entire label; for example, you can't specify <code>prod*.example.com</code>.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// <p>The DNS record type. For information about different record types and how data is encoded for them, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/ResourceRecordTypes.html">Supported DNS Resource Record Types</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// <p>Valid values for basic resource record sets: <code>A</code> | <code>AAAA</code> | <code>CAA</code> | <code>CNAME</code> | <code>DS</code> |<code>MX</code> | <code>NAPTR</code> | <code>NS</code> | <code>PTR</code> | <code>SOA</code> | <code>SPF</code> | <code>SRV</code> | <code>TXT</code> </p>
/// <p>Values for weighted, latency, geolocation, and failover resource record sets: <code>A</code> | <code>AAAA</code> | <code>CAA</code> | <code>CNAME</code> | <code>MX</code> | <code>NAPTR</code> | <code>PTR</code> | <code>SPF</code> | <code>SRV</code> | <code>TXT</code>. When creating a group of weighted, latency, geolocation, or failover resource record sets, specify the same value for all of the resource record sets in the group.</p>
/// <p>Valid values for multivalue answer resource record sets: <code>A</code> | <code>AAAA</code> | <code>MX</code> | <code>NAPTR</code> | <code>PTR</code> | <code>SPF</code> | <code>SRV</code> | <code>TXT</code> </p> <note>
/// <p>SPF records were formerly used to verify the identity of the sender of email messages. However, we no longer recommend that you create resource record sets for which the value of <code>Type</code> is <code>SPF</code>. RFC 7208, <i>Sender Policy Framework (SPF) for Authorizing Use of Domains in Email, Version 1</i>, has been updated to say, "...[I]ts existence and mechanism defined in [RFC4408] have led to some interoperability issues. Accordingly, its use is no longer appropriate for SPF version 1; implementations are not to use it." In RFC 7208, see section 14.1, <a href="http://tools.ietf.org/html/rfc7208#section-14.1">The SPF DNS Record Type</a>.</p>
/// </note>
/// <p>Values for alias resource record sets:</p>
/// <ul>
/// <li> <p> <b>Amazon API Gateway custom regional APIs and edge-optimized APIs:</b> <code>A</code> </p> </li>
/// <li> <p> <b>CloudFront distributions:</b> <code>A</code> </p> <p>If IPv6 is enabled for the distribution, create two resource record sets to route traffic to your distribution, one with a value of <code>A</code> and one with a value of <code>AAAA</code>. </p> </li>
/// <li> <p> <b>Amazon API Gateway environment that has a regionalized subdomain</b>: <code>A</code> </p> </li>
/// <li> <p> <b>ELB load balancers:</b> <code>A</code> | <code>AAAA</code> </p> </li>
/// <li> <p> <b>Amazon S3 buckets:</b> <code>A</code> </p> </li>
/// <li> <p> <b>Amazon Virtual Private Cloud interface VPC endpoints</b> <code>A</code> </p> </li>
/// <li> <p> <b>Another resource record set in this hosted zone:</b> Specify the type of the resource record set that you're creating the alias for. All values are supported except <code>NS</code> and <code>SOA</code>.</p> <note>
/// <p>If you're creating an alias record that has the same name as the hosted zone (known as the zone apex), you can't route traffic to a record for which the value of <code>Type</code> is <code>CNAME</code>. This is because the alias record must have the same type as the record you're routing traffic to, and creating a CNAME record for the zone apex isn't supported even for an alias record.</p>
/// </note> </li>
/// </ul>
pub fn r#type(mut self, input: crate::model::RrType) -> Self {
self.r#type = Some(input);
self
}
/// <p>The DNS record type. For information about different record types and how data is encoded for them, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/ResourceRecordTypes.html">Supported DNS Resource Record Types</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// <p>Valid values for basic resource record sets: <code>A</code> | <code>AAAA</code> | <code>CAA</code> | <code>CNAME</code> | <code>DS</code> |<code>MX</code> | <code>NAPTR</code> | <code>NS</code> | <code>PTR</code> | <code>SOA</code> | <code>SPF</code> | <code>SRV</code> | <code>TXT</code> </p>
/// <p>Values for weighted, latency, geolocation, and failover resource record sets: <code>A</code> | <code>AAAA</code> | <code>CAA</code> | <code>CNAME</code> | <code>MX</code> | <code>NAPTR</code> | <code>PTR</code> | <code>SPF</code> | <code>SRV</code> | <code>TXT</code>. When creating a group of weighted, latency, geolocation, or failover resource record sets, specify the same value for all of the resource record sets in the group.</p>
/// <p>Valid values for multivalue answer resource record sets: <code>A</code> | <code>AAAA</code> | <code>MX</code> | <code>NAPTR</code> | <code>PTR</code> | <code>SPF</code> | <code>SRV</code> | <code>TXT</code> </p> <note>
/// <p>SPF records were formerly used to verify the identity of the sender of email messages. However, we no longer recommend that you create resource record sets for which the value of <code>Type</code> is <code>SPF</code>. RFC 7208, <i>Sender Policy Framework (SPF) for Authorizing Use of Domains in Email, Version 1</i>, has been updated to say, "...[I]ts existence and mechanism defined in [RFC4408] have led to some interoperability issues. Accordingly, its use is no longer appropriate for SPF version 1; implementations are not to use it." In RFC 7208, see section 14.1, <a href="http://tools.ietf.org/html/rfc7208#section-14.1">The SPF DNS Record Type</a>.</p>
/// </note>
/// <p>Values for alias resource record sets:</p>
/// <ul>
/// <li> <p> <b>Amazon API Gateway custom regional APIs and edge-optimized APIs:</b> <code>A</code> </p> </li>
/// <li> <p> <b>CloudFront distributions:</b> <code>A</code> </p> <p>If IPv6 is enabled for the distribution, create two resource record sets to route traffic to your distribution, one with a value of <code>A</code> and one with a value of <code>AAAA</code>. </p> </li>
/// <li> <p> <b>Amazon API Gateway environment that has a regionalized subdomain</b>: <code>A</code> </p> </li>
/// <li> <p> <b>ELB load balancers:</b> <code>A</code> | <code>AAAA</code> </p> </li>
/// <li> <p> <b>Amazon S3 buckets:</b> <code>A</code> </p> </li>
/// <li> <p> <b>Amazon Virtual Private Cloud interface VPC endpoints</b> <code>A</code> </p> </li>
/// <li> <p> <b>Another resource record set in this hosted zone:</b> Specify the type of the resource record set that you're creating the alias for. All values are supported except <code>NS</code> and <code>SOA</code>.</p> <note>
/// <p>If you're creating an alias record that has the same name as the hosted zone (known as the zone apex), you can't route traffic to a record for which the value of <code>Type</code> is <code>CNAME</code>. This is because the alias record must have the same type as the record you're routing traffic to, and creating a CNAME record for the zone apex isn't supported even for an alias record.</p>
/// </note> </li>
/// </ul>
pub fn set_type(mut self, input: std::option::Option<crate::model::RrType>) -> Self {
self.r#type = input;
self
}
/// <p> <i>Resource record sets that have a routing policy other than simple:</i> An identifier that differentiates among multiple resource record sets that have the same combination of name and type, such as multiple weighted resource record sets named acme.example.com that have a type of A. In a group of resource record sets that have the same name and type, the value of <code>SetIdentifier</code> must be unique for each resource record set. </p>
/// <p>For information about routing policies, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/routing-policy.html">Choosing a Routing Policy</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
pub fn set_identifier(mut self, input: impl Into<std::string::String>) -> Self {
self.set_identifier = Some(input.into());
self
}
/// <p> <i>Resource record sets that have a routing policy other than simple:</i> An identifier that differentiates among multiple resource record sets that have the same combination of name and type, such as multiple weighted resource record sets named acme.example.com that have a type of A. In a group of resource record sets that have the same name and type, the value of <code>SetIdentifier</code> must be unique for each resource record set. </p>
/// <p>For information about routing policies, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/routing-policy.html">Choosing a Routing Policy</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
pub fn set_set_identifier(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.set_identifier = input;
self
}
/// <p> <i>Weighted resource record sets only:</i> Among resource record sets that have the same combination of DNS name and type, a value that determines the proportion of DNS queries that Amazon Route 53 responds to using the current resource record set. Route 53 calculates the sum of the weights for the resource record sets that have the same combination of DNS name and type. Route 53 then responds to queries based on the ratio of a resource's weight to the total. Note the following:</p>
/// <ul>
/// <li> <p>You must specify a value for the <code>Weight</code> element for every weighted resource record set.</p> </li>
/// <li> <p>You can only specify one <code>ResourceRecord</code> per weighted resource record set.</p> </li>
/// <li> <p>You can't create latency, failover, or geolocation resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements as weighted resource record sets.</p> </li>
/// <li> <p>You can create a maximum of 100 weighted resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements.</p> </li>
/// <li> <p>For weighted (but not weighted alias) resource record sets, if you set <code>Weight</code> to <code>0</code> for a resource record set, Route 53 never responds to queries with the applicable value for that resource record set. However, if you set <code>Weight</code> to <code>0</code> for all resource record sets that have the same combination of DNS name and type, traffic is routed to all resources with equal probability.</p> <p>The effect of setting <code>Weight</code> to <code>0</code> is different when you associate health checks with weighted resource record sets. For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-configuring-options.html">Options for Configuring Route 53 Active-Active and Active-Passive Failover</a> in the <i>Amazon Route 53 Developer Guide</i>.</p> </li>
/// </ul>
pub fn weight(mut self, input: i64) -> Self {
self.weight = Some(input);
self
}
/// <p> <i>Weighted resource record sets only:</i> Among resource record sets that have the same combination of DNS name and type, a value that determines the proportion of DNS queries that Amazon Route 53 responds to using the current resource record set. Route 53 calculates the sum of the weights for the resource record sets that have the same combination of DNS name and type. Route 53 then responds to queries based on the ratio of a resource's weight to the total. Note the following:</p>
/// <ul>
/// <li> <p>You must specify a value for the <code>Weight</code> element for every weighted resource record set.</p> </li>
/// <li> <p>You can only specify one <code>ResourceRecord</code> per weighted resource record set.</p> </li>
/// <li> <p>You can't create latency, failover, or geolocation resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements as weighted resource record sets.</p> </li>
/// <li> <p>You can create a maximum of 100 weighted resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements.</p> </li>
/// <li> <p>For weighted (but not weighted alias) resource record sets, if you set <code>Weight</code> to <code>0</code> for a resource record set, Route 53 never responds to queries with the applicable value for that resource record set. However, if you set <code>Weight</code> to <code>0</code> for all resource record sets that have the same combination of DNS name and type, traffic is routed to all resources with equal probability.</p> <p>The effect of setting <code>Weight</code> to <code>0</code> is different when you associate health checks with weighted resource record sets. For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-configuring-options.html">Options for Configuring Route 53 Active-Active and Active-Passive Failover</a> in the <i>Amazon Route 53 Developer Guide</i>.</p> </li>
/// </ul>
pub fn set_weight(mut self, input: std::option::Option<i64>) -> Self {
self.weight = input;
self
}
/// <p> <i>Latency-based resource record sets only:</i> The Amazon EC2 Region where you created the resource that this resource record set refers to. The resource typically is an Amazon Web Services resource, such as an EC2 instance or an ELB load balancer, and is referred to by an IP address or a DNS domain name, depending on the record type.</p> <note>
/// <p>Although creating latency and latency alias resource record sets in a private hosted zone is allowed, it's not supported.</p>
/// </note>
/// <p>When Amazon Route 53 receives a DNS query for a domain name and type for which you have created latency resource record sets, Route 53 selects the latency resource record set that has the lowest latency between the end user and the associated Amazon EC2 Region. Route 53 then returns the value that is associated with the selected resource record set.</p>
/// <p>Note the following:</p>
/// <ul>
/// <li> <p>You can only specify one <code>ResourceRecord</code> per latency resource record set.</p> </li>
/// <li> <p>You can only create one latency resource record set for each Amazon EC2 Region.</p> </li>
/// <li> <p>You aren't required to create latency resource record sets for all Amazon EC2 Regions. Route 53 will choose the region with the best latency from among the regions that you create latency resource record sets for.</p> </li>
/// <li> <p>You can't create non-latency resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements as latency resource record sets.</p> </li>
/// </ul>
pub fn region(mut self, input: crate::model::ResourceRecordSetRegion) -> Self {
self.region = Some(input);
self
}
/// <p> <i>Latency-based resource record sets only:</i> The Amazon EC2 Region where you created the resource that this resource record set refers to. The resource typically is an Amazon Web Services resource, such as an EC2 instance or an ELB load balancer, and is referred to by an IP address or a DNS domain name, depending on the record type.</p> <note>
/// <p>Although creating latency and latency alias resource record sets in a private hosted zone is allowed, it's not supported.</p>
/// </note>
/// <p>When Amazon Route 53 receives a DNS query for a domain name and type for which you have created latency resource record sets, Route 53 selects the latency resource record set that has the lowest latency between the end user and the associated Amazon EC2 Region. Route 53 then returns the value that is associated with the selected resource record set.</p>
/// <p>Note the following:</p>
/// <ul>
/// <li> <p>You can only specify one <code>ResourceRecord</code> per latency resource record set.</p> </li>
/// <li> <p>You can only create one latency resource record set for each Amazon EC2 Region.</p> </li>
/// <li> <p>You aren't required to create latency resource record sets for all Amazon EC2 Regions. Route 53 will choose the region with the best latency from among the regions that you create latency resource record sets for.</p> </li>
/// <li> <p>You can't create non-latency resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements as latency resource record sets.</p> </li>
/// </ul>
pub fn set_region(
mut self,
input: std::option::Option<crate::model::ResourceRecordSetRegion>,
) -> Self {
self.region = input;
self
}
/// <p> <i>Geolocation resource record sets only:</i> A complex type that lets you control how Amazon Route 53 responds to DNS queries based on the geographic origin of the query. For example, if you want all queries from Africa to be routed to a web server with an IP address of <code>192.0.2.111</code>, create a resource record set with a <code>Type</code> of <code>A</code> and a <code>ContinentCode</code> of <code>AF</code>.</p> <note>
/// <p>Although creating geolocation and geolocation alias resource record sets in a private hosted zone is allowed, it's not supported.</p>
/// </note>
/// <p>If you create separate resource record sets for overlapping geographic regions (for example, one resource record set for a continent and one for a country on the same continent), priority goes to the smallest geographic region. This allows you to route most queries for a continent to one resource and to route queries for a country on that continent to a different resource.</p>
/// <p>You can't create two geolocation resource record sets that specify the same geographic location.</p>
/// <p>The value <code>*</code> in the <code>CountryCode</code> element matches all geographic locations that aren't specified in other geolocation resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements.</p> <important>
/// <p>Geolocation works by mapping IP addresses to locations. However, some IP addresses aren't mapped to geographic locations, so even if you create geolocation resource record sets that cover all seven continents, Route 53 will receive some DNS queries from locations that it can't identify. We recommend that you create a resource record set for which the value of <code>CountryCode</code> is <code>*</code>. Two groups of queries are routed to the resource that you specify in this record: queries that come from locations for which you haven't created geolocation resource record sets and queries from IP addresses that aren't mapped to a location. If you don't create a <code>*</code> resource record set, Route 53 returns a "no answer" response for queries from those locations.</p>
/// </important>
/// <p>You can't create non-geolocation resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements as geolocation resource record sets.</p>
pub fn geo_location(mut self, input: crate::model::GeoLocation) -> Self {
self.geo_location = Some(input);
self
}
/// <p> <i>Geolocation resource record sets only:</i> A complex type that lets you control how Amazon Route 53 responds to DNS queries based on the geographic origin of the query. For example, if you want all queries from Africa to be routed to a web server with an IP address of <code>192.0.2.111</code>, create a resource record set with a <code>Type</code> of <code>A</code> and a <code>ContinentCode</code> of <code>AF</code>.</p> <note>
/// <p>Although creating geolocation and geolocation alias resource record sets in a private hosted zone is allowed, it's not supported.</p>
/// </note>
/// <p>If you create separate resource record sets for overlapping geographic regions (for example, one resource record set for a continent and one for a country on the same continent), priority goes to the smallest geographic region. This allows you to route most queries for a continent to one resource and to route queries for a country on that continent to a different resource.</p>
/// <p>You can't create two geolocation resource record sets that specify the same geographic location.</p>
/// <p>The value <code>*</code> in the <code>CountryCode</code> element matches all geographic locations that aren't specified in other geolocation resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements.</p> <important>
/// <p>Geolocation works by mapping IP addresses to locations. However, some IP addresses aren't mapped to geographic locations, so even if you create geolocation resource record sets that cover all seven continents, Route 53 will receive some DNS queries from locations that it can't identify. We recommend that you create a resource record set for which the value of <code>CountryCode</code> is <code>*</code>. Two groups of queries are routed to the resource that you specify in this record: queries that come from locations for which you haven't created geolocation resource record sets and queries from IP addresses that aren't mapped to a location. If you don't create a <code>*</code> resource record set, Route 53 returns a "no answer" response for queries from those locations.</p>
/// </important>
/// <p>You can't create non-geolocation resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements as geolocation resource record sets.</p>
pub fn set_geo_location(
mut self,
input: std::option::Option<crate::model::GeoLocation>,
) -> Self {
self.geo_location = input;
self
}
/// <p> <i>Failover resource record sets only:</i> To configure failover, you add the <code>Failover</code> element to two resource record sets. For one resource record set, you specify <code>PRIMARY</code> as the value for <code>Failover</code>; for the other resource record set, you specify <code>SECONDARY</code>. In addition, you include the <code>HealthCheckId</code> element and specify the health check that you want Amazon Route 53 to perform for each resource record set.</p>
/// <p>Except where noted, the following failover behaviors assume that you have included the <code>HealthCheckId</code> element in both resource record sets:</p>
/// <ul>
/// <li> <p>When the primary resource record set is healthy, Route 53 responds to DNS queries with the applicable value from the primary resource record set regardless of the health of the secondary resource record set.</p> </li>
/// <li> <p>When the primary resource record set is unhealthy and the secondary resource record set is healthy, Route 53 responds to DNS queries with the applicable value from the secondary resource record set.</p> </li>
/// <li> <p>When the secondary resource record set is unhealthy, Route 53 responds to DNS queries with the applicable value from the primary resource record set regardless of the health of the primary resource record set.</p> </li>
/// <li> <p>If you omit the <code>HealthCheckId</code> element for the secondary resource record set, and if the primary resource record set is unhealthy, Route 53 always responds to DNS queries with the applicable value from the secondary resource record set. This is true regardless of the health of the associated endpoint.</p> </li>
/// </ul>
/// <p>You can't create non-failover resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements as failover resource record sets.</p>
/// <p>For failover alias resource record sets, you must also include the <code>EvaluateTargetHealth</code> element and set the value to true.</p>
/// <p>For more information about configuring failover for Route 53, see the following topics in the <i>Amazon Route 53 Developer Guide</i>: </p>
/// <ul>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover.html">Route 53 Health Checks and DNS Failover</a> </p> </li>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-private-hosted-zones.html">Configuring Failover in a Private Hosted Zone</a> </p> </li>
/// </ul>
pub fn failover(mut self, input: crate::model::ResourceRecordSetFailover) -> Self {
self.failover = Some(input);
self
}
/// <p> <i>Failover resource record sets only:</i> To configure failover, you add the <code>Failover</code> element to two resource record sets. For one resource record set, you specify <code>PRIMARY</code> as the value for <code>Failover</code>; for the other resource record set, you specify <code>SECONDARY</code>. In addition, you include the <code>HealthCheckId</code> element and specify the health check that you want Amazon Route 53 to perform for each resource record set.</p>
/// <p>Except where noted, the following failover behaviors assume that you have included the <code>HealthCheckId</code> element in both resource record sets:</p>
/// <ul>
/// <li> <p>When the primary resource record set is healthy, Route 53 responds to DNS queries with the applicable value from the primary resource record set regardless of the health of the secondary resource record set.</p> </li>
/// <li> <p>When the primary resource record set is unhealthy and the secondary resource record set is healthy, Route 53 responds to DNS queries with the applicable value from the secondary resource record set.</p> </li>
/// <li> <p>When the secondary resource record set is unhealthy, Route 53 responds to DNS queries with the applicable value from the primary resource record set regardless of the health of the primary resource record set.</p> </li>
/// <li> <p>If you omit the <code>HealthCheckId</code> element for the secondary resource record set, and if the primary resource record set is unhealthy, Route 53 always responds to DNS queries with the applicable value from the secondary resource record set. This is true regardless of the health of the associated endpoint.</p> </li>
/// </ul>
/// <p>You can't create non-failover resource record sets that have the same values for the <code>Name</code> and <code>Type</code> elements as failover resource record sets.</p>
/// <p>For failover alias resource record sets, you must also include the <code>EvaluateTargetHealth</code> element and set the value to true.</p>
/// <p>For more information about configuring failover for Route 53, see the following topics in the <i>Amazon Route 53 Developer Guide</i>: </p>
/// <ul>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover.html">Route 53 Health Checks and DNS Failover</a> </p> </li>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-private-hosted-zones.html">Configuring Failover in a Private Hosted Zone</a> </p> </li>
/// </ul>
pub fn set_failover(
mut self,
input: std::option::Option<crate::model::ResourceRecordSetFailover>,
) -> Self {
self.failover = input;
self
}
/// <p> <i>Multivalue answer resource record sets only</i>: To route traffic approximately randomly to multiple resources, such as web servers, create one multivalue answer record for each resource and specify <code>true</code> for <code>MultiValueAnswer</code>. Note the following:</p>
/// <ul>
/// <li> <p>If you associate a health check with a multivalue answer resource record set, Amazon Route 53 responds to DNS queries with the corresponding IP address only when the health check is healthy.</p> </li>
/// <li> <p>If you don't associate a health check with a multivalue answer record, Route 53 always considers the record to be healthy.</p> </li>
/// <li> <p>Route 53 responds to DNS queries with up to eight healthy records; if you have eight or fewer healthy records, Route 53 responds to all DNS queries with all the healthy records.</p> </li>
/// <li> <p>If you have more than eight healthy records, Route 53 responds to different DNS resolvers with different combinations of healthy records.</p> </li>
/// <li> <p>When all records are unhealthy, Route 53 responds to DNS queries with up to eight unhealthy records.</p> </li>
/// <li> <p>If a resource becomes unavailable after a resolver caches a response, client software typically tries another of the IP addresses in the response.</p> </li>
/// </ul>
/// <p>You can't create multivalue answer alias records.</p>
pub fn multi_value_answer(mut self, input: bool) -> Self {
self.multi_value_answer = Some(input);
self
}
/// <p> <i>Multivalue answer resource record sets only</i>: To route traffic approximately randomly to multiple resources, such as web servers, create one multivalue answer record for each resource and specify <code>true</code> for <code>MultiValueAnswer</code>. Note the following:</p>
/// <ul>
/// <li> <p>If you associate a health check with a multivalue answer resource record set, Amazon Route 53 responds to DNS queries with the corresponding IP address only when the health check is healthy.</p> </li>
/// <li> <p>If you don't associate a health check with a multivalue answer record, Route 53 always considers the record to be healthy.</p> </li>
/// <li> <p>Route 53 responds to DNS queries with up to eight healthy records; if you have eight or fewer healthy records, Route 53 responds to all DNS queries with all the healthy records.</p> </li>
/// <li> <p>If you have more than eight healthy records, Route 53 responds to different DNS resolvers with different combinations of healthy records.</p> </li>
/// <li> <p>When all records are unhealthy, Route 53 responds to DNS queries with up to eight unhealthy records.</p> </li>
/// <li> <p>If a resource becomes unavailable after a resolver caches a response, client software typically tries another of the IP addresses in the response.</p> </li>
/// </ul>
/// <p>You can't create multivalue answer alias records.</p>
pub fn set_multi_value_answer(mut self, input: std::option::Option<bool>) -> Self {
self.multi_value_answer = input;
self
}
/// <p>The resource record cache time to live (TTL), in seconds. Note the following:</p>
/// <ul>
/// <li> <p>If you're creating or updating an alias resource record set, omit <code>TTL</code>. Amazon Route 53 uses the value of <code>TTL</code> for the alias target. </p> </li>
/// <li> <p>If you're associating this resource record set with a health check (if you're adding a <code>HealthCheckId</code> element), we recommend that you specify a <code>TTL</code> of 60 seconds or less so clients respond quickly to changes in health status.</p> </li>
/// <li> <p>All of the resource record sets in a group of weighted resource record sets must have the same value for <code>TTL</code>.</p> </li>
/// <li> <p>If a group of weighted resource record sets includes one or more weighted alias resource record sets for which the alias target is an ELB load balancer, we recommend that you specify a <code>TTL</code> of 60 seconds for all of the non-alias weighted resource record sets that have the same name and type. Values other than 60 seconds (the TTL for load balancers) will change the effect of the values that you specify for <code>Weight</code>.</p> </li>
/// </ul>
pub fn ttl(mut self, input: i64) -> Self {
self.ttl = Some(input);
self
}
/// <p>The resource record cache time to live (TTL), in seconds. Note the following:</p>
/// <ul>
/// <li> <p>If you're creating or updating an alias resource record set, omit <code>TTL</code>. Amazon Route 53 uses the value of <code>TTL</code> for the alias target. </p> </li>
/// <li> <p>If you're associating this resource record set with a health check (if you're adding a <code>HealthCheckId</code> element), we recommend that you specify a <code>TTL</code> of 60 seconds or less so clients respond quickly to changes in health status.</p> </li>
/// <li> <p>All of the resource record sets in a group of weighted resource record sets must have the same value for <code>TTL</code>.</p> </li>
/// <li> <p>If a group of weighted resource record sets includes one or more weighted alias resource record sets for which the alias target is an ELB load balancer, we recommend that you specify a <code>TTL</code> of 60 seconds for all of the non-alias weighted resource record sets that have the same name and type. Values other than 60 seconds (the TTL for load balancers) will change the effect of the values that you specify for <code>Weight</code>.</p> </li>
/// </ul>
pub fn set_ttl(mut self, input: std::option::Option<i64>) -> Self {
self.ttl = input;
self
}
/// Appends an item to `resource_records`.
///
/// To override the contents of this collection use [`set_resource_records`](Self::set_resource_records).
///
/// <p>Information about the resource records to act upon.</p> <note>
/// <p>If you're creating an alias resource record set, omit <code>ResourceRecords</code>.</p>
/// </note>
pub fn resource_records(mut self, input: crate::model::ResourceRecord) -> Self {
let mut v = self.resource_records.unwrap_or_default();
v.push(input);
self.resource_records = Some(v);
self
}
/// <p>Information about the resource records to act upon.</p> <note>
/// <p>If you're creating an alias resource record set, omit <code>ResourceRecords</code>.</p>
/// </note>
pub fn set_resource_records(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::ResourceRecord>>,
) -> Self {
self.resource_records = input;
self
}
/// <p> <i>Alias resource record sets only:</i> Information about the Amazon Web Services resource, such as a CloudFront distribution or an Amazon S3 bucket, that you want to route traffic to. </p>
/// <p>If you're creating resource records sets for a private hosted zone, note the following:</p>
/// <ul>
/// <li> <p>You can't create an alias resource record set in a private hosted zone to route traffic to a CloudFront distribution.</p> </li>
/// <li> <p>Creating geolocation alias resource record sets or latency alias resource record sets in a private hosted zone is unsupported.</p> </li>
/// <li> <p>For information about creating failover resource record sets in a private hosted zone, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-private-hosted-zones.html">Configuring Failover in a Private Hosted Zone</a> in the <i>Amazon Route 53 Developer Guide</i>.</p> </li>
/// </ul>
pub fn alias_target(mut self, input: crate::model::AliasTarget) -> Self {
self.alias_target = Some(input);
self
}
/// <p> <i>Alias resource record sets only:</i> Information about the Amazon Web Services resource, such as a CloudFront distribution or an Amazon S3 bucket, that you want to route traffic to. </p>
/// <p>If you're creating resource records sets for a private hosted zone, note the following:</p>
/// <ul>
/// <li> <p>You can't create an alias resource record set in a private hosted zone to route traffic to a CloudFront distribution.</p> </li>
/// <li> <p>Creating geolocation alias resource record sets or latency alias resource record sets in a private hosted zone is unsupported.</p> </li>
/// <li> <p>For information about creating failover resource record sets in a private hosted zone, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-private-hosted-zones.html">Configuring Failover in a Private Hosted Zone</a> in the <i>Amazon Route 53 Developer Guide</i>.</p> </li>
/// </ul>
pub fn set_alias_target(
mut self,
input: std::option::Option<crate::model::AliasTarget>,
) -> Self {
self.alias_target = input;
self
}
/// <p>If you want Amazon Route 53 to return this resource record set in response to a DNS query only when the status of a health check is healthy, include the <code>HealthCheckId</code> element and specify the ID of the applicable health check.</p>
/// <p>Route 53 determines whether a resource record set is healthy based on one of the following:</p>
/// <ul>
/// <li> <p>By periodically sending a request to the endpoint that is specified in the health check</p> </li>
/// <li> <p>By aggregating the status of a specified group of health checks (calculated health checks)</p> </li>
/// <li> <p>By determining the current state of a CloudWatch alarm (CloudWatch metric health checks)</p> </li>
/// </ul> <important>
/// <p>Route 53 doesn't check the health of the endpoint that is specified in the resource record set, for example, the endpoint specified by the IP address in the <code>Value</code> element. When you add a <code>HealthCheckId</code> element to a resource record set, Route 53 checks the health of the endpoint that you specified in the health check. </p>
/// </important>
/// <p>For more information, see the following topics in the <i>Amazon Route 53 Developer Guide</i>:</p>
/// <ul>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-determining-health-of-endpoints.html">How Amazon Route 53 Determines Whether an Endpoint Is Healthy</a> </p> </li>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover.html">Route 53 Health Checks and DNS Failover</a> </p> </li>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-private-hosted-zones.html">Configuring Failover in a Private Hosted Zone</a> </p> </li>
/// </ul>
/// <p> <b>When to Specify HealthCheckId</b> </p>
/// <p>Specifying a value for <code>HealthCheckId</code> is useful only when Route 53 is choosing between two or more resource record sets to respond to a DNS query, and you want Route 53 to base the choice in part on the status of a health check. Configuring health checks makes sense only in the following configurations:</p>
/// <ul>
/// <li> <p> <b>Non-alias resource record sets</b>: You're checking the health of a group of non-alias resource record sets that have the same routing policy, name, and type (such as multiple weighted records named www.example.com with a type of A) and you specify health check IDs for all the resource record sets. </p> <p>If the health check status for a resource record set is healthy, Route 53 includes the record among the records that it responds to DNS queries with.</p> <p>If the health check status for a resource record set is unhealthy, Route 53 stops responding to DNS queries using the value for that resource record set.</p> <p>If the health check status for all resource record sets in the group is unhealthy, Route 53 considers all resource record sets in the group healthy and responds to DNS queries accordingly. </p> </li>
/// <li> <p> <b>Alias resource record sets</b>: You specify the following settings:</p>
/// <ul>
/// <li> <p>You set <code>EvaluateTargetHealth</code> to true for an alias resource record set in a group of resource record sets that have the same routing policy, name, and type (such as multiple weighted records named www.example.com with a type of A). </p> </li>
/// <li> <p>You configure the alias resource record set to route traffic to a non-alias resource record set in the same hosted zone.</p> </li>
/// <li> <p>You specify a health check ID for the non-alias resource record set. </p> </li>
/// </ul> <p>If the health check status is healthy, Route 53 considers the alias resource record set to be healthy and includes the alias record among the records that it responds to DNS queries with.</p> <p>If the health check status is unhealthy, Route 53 stops responding to DNS queries using the alias resource record set.</p> <note>
/// <p>The alias resource record set can also route traffic to a <i>group</i> of non-alias resource record sets that have the same routing policy, name, and type. In that configuration, associate health checks with all of the resource record sets in the group of non-alias resource record sets.</p>
/// </note> </li>
/// </ul>
/// <p> <b>Geolocation Routing</b> </p>
/// <p>For geolocation resource record sets, if an endpoint is unhealthy, Route 53 looks for a resource record set for the larger, associated geographic region. For example, suppose you have resource record sets for a state in the United States, for the entire United States, for North America, and a resource record set that has <code>*</code> for <code>CountryCode</code> is <code>*</code>, which applies to all locations. If the endpoint for the state resource record set is unhealthy, Route 53 checks for healthy resource record sets in the following order until it finds a resource record set for which the endpoint is healthy:</p>
/// <ul>
/// <li> <p>The United States</p> </li>
/// <li> <p>North America</p> </li>
/// <li> <p>The default resource record set</p> </li>
/// </ul>
/// <p> <b>Specifying the Health Check Endpoint by Domain Name</b> </p>
/// <p>If your health checks specify the endpoint only by domain name, we recommend that you create a separate health check for each endpoint. For example, create a health check for each <code>HTTP</code> server that is serving content for <code>www.example.com</code>. For the value of <code>FullyQualifiedDomainName</code>, specify the domain name of the server (such as <code>us-east-2-www.example.com</code>), not the name of the resource record sets (<code>www.example.com</code>).</p> <important>
/// <p>Health check results will be unpredictable if you do the following:</p>
/// <ul>
/// <li> <p>Create a health check that has the same value for <code>FullyQualifiedDomainName</code> as the name of a resource record set.</p> </li>
/// <li> <p>Associate that health check with the resource record set.</p> </li>
/// </ul>
/// </important>
pub fn health_check_id(mut self, input: impl Into<std::string::String>) -> Self {
self.health_check_id = Some(input.into());
self
}
/// <p>If you want Amazon Route 53 to return this resource record set in response to a DNS query only when the status of a health check is healthy, include the <code>HealthCheckId</code> element and specify the ID of the applicable health check.</p>
/// <p>Route 53 determines whether a resource record set is healthy based on one of the following:</p>
/// <ul>
/// <li> <p>By periodically sending a request to the endpoint that is specified in the health check</p> </li>
/// <li> <p>By aggregating the status of a specified group of health checks (calculated health checks)</p> </li>
/// <li> <p>By determining the current state of a CloudWatch alarm (CloudWatch metric health checks)</p> </li>
/// </ul> <important>
/// <p>Route 53 doesn't check the health of the endpoint that is specified in the resource record set, for example, the endpoint specified by the IP address in the <code>Value</code> element. When you add a <code>HealthCheckId</code> element to a resource record set, Route 53 checks the health of the endpoint that you specified in the health check. </p>
/// </important>
/// <p>For more information, see the following topics in the <i>Amazon Route 53 Developer Guide</i>:</p>
/// <ul>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-determining-health-of-endpoints.html">How Amazon Route 53 Determines Whether an Endpoint Is Healthy</a> </p> </li>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover.html">Route 53 Health Checks and DNS Failover</a> </p> </li>
/// <li> <p> <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-private-hosted-zones.html">Configuring Failover in a Private Hosted Zone</a> </p> </li>
/// </ul>
/// <p> <b>When to Specify HealthCheckId</b> </p>
/// <p>Specifying a value for <code>HealthCheckId</code> is useful only when Route 53 is choosing between two or more resource record sets to respond to a DNS query, and you want Route 53 to base the choice in part on the status of a health check. Configuring health checks makes sense only in the following configurations:</p>
/// <ul>
/// <li> <p> <b>Non-alias resource record sets</b>: You're checking the health of a group of non-alias resource record sets that have the same routing policy, name, and type (such as multiple weighted records named www.example.com with a type of A) and you specify health check IDs for all the resource record sets. </p> <p>If the health check status for a resource record set is healthy, Route 53 includes the record among the records that it responds to DNS queries with.</p> <p>If the health check status for a resource record set is unhealthy, Route 53 stops responding to DNS queries using the value for that resource record set.</p> <p>If the health check status for all resource record sets in the group is unhealthy, Route 53 considers all resource record sets in the group healthy and responds to DNS queries accordingly. </p> </li>
/// <li> <p> <b>Alias resource record sets</b>: You specify the following settings:</p>
/// <ul>
/// <li> <p>You set <code>EvaluateTargetHealth</code> to true for an alias resource record set in a group of resource record sets that have the same routing policy, name, and type (such as multiple weighted records named www.example.com with a type of A). </p> </li>
/// <li> <p>You configure the alias resource record set to route traffic to a non-alias resource record set in the same hosted zone.</p> </li>
/// <li> <p>You specify a health check ID for the non-alias resource record set. </p> </li>
/// </ul> <p>If the health check status is healthy, Route 53 considers the alias resource record set to be healthy and includes the alias record among the records that it responds to DNS queries with.</p> <p>If the health check status is unhealthy, Route 53 stops responding to DNS queries using the alias resource record set.</p> <note>
/// <p>The alias resource record set can also route traffic to a <i>group</i> of non-alias resource record sets that have the same routing policy, name, and type. In that configuration, associate health checks with all of the resource record sets in the group of non-alias resource record sets.</p>
/// </note> </li>
/// </ul>
/// <p> <b>Geolocation Routing</b> </p>
/// <p>For geolocation resource record sets, if an endpoint is unhealthy, Route 53 looks for a resource record set for the larger, associated geographic region. For example, suppose you have resource record sets for a state in the United States, for the entire United States, for North America, and a resource record set that has <code>*</code> for <code>CountryCode</code> is <code>*</code>, which applies to all locations. If the endpoint for the state resource record set is unhealthy, Route 53 checks for healthy resource record sets in the following order until it finds a resource record set for which the endpoint is healthy:</p>
/// <ul>
/// <li> <p>The United States</p> </li>
/// <li> <p>North America</p> </li>
/// <li> <p>The default resource record set</p> </li>
/// </ul>
/// <p> <b>Specifying the Health Check Endpoint by Domain Name</b> </p>
/// <p>If your health checks specify the endpoint only by domain name, we recommend that you create a separate health check for each endpoint. For example, create a health check for each <code>HTTP</code> server that is serving content for <code>www.example.com</code>. For the value of <code>FullyQualifiedDomainName</code>, specify the domain name of the server (such as <code>us-east-2-www.example.com</code>), not the name of the resource record sets (<code>www.example.com</code>).</p> <important>
/// <p>Health check results will be unpredictable if you do the following:</p>
/// <ul>
/// <li> <p>Create a health check that has the same value for <code>FullyQualifiedDomainName</code> as the name of a resource record set.</p> </li>
/// <li> <p>Associate that health check with the resource record set.</p> </li>
/// </ul>
/// </important>
pub fn set_health_check_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.health_check_id = input;
self
}
/// <p>When you create a traffic policy instance, Amazon Route 53 automatically creates a resource record set. <code>TrafficPolicyInstanceId</code> is the ID of the traffic policy instance that Route 53 created this resource record set for.</p> <important>
/// <p>To delete the resource record set that is associated with a traffic policy instance, use <code>DeleteTrafficPolicyInstance</code>. Route 53 will delete the resource record set automatically. If you delete the resource record set by using <code>ChangeResourceRecordSets</code>, Route 53 doesn't automatically delete the traffic policy instance, and you'll continue to be charged for it even though it's no longer in use. </p>
/// </important>
pub fn traffic_policy_instance_id(mut self, input: impl Into<std::string::String>) -> Self {
self.traffic_policy_instance_id = Some(input.into());
self
}
/// <p>When you create a traffic policy instance, Amazon Route 53 automatically creates a resource record set. <code>TrafficPolicyInstanceId</code> is the ID of the traffic policy instance that Route 53 created this resource record set for.</p> <important>
/// <p>To delete the resource record set that is associated with a traffic policy instance, use <code>DeleteTrafficPolicyInstance</code>. Route 53 will delete the resource record set automatically. If you delete the resource record set by using <code>ChangeResourceRecordSets</code>, Route 53 doesn't automatically delete the traffic policy instance, and you'll continue to be charged for it even though it's no longer in use. </p>
/// </important>
pub fn set_traffic_policy_instance_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.traffic_policy_instance_id = input;
self
}
/// Consumes the builder and constructs a [`ResourceRecordSet`](crate::model::ResourceRecordSet)
pub fn build(self) -> crate::model::ResourceRecordSet {
crate::model::ResourceRecordSet {
name: self.name,
r#type: self.r#type,
set_identifier: self.set_identifier,
weight: self.weight,
region: self.region,
geo_location: self.geo_location,
failover: self.failover,
multi_value_answer: self.multi_value_answer,
ttl: self.ttl,
resource_records: self.resource_records,
alias_target: self.alias_target,
health_check_id: self.health_check_id,
traffic_policy_instance_id: self.traffic_policy_instance_id,
}
}
}
}
impl ResourceRecordSet {
/// Creates a new builder-style object to manufacture [`ResourceRecordSet`](crate::model::ResourceRecordSet)
pub fn builder() -> crate::model::resource_record_set::Builder {
crate::model::resource_record_set::Builder::default()
}
}
/// <p> <i>Alias resource record sets only:</i> Information about the Amazon Web Services resource, such as a CloudFront distribution or an Amazon S3 bucket, that you want to route traffic to.</p>
/// <p>When creating resource record sets for a private hosted zone, note the following:</p>
/// <ul>
/// <li> <p>Creating geolocation alias resource record sets or latency alias resource record sets in a private hosted zone is unsupported.</p> </li>
/// <li> <p>For information about creating failover resource record sets in a private hosted zone, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-private-hosted-zones.html">Configuring Failover in a Private Hosted Zone</a>.</p> </li>
/// </ul>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct AliasTarget {
/// <p> <i>Alias resource records sets only</i>: The value used depends on where you want to route traffic:</p>
/// <dl>
/// <dt>
/// Amazon API Gateway custom regional APIs and edge-optimized APIs
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID for your API. You can get the applicable value using the CLI command <a href="https://docs.aws.amazon.com/cli/latest/reference/apigateway/get-domain-names.html">get-domain-names</a>:</p>
/// <ul>
/// <li> <p>For regional APIs, specify the value of <code>regionalHostedZoneId</code>.</p> </li>
/// <li> <p>For edge-optimized APIs, specify the value of <code>distributionHostedZoneId</code>.</p> </li>
/// </ul>
/// </dd>
/// <dt>
/// Amazon Virtual Private Cloud interface VPC endpoint
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID for your interface endpoint. You can get the value of <code>HostedZoneId</code> using the CLI command <a href="https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-vpc-endpoints.html">describe-vpc-endpoints</a>.</p>
/// </dd>
/// <dt>
/// CloudFront distribution
/// </dt>
/// <dd>
/// <p>Specify <code>Z2FDTNDATAQYW2</code>.</p> <note>
/// <p>Alias resource record sets for CloudFront can't be created in a private zone.</p>
/// </note>
/// </dd>
/// <dt>
/// Elastic Beanstalk environment
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID for the region that you created the environment in. The environment must have a regionalized subdomain. For a list of regions and the corresponding hosted zone IDs, see <a href="https://docs.aws.amazon.com/general/latest/gr/elasticbeanstalk.html">Elastic Beanstalk endpoints and quotas</a> in the the <i>Amazon Web Services General Reference</i>.</p>
/// </dd>
/// <dt>
/// ELB load balancer
/// </dt>
/// <dd>
/// <p>Specify the value of the hosted zone ID for the load balancer. Use the following methods to get the hosted zone ID:</p>
/// <ul>
/// <li> <p> <a href="https://docs.aws.amazon.com/general/latest/gr/elb.html">Elastic Load Balancing endpoints and quotas</a> topic in the <i>Amazon Web Services General Reference</i>: Use the value that corresponds with the region that you created your load balancer in. Note that there are separate columns for Application and Classic Load Balancers and for Network Load Balancers.</p> </li>
/// <li> <p> <b>Amazon Web Services Management Console</b>: Go to the Amazon EC2 page, choose <b>Load Balancers</b> in the navigation pane, select the load balancer, and get the value of the <b>Hosted zone</b> field on the <b>Description</b> tab.</p> </li>
/// <li> <p> <b>Elastic Load Balancing API</b>: Use <code>DescribeLoadBalancers</code> to get the applicable value. For more information, see the applicable guide:</p>
/// <ul>
/// <li> <p>Classic Load Balancers: Use <a href="https://docs.aws.amazon.com/elasticloadbalancing/2012-06-01/APIReference/API_DescribeLoadBalancers.html">DescribeLoadBalancers</a> to get the value of <code>CanonicalHostedZoneNameId</code>.</p> </li>
/// <li> <p>Application and Network Load Balancers: Use <a href="https://docs.aws.amazon.com/elasticloadbalancing/latest/APIReference/API_DescribeLoadBalancers.html">DescribeLoadBalancers</a> to get the value of <code>CanonicalHostedZoneId</code>.</p> </li>
/// </ul> </li>
/// <li> <p> <b>CLI</b>: Use <code>describe-load-balancers</code> to get the applicable value. For more information, see the applicable guide:</p>
/// <ul>
/// <li> <p>Classic Load Balancers: Use <a href="http://docs.aws.amazon.com/cli/latest/reference/elb/describe-load-balancers.html">describe-load-balancers</a> to get the value of <code>CanonicalHostedZoneNameId</code>.</p> </li>
/// <li> <p>Application and Network Load Balancers: Use <a href="http://docs.aws.amazon.com/cli/latest/reference/elbv2/describe-load-balancers.html">describe-load-balancers</a> to get the value of <code>CanonicalHostedZoneId</code>.</p> </li>
/// </ul> </li>
/// </ul>
/// </dd>
/// <dt>
/// Global Accelerator accelerator
/// </dt>
/// <dd>
/// <p>Specify <code>Z2BJ6XQ5FK7U4H</code>.</p>
/// </dd>
/// <dt>
/// An Amazon S3 bucket configured as a static website
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID for the region that you created the bucket in. For more information about valid values, see the table <a href="https://docs.aws.amazon.com/general/latest/gr/s3.html#s3_website_region_endpoints">Amazon S3 Website Endpoints</a> in the <i>Amazon Web Services General Reference</i>.</p>
/// </dd>
/// <dt>
/// Another Route 53 resource record set in your hosted zone
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID of your hosted zone. (An alias resource record set can't reference a resource record set in a different hosted zone.)</p>
/// </dd>
/// </dl>
pub hosted_zone_id: std::option::Option<std::string::String>,
/// <p> <i>Alias resource record sets only:</i> The value that you specify depends on where you want to route queries:</p>
/// <dl>
/// <dt>
/// Amazon API Gateway custom regional APIs and edge-optimized APIs
/// </dt>
/// <dd>
/// <p>Specify the applicable domain name for your API. You can get the applicable value using the CLI command <a href="https://docs.aws.amazon.com/cli/latest/reference/apigateway/get-domain-names.html">get-domain-names</a>:</p>
/// <ul>
/// <li> <p>For regional APIs, specify the value of <code>regionalDomainName</code>.</p> </li>
/// <li> <p>For edge-optimized APIs, specify the value of <code>distributionDomainName</code>. This is the name of the associated CloudFront distribution, such as <code>da1b2c3d4e5.cloudfront.net</code>.</p> </li>
/// </ul> <note>
/// <p>The name of the record that you're creating must match a custom domain name for your API, such as <code>api.example.com</code>.</p>
/// </note>
/// </dd>
/// <dt>
/// Amazon Virtual Private Cloud interface VPC endpoint
/// </dt>
/// <dd>
/// <p>Enter the API endpoint for the interface endpoint, such as <code>vpce-123456789abcdef01-example-us-east-1a.elasticloadbalancing.us-east-1.vpce.amazonaws.com</code>. For edge-optimized APIs, this is the domain name for the corresponding CloudFront distribution. You can get the value of <code>DnsName</code> using the CLI command <a href="https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-vpc-endpoints.html">describe-vpc-endpoints</a>.</p>
/// </dd>
/// <dt>
/// CloudFront distribution
/// </dt>
/// <dd>
/// <p>Specify the domain name that CloudFront assigned when you created your distribution.</p>
/// <p>Your CloudFront distribution must include an alternate domain name that matches the name of the resource record set. For example, if the name of the resource record set is <i>acme.example.com</i>, your CloudFront distribution must include <i>acme.example.com</i> as one of the alternate domain names. For more information, see <a href="https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/CNAMEs.html">Using Alternate Domain Names (CNAMEs)</a> in the <i>Amazon CloudFront Developer Guide</i>.</p>
/// <p>You can't create a resource record set in a private hosted zone to route traffic to a CloudFront distribution.</p> <note>
/// <p>For failover alias records, you can't specify a CloudFront distribution for both the primary and secondary records. A distribution must include an alternate domain name that matches the name of the record. However, the primary and secondary records have the same name, and you can't include the same alternate domain name in more than one distribution. </p>
/// </note>
/// </dd>
/// <dt>
/// Elastic Beanstalk environment
/// </dt>
/// <dd>
/// <p>If the domain name for your Elastic Beanstalk environment includes the region that you deployed the environment in, you can create an alias record that routes traffic to the environment. For example, the domain name <code>my-environment.<i>us-west-2</i>.elasticbeanstalk.com</code> is a regionalized domain name. </p> <important>
/// <p>For environments that were created before early 2016, the domain name doesn't include the region. To route traffic to these environments, you must create a CNAME record instead of an alias record. Note that you can't create a CNAME record for the root domain name. For example, if your domain name is example.com, you can create a record that routes traffic for acme.example.com to your Elastic Beanstalk environment, but you can't create a record that routes traffic for example.com to your Elastic Beanstalk environment.</p>
/// </important>
/// <p>For Elastic Beanstalk environments that have regionalized subdomains, specify the <code>CNAME</code> attribute for the environment. You can use the following methods to get the value of the CNAME attribute:</p>
/// <ul>
/// <li> <p> <i>Amazon Web Services Management Console</i>: For information about how to get the value by using the console, see <a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/dg/customdomains.html">Using Custom Domains with Elastic Beanstalk</a> in the <i>Elastic Beanstalk Developer Guide</i>.</p> </li>
/// <li> <p> <i>Elastic Beanstalk API</i>: Use the <code>DescribeEnvironments</code> action to get the value of the <code>CNAME</code> attribute. For more information, see <a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/api/API_DescribeEnvironments.html">DescribeEnvironments</a> in the <i>Elastic Beanstalk API Reference</i>.</p> </li>
/// <li> <p> <i>CLI</i>: Use the <code>describe-environments</code> command to get the value of the <code>CNAME</code> attribute. For more information, see <a href="https://docs.aws.amazon.com/cli/latest/reference/elasticbeanstalk/describe-environments.html">describe-environments</a> in the <i>CLI Command Reference</i>.</p> </li>
/// </ul>
/// </dd>
/// <dt>
/// ELB load balancer
/// </dt>
/// <dd>
/// <p>Specify the DNS name that is associated with the load balancer. Get the DNS name by using the Amazon Web Services Management Console, the ELB API, or the CLI. </p>
/// <ul>
/// <li> <p> <b>Amazon Web Services Management Console</b>: Go to the EC2 page, choose <b>Load Balancers</b> in the navigation pane, choose the load balancer, choose the <b>Description</b> tab, and get the value of the <b>DNS name</b> field. </p> <p>If you're routing traffic to a Classic Load Balancer, get the value that begins with <b>dualstack</b>. If you're routing traffic to another type of load balancer, get the value that applies to the record type, A or AAAA.</p> </li>
/// <li> <p> <b>Elastic Load Balancing API</b>: Use <code>DescribeLoadBalancers</code> to get the value of <code>DNSName</code>. For more information, see the applicable guide:</p>
/// <ul>
/// <li> <p>Classic Load Balancers: <a href="https://docs.aws.amazon.com/elasticloadbalancing/2012-06-01/APIReference/API_DescribeLoadBalancers.html">DescribeLoadBalancers</a> </p> </li>
/// <li> <p>Application and Network Load Balancers: <a href="https://docs.aws.amazon.com/elasticloadbalancing/latest/APIReference/API_DescribeLoadBalancers.html">DescribeLoadBalancers</a> </p> </li>
/// </ul> </li>
/// <li> <p> <b>CLI</b>: Use <code>describe-load-balancers</code> to get the value of <code>DNSName</code>. For more information, see the applicable guide:</p>
/// <ul>
/// <li> <p>Classic Load Balancers: <a href="http://docs.aws.amazon.com/cli/latest/reference/elb/describe-load-balancers.html">describe-load-balancers</a> </p> </li>
/// <li> <p>Application and Network Load Balancers: <a href="http://docs.aws.amazon.com/cli/latest/reference/elbv2/describe-load-balancers.html">describe-load-balancers</a> </p> </li>
/// </ul> </li>
/// </ul>
/// </dd>
/// <dt>
/// Global Accelerator accelerator
/// </dt>
/// <dd>
/// <p>Specify the DNS name for your accelerator:</p>
/// <ul>
/// <li> <p> <b>Global Accelerator API:</b> To get the DNS name, use <a href="https://docs.aws.amazon.com/global-accelerator/latest/api/API_DescribeAccelerator.html">DescribeAccelerator</a>.</p> </li>
/// <li> <p> <b>CLI:</b> To get the DNS name, use <a href="https://docs.aws.amazon.com/cli/latest/reference/globalaccelerator/describe-accelerator.html">describe-accelerator</a>.</p> </li>
/// </ul>
/// </dd>
/// <dt>
/// Amazon S3 bucket that is configured as a static website
/// </dt>
/// <dd>
/// <p>Specify the domain name of the Amazon S3 website endpoint that you created the bucket in, for example, <code>s3-website.us-east-2.amazonaws.com</code>. For more information about valid values, see the table <a href="https://docs.aws.amazon.com/general/latest/gr/s3.html#s3_website_region_endpoints">Amazon S3 Website Endpoints</a> in the <i>Amazon Web Services General Reference</i>. For more information about using S3 buckets for websites, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/getting-started.html">Getting Started with Amazon Route 53</a> in the <i>Amazon Route 53 Developer Guide.</i> </p>
/// </dd>
/// <dt>
/// Another Route 53 resource record set
/// </dt>
/// <dd>
/// <p>Specify the value of the <code>Name</code> element for a resource record set in the current hosted zone.</p> <note>
/// <p>If you're creating an alias record that has the same name as the hosted zone (known as the zone apex), you can't specify the domain name for a record for which the value of <code>Type</code> is <code>CNAME</code>. This is because the alias record must have the same type as the record that you're routing traffic to, and creating a CNAME record for the zone apex isn't supported even for an alias record.</p>
/// </note>
/// </dd>
/// </dl>
pub dns_name: std::option::Option<std::string::String>,
/// <p> <i>Applies only to alias, failover alias, geolocation alias, latency alias, and weighted alias resource record sets:</i> When <code>EvaluateTargetHealth</code> is <code>true</code>, an alias resource record set inherits the health of the referenced Amazon Web Services resource, such as an ELB load balancer or another resource record set in the hosted zone.</p>
/// <p>Note the following:</p>
/// <dl>
/// <dt>
/// CloudFront distributions
/// </dt>
/// <dd>
/// <p>You can't set <code>EvaluateTargetHealth</code> to <code>true</code> when the alias target is a CloudFront distribution.</p>
/// </dd>
/// <dt>
/// Elastic Beanstalk environments that have regionalized subdomains
/// </dt>
/// <dd>
/// <p>If you specify an Elastic Beanstalk environment in <code>DNSName</code> and the environment contains an ELB load balancer, Elastic Load Balancing routes queries only to the healthy Amazon EC2 instances that are registered with the load balancer. (An environment automatically contains an ELB load balancer if it includes more than one Amazon EC2 instance.) If you set <code>EvaluateTargetHealth</code> to <code>true</code> and either no Amazon EC2 instances are healthy or the load balancer itself is unhealthy, Route 53 routes queries to other available resources that are healthy, if any. </p>
/// <p>If the environment contains a single Amazon EC2 instance, there are no special requirements.</p>
/// </dd>
/// <dt>
/// ELB load balancers
/// </dt>
/// <dd>
/// <p>Health checking behavior depends on the type of load balancer:</p>
/// <ul>
/// <li> <p> <b>Classic Load Balancers</b>: If you specify an ELB Classic Load Balancer in <code>DNSName</code>, Elastic Load Balancing routes queries only to the healthy Amazon EC2 instances that are registered with the load balancer. If you set <code>EvaluateTargetHealth</code> to <code>true</code> and either no EC2 instances are healthy or the load balancer itself is unhealthy, Route 53 routes queries to other resources.</p> </li>
/// <li> <p> <b>Application and Network Load Balancers</b>: If you specify an ELB Application or Network Load Balancer and you set <code>EvaluateTargetHealth</code> to <code>true</code>, Route 53 routes queries to the load balancer based on the health of the target groups that are associated with the load balancer:</p>
/// <ul>
/// <li> <p>For an Application or Network Load Balancer to be considered healthy, every target group that contains targets must contain at least one healthy target. If any target group contains only unhealthy targets, the load balancer is considered unhealthy, and Route 53 routes queries to other resources.</p> </li>
/// <li> <p>A target group that has no registered targets is considered unhealthy.</p> </li>
/// </ul> </li>
/// </ul> <note>
/// <p>When you create a load balancer, you configure settings for Elastic Load Balancing health checks; they're not Route 53 health checks, but they perform a similar function. Do not create Route 53 health checks for the EC2 instances that you register with an ELB load balancer. </p>
/// </note>
/// </dd>
/// <dt>
/// S3 buckets
/// </dt>
/// <dd>
/// <p>There are no special requirements for setting <code>EvaluateTargetHealth</code> to <code>true</code> when the alias target is an S3 bucket.</p>
/// </dd>
/// <dt>
/// Other records in the same hosted zone
/// </dt>
/// <dd>
/// <p>If the Amazon Web Services resource that you specify in <code>DNSName</code> is a record or a group of records (for example, a group of weighted records) but is not another alias record, we recommend that you associate a health check with all of the records in the alias target. For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-complex-configs.html#dns-failover-complex-configs-hc-omitting">What Happens When You Omit Health Checks?</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// </dd>
/// </dl>
/// <p>For more information and examples, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover.html">Amazon Route 53 Health Checks and DNS Failover</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
pub evaluate_target_health: bool,
}
impl AliasTarget {
/// <p> <i>Alias resource records sets only</i>: The value used depends on where you want to route traffic:</p>
/// <dl>
/// <dt>
/// Amazon API Gateway custom regional APIs and edge-optimized APIs
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID for your API. You can get the applicable value using the CLI command <a href="https://docs.aws.amazon.com/cli/latest/reference/apigateway/get-domain-names.html">get-domain-names</a>:</p>
/// <ul>
/// <li> <p>For regional APIs, specify the value of <code>regionalHostedZoneId</code>.</p> </li>
/// <li> <p>For edge-optimized APIs, specify the value of <code>distributionHostedZoneId</code>.</p> </li>
/// </ul>
/// </dd>
/// <dt>
/// Amazon Virtual Private Cloud interface VPC endpoint
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID for your interface endpoint. You can get the value of <code>HostedZoneId</code> using the CLI command <a href="https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-vpc-endpoints.html">describe-vpc-endpoints</a>.</p>
/// </dd>
/// <dt>
/// CloudFront distribution
/// </dt>
/// <dd>
/// <p>Specify <code>Z2FDTNDATAQYW2</code>.</p> <note>
/// <p>Alias resource record sets for CloudFront can't be created in a private zone.</p>
/// </note>
/// </dd>
/// <dt>
/// Elastic Beanstalk environment
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID for the region that you created the environment in. The environment must have a regionalized subdomain. For a list of regions and the corresponding hosted zone IDs, see <a href="https://docs.aws.amazon.com/general/latest/gr/elasticbeanstalk.html">Elastic Beanstalk endpoints and quotas</a> in the the <i>Amazon Web Services General Reference</i>.</p>
/// </dd>
/// <dt>
/// ELB load balancer
/// </dt>
/// <dd>
/// <p>Specify the value of the hosted zone ID for the load balancer. Use the following methods to get the hosted zone ID:</p>
/// <ul>
/// <li> <p> <a href="https://docs.aws.amazon.com/general/latest/gr/elb.html">Elastic Load Balancing endpoints and quotas</a> topic in the <i>Amazon Web Services General Reference</i>: Use the value that corresponds with the region that you created your load balancer in. Note that there are separate columns for Application and Classic Load Balancers and for Network Load Balancers.</p> </li>
/// <li> <p> <b>Amazon Web Services Management Console</b>: Go to the Amazon EC2 page, choose <b>Load Balancers</b> in the navigation pane, select the load balancer, and get the value of the <b>Hosted zone</b> field on the <b>Description</b> tab.</p> </li>
/// <li> <p> <b>Elastic Load Balancing API</b>: Use <code>DescribeLoadBalancers</code> to get the applicable value. For more information, see the applicable guide:</p>
/// <ul>
/// <li> <p>Classic Load Balancers: Use <a href="https://docs.aws.amazon.com/elasticloadbalancing/2012-06-01/APIReference/API_DescribeLoadBalancers.html">DescribeLoadBalancers</a> to get the value of <code>CanonicalHostedZoneNameId</code>.</p> </li>
/// <li> <p>Application and Network Load Balancers: Use <a href="https://docs.aws.amazon.com/elasticloadbalancing/latest/APIReference/API_DescribeLoadBalancers.html">DescribeLoadBalancers</a> to get the value of <code>CanonicalHostedZoneId</code>.</p> </li>
/// </ul> </li>
/// <li> <p> <b>CLI</b>: Use <code>describe-load-balancers</code> to get the applicable value. For more information, see the applicable guide:</p>
/// <ul>
/// <li> <p>Classic Load Balancers: Use <a href="http://docs.aws.amazon.com/cli/latest/reference/elb/describe-load-balancers.html">describe-load-balancers</a> to get the value of <code>CanonicalHostedZoneNameId</code>.</p> </li>
/// <li> <p>Application and Network Load Balancers: Use <a href="http://docs.aws.amazon.com/cli/latest/reference/elbv2/describe-load-balancers.html">describe-load-balancers</a> to get the value of <code>CanonicalHostedZoneId</code>.</p> </li>
/// </ul> </li>
/// </ul>
/// </dd>
/// <dt>
/// Global Accelerator accelerator
/// </dt>
/// <dd>
/// <p>Specify <code>Z2BJ6XQ5FK7U4H</code>.</p>
/// </dd>
/// <dt>
/// An Amazon S3 bucket configured as a static website
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID for the region that you created the bucket in. For more information about valid values, see the table <a href="https://docs.aws.amazon.com/general/latest/gr/s3.html#s3_website_region_endpoints">Amazon S3 Website Endpoints</a> in the <i>Amazon Web Services General Reference</i>.</p>
/// </dd>
/// <dt>
/// Another Route 53 resource record set in your hosted zone
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID of your hosted zone. (An alias resource record set can't reference a resource record set in a different hosted zone.)</p>
/// </dd>
/// </dl>
pub fn hosted_zone_id(&self) -> std::option::Option<&str> {
self.hosted_zone_id.as_deref()
}
/// <p> <i>Alias resource record sets only:</i> The value that you specify depends on where you want to route queries:</p>
/// <dl>
/// <dt>
/// Amazon API Gateway custom regional APIs and edge-optimized APIs
/// </dt>
/// <dd>
/// <p>Specify the applicable domain name for your API. You can get the applicable value using the CLI command <a href="https://docs.aws.amazon.com/cli/latest/reference/apigateway/get-domain-names.html">get-domain-names</a>:</p>
/// <ul>
/// <li> <p>For regional APIs, specify the value of <code>regionalDomainName</code>.</p> </li>
/// <li> <p>For edge-optimized APIs, specify the value of <code>distributionDomainName</code>. This is the name of the associated CloudFront distribution, such as <code>da1b2c3d4e5.cloudfront.net</code>.</p> </li>
/// </ul> <note>
/// <p>The name of the record that you're creating must match a custom domain name for your API, such as <code>api.example.com</code>.</p>
/// </note>
/// </dd>
/// <dt>
/// Amazon Virtual Private Cloud interface VPC endpoint
/// </dt>
/// <dd>
/// <p>Enter the API endpoint for the interface endpoint, such as <code>vpce-123456789abcdef01-example-us-east-1a.elasticloadbalancing.us-east-1.vpce.amazonaws.com</code>. For edge-optimized APIs, this is the domain name for the corresponding CloudFront distribution. You can get the value of <code>DnsName</code> using the CLI command <a href="https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-vpc-endpoints.html">describe-vpc-endpoints</a>.</p>
/// </dd>
/// <dt>
/// CloudFront distribution
/// </dt>
/// <dd>
/// <p>Specify the domain name that CloudFront assigned when you created your distribution.</p>
/// <p>Your CloudFront distribution must include an alternate domain name that matches the name of the resource record set. For example, if the name of the resource record set is <i>acme.example.com</i>, your CloudFront distribution must include <i>acme.example.com</i> as one of the alternate domain names. For more information, see <a href="https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/CNAMEs.html">Using Alternate Domain Names (CNAMEs)</a> in the <i>Amazon CloudFront Developer Guide</i>.</p>
/// <p>You can't create a resource record set in a private hosted zone to route traffic to a CloudFront distribution.</p> <note>
/// <p>For failover alias records, you can't specify a CloudFront distribution for both the primary and secondary records. A distribution must include an alternate domain name that matches the name of the record. However, the primary and secondary records have the same name, and you can't include the same alternate domain name in more than one distribution. </p>
/// </note>
/// </dd>
/// <dt>
/// Elastic Beanstalk environment
/// </dt>
/// <dd>
/// <p>If the domain name for your Elastic Beanstalk environment includes the region that you deployed the environment in, you can create an alias record that routes traffic to the environment. For example, the domain name <code>my-environment.<i>us-west-2</i>.elasticbeanstalk.com</code> is a regionalized domain name. </p> <important>
/// <p>For environments that were created before early 2016, the domain name doesn't include the region. To route traffic to these environments, you must create a CNAME record instead of an alias record. Note that you can't create a CNAME record for the root domain name. For example, if your domain name is example.com, you can create a record that routes traffic for acme.example.com to your Elastic Beanstalk environment, but you can't create a record that routes traffic for example.com to your Elastic Beanstalk environment.</p>
/// </important>
/// <p>For Elastic Beanstalk environments that have regionalized subdomains, specify the <code>CNAME</code> attribute for the environment. You can use the following methods to get the value of the CNAME attribute:</p>
/// <ul>
/// <li> <p> <i>Amazon Web Services Management Console</i>: For information about how to get the value by using the console, see <a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/dg/customdomains.html">Using Custom Domains with Elastic Beanstalk</a> in the <i>Elastic Beanstalk Developer Guide</i>.</p> </li>
/// <li> <p> <i>Elastic Beanstalk API</i>: Use the <code>DescribeEnvironments</code> action to get the value of the <code>CNAME</code> attribute. For more information, see <a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/api/API_DescribeEnvironments.html">DescribeEnvironments</a> in the <i>Elastic Beanstalk API Reference</i>.</p> </li>
/// <li> <p> <i>CLI</i>: Use the <code>describe-environments</code> command to get the value of the <code>CNAME</code> attribute. For more information, see <a href="https://docs.aws.amazon.com/cli/latest/reference/elasticbeanstalk/describe-environments.html">describe-environments</a> in the <i>CLI Command Reference</i>.</p> </li>
/// </ul>
/// </dd>
/// <dt>
/// ELB load balancer
/// </dt>
/// <dd>
/// <p>Specify the DNS name that is associated with the load balancer. Get the DNS name by using the Amazon Web Services Management Console, the ELB API, or the CLI. </p>
/// <ul>
/// <li> <p> <b>Amazon Web Services Management Console</b>: Go to the EC2 page, choose <b>Load Balancers</b> in the navigation pane, choose the load balancer, choose the <b>Description</b> tab, and get the value of the <b>DNS name</b> field. </p> <p>If you're routing traffic to a Classic Load Balancer, get the value that begins with <b>dualstack</b>. If you're routing traffic to another type of load balancer, get the value that applies to the record type, A or AAAA.</p> </li>
/// <li> <p> <b>Elastic Load Balancing API</b>: Use <code>DescribeLoadBalancers</code> to get the value of <code>DNSName</code>. For more information, see the applicable guide:</p>
/// <ul>
/// <li> <p>Classic Load Balancers: <a href="https://docs.aws.amazon.com/elasticloadbalancing/2012-06-01/APIReference/API_DescribeLoadBalancers.html">DescribeLoadBalancers</a> </p> </li>
/// <li> <p>Application and Network Load Balancers: <a href="https://docs.aws.amazon.com/elasticloadbalancing/latest/APIReference/API_DescribeLoadBalancers.html">DescribeLoadBalancers</a> </p> </li>
/// </ul> </li>
/// <li> <p> <b>CLI</b>: Use <code>describe-load-balancers</code> to get the value of <code>DNSName</code>. For more information, see the applicable guide:</p>
/// <ul>
/// <li> <p>Classic Load Balancers: <a href="http://docs.aws.amazon.com/cli/latest/reference/elb/describe-load-balancers.html">describe-load-balancers</a> </p> </li>
/// <li> <p>Application and Network Load Balancers: <a href="http://docs.aws.amazon.com/cli/latest/reference/elbv2/describe-load-balancers.html">describe-load-balancers</a> </p> </li>
/// </ul> </li>
/// </ul>
/// </dd>
/// <dt>
/// Global Accelerator accelerator
/// </dt>
/// <dd>
/// <p>Specify the DNS name for your accelerator:</p>
/// <ul>
/// <li> <p> <b>Global Accelerator API:</b> To get the DNS name, use <a href="https://docs.aws.amazon.com/global-accelerator/latest/api/API_DescribeAccelerator.html">DescribeAccelerator</a>.</p> </li>
/// <li> <p> <b>CLI:</b> To get the DNS name, use <a href="https://docs.aws.amazon.com/cli/latest/reference/globalaccelerator/describe-accelerator.html">describe-accelerator</a>.</p> </li>
/// </ul>
/// </dd>
/// <dt>
/// Amazon S3 bucket that is configured as a static website
/// </dt>
/// <dd>
/// <p>Specify the domain name of the Amazon S3 website endpoint that you created the bucket in, for example, <code>s3-website.us-east-2.amazonaws.com</code>. For more information about valid values, see the table <a href="https://docs.aws.amazon.com/general/latest/gr/s3.html#s3_website_region_endpoints">Amazon S3 Website Endpoints</a> in the <i>Amazon Web Services General Reference</i>. For more information about using S3 buckets for websites, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/getting-started.html">Getting Started with Amazon Route 53</a> in the <i>Amazon Route 53 Developer Guide.</i> </p>
/// </dd>
/// <dt>
/// Another Route 53 resource record set
/// </dt>
/// <dd>
/// <p>Specify the value of the <code>Name</code> element for a resource record set in the current hosted zone.</p> <note>
/// <p>If you're creating an alias record that has the same name as the hosted zone (known as the zone apex), you can't specify the domain name for a record for which the value of <code>Type</code> is <code>CNAME</code>. This is because the alias record must have the same type as the record that you're routing traffic to, and creating a CNAME record for the zone apex isn't supported even for an alias record.</p>
/// </note>
/// </dd>
/// </dl>
pub fn dns_name(&self) -> std::option::Option<&str> {
self.dns_name.as_deref()
}
/// <p> <i>Applies only to alias, failover alias, geolocation alias, latency alias, and weighted alias resource record sets:</i> When <code>EvaluateTargetHealth</code> is <code>true</code>, an alias resource record set inherits the health of the referenced Amazon Web Services resource, such as an ELB load balancer or another resource record set in the hosted zone.</p>
/// <p>Note the following:</p>
/// <dl>
/// <dt>
/// CloudFront distributions
/// </dt>
/// <dd>
/// <p>You can't set <code>EvaluateTargetHealth</code> to <code>true</code> when the alias target is a CloudFront distribution.</p>
/// </dd>
/// <dt>
/// Elastic Beanstalk environments that have regionalized subdomains
/// </dt>
/// <dd>
/// <p>If you specify an Elastic Beanstalk environment in <code>DNSName</code> and the environment contains an ELB load balancer, Elastic Load Balancing routes queries only to the healthy Amazon EC2 instances that are registered with the load balancer. (An environment automatically contains an ELB load balancer if it includes more than one Amazon EC2 instance.) If you set <code>EvaluateTargetHealth</code> to <code>true</code> and either no Amazon EC2 instances are healthy or the load balancer itself is unhealthy, Route 53 routes queries to other available resources that are healthy, if any. </p>
/// <p>If the environment contains a single Amazon EC2 instance, there are no special requirements.</p>
/// </dd>
/// <dt>
/// ELB load balancers
/// </dt>
/// <dd>
/// <p>Health checking behavior depends on the type of load balancer:</p>
/// <ul>
/// <li> <p> <b>Classic Load Balancers</b>: If you specify an ELB Classic Load Balancer in <code>DNSName</code>, Elastic Load Balancing routes queries only to the healthy Amazon EC2 instances that are registered with the load balancer. If you set <code>EvaluateTargetHealth</code> to <code>true</code> and either no EC2 instances are healthy or the load balancer itself is unhealthy, Route 53 routes queries to other resources.</p> </li>
/// <li> <p> <b>Application and Network Load Balancers</b>: If you specify an ELB Application or Network Load Balancer and you set <code>EvaluateTargetHealth</code> to <code>true</code>, Route 53 routes queries to the load balancer based on the health of the target groups that are associated with the load balancer:</p>
/// <ul>
/// <li> <p>For an Application or Network Load Balancer to be considered healthy, every target group that contains targets must contain at least one healthy target. If any target group contains only unhealthy targets, the load balancer is considered unhealthy, and Route 53 routes queries to other resources.</p> </li>
/// <li> <p>A target group that has no registered targets is considered unhealthy.</p> </li>
/// </ul> </li>
/// </ul> <note>
/// <p>When you create a load balancer, you configure settings for Elastic Load Balancing health checks; they're not Route 53 health checks, but they perform a similar function. Do not create Route 53 health checks for the EC2 instances that you register with an ELB load balancer. </p>
/// </note>
/// </dd>
/// <dt>
/// S3 buckets
/// </dt>
/// <dd>
/// <p>There are no special requirements for setting <code>EvaluateTargetHealth</code> to <code>true</code> when the alias target is an S3 bucket.</p>
/// </dd>
/// <dt>
/// Other records in the same hosted zone
/// </dt>
/// <dd>
/// <p>If the Amazon Web Services resource that you specify in <code>DNSName</code> is a record or a group of records (for example, a group of weighted records) but is not another alias record, we recommend that you associate a health check with all of the records in the alias target. For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-complex-configs.html#dns-failover-complex-configs-hc-omitting">What Happens When You Omit Health Checks?</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// </dd>
/// </dl>
/// <p>For more information and examples, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover.html">Amazon Route 53 Health Checks and DNS Failover</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
pub fn evaluate_target_health(&self) -> bool {
self.evaluate_target_health
}
}
impl std::fmt::Debug for AliasTarget {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("AliasTarget");
formatter.field("hosted_zone_id", &self.hosted_zone_id);
formatter.field("dns_name", &self.dns_name);
formatter.field("evaluate_target_health", &self.evaluate_target_health);
formatter.finish()
}
}
/// See [`AliasTarget`](crate::model::AliasTarget)
pub mod alias_target {
/// A builder for [`AliasTarget`](crate::model::AliasTarget)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) hosted_zone_id: std::option::Option<std::string::String>,
pub(crate) dns_name: std::option::Option<std::string::String>,
pub(crate) evaluate_target_health: std::option::Option<bool>,
}
impl Builder {
/// <p> <i>Alias resource records sets only</i>: The value used depends on where you want to route traffic:</p>
/// <dl>
/// <dt>
/// Amazon API Gateway custom regional APIs and edge-optimized APIs
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID for your API. You can get the applicable value using the CLI command <a href="https://docs.aws.amazon.com/cli/latest/reference/apigateway/get-domain-names.html">get-domain-names</a>:</p>
/// <ul>
/// <li> <p>For regional APIs, specify the value of <code>regionalHostedZoneId</code>.</p> </li>
/// <li> <p>For edge-optimized APIs, specify the value of <code>distributionHostedZoneId</code>.</p> </li>
/// </ul>
/// </dd>
/// <dt>
/// Amazon Virtual Private Cloud interface VPC endpoint
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID for your interface endpoint. You can get the value of <code>HostedZoneId</code> using the CLI command <a href="https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-vpc-endpoints.html">describe-vpc-endpoints</a>.</p>
/// </dd>
/// <dt>
/// CloudFront distribution
/// </dt>
/// <dd>
/// <p>Specify <code>Z2FDTNDATAQYW2</code>.</p> <note>
/// <p>Alias resource record sets for CloudFront can't be created in a private zone.</p>
/// </note>
/// </dd>
/// <dt>
/// Elastic Beanstalk environment
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID for the region that you created the environment in. The environment must have a regionalized subdomain. For a list of regions and the corresponding hosted zone IDs, see <a href="https://docs.aws.amazon.com/general/latest/gr/elasticbeanstalk.html">Elastic Beanstalk endpoints and quotas</a> in the the <i>Amazon Web Services General Reference</i>.</p>
/// </dd>
/// <dt>
/// ELB load balancer
/// </dt>
/// <dd>
/// <p>Specify the value of the hosted zone ID for the load balancer. Use the following methods to get the hosted zone ID:</p>
/// <ul>
/// <li> <p> <a href="https://docs.aws.amazon.com/general/latest/gr/elb.html">Elastic Load Balancing endpoints and quotas</a> topic in the <i>Amazon Web Services General Reference</i>: Use the value that corresponds with the region that you created your load balancer in. Note that there are separate columns for Application and Classic Load Balancers and for Network Load Balancers.</p> </li>
/// <li> <p> <b>Amazon Web Services Management Console</b>: Go to the Amazon EC2 page, choose <b>Load Balancers</b> in the navigation pane, select the load balancer, and get the value of the <b>Hosted zone</b> field on the <b>Description</b> tab.</p> </li>
/// <li> <p> <b>Elastic Load Balancing API</b>: Use <code>DescribeLoadBalancers</code> to get the applicable value. For more information, see the applicable guide:</p>
/// <ul>
/// <li> <p>Classic Load Balancers: Use <a href="https://docs.aws.amazon.com/elasticloadbalancing/2012-06-01/APIReference/API_DescribeLoadBalancers.html">DescribeLoadBalancers</a> to get the value of <code>CanonicalHostedZoneNameId</code>.</p> </li>
/// <li> <p>Application and Network Load Balancers: Use <a href="https://docs.aws.amazon.com/elasticloadbalancing/latest/APIReference/API_DescribeLoadBalancers.html">DescribeLoadBalancers</a> to get the value of <code>CanonicalHostedZoneId</code>.</p> </li>
/// </ul> </li>
/// <li> <p> <b>CLI</b>: Use <code>describe-load-balancers</code> to get the applicable value. For more information, see the applicable guide:</p>
/// <ul>
/// <li> <p>Classic Load Balancers: Use <a href="http://docs.aws.amazon.com/cli/latest/reference/elb/describe-load-balancers.html">describe-load-balancers</a> to get the value of <code>CanonicalHostedZoneNameId</code>.</p> </li>
/// <li> <p>Application and Network Load Balancers: Use <a href="http://docs.aws.amazon.com/cli/latest/reference/elbv2/describe-load-balancers.html">describe-load-balancers</a> to get the value of <code>CanonicalHostedZoneId</code>.</p> </li>
/// </ul> </li>
/// </ul>
/// </dd>
/// <dt>
/// Global Accelerator accelerator
/// </dt>
/// <dd>
/// <p>Specify <code>Z2BJ6XQ5FK7U4H</code>.</p>
/// </dd>
/// <dt>
/// An Amazon S3 bucket configured as a static website
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID for the region that you created the bucket in. For more information about valid values, see the table <a href="https://docs.aws.amazon.com/general/latest/gr/s3.html#s3_website_region_endpoints">Amazon S3 Website Endpoints</a> in the <i>Amazon Web Services General Reference</i>.</p>
/// </dd>
/// <dt>
/// Another Route 53 resource record set in your hosted zone
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID of your hosted zone. (An alias resource record set can't reference a resource record set in a different hosted zone.)</p>
/// </dd>
/// </dl>
pub fn hosted_zone_id(mut self, input: impl Into<std::string::String>) -> Self {
self.hosted_zone_id = Some(input.into());
self
}
/// <p> <i>Alias resource records sets only</i>: The value used depends on where you want to route traffic:</p>
/// <dl>
/// <dt>
/// Amazon API Gateway custom regional APIs and edge-optimized APIs
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID for your API. You can get the applicable value using the CLI command <a href="https://docs.aws.amazon.com/cli/latest/reference/apigateway/get-domain-names.html">get-domain-names</a>:</p>
/// <ul>
/// <li> <p>For regional APIs, specify the value of <code>regionalHostedZoneId</code>.</p> </li>
/// <li> <p>For edge-optimized APIs, specify the value of <code>distributionHostedZoneId</code>.</p> </li>
/// </ul>
/// </dd>
/// <dt>
/// Amazon Virtual Private Cloud interface VPC endpoint
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID for your interface endpoint. You can get the value of <code>HostedZoneId</code> using the CLI command <a href="https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-vpc-endpoints.html">describe-vpc-endpoints</a>.</p>
/// </dd>
/// <dt>
/// CloudFront distribution
/// </dt>
/// <dd>
/// <p>Specify <code>Z2FDTNDATAQYW2</code>.</p> <note>
/// <p>Alias resource record sets for CloudFront can't be created in a private zone.</p>
/// </note>
/// </dd>
/// <dt>
/// Elastic Beanstalk environment
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID for the region that you created the environment in. The environment must have a regionalized subdomain. For a list of regions and the corresponding hosted zone IDs, see <a href="https://docs.aws.amazon.com/general/latest/gr/elasticbeanstalk.html">Elastic Beanstalk endpoints and quotas</a> in the the <i>Amazon Web Services General Reference</i>.</p>
/// </dd>
/// <dt>
/// ELB load balancer
/// </dt>
/// <dd>
/// <p>Specify the value of the hosted zone ID for the load balancer. Use the following methods to get the hosted zone ID:</p>
/// <ul>
/// <li> <p> <a href="https://docs.aws.amazon.com/general/latest/gr/elb.html">Elastic Load Balancing endpoints and quotas</a> topic in the <i>Amazon Web Services General Reference</i>: Use the value that corresponds with the region that you created your load balancer in. Note that there are separate columns for Application and Classic Load Balancers and for Network Load Balancers.</p> </li>
/// <li> <p> <b>Amazon Web Services Management Console</b>: Go to the Amazon EC2 page, choose <b>Load Balancers</b> in the navigation pane, select the load balancer, and get the value of the <b>Hosted zone</b> field on the <b>Description</b> tab.</p> </li>
/// <li> <p> <b>Elastic Load Balancing API</b>: Use <code>DescribeLoadBalancers</code> to get the applicable value. For more information, see the applicable guide:</p>
/// <ul>
/// <li> <p>Classic Load Balancers: Use <a href="https://docs.aws.amazon.com/elasticloadbalancing/2012-06-01/APIReference/API_DescribeLoadBalancers.html">DescribeLoadBalancers</a> to get the value of <code>CanonicalHostedZoneNameId</code>.</p> </li>
/// <li> <p>Application and Network Load Balancers: Use <a href="https://docs.aws.amazon.com/elasticloadbalancing/latest/APIReference/API_DescribeLoadBalancers.html">DescribeLoadBalancers</a> to get the value of <code>CanonicalHostedZoneId</code>.</p> </li>
/// </ul> </li>
/// <li> <p> <b>CLI</b>: Use <code>describe-load-balancers</code> to get the applicable value. For more information, see the applicable guide:</p>
/// <ul>
/// <li> <p>Classic Load Balancers: Use <a href="http://docs.aws.amazon.com/cli/latest/reference/elb/describe-load-balancers.html">describe-load-balancers</a> to get the value of <code>CanonicalHostedZoneNameId</code>.</p> </li>
/// <li> <p>Application and Network Load Balancers: Use <a href="http://docs.aws.amazon.com/cli/latest/reference/elbv2/describe-load-balancers.html">describe-load-balancers</a> to get the value of <code>CanonicalHostedZoneId</code>.</p> </li>
/// </ul> </li>
/// </ul>
/// </dd>
/// <dt>
/// Global Accelerator accelerator
/// </dt>
/// <dd>
/// <p>Specify <code>Z2BJ6XQ5FK7U4H</code>.</p>
/// </dd>
/// <dt>
/// An Amazon S3 bucket configured as a static website
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID for the region that you created the bucket in. For more information about valid values, see the table <a href="https://docs.aws.amazon.com/general/latest/gr/s3.html#s3_website_region_endpoints">Amazon S3 Website Endpoints</a> in the <i>Amazon Web Services General Reference</i>.</p>
/// </dd>
/// <dt>
/// Another Route 53 resource record set in your hosted zone
/// </dt>
/// <dd>
/// <p>Specify the hosted zone ID of your hosted zone. (An alias resource record set can't reference a resource record set in a different hosted zone.)</p>
/// </dd>
/// </dl>
pub fn set_hosted_zone_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.hosted_zone_id = input;
self
}
/// <p> <i>Alias resource record sets only:</i> The value that you specify depends on where you want to route queries:</p>
/// <dl>
/// <dt>
/// Amazon API Gateway custom regional APIs and edge-optimized APIs
/// </dt>
/// <dd>
/// <p>Specify the applicable domain name for your API. You can get the applicable value using the CLI command <a href="https://docs.aws.amazon.com/cli/latest/reference/apigateway/get-domain-names.html">get-domain-names</a>:</p>
/// <ul>
/// <li> <p>For regional APIs, specify the value of <code>regionalDomainName</code>.</p> </li>
/// <li> <p>For edge-optimized APIs, specify the value of <code>distributionDomainName</code>. This is the name of the associated CloudFront distribution, such as <code>da1b2c3d4e5.cloudfront.net</code>.</p> </li>
/// </ul> <note>
/// <p>The name of the record that you're creating must match a custom domain name for your API, such as <code>api.example.com</code>.</p>
/// </note>
/// </dd>
/// <dt>
/// Amazon Virtual Private Cloud interface VPC endpoint
/// </dt>
/// <dd>
/// <p>Enter the API endpoint for the interface endpoint, such as <code>vpce-123456789abcdef01-example-us-east-1a.elasticloadbalancing.us-east-1.vpce.amazonaws.com</code>. For edge-optimized APIs, this is the domain name for the corresponding CloudFront distribution. You can get the value of <code>DnsName</code> using the CLI command <a href="https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-vpc-endpoints.html">describe-vpc-endpoints</a>.</p>
/// </dd>
/// <dt>
/// CloudFront distribution
/// </dt>
/// <dd>
/// <p>Specify the domain name that CloudFront assigned when you created your distribution.</p>
/// <p>Your CloudFront distribution must include an alternate domain name that matches the name of the resource record set. For example, if the name of the resource record set is <i>acme.example.com</i>, your CloudFront distribution must include <i>acme.example.com</i> as one of the alternate domain names. For more information, see <a href="https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/CNAMEs.html">Using Alternate Domain Names (CNAMEs)</a> in the <i>Amazon CloudFront Developer Guide</i>.</p>
/// <p>You can't create a resource record set in a private hosted zone to route traffic to a CloudFront distribution.</p> <note>
/// <p>For failover alias records, you can't specify a CloudFront distribution for both the primary and secondary records. A distribution must include an alternate domain name that matches the name of the record. However, the primary and secondary records have the same name, and you can't include the same alternate domain name in more than one distribution. </p>
/// </note>
/// </dd>
/// <dt>
/// Elastic Beanstalk environment
/// </dt>
/// <dd>
/// <p>If the domain name for your Elastic Beanstalk environment includes the region that you deployed the environment in, you can create an alias record that routes traffic to the environment. For example, the domain name <code>my-environment.<i>us-west-2</i>.elasticbeanstalk.com</code> is a regionalized domain name. </p> <important>
/// <p>For environments that were created before early 2016, the domain name doesn't include the region. To route traffic to these environments, you must create a CNAME record instead of an alias record. Note that you can't create a CNAME record for the root domain name. For example, if your domain name is example.com, you can create a record that routes traffic for acme.example.com to your Elastic Beanstalk environment, but you can't create a record that routes traffic for example.com to your Elastic Beanstalk environment.</p>
/// </important>
/// <p>For Elastic Beanstalk environments that have regionalized subdomains, specify the <code>CNAME</code> attribute for the environment. You can use the following methods to get the value of the CNAME attribute:</p>
/// <ul>
/// <li> <p> <i>Amazon Web Services Management Console</i>: For information about how to get the value by using the console, see <a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/dg/customdomains.html">Using Custom Domains with Elastic Beanstalk</a> in the <i>Elastic Beanstalk Developer Guide</i>.</p> </li>
/// <li> <p> <i>Elastic Beanstalk API</i>: Use the <code>DescribeEnvironments</code> action to get the value of the <code>CNAME</code> attribute. For more information, see <a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/api/API_DescribeEnvironments.html">DescribeEnvironments</a> in the <i>Elastic Beanstalk API Reference</i>.</p> </li>
/// <li> <p> <i>CLI</i>: Use the <code>describe-environments</code> command to get the value of the <code>CNAME</code> attribute. For more information, see <a href="https://docs.aws.amazon.com/cli/latest/reference/elasticbeanstalk/describe-environments.html">describe-environments</a> in the <i>CLI Command Reference</i>.</p> </li>
/// </ul>
/// </dd>
/// <dt>
/// ELB load balancer
/// </dt>
/// <dd>
/// <p>Specify the DNS name that is associated with the load balancer. Get the DNS name by using the Amazon Web Services Management Console, the ELB API, or the CLI. </p>
/// <ul>
/// <li> <p> <b>Amazon Web Services Management Console</b>: Go to the EC2 page, choose <b>Load Balancers</b> in the navigation pane, choose the load balancer, choose the <b>Description</b> tab, and get the value of the <b>DNS name</b> field. </p> <p>If you're routing traffic to a Classic Load Balancer, get the value that begins with <b>dualstack</b>. If you're routing traffic to another type of load balancer, get the value that applies to the record type, A or AAAA.</p> </li>
/// <li> <p> <b>Elastic Load Balancing API</b>: Use <code>DescribeLoadBalancers</code> to get the value of <code>DNSName</code>. For more information, see the applicable guide:</p>
/// <ul>
/// <li> <p>Classic Load Balancers: <a href="https://docs.aws.amazon.com/elasticloadbalancing/2012-06-01/APIReference/API_DescribeLoadBalancers.html">DescribeLoadBalancers</a> </p> </li>
/// <li> <p>Application and Network Load Balancers: <a href="https://docs.aws.amazon.com/elasticloadbalancing/latest/APIReference/API_DescribeLoadBalancers.html">DescribeLoadBalancers</a> </p> </li>
/// </ul> </li>
/// <li> <p> <b>CLI</b>: Use <code>describe-load-balancers</code> to get the value of <code>DNSName</code>. For more information, see the applicable guide:</p>
/// <ul>
/// <li> <p>Classic Load Balancers: <a href="http://docs.aws.amazon.com/cli/latest/reference/elb/describe-load-balancers.html">describe-load-balancers</a> </p> </li>
/// <li> <p>Application and Network Load Balancers: <a href="http://docs.aws.amazon.com/cli/latest/reference/elbv2/describe-load-balancers.html">describe-load-balancers</a> </p> </li>
/// </ul> </li>
/// </ul>
/// </dd>
/// <dt>
/// Global Accelerator accelerator
/// </dt>
/// <dd>
/// <p>Specify the DNS name for your accelerator:</p>
/// <ul>
/// <li> <p> <b>Global Accelerator API:</b> To get the DNS name, use <a href="https://docs.aws.amazon.com/global-accelerator/latest/api/API_DescribeAccelerator.html">DescribeAccelerator</a>.</p> </li>
/// <li> <p> <b>CLI:</b> To get the DNS name, use <a href="https://docs.aws.amazon.com/cli/latest/reference/globalaccelerator/describe-accelerator.html">describe-accelerator</a>.</p> </li>
/// </ul>
/// </dd>
/// <dt>
/// Amazon S3 bucket that is configured as a static website
/// </dt>
/// <dd>
/// <p>Specify the domain name of the Amazon S3 website endpoint that you created the bucket in, for example, <code>s3-website.us-east-2.amazonaws.com</code>. For more information about valid values, see the table <a href="https://docs.aws.amazon.com/general/latest/gr/s3.html#s3_website_region_endpoints">Amazon S3 Website Endpoints</a> in the <i>Amazon Web Services General Reference</i>. For more information about using S3 buckets for websites, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/getting-started.html">Getting Started with Amazon Route 53</a> in the <i>Amazon Route 53 Developer Guide.</i> </p>
/// </dd>
/// <dt>
/// Another Route 53 resource record set
/// </dt>
/// <dd>
/// <p>Specify the value of the <code>Name</code> element for a resource record set in the current hosted zone.</p> <note>
/// <p>If you're creating an alias record that has the same name as the hosted zone (known as the zone apex), you can't specify the domain name for a record for which the value of <code>Type</code> is <code>CNAME</code>. This is because the alias record must have the same type as the record that you're routing traffic to, and creating a CNAME record for the zone apex isn't supported even for an alias record.</p>
/// </note>
/// </dd>
/// </dl>
pub fn dns_name(mut self, input: impl Into<std::string::String>) -> Self {
self.dns_name = Some(input.into());
self
}
/// <p> <i>Alias resource record sets only:</i> The value that you specify depends on where you want to route queries:</p>
/// <dl>
/// <dt>
/// Amazon API Gateway custom regional APIs and edge-optimized APIs
/// </dt>
/// <dd>
/// <p>Specify the applicable domain name for your API. You can get the applicable value using the CLI command <a href="https://docs.aws.amazon.com/cli/latest/reference/apigateway/get-domain-names.html">get-domain-names</a>:</p>
/// <ul>
/// <li> <p>For regional APIs, specify the value of <code>regionalDomainName</code>.</p> </li>
/// <li> <p>For edge-optimized APIs, specify the value of <code>distributionDomainName</code>. This is the name of the associated CloudFront distribution, such as <code>da1b2c3d4e5.cloudfront.net</code>.</p> </li>
/// </ul> <note>
/// <p>The name of the record that you're creating must match a custom domain name for your API, such as <code>api.example.com</code>.</p>
/// </note>
/// </dd>
/// <dt>
/// Amazon Virtual Private Cloud interface VPC endpoint
/// </dt>
/// <dd>
/// <p>Enter the API endpoint for the interface endpoint, such as <code>vpce-123456789abcdef01-example-us-east-1a.elasticloadbalancing.us-east-1.vpce.amazonaws.com</code>. For edge-optimized APIs, this is the domain name for the corresponding CloudFront distribution. You can get the value of <code>DnsName</code> using the CLI command <a href="https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-vpc-endpoints.html">describe-vpc-endpoints</a>.</p>
/// </dd>
/// <dt>
/// CloudFront distribution
/// </dt>
/// <dd>
/// <p>Specify the domain name that CloudFront assigned when you created your distribution.</p>
/// <p>Your CloudFront distribution must include an alternate domain name that matches the name of the resource record set. For example, if the name of the resource record set is <i>acme.example.com</i>, your CloudFront distribution must include <i>acme.example.com</i> as one of the alternate domain names. For more information, see <a href="https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/CNAMEs.html">Using Alternate Domain Names (CNAMEs)</a> in the <i>Amazon CloudFront Developer Guide</i>.</p>
/// <p>You can't create a resource record set in a private hosted zone to route traffic to a CloudFront distribution.</p> <note>
/// <p>For failover alias records, you can't specify a CloudFront distribution for both the primary and secondary records. A distribution must include an alternate domain name that matches the name of the record. However, the primary and secondary records have the same name, and you can't include the same alternate domain name in more than one distribution. </p>
/// </note>
/// </dd>
/// <dt>
/// Elastic Beanstalk environment
/// </dt>
/// <dd>
/// <p>If the domain name for your Elastic Beanstalk environment includes the region that you deployed the environment in, you can create an alias record that routes traffic to the environment. For example, the domain name <code>my-environment.<i>us-west-2</i>.elasticbeanstalk.com</code> is a regionalized domain name. </p> <important>
/// <p>For environments that were created before early 2016, the domain name doesn't include the region. To route traffic to these environments, you must create a CNAME record instead of an alias record. Note that you can't create a CNAME record for the root domain name. For example, if your domain name is example.com, you can create a record that routes traffic for acme.example.com to your Elastic Beanstalk environment, but you can't create a record that routes traffic for example.com to your Elastic Beanstalk environment.</p>
/// </important>
/// <p>For Elastic Beanstalk environments that have regionalized subdomains, specify the <code>CNAME</code> attribute for the environment. You can use the following methods to get the value of the CNAME attribute:</p>
/// <ul>
/// <li> <p> <i>Amazon Web Services Management Console</i>: For information about how to get the value by using the console, see <a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/dg/customdomains.html">Using Custom Domains with Elastic Beanstalk</a> in the <i>Elastic Beanstalk Developer Guide</i>.</p> </li>
/// <li> <p> <i>Elastic Beanstalk API</i>: Use the <code>DescribeEnvironments</code> action to get the value of the <code>CNAME</code> attribute. For more information, see <a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/api/API_DescribeEnvironments.html">DescribeEnvironments</a> in the <i>Elastic Beanstalk API Reference</i>.</p> </li>
/// <li> <p> <i>CLI</i>: Use the <code>describe-environments</code> command to get the value of the <code>CNAME</code> attribute. For more information, see <a href="https://docs.aws.amazon.com/cli/latest/reference/elasticbeanstalk/describe-environments.html">describe-environments</a> in the <i>CLI Command Reference</i>.</p> </li>
/// </ul>
/// </dd>
/// <dt>
/// ELB load balancer
/// </dt>
/// <dd>
/// <p>Specify the DNS name that is associated with the load balancer. Get the DNS name by using the Amazon Web Services Management Console, the ELB API, or the CLI. </p>
/// <ul>
/// <li> <p> <b>Amazon Web Services Management Console</b>: Go to the EC2 page, choose <b>Load Balancers</b> in the navigation pane, choose the load balancer, choose the <b>Description</b> tab, and get the value of the <b>DNS name</b> field. </p> <p>If you're routing traffic to a Classic Load Balancer, get the value that begins with <b>dualstack</b>. If you're routing traffic to another type of load balancer, get the value that applies to the record type, A or AAAA.</p> </li>
/// <li> <p> <b>Elastic Load Balancing API</b>: Use <code>DescribeLoadBalancers</code> to get the value of <code>DNSName</code>. For more information, see the applicable guide:</p>
/// <ul>
/// <li> <p>Classic Load Balancers: <a href="https://docs.aws.amazon.com/elasticloadbalancing/2012-06-01/APIReference/API_DescribeLoadBalancers.html">DescribeLoadBalancers</a> </p> </li>
/// <li> <p>Application and Network Load Balancers: <a href="https://docs.aws.amazon.com/elasticloadbalancing/latest/APIReference/API_DescribeLoadBalancers.html">DescribeLoadBalancers</a> </p> </li>
/// </ul> </li>
/// <li> <p> <b>CLI</b>: Use <code>describe-load-balancers</code> to get the value of <code>DNSName</code>. For more information, see the applicable guide:</p>
/// <ul>
/// <li> <p>Classic Load Balancers: <a href="http://docs.aws.amazon.com/cli/latest/reference/elb/describe-load-balancers.html">describe-load-balancers</a> </p> </li>
/// <li> <p>Application and Network Load Balancers: <a href="http://docs.aws.amazon.com/cli/latest/reference/elbv2/describe-load-balancers.html">describe-load-balancers</a> </p> </li>
/// </ul> </li>
/// </ul>
/// </dd>
/// <dt>
/// Global Accelerator accelerator
/// </dt>
/// <dd>
/// <p>Specify the DNS name for your accelerator:</p>
/// <ul>
/// <li> <p> <b>Global Accelerator API:</b> To get the DNS name, use <a href="https://docs.aws.amazon.com/global-accelerator/latest/api/API_DescribeAccelerator.html">DescribeAccelerator</a>.</p> </li>
/// <li> <p> <b>CLI:</b> To get the DNS name, use <a href="https://docs.aws.amazon.com/cli/latest/reference/globalaccelerator/describe-accelerator.html">describe-accelerator</a>.</p> </li>
/// </ul>
/// </dd>
/// <dt>
/// Amazon S3 bucket that is configured as a static website
/// </dt>
/// <dd>
/// <p>Specify the domain name of the Amazon S3 website endpoint that you created the bucket in, for example, <code>s3-website.us-east-2.amazonaws.com</code>. For more information about valid values, see the table <a href="https://docs.aws.amazon.com/general/latest/gr/s3.html#s3_website_region_endpoints">Amazon S3 Website Endpoints</a> in the <i>Amazon Web Services General Reference</i>. For more information about using S3 buckets for websites, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/getting-started.html">Getting Started with Amazon Route 53</a> in the <i>Amazon Route 53 Developer Guide.</i> </p>
/// </dd>
/// <dt>
/// Another Route 53 resource record set
/// </dt>
/// <dd>
/// <p>Specify the value of the <code>Name</code> element for a resource record set in the current hosted zone.</p> <note>
/// <p>If you're creating an alias record that has the same name as the hosted zone (known as the zone apex), you can't specify the domain name for a record for which the value of <code>Type</code> is <code>CNAME</code>. This is because the alias record must have the same type as the record that you're routing traffic to, and creating a CNAME record for the zone apex isn't supported even for an alias record.</p>
/// </note>
/// </dd>
/// </dl>
pub fn set_dns_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.dns_name = input;
self
}
/// <p> <i>Applies only to alias, failover alias, geolocation alias, latency alias, and weighted alias resource record sets:</i> When <code>EvaluateTargetHealth</code> is <code>true</code>, an alias resource record set inherits the health of the referenced Amazon Web Services resource, such as an ELB load balancer or another resource record set in the hosted zone.</p>
/// <p>Note the following:</p>
/// <dl>
/// <dt>
/// CloudFront distributions
/// </dt>
/// <dd>
/// <p>You can't set <code>EvaluateTargetHealth</code> to <code>true</code> when the alias target is a CloudFront distribution.</p>
/// </dd>
/// <dt>
/// Elastic Beanstalk environments that have regionalized subdomains
/// </dt>
/// <dd>
/// <p>If you specify an Elastic Beanstalk environment in <code>DNSName</code> and the environment contains an ELB load balancer, Elastic Load Balancing routes queries only to the healthy Amazon EC2 instances that are registered with the load balancer. (An environment automatically contains an ELB load balancer if it includes more than one Amazon EC2 instance.) If you set <code>EvaluateTargetHealth</code> to <code>true</code> and either no Amazon EC2 instances are healthy or the load balancer itself is unhealthy, Route 53 routes queries to other available resources that are healthy, if any. </p>
/// <p>If the environment contains a single Amazon EC2 instance, there are no special requirements.</p>
/// </dd>
/// <dt>
/// ELB load balancers
/// </dt>
/// <dd>
/// <p>Health checking behavior depends on the type of load balancer:</p>
/// <ul>
/// <li> <p> <b>Classic Load Balancers</b>: If you specify an ELB Classic Load Balancer in <code>DNSName</code>, Elastic Load Balancing routes queries only to the healthy Amazon EC2 instances that are registered with the load balancer. If you set <code>EvaluateTargetHealth</code> to <code>true</code> and either no EC2 instances are healthy or the load balancer itself is unhealthy, Route 53 routes queries to other resources.</p> </li>
/// <li> <p> <b>Application and Network Load Balancers</b>: If you specify an ELB Application or Network Load Balancer and you set <code>EvaluateTargetHealth</code> to <code>true</code>, Route 53 routes queries to the load balancer based on the health of the target groups that are associated with the load balancer:</p>
/// <ul>
/// <li> <p>For an Application or Network Load Balancer to be considered healthy, every target group that contains targets must contain at least one healthy target. If any target group contains only unhealthy targets, the load balancer is considered unhealthy, and Route 53 routes queries to other resources.</p> </li>
/// <li> <p>A target group that has no registered targets is considered unhealthy.</p> </li>
/// </ul> </li>
/// </ul> <note>
/// <p>When you create a load balancer, you configure settings for Elastic Load Balancing health checks; they're not Route 53 health checks, but they perform a similar function. Do not create Route 53 health checks for the EC2 instances that you register with an ELB load balancer. </p>
/// </note>
/// </dd>
/// <dt>
/// S3 buckets
/// </dt>
/// <dd>
/// <p>There are no special requirements for setting <code>EvaluateTargetHealth</code> to <code>true</code> when the alias target is an S3 bucket.</p>
/// </dd>
/// <dt>
/// Other records in the same hosted zone
/// </dt>
/// <dd>
/// <p>If the Amazon Web Services resource that you specify in <code>DNSName</code> is a record or a group of records (for example, a group of weighted records) but is not another alias record, we recommend that you associate a health check with all of the records in the alias target. For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-complex-configs.html#dns-failover-complex-configs-hc-omitting">What Happens When You Omit Health Checks?</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// </dd>
/// </dl>
/// <p>For more information and examples, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover.html">Amazon Route 53 Health Checks and DNS Failover</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
pub fn evaluate_target_health(mut self, input: bool) -> Self {
self.evaluate_target_health = Some(input);
self
}
/// <p> <i>Applies only to alias, failover alias, geolocation alias, latency alias, and weighted alias resource record sets:</i> When <code>EvaluateTargetHealth</code> is <code>true</code>, an alias resource record set inherits the health of the referenced Amazon Web Services resource, such as an ELB load balancer or another resource record set in the hosted zone.</p>
/// <p>Note the following:</p>
/// <dl>
/// <dt>
/// CloudFront distributions
/// </dt>
/// <dd>
/// <p>You can't set <code>EvaluateTargetHealth</code> to <code>true</code> when the alias target is a CloudFront distribution.</p>
/// </dd>
/// <dt>
/// Elastic Beanstalk environments that have regionalized subdomains
/// </dt>
/// <dd>
/// <p>If you specify an Elastic Beanstalk environment in <code>DNSName</code> and the environment contains an ELB load balancer, Elastic Load Balancing routes queries only to the healthy Amazon EC2 instances that are registered with the load balancer. (An environment automatically contains an ELB load balancer if it includes more than one Amazon EC2 instance.) If you set <code>EvaluateTargetHealth</code> to <code>true</code> and either no Amazon EC2 instances are healthy or the load balancer itself is unhealthy, Route 53 routes queries to other available resources that are healthy, if any. </p>
/// <p>If the environment contains a single Amazon EC2 instance, there are no special requirements.</p>
/// </dd>
/// <dt>
/// ELB load balancers
/// </dt>
/// <dd>
/// <p>Health checking behavior depends on the type of load balancer:</p>
/// <ul>
/// <li> <p> <b>Classic Load Balancers</b>: If you specify an ELB Classic Load Balancer in <code>DNSName</code>, Elastic Load Balancing routes queries only to the healthy Amazon EC2 instances that are registered with the load balancer. If you set <code>EvaluateTargetHealth</code> to <code>true</code> and either no EC2 instances are healthy or the load balancer itself is unhealthy, Route 53 routes queries to other resources.</p> </li>
/// <li> <p> <b>Application and Network Load Balancers</b>: If you specify an ELB Application or Network Load Balancer and you set <code>EvaluateTargetHealth</code> to <code>true</code>, Route 53 routes queries to the load balancer based on the health of the target groups that are associated with the load balancer:</p>
/// <ul>
/// <li> <p>For an Application or Network Load Balancer to be considered healthy, every target group that contains targets must contain at least one healthy target. If any target group contains only unhealthy targets, the load balancer is considered unhealthy, and Route 53 routes queries to other resources.</p> </li>
/// <li> <p>A target group that has no registered targets is considered unhealthy.</p> </li>
/// </ul> </li>
/// </ul> <note>
/// <p>When you create a load balancer, you configure settings for Elastic Load Balancing health checks; they're not Route 53 health checks, but they perform a similar function. Do not create Route 53 health checks for the EC2 instances that you register with an ELB load balancer. </p>
/// </note>
/// </dd>
/// <dt>
/// S3 buckets
/// </dt>
/// <dd>
/// <p>There are no special requirements for setting <code>EvaluateTargetHealth</code> to <code>true</code> when the alias target is an S3 bucket.</p>
/// </dd>
/// <dt>
/// Other records in the same hosted zone
/// </dt>
/// <dd>
/// <p>If the Amazon Web Services resource that you specify in <code>DNSName</code> is a record or a group of records (for example, a group of weighted records) but is not another alias record, we recommend that you associate a health check with all of the records in the alias target. For more information, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover-complex-configs.html#dns-failover-complex-configs-hc-omitting">What Happens When You Omit Health Checks?</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// </dd>
/// </dl>
/// <p>For more information and examples, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/dns-failover.html">Amazon Route 53 Health Checks and DNS Failover</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
pub fn set_evaluate_target_health(mut self, input: std::option::Option<bool>) -> Self {
self.evaluate_target_health = input;
self
}
/// Consumes the builder and constructs a [`AliasTarget`](crate::model::AliasTarget)
pub fn build(self) -> crate::model::AliasTarget {
crate::model::AliasTarget {
hosted_zone_id: self.hosted_zone_id,
dns_name: self.dns_name,
evaluate_target_health: self.evaluate_target_health.unwrap_or_default(),
}
}
}
}
impl AliasTarget {
/// Creates a new builder-style object to manufacture [`AliasTarget`](crate::model::AliasTarget)
pub fn builder() -> crate::model::alias_target::Builder {
crate::model::alias_target::Builder::default()
}
}
/// <p>Information specific to the resource record.</p> <note>
/// <p>If you're creating an alias resource record set, omit <code>ResourceRecord</code>.</p>
/// </note>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct ResourceRecord {
/// <p>The current or new DNS record value, not to exceed 4,000 characters. In the case of a <code>DELETE</code> action, if the current value does not match the actual value, an error is returned. For descriptions about how to format <code>Value</code> for different record types, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/ResourceRecordTypes.html">Supported DNS Resource Record Types</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// <p>You can specify more than one value for all record types except <code>CNAME</code> and <code>SOA</code>. </p> <note>
/// <p>If you're creating an alias resource record set, omit <code>Value</code>.</p>
/// </note>
pub value: std::option::Option<std::string::String>,
}
impl ResourceRecord {
/// <p>The current or new DNS record value, not to exceed 4,000 characters. In the case of a <code>DELETE</code> action, if the current value does not match the actual value, an error is returned. For descriptions about how to format <code>Value</code> for different record types, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/ResourceRecordTypes.html">Supported DNS Resource Record Types</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// <p>You can specify more than one value for all record types except <code>CNAME</code> and <code>SOA</code>. </p> <note>
/// <p>If you're creating an alias resource record set, omit <code>Value</code>.</p>
/// </note>
pub fn value(&self) -> std::option::Option<&str> {
self.value.as_deref()
}
}
impl std::fmt::Debug for ResourceRecord {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("ResourceRecord");
formatter.field("value", &self.value);
formatter.finish()
}
}
/// See [`ResourceRecord`](crate::model::ResourceRecord)
pub mod resource_record {
/// A builder for [`ResourceRecord`](crate::model::ResourceRecord)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) value: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The current or new DNS record value, not to exceed 4,000 characters. In the case of a <code>DELETE</code> action, if the current value does not match the actual value, an error is returned. For descriptions about how to format <code>Value</code> for different record types, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/ResourceRecordTypes.html">Supported DNS Resource Record Types</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// <p>You can specify more than one value for all record types except <code>CNAME</code> and <code>SOA</code>. </p> <note>
/// <p>If you're creating an alias resource record set, omit <code>Value</code>.</p>
/// </note>
pub fn value(mut self, input: impl Into<std::string::String>) -> Self {
self.value = Some(input.into());
self
}
/// <p>The current or new DNS record value, not to exceed 4,000 characters. In the case of a <code>DELETE</code> action, if the current value does not match the actual value, an error is returned. For descriptions about how to format <code>Value</code> for different record types, see <a href="https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/ResourceRecordTypes.html">Supported DNS Resource Record Types</a> in the <i>Amazon Route 53 Developer Guide</i>.</p>
/// <p>You can specify more than one value for all record types except <code>CNAME</code> and <code>SOA</code>. </p> <note>
/// <p>If you're creating an alias resource record set, omit <code>Value</code>.</p>
/// </note>
pub fn set_value(mut self, input: std::option::Option<std::string::String>) -> Self {
self.value = input;
self
}
/// Consumes the builder and constructs a [`ResourceRecord`](crate::model::ResourceRecord)
pub fn build(self) -> crate::model::ResourceRecord {
crate::model::ResourceRecord { value: self.value }
}
}
}
impl ResourceRecord {
/// Creates a new builder-style object to manufacture [`ResourceRecord`](crate::model::ResourceRecord)
pub fn builder() -> crate::model::resource_record::Builder {
crate::model::resource_record::Builder::default()
}
}
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum ResourceRecordSetFailover {
#[allow(missing_docs)] // documentation missing in model
Primary,
#[allow(missing_docs)] // documentation missing in model
Secondary,
/// Unknown contains new variants that have been added since this code was generated.
Unknown(String),
}
impl std::convert::From<&str> for ResourceRecordSetFailover {
fn from(s: &str) -> Self {
match s {
"PRIMARY" => ResourceRecordSetFailover::Primary,
"SECONDARY" => ResourceRecordSetFailover::Secondary,
other => ResourceRecordSetFailover::Unknown(other.to_owned()),
}
}
}
impl std::str::FromStr for ResourceRecordSetFailover {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(ResourceRecordSetFailover::from(s))
}
}
impl ResourceRecordSetFailover {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
ResourceRecordSetFailover::Primary => "PRIMARY",
ResourceRecordSetFailover::Secondary => "SECONDARY",
ResourceRecordSetFailover::Unknown(s) => s.as_ref(),
}
}
/// Returns all the `&str` values of the enum members.
pub fn values() -> &'static [&'static str] {
&["PRIMARY", "SECONDARY"]
}
}
impl AsRef<str> for ResourceRecordSetFailover {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>A complex type that contains information about a geographic location.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct GeoLocation {
/// <p>The two-letter code for the continent.</p>
/// <p>Amazon Route 53 supports the following continent codes:</p>
/// <ul>
/// <li> <p> <b>AF</b>: Africa</p> </li>
/// <li> <p> <b>AN</b>: Antarctica</p> </li>
/// <li> <p> <b>AS</b>: Asia</p> </li>
/// <li> <p> <b>EU</b>: Europe</p> </li>
/// <li> <p> <b>OC</b>: Oceania</p> </li>
/// <li> <p> <b>NA</b>: North America</p> </li>
/// <li> <p> <b>SA</b>: South America</p> </li>
/// </ul>
/// <p>Constraint: Specifying <code>ContinentCode</code> with either <code>CountryCode</code> or <code>SubdivisionCode</code> returns an <code>InvalidInput</code> error.</p>
pub continent_code: std::option::Option<std::string::String>,
/// <p>For geolocation resource record sets, the two-letter code for a country.</p>
/// <p>Amazon Route 53 uses the two-letter country codes that are specified in <a href="https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2">ISO standard 3166-1 alpha-2</a>.</p>
pub country_code: std::option::Option<std::string::String>,
/// <p>For geolocation resource record sets, the two-letter code for a state of the United States. Route 53 doesn't support any other values for <code>SubdivisionCode</code>. For a list of state abbreviations, see <a href="https://pe.usps.com/text/pub28/28apb.htm">Appendix B: Two–Letter State and Possession Abbreviations</a> on the United States Postal Service website. </p>
/// <p>If you specify <code>subdivisioncode</code>, you must also specify <code>US</code> for <code>CountryCode</code>. </p>
pub subdivision_code: std::option::Option<std::string::String>,
}
impl GeoLocation {
/// <p>The two-letter code for the continent.</p>
/// <p>Amazon Route 53 supports the following continent codes:</p>
/// <ul>
/// <li> <p> <b>AF</b>: Africa</p> </li>
/// <li> <p> <b>AN</b>: Antarctica</p> </li>
/// <li> <p> <b>AS</b>: Asia</p> </li>
/// <li> <p> <b>EU</b>: Europe</p> </li>
/// <li> <p> <b>OC</b>: Oceania</p> </li>
/// <li> <p> <b>NA</b>: North America</p> </li>
/// <li> <p> <b>SA</b>: South America</p> </li>
/// </ul>
/// <p>Constraint: Specifying <code>ContinentCode</code> with either <code>CountryCode</code> or <code>SubdivisionCode</code> returns an <code>InvalidInput</code> error.</p>
pub fn continent_code(&self) -> std::option::Option<&str> {
self.continent_code.as_deref()
}
/// <p>For geolocation resource record sets, the two-letter code for a country.</p>
/// <p>Amazon Route 53 uses the two-letter country codes that are specified in <a href="https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2">ISO standard 3166-1 alpha-2</a>.</p>
pub fn country_code(&self) -> std::option::Option<&str> {
self.country_code.as_deref()
}
/// <p>For geolocation resource record sets, the two-letter code for a state of the United States. Route 53 doesn't support any other values for <code>SubdivisionCode</code>. For a list of state abbreviations, see <a href="https://pe.usps.com/text/pub28/28apb.htm">Appendix B: Two–Letter State and Possession Abbreviations</a> on the United States Postal Service website. </p>
/// <p>If you specify <code>subdivisioncode</code>, you must also specify <code>US</code> for <code>CountryCode</code>. </p>
pub fn subdivision_code(&self) -> std::option::Option<&str> {
self.subdivision_code.as_deref()
}
}
impl std::fmt::Debug for GeoLocation {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("GeoLocation");
formatter.field("continent_code", &self.continent_code);
formatter.field("country_code", &self.country_code);
formatter.field("subdivision_code", &self.subdivision_code);
formatter.finish()
}
}
/// See [`GeoLocation`](crate::model::GeoLocation)
pub mod geo_location {
/// A builder for [`GeoLocation`](crate::model::GeoLocation)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) continent_code: std::option::Option<std::string::String>,
pub(crate) country_code: std::option::Option<std::string::String>,
pub(crate) subdivision_code: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The two-letter code for the continent.</p>
/// <p>Amazon Route 53 supports the following continent codes:</p>
/// <ul>
/// <li> <p> <b>AF</b>: Africa</p> </li>
/// <li> <p> <b>AN</b>: Antarctica</p> </li>
/// <li> <p> <b>AS</b>: Asia</p> </li>
/// <li> <p> <b>EU</b>: Europe</p> </li>
/// <li> <p> <b>OC</b>: Oceania</p> </li>
/// <li> <p> <b>NA</b>: North America</p> </li>
/// <li> <p> <b>SA</b>: South America</p> </li>
/// </ul>
/// <p>Constraint: Specifying <code>ContinentCode</code> with either <code>CountryCode</code> or <code>SubdivisionCode</code> returns an <code>InvalidInput</code> error.</p>
pub fn continent_code(mut self, input: impl Into<std::string::String>) -> Self {
self.continent_code = Some(input.into());
self
}
/// <p>The two-letter code for the continent.</p>
/// <p>Amazon Route 53 supports the following continent codes:</p>
/// <ul>
/// <li> <p> <b>AF</b>: Africa</p> </li>
/// <li> <p> <b>AN</b>: Antarctica</p> </li>
/// <li> <p> <b>AS</b>: Asia</p> </li>
/// <li> <p> <b>EU</b>: Europe</p> </li>
/// <li> <p> <b>OC</b>: Oceania</p> </li>
/// <li> <p> <b>NA</b>: North America</p> </li>
/// <li> <p> <b>SA</b>: South America</p> </li>
/// </ul>
/// <p>Constraint: Specifying <code>ContinentCode</code> with either <code>CountryCode</code> or <code>SubdivisionCode</code> returns an <code>InvalidInput</code> error.</p>
pub fn set_continent_code(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.continent_code = input;
self
}
/// <p>For geolocation resource record sets, the two-letter code for a country.</p>
/// <p>Amazon Route 53 uses the two-letter country codes that are specified in <a href="https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2">ISO standard 3166-1 alpha-2</a>.</p>
pub fn country_code(mut self, input: impl Into<std::string::String>) -> Self {
self.country_code = Some(input.into());
self
}
/// <p>For geolocation resource record sets, the two-letter code for a country.</p>
/// <p>Amazon Route 53 uses the two-letter country codes that are specified in <a href="https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2">ISO standard 3166-1 alpha-2</a>.</p>
pub fn set_country_code(mut self, input: std::option::Option<std::string::String>) -> Self {
self.country_code = input;
self
}
/// <p>For geolocation resource record sets, the two-letter code for a state of the United States. Route 53 doesn't support any other values for <code>SubdivisionCode</code>. For a list of state abbreviations, see <a href="https://pe.usps.com/text/pub28/28apb.htm">Appendix B: Two–Letter State and Possession Abbreviations</a> on the United States Postal Service website. </p>
/// <p>If you specify <code>subdivisioncode</code>, you must also specify <code>US</code> for <code>CountryCode</code>. </p>
pub fn subdivision_code(mut self, input: impl Into<std::string::String>) -> Self {
self.subdivision_code = Some(input.into());
self
}
/// <p>For geolocation resource record sets, the two-letter code for a state of the United States. Route 53 doesn't support any other values for <code>SubdivisionCode</code>. For a list of state abbreviations, see <a href="https://pe.usps.com/text/pub28/28apb.htm">Appendix B: Two–Letter State and Possession Abbreviations</a> on the United States Postal Service website. </p>
/// <p>If you specify <code>subdivisioncode</code>, you must also specify <code>US</code> for <code>CountryCode</code>. </p>
pub fn set_subdivision_code(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.subdivision_code = input;
self
}
/// Consumes the builder and constructs a [`GeoLocation`](crate::model::GeoLocation)
pub fn build(self) -> crate::model::GeoLocation {
crate::model::GeoLocation {
continent_code: self.continent_code,
country_code: self.country_code,
subdivision_code: self.subdivision_code,
}
}
}
}
impl GeoLocation {
/// Creates a new builder-style object to manufacture [`GeoLocation`](crate::model::GeoLocation)
pub fn builder() -> crate::model::geo_location::Builder {
crate::model::geo_location::Builder::default()
}
}
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum ResourceRecordSetRegion {
#[allow(missing_docs)] // documentation missing in model
AfSouth1,
#[allow(missing_docs)] // documentation missing in model
ApEast1,
#[allow(missing_docs)] // documentation missing in model
ApNortheast1,
#[allow(missing_docs)] // documentation missing in model
ApNortheast2,
#[allow(missing_docs)] // documentation missing in model
ApNortheast3,
#[allow(missing_docs)] // documentation missing in model
ApSouth1,
#[allow(missing_docs)] // documentation missing in model
ApSoutheast1,
#[allow(missing_docs)] // documentation missing in model
ApSoutheast2,
#[allow(missing_docs)] // documentation missing in model
ApSoutheast3,
#[allow(missing_docs)] // documentation missing in model
CaCentral1,
#[allow(missing_docs)] // documentation missing in model
CnNorth1,
#[allow(missing_docs)] // documentation missing in model
CnNorthwest1,
#[allow(missing_docs)] // documentation missing in model
EuCentral1,
#[allow(missing_docs)] // documentation missing in model
EuNorth1,
#[allow(missing_docs)] // documentation missing in model
EuSouth1,
#[allow(missing_docs)] // documentation missing in model
EuWest1,
#[allow(missing_docs)] // documentation missing in model
EuWest2,
#[allow(missing_docs)] // documentation missing in model
EuWest3,
#[allow(missing_docs)] // documentation missing in model
MeSouth1,
#[allow(missing_docs)] // documentation missing in model
SaEast1,
#[allow(missing_docs)] // documentation missing in model
UsEast1,
#[allow(missing_docs)] // documentation missing in model
UsEast2,
#[allow(missing_docs)] // documentation missing in model
UsWest1,
#[allow(missing_docs)] // documentation missing in model
UsWest2,
/// Unknown contains new variants that have been added since this code was generated.
Unknown(String),
}
impl std::convert::From<&str> for ResourceRecordSetRegion {
fn from(s: &str) -> Self {
match s {
"af-south-1" => ResourceRecordSetRegion::AfSouth1,
"ap-east-1" => ResourceRecordSetRegion::ApEast1,
"ap-northeast-1" => ResourceRecordSetRegion::ApNortheast1,
"ap-northeast-2" => ResourceRecordSetRegion::ApNortheast2,
"ap-northeast-3" => ResourceRecordSetRegion::ApNortheast3,
"ap-south-1" => ResourceRecordSetRegion::ApSouth1,
"ap-southeast-1" => ResourceRecordSetRegion::ApSoutheast1,
"ap-southeast-2" => ResourceRecordSetRegion::ApSoutheast2,
"ap-southeast-3" => ResourceRecordSetRegion::ApSoutheast3,
"ca-central-1" => ResourceRecordSetRegion::CaCentral1,
"cn-north-1" => ResourceRecordSetRegion::CnNorth1,
"cn-northwest-1" => ResourceRecordSetRegion::CnNorthwest1,
"eu-central-1" => ResourceRecordSetRegion::EuCentral1,
"eu-north-1" => ResourceRecordSetRegion::EuNorth1,
"eu-south-1" => ResourceRecordSetRegion::EuSouth1,
"eu-west-1" => ResourceRecordSetRegion::EuWest1,
"eu-west-2" => ResourceRecordSetRegion::EuWest2,
"eu-west-3" => ResourceRecordSetRegion::EuWest3,
"me-south-1" => ResourceRecordSetRegion::MeSouth1,
"sa-east-1" => ResourceRecordSetRegion::SaEast1,
"us-east-1" => ResourceRecordSetRegion::UsEast1,
"us-east-2" => ResourceRecordSetRegion::UsEast2,
"us-west-1" => ResourceRecordSetRegion::UsWest1,
"us-west-2" => ResourceRecordSetRegion::UsWest2,
other => ResourceRecordSetRegion::Unknown(other.to_owned()),
}
}
}
impl std::str::FromStr for ResourceRecordSetRegion {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(ResourceRecordSetRegion::from(s))
}
}
impl ResourceRecordSetRegion {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
ResourceRecordSetRegion::AfSouth1 => "af-south-1",
ResourceRecordSetRegion::ApEast1 => "ap-east-1",
ResourceRecordSetRegion::ApNortheast1 => "ap-northeast-1",
ResourceRecordSetRegion::ApNortheast2 => "ap-northeast-2",
ResourceRecordSetRegion::ApNortheast3 => "ap-northeast-3",
ResourceRecordSetRegion::ApSouth1 => "ap-south-1",
ResourceRecordSetRegion::ApSoutheast1 => "ap-southeast-1",
ResourceRecordSetRegion::ApSoutheast2 => "ap-southeast-2",
ResourceRecordSetRegion::ApSoutheast3 => "ap-southeast-3",
ResourceRecordSetRegion::CaCentral1 => "ca-central-1",
ResourceRecordSetRegion::CnNorth1 => "cn-north-1",
ResourceRecordSetRegion::CnNorthwest1 => "cn-northwest-1",
ResourceRecordSetRegion::EuCentral1 => "eu-central-1",
ResourceRecordSetRegion::EuNorth1 => "eu-north-1",
ResourceRecordSetRegion::EuSouth1 => "eu-south-1",
ResourceRecordSetRegion::EuWest1 => "eu-west-1",
ResourceRecordSetRegion::EuWest2 => "eu-west-2",
ResourceRecordSetRegion::EuWest3 => "eu-west-3",
ResourceRecordSetRegion::MeSouth1 => "me-south-1",
ResourceRecordSetRegion::SaEast1 => "sa-east-1",
ResourceRecordSetRegion::UsEast1 => "us-east-1",
ResourceRecordSetRegion::UsEast2 => "us-east-2",
ResourceRecordSetRegion::UsWest1 => "us-west-1",
ResourceRecordSetRegion::UsWest2 => "us-west-2",
ResourceRecordSetRegion::Unknown(s) => s.as_ref(),
}
}
/// Returns all the `&str` values of the enum members.
pub fn values() -> &'static [&'static str] {
&[
"af-south-1",
"ap-east-1",
"ap-northeast-1",
"ap-northeast-2",
"ap-northeast-3",
"ap-south-1",
"ap-southeast-1",
"ap-southeast-2",
"ap-southeast-3",
"ca-central-1",
"cn-north-1",
"cn-northwest-1",
"eu-central-1",
"eu-north-1",
"eu-south-1",
"eu-west-1",
"eu-west-2",
"eu-west-3",
"me-south-1",
"sa-east-1",
"us-east-1",
"us-east-2",
"us-west-1",
"us-west-2",
]
}
}
impl AsRef<str> for ResourceRecordSetRegion {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>A complex type that contains information about a configuration for DNS query logging.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct QueryLoggingConfig {
/// <p>The ID for a configuration for DNS query logging.</p>
pub id: std::option::Option<std::string::String>,
/// <p>The ID of the hosted zone that CloudWatch Logs is logging queries for. </p>
pub hosted_zone_id: std::option::Option<std::string::String>,
/// <p>The Amazon Resource Name (ARN) of the CloudWatch Logs log group that Amazon Route 53 is publishing logs to.</p>
pub cloud_watch_logs_log_group_arn: std::option::Option<std::string::String>,
}
impl QueryLoggingConfig {
/// <p>The ID for a configuration for DNS query logging.</p>
pub fn id(&self) -> std::option::Option<&str> {
self.id.as_deref()
}
/// <p>The ID of the hosted zone that CloudWatch Logs is logging queries for. </p>
pub fn hosted_zone_id(&self) -> std::option::Option<&str> {
self.hosted_zone_id.as_deref()
}
/// <p>The Amazon Resource Name (ARN) of the CloudWatch Logs log group that Amazon Route 53 is publishing logs to.</p>
pub fn cloud_watch_logs_log_group_arn(&self) -> std::option::Option<&str> {
self.cloud_watch_logs_log_group_arn.as_deref()
}
}
impl std::fmt::Debug for QueryLoggingConfig {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("QueryLoggingConfig");
formatter.field("id", &self.id);
formatter.field("hosted_zone_id", &self.hosted_zone_id);
formatter.field(
"cloud_watch_logs_log_group_arn",
&self.cloud_watch_logs_log_group_arn,
);
formatter.finish()
}
}
/// See [`QueryLoggingConfig`](crate::model::QueryLoggingConfig)
pub mod query_logging_config {
/// A builder for [`QueryLoggingConfig`](crate::model::QueryLoggingConfig)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) id: std::option::Option<std::string::String>,
pub(crate) hosted_zone_id: std::option::Option<std::string::String>,
pub(crate) cloud_watch_logs_log_group_arn: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The ID for a configuration for DNS query logging.</p>
pub fn id(mut self, input: impl Into<std::string::String>) -> Self {
self.id = Some(input.into());
self
}
/// <p>The ID for a configuration for DNS query logging.</p>
pub fn set_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.id = input;
self
}
/// <p>The ID of the hosted zone that CloudWatch Logs is logging queries for. </p>
pub fn hosted_zone_id(mut self, input: impl Into<std::string::String>) -> Self {
self.hosted_zone_id = Some(input.into());
self
}
/// <p>The ID of the hosted zone that CloudWatch Logs is logging queries for. </p>
pub fn set_hosted_zone_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.hosted_zone_id = input;
self
}
/// <p>The Amazon Resource Name (ARN) of the CloudWatch Logs log group that Amazon Route 53 is publishing logs to.</p>
pub fn cloud_watch_logs_log_group_arn(
mut self,
input: impl Into<std::string::String>,
) -> Self {
self.cloud_watch_logs_log_group_arn = Some(input.into());
self
}
/// <p>The Amazon Resource Name (ARN) of the CloudWatch Logs log group that Amazon Route 53 is publishing logs to.</p>
pub fn set_cloud_watch_logs_log_group_arn(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.cloud_watch_logs_log_group_arn = input;
self
}
/// Consumes the builder and constructs a [`QueryLoggingConfig`](crate::model::QueryLoggingConfig)
pub fn build(self) -> crate::model::QueryLoggingConfig {
crate::model::QueryLoggingConfig {
id: self.id,
hosted_zone_id: self.hosted_zone_id,
cloud_watch_logs_log_group_arn: self.cloud_watch_logs_log_group_arn,
}
}
}
}
impl QueryLoggingConfig {
/// Creates a new builder-style object to manufacture [`QueryLoggingConfig`](crate::model::QueryLoggingConfig)
pub fn builder() -> crate::model::query_logging_config::Builder {
crate::model::query_logging_config::Builder::default()
}
}
/// <p>In the response to a <code>ListHostedZonesByVPC</code> request, the <code>HostedZoneSummaries</code> element contains one <code>HostedZoneSummary</code> element for each hosted zone that the specified Amazon VPC is associated with. Each <code>HostedZoneSummary</code> element contains the hosted zone name and ID, and information about who owns the hosted zone.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct HostedZoneSummary {
/// <p>The Route 53 hosted zone ID of a private hosted zone that the specified VPC is associated with.</p>
pub hosted_zone_id: std::option::Option<std::string::String>,
/// <p>The name of the private hosted zone, such as <code>example.com</code>.</p>
pub name: std::option::Option<std::string::String>,
/// <p>The owner of a private hosted zone that the specified VPC is associated with. The owner can be either an Amazon Web Services account or an Amazon Web Services service.</p>
pub owner: std::option::Option<crate::model::HostedZoneOwner>,
}
impl HostedZoneSummary {
/// <p>The Route 53 hosted zone ID of a private hosted zone that the specified VPC is associated with.</p>
pub fn hosted_zone_id(&self) -> std::option::Option<&str> {
self.hosted_zone_id.as_deref()
}
/// <p>The name of the private hosted zone, such as <code>example.com</code>.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>The owner of a private hosted zone that the specified VPC is associated with. The owner can be either an Amazon Web Services account or an Amazon Web Services service.</p>
pub fn owner(&self) -> std::option::Option<&crate::model::HostedZoneOwner> {
self.owner.as_ref()
}
}
impl std::fmt::Debug for HostedZoneSummary {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("HostedZoneSummary");
formatter.field("hosted_zone_id", &self.hosted_zone_id);
formatter.field("name", &self.name);
formatter.field("owner", &self.owner);
formatter.finish()
}
}
/// See [`HostedZoneSummary`](crate::model::HostedZoneSummary)
pub mod hosted_zone_summary {
/// A builder for [`HostedZoneSummary`](crate::model::HostedZoneSummary)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) hosted_zone_id: std::option::Option<std::string::String>,
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) owner: std::option::Option<crate::model::HostedZoneOwner>,
}
impl Builder {
/// <p>The Route 53 hosted zone ID of a private hosted zone that the specified VPC is associated with.</p>
pub fn hosted_zone_id(mut self, input: impl Into<std::string::String>) -> Self {
self.hosted_zone_id = Some(input.into());
self
}
/// <p>The Route 53 hosted zone ID of a private hosted zone that the specified VPC is associated with.</p>
pub fn set_hosted_zone_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.hosted_zone_id = input;
self
}
/// <p>The name of the private hosted zone, such as <code>example.com</code>.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The name of the private hosted zone, such as <code>example.com</code>.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// <p>The owner of a private hosted zone that the specified VPC is associated with. The owner can be either an Amazon Web Services account or an Amazon Web Services service.</p>
pub fn owner(mut self, input: crate::model::HostedZoneOwner) -> Self {
self.owner = Some(input);
self
}
/// <p>The owner of a private hosted zone that the specified VPC is associated with. The owner can be either an Amazon Web Services account or an Amazon Web Services service.</p>
pub fn set_owner(
mut self,
input: std::option::Option<crate::model::HostedZoneOwner>,
) -> Self {
self.owner = input;
self
}
/// Consumes the builder and constructs a [`HostedZoneSummary`](crate::model::HostedZoneSummary)
pub fn build(self) -> crate::model::HostedZoneSummary {
crate::model::HostedZoneSummary {
hosted_zone_id: self.hosted_zone_id,
name: self.name,
owner: self.owner,
}
}
}
}
impl HostedZoneSummary {
/// Creates a new builder-style object to manufacture [`HostedZoneSummary`](crate::model::HostedZoneSummary)
pub fn builder() -> crate::model::hosted_zone_summary::Builder {
crate::model::hosted_zone_summary::Builder::default()
}
}
/// <p>A complex type that identifies a hosted zone that a specified Amazon VPC is associated with and the owner of the hosted zone. If there is a value for <code>OwningAccount</code>, there is no value for <code>OwningService</code>, and vice versa. </p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct HostedZoneOwner {
/// <p>If the hosted zone was created by an Amazon Web Services account, or was created by an Amazon Web Services service that creates hosted zones using the current account, <code>OwningAccount</code> contains the account ID of that account. For example, when you use Cloud Map to create a hosted zone, Cloud Map creates the hosted zone using the current Amazon Web Services account. </p>
pub owning_account: std::option::Option<std::string::String>,
/// <p>If an Amazon Web Services service uses its own account to create a hosted zone and associate the specified VPC with that hosted zone, <code>OwningService</code> contains an abbreviation that identifies the service. For example, if Amazon Elastic File System (Amazon EFS) created a hosted zone and associated a VPC with the hosted zone, the value of <code>OwningService</code> is <code>efs.amazonaws.com</code>.</p>
pub owning_service: std::option::Option<std::string::String>,
}
impl HostedZoneOwner {
/// <p>If the hosted zone was created by an Amazon Web Services account, or was created by an Amazon Web Services service that creates hosted zones using the current account, <code>OwningAccount</code> contains the account ID of that account. For example, when you use Cloud Map to create a hosted zone, Cloud Map creates the hosted zone using the current Amazon Web Services account. </p>
pub fn owning_account(&self) -> std::option::Option<&str> {
self.owning_account.as_deref()
}
/// <p>If an Amazon Web Services service uses its own account to create a hosted zone and associate the specified VPC with that hosted zone, <code>OwningService</code> contains an abbreviation that identifies the service. For example, if Amazon Elastic File System (Amazon EFS) created a hosted zone and associated a VPC with the hosted zone, the value of <code>OwningService</code> is <code>efs.amazonaws.com</code>.</p>
pub fn owning_service(&self) -> std::option::Option<&str> {
self.owning_service.as_deref()
}
}
impl std::fmt::Debug for HostedZoneOwner {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("HostedZoneOwner");
formatter.field("owning_account", &self.owning_account);
formatter.field("owning_service", &self.owning_service);
formatter.finish()
}
}
/// See [`HostedZoneOwner`](crate::model::HostedZoneOwner)
pub mod hosted_zone_owner {
/// A builder for [`HostedZoneOwner`](crate::model::HostedZoneOwner)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) owning_account: std::option::Option<std::string::String>,
pub(crate) owning_service: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>If the hosted zone was created by an Amazon Web Services account, or was created by an Amazon Web Services service that creates hosted zones using the current account, <code>OwningAccount</code> contains the account ID of that account. For example, when you use Cloud Map to create a hosted zone, Cloud Map creates the hosted zone using the current Amazon Web Services account. </p>
pub fn owning_account(mut self, input: impl Into<std::string::String>) -> Self {
self.owning_account = Some(input.into());
self
}
/// <p>If the hosted zone was created by an Amazon Web Services account, or was created by an Amazon Web Services service that creates hosted zones using the current account, <code>OwningAccount</code> contains the account ID of that account. For example, when you use Cloud Map to create a hosted zone, Cloud Map creates the hosted zone using the current Amazon Web Services account. </p>
pub fn set_owning_account(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.owning_account = input;
self
}
/// <p>If an Amazon Web Services service uses its own account to create a hosted zone and associate the specified VPC with that hosted zone, <code>OwningService</code> contains an abbreviation that identifies the service. For example, if Amazon Elastic File System (Amazon EFS) created a hosted zone and associated a VPC with the hosted zone, the value of <code>OwningService</code> is <code>efs.amazonaws.com</code>.</p>
pub fn owning_service(mut self, input: impl Into<std::string::String>) -> Self {
self.owning_service = Some(input.into());
self
}
/// <p>If an Amazon Web Services service uses its own account to create a hosted zone and associate the specified VPC with that hosted zone, <code>OwningService</code> contains an abbreviation that identifies the service. For example, if Amazon Elastic File System (Amazon EFS) created a hosted zone and associated a VPC with the hosted zone, the value of <code>OwningService</code> is <code>efs.amazonaws.com</code>.</p>
pub fn set_owning_service(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.owning_service = input;
self
}
/// Consumes the builder and constructs a [`HostedZoneOwner`](crate::model::HostedZoneOwner)
pub fn build(self) -> crate::model::HostedZoneOwner {
crate::model::HostedZoneOwner {
owning_account: self.owning_account,
owning_service: self.owning_service,
}
}
}
}
impl HostedZoneOwner {
/// Creates a new builder-style object to manufacture [`HostedZoneOwner`](crate::model::HostedZoneOwner)
pub fn builder() -> crate::model::hosted_zone_owner::Builder {
crate::model::hosted_zone_owner::Builder::default()
}
}
/// <p>A complex type that contains the codes and full continent, country, and subdivision names for the specified <code>geolocation</code> code.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct GeoLocationDetails {
/// <p>The two-letter code for the continent.</p>
pub continent_code: std::option::Option<std::string::String>,
/// <p>The full name of the continent.</p>
pub continent_name: std::option::Option<std::string::String>,
/// <p>The two-letter code for the country.</p>
pub country_code: std::option::Option<std::string::String>,
/// <p>The name of the country.</p>
pub country_name: std::option::Option<std::string::String>,
/// <p>The code for the subdivision, such as a particular state within the United States. For a list of US state abbreviations, see <a href="https://pe.usps.com/text/pub28/28apb.htm">Appendix B: Two–Letter State and Possession Abbreviations</a> on the United States Postal Service website. For a list of all supported subdivision codes, use the <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_ListGeoLocations.html">ListGeoLocations</a> API.</p>
pub subdivision_code: std::option::Option<std::string::String>,
/// <p>The full name of the subdivision. Route 53 currently supports only states in the United States.</p>
pub subdivision_name: std::option::Option<std::string::String>,
}
impl GeoLocationDetails {
/// <p>The two-letter code for the continent.</p>
pub fn continent_code(&self) -> std::option::Option<&str> {
self.continent_code.as_deref()
}
/// <p>The full name of the continent.</p>
pub fn continent_name(&self) -> std::option::Option<&str> {
self.continent_name.as_deref()
}
/// <p>The two-letter code for the country.</p>
pub fn country_code(&self) -> std::option::Option<&str> {
self.country_code.as_deref()
}
/// <p>The name of the country.</p>
pub fn country_name(&self) -> std::option::Option<&str> {
self.country_name.as_deref()
}
/// <p>The code for the subdivision, such as a particular state within the United States. For a list of US state abbreviations, see <a href="https://pe.usps.com/text/pub28/28apb.htm">Appendix B: Two–Letter State and Possession Abbreviations</a> on the United States Postal Service website. For a list of all supported subdivision codes, use the <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_ListGeoLocations.html">ListGeoLocations</a> API.</p>
pub fn subdivision_code(&self) -> std::option::Option<&str> {
self.subdivision_code.as_deref()
}
/// <p>The full name of the subdivision. Route 53 currently supports only states in the United States.</p>
pub fn subdivision_name(&self) -> std::option::Option<&str> {
self.subdivision_name.as_deref()
}
}
impl std::fmt::Debug for GeoLocationDetails {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("GeoLocationDetails");
formatter.field("continent_code", &self.continent_code);
formatter.field("continent_name", &self.continent_name);
formatter.field("country_code", &self.country_code);
formatter.field("country_name", &self.country_name);
formatter.field("subdivision_code", &self.subdivision_code);
formatter.field("subdivision_name", &self.subdivision_name);
formatter.finish()
}
}
/// See [`GeoLocationDetails`](crate::model::GeoLocationDetails)
pub mod geo_location_details {
/// A builder for [`GeoLocationDetails`](crate::model::GeoLocationDetails)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) continent_code: std::option::Option<std::string::String>,
pub(crate) continent_name: std::option::Option<std::string::String>,
pub(crate) country_code: std::option::Option<std::string::String>,
pub(crate) country_name: std::option::Option<std::string::String>,
pub(crate) subdivision_code: std::option::Option<std::string::String>,
pub(crate) subdivision_name: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The two-letter code for the continent.</p>
pub fn continent_code(mut self, input: impl Into<std::string::String>) -> Self {
self.continent_code = Some(input.into());
self
}
/// <p>The two-letter code for the continent.</p>
pub fn set_continent_code(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.continent_code = input;
self
}
/// <p>The full name of the continent.</p>
pub fn continent_name(mut self, input: impl Into<std::string::String>) -> Self {
self.continent_name = Some(input.into());
self
}
/// <p>The full name of the continent.</p>
pub fn set_continent_name(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.continent_name = input;
self
}
/// <p>The two-letter code for the country.</p>
pub fn country_code(mut self, input: impl Into<std::string::String>) -> Self {
self.country_code = Some(input.into());
self
}
/// <p>The two-letter code for the country.</p>
pub fn set_country_code(mut self, input: std::option::Option<std::string::String>) -> Self {
self.country_code = input;
self
}
/// <p>The name of the country.</p>
pub fn country_name(mut self, input: impl Into<std::string::String>) -> Self {
self.country_name = Some(input.into());
self
}
/// <p>The name of the country.</p>
pub fn set_country_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.country_name = input;
self
}
/// <p>The code for the subdivision, such as a particular state within the United States. For a list of US state abbreviations, see <a href="https://pe.usps.com/text/pub28/28apb.htm">Appendix B: Two–Letter State and Possession Abbreviations</a> on the United States Postal Service website. For a list of all supported subdivision codes, use the <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_ListGeoLocations.html">ListGeoLocations</a> API.</p>
pub fn subdivision_code(mut self, input: impl Into<std::string::String>) -> Self {
self.subdivision_code = Some(input.into());
self
}
/// <p>The code for the subdivision, such as a particular state within the United States. For a list of US state abbreviations, see <a href="https://pe.usps.com/text/pub28/28apb.htm">Appendix B: Two–Letter State and Possession Abbreviations</a> on the United States Postal Service website. For a list of all supported subdivision codes, use the <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_ListGeoLocations.html">ListGeoLocations</a> API.</p>
pub fn set_subdivision_code(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.subdivision_code = input;
self
}
/// <p>The full name of the subdivision. Route 53 currently supports only states in the United States.</p>
pub fn subdivision_name(mut self, input: impl Into<std::string::String>) -> Self {
self.subdivision_name = Some(input.into());
self
}
/// <p>The full name of the subdivision. Route 53 currently supports only states in the United States.</p>
pub fn set_subdivision_name(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.subdivision_name = input;
self
}
/// Consumes the builder and constructs a [`GeoLocationDetails`](crate::model::GeoLocationDetails)
pub fn build(self) -> crate::model::GeoLocationDetails {
crate::model::GeoLocationDetails {
continent_code: self.continent_code,
continent_name: self.continent_name,
country_code: self.country_code,
country_name: self.country_name,
subdivision_code: self.subdivision_code,
subdivision_name: self.subdivision_name,
}
}
}
}
impl GeoLocationDetails {
/// Creates a new builder-style object to manufacture [`GeoLocationDetails`](crate::model::GeoLocationDetails)
pub fn builder() -> crate::model::geo_location_details::Builder {
crate::model::geo_location_details::Builder::default()
}
}
/// <p>A complex type that contains the type of limit that you specified in the request and the current value for that limit.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct ReusableDelegationSetLimit {
/// <p>The limit that you requested: <code>MAX_ZONES_BY_REUSABLE_DELEGATION_SET</code>, the maximum number of hosted zones that you can associate with the specified reusable delegation set.</p>
pub r#type: std::option::Option<crate::model::ReusableDelegationSetLimitType>,
/// <p>The current value for the <code>MAX_ZONES_BY_REUSABLE_DELEGATION_SET</code> limit.</p>
pub value: i64,
}
impl ReusableDelegationSetLimit {
/// <p>The limit that you requested: <code>MAX_ZONES_BY_REUSABLE_DELEGATION_SET</code>, the maximum number of hosted zones that you can associate with the specified reusable delegation set.</p>
pub fn r#type(&self) -> std::option::Option<&crate::model::ReusableDelegationSetLimitType> {
self.r#type.as_ref()
}
/// <p>The current value for the <code>MAX_ZONES_BY_REUSABLE_DELEGATION_SET</code> limit.</p>
pub fn value(&self) -> i64 {
self.value
}
}
impl std::fmt::Debug for ReusableDelegationSetLimit {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("ReusableDelegationSetLimit");
formatter.field("r#type", &self.r#type);
formatter.field("value", &self.value);
formatter.finish()
}
}
/// See [`ReusableDelegationSetLimit`](crate::model::ReusableDelegationSetLimit)
pub mod reusable_delegation_set_limit {
/// A builder for [`ReusableDelegationSetLimit`](crate::model::ReusableDelegationSetLimit)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) r#type: std::option::Option<crate::model::ReusableDelegationSetLimitType>,
pub(crate) value: std::option::Option<i64>,
}
impl Builder {
/// <p>The limit that you requested: <code>MAX_ZONES_BY_REUSABLE_DELEGATION_SET</code>, the maximum number of hosted zones that you can associate with the specified reusable delegation set.</p>
pub fn r#type(mut self, input: crate::model::ReusableDelegationSetLimitType) -> Self {
self.r#type = Some(input);
self
}
/// <p>The limit that you requested: <code>MAX_ZONES_BY_REUSABLE_DELEGATION_SET</code>, the maximum number of hosted zones that you can associate with the specified reusable delegation set.</p>
pub fn set_type(
mut self,
input: std::option::Option<crate::model::ReusableDelegationSetLimitType>,
) -> Self {
self.r#type = input;
self
}
/// <p>The current value for the <code>MAX_ZONES_BY_REUSABLE_DELEGATION_SET</code> limit.</p>
pub fn value(mut self, input: i64) -> Self {
self.value = Some(input);
self
}
/// <p>The current value for the <code>MAX_ZONES_BY_REUSABLE_DELEGATION_SET</code> limit.</p>
pub fn set_value(mut self, input: std::option::Option<i64>) -> Self {
self.value = input;
self
}
/// Consumes the builder and constructs a [`ReusableDelegationSetLimit`](crate::model::ReusableDelegationSetLimit)
pub fn build(self) -> crate::model::ReusableDelegationSetLimit {
crate::model::ReusableDelegationSetLimit {
r#type: self.r#type,
value: self.value.unwrap_or_default(),
}
}
}
}
impl ReusableDelegationSetLimit {
/// Creates a new builder-style object to manufacture [`ReusableDelegationSetLimit`](crate::model::ReusableDelegationSetLimit)
pub fn builder() -> crate::model::reusable_delegation_set_limit::Builder {
crate::model::reusable_delegation_set_limit::Builder::default()
}
}
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum ReusableDelegationSetLimitType {
#[allow(missing_docs)] // documentation missing in model
MaxZonesByReusableDelegationSet,
/// Unknown contains new variants that have been added since this code was generated.
Unknown(String),
}
impl std::convert::From<&str> for ReusableDelegationSetLimitType {
fn from(s: &str) -> Self {
match s {
"MAX_ZONES_BY_REUSABLE_DELEGATION_SET" => {
ReusableDelegationSetLimitType::MaxZonesByReusableDelegationSet
}
other => ReusableDelegationSetLimitType::Unknown(other.to_owned()),
}
}
}
impl std::str::FromStr for ReusableDelegationSetLimitType {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(ReusableDelegationSetLimitType::from(s))
}
}
impl ReusableDelegationSetLimitType {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
ReusableDelegationSetLimitType::MaxZonesByReusableDelegationSet => {
"MAX_ZONES_BY_REUSABLE_DELEGATION_SET"
}
ReusableDelegationSetLimitType::Unknown(s) => s.as_ref(),
}
}
/// Returns all the `&str` values of the enum members.
pub fn values() -> &'static [&'static str] {
&["MAX_ZONES_BY_REUSABLE_DELEGATION_SET"]
}
}
impl AsRef<str> for ReusableDelegationSetLimitType {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>A complex type that contains the type of limit that you specified in the request and the current value for that limit.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct HostedZoneLimit {
/// <p>The limit that you requested. Valid values include the following:</p>
/// <ul>
/// <li> <p> <b>MAX_RRSETS_BY_ZONE</b>: The maximum number of records that you can create in the specified hosted zone.</p> </li>
/// <li> <p> <b>MAX_VPCS_ASSOCIATED_BY_ZONE</b>: The maximum number of Amazon VPCs that you can associate with the specified private hosted zone.</p> </li>
/// </ul>
pub r#type: std::option::Option<crate::model::HostedZoneLimitType>,
/// <p>The current value for the limit that is specified by <code>Type</code>.</p>
pub value: i64,
}
impl HostedZoneLimit {
/// <p>The limit that you requested. Valid values include the following:</p>
/// <ul>
/// <li> <p> <b>MAX_RRSETS_BY_ZONE</b>: The maximum number of records that you can create in the specified hosted zone.</p> </li>
/// <li> <p> <b>MAX_VPCS_ASSOCIATED_BY_ZONE</b>: The maximum number of Amazon VPCs that you can associate with the specified private hosted zone.</p> </li>
/// </ul>
pub fn r#type(&self) -> std::option::Option<&crate::model::HostedZoneLimitType> {
self.r#type.as_ref()
}
/// <p>The current value for the limit that is specified by <code>Type</code>.</p>
pub fn value(&self) -> i64 {
self.value
}
}
impl std::fmt::Debug for HostedZoneLimit {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("HostedZoneLimit");
formatter.field("r#type", &self.r#type);
formatter.field("value", &self.value);
formatter.finish()
}
}
/// See [`HostedZoneLimit`](crate::model::HostedZoneLimit)
pub mod hosted_zone_limit {
/// A builder for [`HostedZoneLimit`](crate::model::HostedZoneLimit)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) r#type: std::option::Option<crate::model::HostedZoneLimitType>,
pub(crate) value: std::option::Option<i64>,
}
impl Builder {
/// <p>The limit that you requested. Valid values include the following:</p>
/// <ul>
/// <li> <p> <b>MAX_RRSETS_BY_ZONE</b>: The maximum number of records that you can create in the specified hosted zone.</p> </li>
/// <li> <p> <b>MAX_VPCS_ASSOCIATED_BY_ZONE</b>: The maximum number of Amazon VPCs that you can associate with the specified private hosted zone.</p> </li>
/// </ul>
pub fn r#type(mut self, input: crate::model::HostedZoneLimitType) -> Self {
self.r#type = Some(input);
self
}
/// <p>The limit that you requested. Valid values include the following:</p>
/// <ul>
/// <li> <p> <b>MAX_RRSETS_BY_ZONE</b>: The maximum number of records that you can create in the specified hosted zone.</p> </li>
/// <li> <p> <b>MAX_VPCS_ASSOCIATED_BY_ZONE</b>: The maximum number of Amazon VPCs that you can associate with the specified private hosted zone.</p> </li>
/// </ul>
pub fn set_type(
mut self,
input: std::option::Option<crate::model::HostedZoneLimitType>,
) -> Self {
self.r#type = input;
self
}
/// <p>The current value for the limit that is specified by <code>Type</code>.</p>
pub fn value(mut self, input: i64) -> Self {
self.value = Some(input);
self
}
/// <p>The current value for the limit that is specified by <code>Type</code>.</p>
pub fn set_value(mut self, input: std::option::Option<i64>) -> Self {
self.value = input;
self
}
/// Consumes the builder and constructs a [`HostedZoneLimit`](crate::model::HostedZoneLimit)
pub fn build(self) -> crate::model::HostedZoneLimit {
crate::model::HostedZoneLimit {
r#type: self.r#type,
value: self.value.unwrap_or_default(),
}
}
}
}
impl HostedZoneLimit {
/// Creates a new builder-style object to manufacture [`HostedZoneLimit`](crate::model::HostedZoneLimit)
pub fn builder() -> crate::model::hosted_zone_limit::Builder {
crate::model::hosted_zone_limit::Builder::default()
}
}
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum HostedZoneLimitType {
#[allow(missing_docs)] // documentation missing in model
MaxRrsetsByZone,
#[allow(missing_docs)] // documentation missing in model
MaxVpcsAssociatedByZone,
/// Unknown contains new variants that have been added since this code was generated.
Unknown(String),
}
impl std::convert::From<&str> for HostedZoneLimitType {
fn from(s: &str) -> Self {
match s {
"MAX_RRSETS_BY_ZONE" => HostedZoneLimitType::MaxRrsetsByZone,
"MAX_VPCS_ASSOCIATED_BY_ZONE" => HostedZoneLimitType::MaxVpcsAssociatedByZone,
other => HostedZoneLimitType::Unknown(other.to_owned()),
}
}
}
impl std::str::FromStr for HostedZoneLimitType {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(HostedZoneLimitType::from(s))
}
}
impl HostedZoneLimitType {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
HostedZoneLimitType::MaxRrsetsByZone => "MAX_RRSETS_BY_ZONE",
HostedZoneLimitType::MaxVpcsAssociatedByZone => "MAX_VPCS_ASSOCIATED_BY_ZONE",
HostedZoneLimitType::Unknown(s) => s.as_ref(),
}
}
/// Returns all the `&str` values of the enum members.
pub fn values() -> &'static [&'static str] {
&["MAX_RRSETS_BY_ZONE", "MAX_VPCS_ASSOCIATED_BY_ZONE"]
}
}
impl AsRef<str> for HostedZoneLimitType {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>A complex type that contains the last failure reason as reported by one Amazon Route 53 health checker.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct HealthCheckObservation {
/// <p>The region of the Amazon Route 53 health checker that provided the status in <code>StatusReport</code>.</p>
pub region: std::option::Option<crate::model::HealthCheckRegion>,
/// <p>The IP address of the Amazon Route 53 health checker that provided the failure reason in <code>StatusReport</code>.</p>
pub ip_address: std::option::Option<std::string::String>,
/// <p>A complex type that contains the last failure reason as reported by one Amazon Route 53 health checker and the time of the failed health check.</p>
pub status_report: std::option::Option<crate::model::StatusReport>,
}
impl HealthCheckObservation {
/// <p>The region of the Amazon Route 53 health checker that provided the status in <code>StatusReport</code>.</p>
pub fn region(&self) -> std::option::Option<&crate::model::HealthCheckRegion> {
self.region.as_ref()
}
/// <p>The IP address of the Amazon Route 53 health checker that provided the failure reason in <code>StatusReport</code>.</p>
pub fn ip_address(&self) -> std::option::Option<&str> {
self.ip_address.as_deref()
}
/// <p>A complex type that contains the last failure reason as reported by one Amazon Route 53 health checker and the time of the failed health check.</p>
pub fn status_report(&self) -> std::option::Option<&crate::model::StatusReport> {
self.status_report.as_ref()
}
}
impl std::fmt::Debug for HealthCheckObservation {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("HealthCheckObservation");
formatter.field("region", &self.region);
formatter.field("ip_address", &self.ip_address);
formatter.field("status_report", &self.status_report);
formatter.finish()
}
}
/// See [`HealthCheckObservation`](crate::model::HealthCheckObservation)
pub mod health_check_observation {
/// A builder for [`HealthCheckObservation`](crate::model::HealthCheckObservation)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) region: std::option::Option<crate::model::HealthCheckRegion>,
pub(crate) ip_address: std::option::Option<std::string::String>,
pub(crate) status_report: std::option::Option<crate::model::StatusReport>,
}
impl Builder {
/// <p>The region of the Amazon Route 53 health checker that provided the status in <code>StatusReport</code>.</p>
pub fn region(mut self, input: crate::model::HealthCheckRegion) -> Self {
self.region = Some(input);
self
}
/// <p>The region of the Amazon Route 53 health checker that provided the status in <code>StatusReport</code>.</p>
pub fn set_region(
mut self,
input: std::option::Option<crate::model::HealthCheckRegion>,
) -> Self {
self.region = input;
self
}
/// <p>The IP address of the Amazon Route 53 health checker that provided the failure reason in <code>StatusReport</code>.</p>
pub fn ip_address(mut self, input: impl Into<std::string::String>) -> Self {
self.ip_address = Some(input.into());
self
}
/// <p>The IP address of the Amazon Route 53 health checker that provided the failure reason in <code>StatusReport</code>.</p>
pub fn set_ip_address(mut self, input: std::option::Option<std::string::String>) -> Self {
self.ip_address = input;
self
}
/// <p>A complex type that contains the last failure reason as reported by one Amazon Route 53 health checker and the time of the failed health check.</p>
pub fn status_report(mut self, input: crate::model::StatusReport) -> Self {
self.status_report = Some(input);
self
}
/// <p>A complex type that contains the last failure reason as reported by one Amazon Route 53 health checker and the time of the failed health check.</p>
pub fn set_status_report(
mut self,
input: std::option::Option<crate::model::StatusReport>,
) -> Self {
self.status_report = input;
self
}
/// Consumes the builder and constructs a [`HealthCheckObservation`](crate::model::HealthCheckObservation)
pub fn build(self) -> crate::model::HealthCheckObservation {
crate::model::HealthCheckObservation {
region: self.region,
ip_address: self.ip_address,
status_report: self.status_report,
}
}
}
}
impl HealthCheckObservation {
/// Creates a new builder-style object to manufacture [`HealthCheckObservation`](crate::model::HealthCheckObservation)
pub fn builder() -> crate::model::health_check_observation::Builder {
crate::model::health_check_observation::Builder::default()
}
}
/// <p>A complex type that contains the status that one Amazon Route 53 health checker reports and the time of the health check.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct StatusReport {
/// <p>A description of the status of the health check endpoint as reported by one of the Amazon Route 53 health checkers.</p>
pub status: std::option::Option<std::string::String>,
/// <p>The date and time that the health checker performed the health check in <a href="https://en.wikipedia.org/wiki/ISO_8601">ISO 8601 format</a> and Coordinated Universal Time (UTC). For example, the value <code>2017-03-27T17:48:16.751Z</code> represents March 27, 2017 at 17:48:16.751 UTC.</p>
pub checked_time: std::option::Option<aws_smithy_types::DateTime>,
}
impl StatusReport {
/// <p>A description of the status of the health check endpoint as reported by one of the Amazon Route 53 health checkers.</p>
pub fn status(&self) -> std::option::Option<&str> {
self.status.as_deref()
}
/// <p>The date and time that the health checker performed the health check in <a href="https://en.wikipedia.org/wiki/ISO_8601">ISO 8601 format</a> and Coordinated Universal Time (UTC). For example, the value <code>2017-03-27T17:48:16.751Z</code> represents March 27, 2017 at 17:48:16.751 UTC.</p>
pub fn checked_time(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
self.checked_time.as_ref()
}
}
impl std::fmt::Debug for StatusReport {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("StatusReport");
formatter.field("status", &self.status);
formatter.field("checked_time", &self.checked_time);
formatter.finish()
}
}
/// See [`StatusReport`](crate::model::StatusReport)
pub mod status_report {
/// A builder for [`StatusReport`](crate::model::StatusReport)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) status: std::option::Option<std::string::String>,
pub(crate) checked_time: std::option::Option<aws_smithy_types::DateTime>,
}
impl Builder {
/// <p>A description of the status of the health check endpoint as reported by one of the Amazon Route 53 health checkers.</p>
pub fn status(mut self, input: impl Into<std::string::String>) -> Self {
self.status = Some(input.into());
self
}
/// <p>A description of the status of the health check endpoint as reported by one of the Amazon Route 53 health checkers.</p>
pub fn set_status(mut self, input: std::option::Option<std::string::String>) -> Self {
self.status = input;
self
}
/// <p>The date and time that the health checker performed the health check in <a href="https://en.wikipedia.org/wiki/ISO_8601">ISO 8601 format</a> and Coordinated Universal Time (UTC). For example, the value <code>2017-03-27T17:48:16.751Z</code> represents March 27, 2017 at 17:48:16.751 UTC.</p>
pub fn checked_time(mut self, input: aws_smithy_types::DateTime) -> Self {
self.checked_time = Some(input);
self
}
/// <p>The date and time that the health checker performed the health check in <a href="https://en.wikipedia.org/wiki/ISO_8601">ISO 8601 format</a> and Coordinated Universal Time (UTC). For example, the value <code>2017-03-27T17:48:16.751Z</code> represents March 27, 2017 at 17:48:16.751 UTC.</p>
pub fn set_checked_time(
mut self,
input: std::option::Option<aws_smithy_types::DateTime>,
) -> Self {
self.checked_time = input;
self
}
/// Consumes the builder and constructs a [`StatusReport`](crate::model::StatusReport)
pub fn build(self) -> crate::model::StatusReport {
crate::model::StatusReport {
status: self.status,
checked_time: self.checked_time,
}
}
}
}
impl StatusReport {
/// Creates a new builder-style object to manufacture [`StatusReport`](crate::model::StatusReport)
pub fn builder() -> crate::model::status_report::Builder {
crate::model::status_report::Builder::default()
}
}
/// <p>A key-signing key (KSK) is a complex type that represents a public/private key pair. The private key is used to generate a digital signature for the zone signing key (ZSK). The public key is stored in the DNS and is used to authenticate the ZSK. A KSK is always associated with a hosted zone; it cannot exist by itself.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct KeySigningKey {
/// <p>A string used to identify a key-signing key (KSK). <code>Name</code> can include numbers, letters, and underscores (_). <code>Name</code> must be unique for each key-signing key in the same hosted zone.</p>
pub name: std::option::Option<std::string::String>,
/// <p>The Amazon resource name (ARN) used to identify the customer managed key in Key Management Service (KMS). The <code>KmsArn</code> must be unique for each key-signing key (KSK) in a single hosted zone.</p>
/// <p>You must configure the customer managed key as follows:</p>
/// <dl>
/// <dt>
/// Status
/// </dt>
/// <dd>
/// <p>Enabled</p>
/// </dd>
/// <dt>
/// Key spec
/// </dt>
/// <dd>
/// <p>ECC_NIST_P256</p>
/// </dd>
/// <dt>
/// Key usage
/// </dt>
/// <dd>
/// <p>Sign and verify</p>
/// </dd>
/// <dt>
/// Key policy
/// </dt>
/// <dd>
/// <p>The key policy must give permission for the following actions:</p>
/// <ul>
/// <li> <p>DescribeKey</p> </li>
/// <li> <p>GetPublicKey</p> </li>
/// <li> <p>Sign</p> </li>
/// </ul>
/// <p>The key policy must also include the Amazon Route 53 service in the principal for your account. Specify the following:</p>
/// <ul>
/// <li> <p> <code>"Service": "dnssec-route53.amazonaws.com"</code> </p> </li>
/// </ul>
/// </dd>
/// </dl>
/// <p>For more information about working with the customer managed key in KMS, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html">Key Management Service concepts</a>.</p>
pub kms_arn: std::option::Option<std::string::String>,
/// <p>An integer that specifies how the key is used. For key-signing key (KSK), this value is always 257.</p>
pub flag: i32,
/// <p>A string used to represent the signing algorithm. This value must follow the guidelines provided by <a href="https://tools.ietf.org/html/rfc8624#section-3.1">RFC-8624 Section 3.1</a>. </p>
pub signing_algorithm_mnemonic: std::option::Option<std::string::String>,
/// <p>An integer used to represent the signing algorithm. This value must follow the guidelines provided by <a href="https://tools.ietf.org/html/rfc8624#section-3.1">RFC-8624 Section 3.1</a>. </p>
pub signing_algorithm_type: i32,
/// <p>A string used to represent the delegation signer digest algorithm. This value must follow the guidelines provided by <a href="https://tools.ietf.org/html/rfc8624#section-3.3">RFC-8624 Section 3.3</a>. </p>
pub digest_algorithm_mnemonic: std::option::Option<std::string::String>,
/// <p>An integer used to represent the delegation signer digest algorithm. This value must follow the guidelines provided by <a href="https://tools.ietf.org/html/rfc8624#section-3.3">RFC-8624 Section 3.3</a>.</p>
pub digest_algorithm_type: i32,
/// <p>An integer used to identify the DNSSEC record for the domain name. The process used to calculate the value is described in <a href="https://tools.ietf.org/rfc/rfc4034.txt">RFC-4034 Appendix B</a>.</p>
pub key_tag: i32,
/// <p>A cryptographic digest of a DNSKEY resource record (RR). DNSKEY records are used to publish the public key that resolvers can use to verify DNSSEC signatures that are used to secure certain kinds of information provided by the DNS system.</p>
pub digest_value: std::option::Option<std::string::String>,
/// <p>The public key, represented as a Base64 encoding, as required by <a href="https://tools.ietf.org/rfc/rfc4034.txt"> RFC-4034 Page 5</a>.</p>
pub public_key: std::option::Option<std::string::String>,
/// <p>A string that represents a delegation signer (DS) record.</p>
pub ds_record: std::option::Option<std::string::String>,
/// <p>A string that represents a DNSKEY record.</p>
pub dnskey_record: std::option::Option<std::string::String>,
/// <p>A string that represents the current key-signing key (KSK) status.</p>
/// <p>Status can have one of the following values:</p>
/// <dl>
/// <dt>
/// ACTIVE
/// </dt>
/// <dd>
/// <p>The KSK is being used for signing.</p>
/// </dd>
/// <dt>
/// INACTIVE
/// </dt>
/// <dd>
/// <p>The KSK is not being used for signing.</p>
/// </dd>
/// <dt>
/// DELETING
/// </dt>
/// <dd>
/// <p>The KSK is in the process of being deleted.</p>
/// </dd>
/// <dt>
/// ACTION_NEEDED
/// </dt>
/// <dd>
/// <p>There is a problem with the KSK that requires you to take action to resolve. For example, the customer managed key might have been deleted, or the permissions for the customer managed key might have been changed.</p>
/// </dd>
/// <dt>
/// INTERNAL_FAILURE
/// </dt>
/// <dd>
/// <p>There was an error during a request. Before you can continue to work with DNSSEC signing, including actions that involve this KSK, you must correct the problem. For example, you may need to activate or deactivate the KSK.</p>
/// </dd>
/// </dl>
pub status: std::option::Option<std::string::String>,
/// <p>The status message provided for the following key-signing key (KSK) statuses: <code>ACTION_NEEDED</code> or <code>INTERNAL_FAILURE</code>. The status message includes information about what the problem might be and steps that you can take to correct the issue.</p>
pub status_message: std::option::Option<std::string::String>,
/// <p>The date when the key-signing key (KSK) was created.</p>
pub created_date: std::option::Option<aws_smithy_types::DateTime>,
/// <p>The last time that the key-signing key (KSK) was changed.</p>
pub last_modified_date: std::option::Option<aws_smithy_types::DateTime>,
}
impl KeySigningKey {
/// <p>A string used to identify a key-signing key (KSK). <code>Name</code> can include numbers, letters, and underscores (_). <code>Name</code> must be unique for each key-signing key in the same hosted zone.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>The Amazon resource name (ARN) used to identify the customer managed key in Key Management Service (KMS). The <code>KmsArn</code> must be unique for each key-signing key (KSK) in a single hosted zone.</p>
/// <p>You must configure the customer managed key as follows:</p>
/// <dl>
/// <dt>
/// Status
/// </dt>
/// <dd>
/// <p>Enabled</p>
/// </dd>
/// <dt>
/// Key spec
/// </dt>
/// <dd>
/// <p>ECC_NIST_P256</p>
/// </dd>
/// <dt>
/// Key usage
/// </dt>
/// <dd>
/// <p>Sign and verify</p>
/// </dd>
/// <dt>
/// Key policy
/// </dt>
/// <dd>
/// <p>The key policy must give permission for the following actions:</p>
/// <ul>
/// <li> <p>DescribeKey</p> </li>
/// <li> <p>GetPublicKey</p> </li>
/// <li> <p>Sign</p> </li>
/// </ul>
/// <p>The key policy must also include the Amazon Route 53 service in the principal for your account. Specify the following:</p>
/// <ul>
/// <li> <p> <code>"Service": "dnssec-route53.amazonaws.com"</code> </p> </li>
/// </ul>
/// </dd>
/// </dl>
/// <p>For more information about working with the customer managed key in KMS, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html">Key Management Service concepts</a>.</p>
pub fn kms_arn(&self) -> std::option::Option<&str> {
self.kms_arn.as_deref()
}
/// <p>An integer that specifies how the key is used. For key-signing key (KSK), this value is always 257.</p>
pub fn flag(&self) -> i32 {
self.flag
}
/// <p>A string used to represent the signing algorithm. This value must follow the guidelines provided by <a href="https://tools.ietf.org/html/rfc8624#section-3.1">RFC-8624 Section 3.1</a>. </p>
pub fn signing_algorithm_mnemonic(&self) -> std::option::Option<&str> {
self.signing_algorithm_mnemonic.as_deref()
}
/// <p>An integer used to represent the signing algorithm. This value must follow the guidelines provided by <a href="https://tools.ietf.org/html/rfc8624#section-3.1">RFC-8624 Section 3.1</a>. </p>
pub fn signing_algorithm_type(&self) -> i32 {
self.signing_algorithm_type
}
/// <p>A string used to represent the delegation signer digest algorithm. This value must follow the guidelines provided by <a href="https://tools.ietf.org/html/rfc8624#section-3.3">RFC-8624 Section 3.3</a>. </p>
pub fn digest_algorithm_mnemonic(&self) -> std::option::Option<&str> {
self.digest_algorithm_mnemonic.as_deref()
}
/// <p>An integer used to represent the delegation signer digest algorithm. This value must follow the guidelines provided by <a href="https://tools.ietf.org/html/rfc8624#section-3.3">RFC-8624 Section 3.3</a>.</p>
pub fn digest_algorithm_type(&self) -> i32 {
self.digest_algorithm_type
}
/// <p>An integer used to identify the DNSSEC record for the domain name. The process used to calculate the value is described in <a href="https://tools.ietf.org/rfc/rfc4034.txt">RFC-4034 Appendix B</a>.</p>
pub fn key_tag(&self) -> i32 {
self.key_tag
}
/// <p>A cryptographic digest of a DNSKEY resource record (RR). DNSKEY records are used to publish the public key that resolvers can use to verify DNSSEC signatures that are used to secure certain kinds of information provided by the DNS system.</p>
pub fn digest_value(&self) -> std::option::Option<&str> {
self.digest_value.as_deref()
}
/// <p>The public key, represented as a Base64 encoding, as required by <a href="https://tools.ietf.org/rfc/rfc4034.txt"> RFC-4034 Page 5</a>.</p>
pub fn public_key(&self) -> std::option::Option<&str> {
self.public_key.as_deref()
}
/// <p>A string that represents a delegation signer (DS) record.</p>
pub fn ds_record(&self) -> std::option::Option<&str> {
self.ds_record.as_deref()
}
/// <p>A string that represents a DNSKEY record.</p>
pub fn dnskey_record(&self) -> std::option::Option<&str> {
self.dnskey_record.as_deref()
}
/// <p>A string that represents the current key-signing key (KSK) status.</p>
/// <p>Status can have one of the following values:</p>
/// <dl>
/// <dt>
/// ACTIVE
/// </dt>
/// <dd>
/// <p>The KSK is being used for signing.</p>
/// </dd>
/// <dt>
/// INACTIVE
/// </dt>
/// <dd>
/// <p>The KSK is not being used for signing.</p>
/// </dd>
/// <dt>
/// DELETING
/// </dt>
/// <dd>
/// <p>The KSK is in the process of being deleted.</p>
/// </dd>
/// <dt>
/// ACTION_NEEDED
/// </dt>
/// <dd>
/// <p>There is a problem with the KSK that requires you to take action to resolve. For example, the customer managed key might have been deleted, or the permissions for the customer managed key might have been changed.</p>
/// </dd>
/// <dt>
/// INTERNAL_FAILURE
/// </dt>
/// <dd>
/// <p>There was an error during a request. Before you can continue to work with DNSSEC signing, including actions that involve this KSK, you must correct the problem. For example, you may need to activate or deactivate the KSK.</p>
/// </dd>
/// </dl>
pub fn status(&self) -> std::option::Option<&str> {
self.status.as_deref()
}
/// <p>The status message provided for the following key-signing key (KSK) statuses: <code>ACTION_NEEDED</code> or <code>INTERNAL_FAILURE</code>. The status message includes information about what the problem might be and steps that you can take to correct the issue.</p>
pub fn status_message(&self) -> std::option::Option<&str> {
self.status_message.as_deref()
}
/// <p>The date when the key-signing key (KSK) was created.</p>
pub fn created_date(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
self.created_date.as_ref()
}
/// <p>The last time that the key-signing key (KSK) was changed.</p>
pub fn last_modified_date(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
self.last_modified_date.as_ref()
}
}
impl std::fmt::Debug for KeySigningKey {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("KeySigningKey");
formatter.field("name", &self.name);
formatter.field("kms_arn", &self.kms_arn);
formatter.field("flag", &self.flag);
formatter.field(
"signing_algorithm_mnemonic",
&self.signing_algorithm_mnemonic,
);
formatter.field("signing_algorithm_type", &self.signing_algorithm_type);
formatter.field("digest_algorithm_mnemonic", &self.digest_algorithm_mnemonic);
formatter.field("digest_algorithm_type", &self.digest_algorithm_type);
formatter.field("key_tag", &self.key_tag);
formatter.field("digest_value", &self.digest_value);
formatter.field("public_key", &self.public_key);
formatter.field("ds_record", &self.ds_record);
formatter.field("dnskey_record", &self.dnskey_record);
formatter.field("status", &self.status);
formatter.field("status_message", &self.status_message);
formatter.field("created_date", &self.created_date);
formatter.field("last_modified_date", &self.last_modified_date);
formatter.finish()
}
}
/// See [`KeySigningKey`](crate::model::KeySigningKey)
pub mod key_signing_key {
/// A builder for [`KeySigningKey`](crate::model::KeySigningKey)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) kms_arn: std::option::Option<std::string::String>,
pub(crate) flag: std::option::Option<i32>,
pub(crate) signing_algorithm_mnemonic: std::option::Option<std::string::String>,
pub(crate) signing_algorithm_type: std::option::Option<i32>,
pub(crate) digest_algorithm_mnemonic: std::option::Option<std::string::String>,
pub(crate) digest_algorithm_type: std::option::Option<i32>,
pub(crate) key_tag: std::option::Option<i32>,
pub(crate) digest_value: std::option::Option<std::string::String>,
pub(crate) public_key: std::option::Option<std::string::String>,
pub(crate) ds_record: std::option::Option<std::string::String>,
pub(crate) dnskey_record: std::option::Option<std::string::String>,
pub(crate) status: std::option::Option<std::string::String>,
pub(crate) status_message: std::option::Option<std::string::String>,
pub(crate) created_date: std::option::Option<aws_smithy_types::DateTime>,
pub(crate) last_modified_date: std::option::Option<aws_smithy_types::DateTime>,
}
impl Builder {
/// <p>A string used to identify a key-signing key (KSK). <code>Name</code> can include numbers, letters, and underscores (_). <code>Name</code> must be unique for each key-signing key in the same hosted zone.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>A string used to identify a key-signing key (KSK). <code>Name</code> can include numbers, letters, and underscores (_). <code>Name</code> must be unique for each key-signing key in the same hosted zone.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// <p>The Amazon resource name (ARN) used to identify the customer managed key in Key Management Service (KMS). The <code>KmsArn</code> must be unique for each key-signing key (KSK) in a single hosted zone.</p>
/// <p>You must configure the customer managed key as follows:</p>
/// <dl>
/// <dt>
/// Status
/// </dt>
/// <dd>
/// <p>Enabled</p>
/// </dd>
/// <dt>
/// Key spec
/// </dt>
/// <dd>
/// <p>ECC_NIST_P256</p>
/// </dd>
/// <dt>
/// Key usage
/// </dt>
/// <dd>
/// <p>Sign and verify</p>
/// </dd>
/// <dt>
/// Key policy
/// </dt>
/// <dd>
/// <p>The key policy must give permission for the following actions:</p>
/// <ul>
/// <li> <p>DescribeKey</p> </li>
/// <li> <p>GetPublicKey</p> </li>
/// <li> <p>Sign</p> </li>
/// </ul>
/// <p>The key policy must also include the Amazon Route 53 service in the principal for your account. Specify the following:</p>
/// <ul>
/// <li> <p> <code>"Service": "dnssec-route53.amazonaws.com"</code> </p> </li>
/// </ul>
/// </dd>
/// </dl>
/// <p>For more information about working with the customer managed key in KMS, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html">Key Management Service concepts</a>.</p>
pub fn kms_arn(mut self, input: impl Into<std::string::String>) -> Self {
self.kms_arn = Some(input.into());
self
}
/// <p>The Amazon resource name (ARN) used to identify the customer managed key in Key Management Service (KMS). The <code>KmsArn</code> must be unique for each key-signing key (KSK) in a single hosted zone.</p>
/// <p>You must configure the customer managed key as follows:</p>
/// <dl>
/// <dt>
/// Status
/// </dt>
/// <dd>
/// <p>Enabled</p>
/// </dd>
/// <dt>
/// Key spec
/// </dt>
/// <dd>
/// <p>ECC_NIST_P256</p>
/// </dd>
/// <dt>
/// Key usage
/// </dt>
/// <dd>
/// <p>Sign and verify</p>
/// </dd>
/// <dt>
/// Key policy
/// </dt>
/// <dd>
/// <p>The key policy must give permission for the following actions:</p>
/// <ul>
/// <li> <p>DescribeKey</p> </li>
/// <li> <p>GetPublicKey</p> </li>
/// <li> <p>Sign</p> </li>
/// </ul>
/// <p>The key policy must also include the Amazon Route 53 service in the principal for your account. Specify the following:</p>
/// <ul>
/// <li> <p> <code>"Service": "dnssec-route53.amazonaws.com"</code> </p> </li>
/// </ul>
/// </dd>
/// </dl>
/// <p>For more information about working with the customer managed key in KMS, see <a href="https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html">Key Management Service concepts</a>.</p>
pub fn set_kms_arn(mut self, input: std::option::Option<std::string::String>) -> Self {
self.kms_arn = input;
self
}
/// <p>An integer that specifies how the key is used. For key-signing key (KSK), this value is always 257.</p>
pub fn flag(mut self, input: i32) -> Self {
self.flag = Some(input);
self
}
/// <p>An integer that specifies how the key is used. For key-signing key (KSK), this value is always 257.</p>
pub fn set_flag(mut self, input: std::option::Option<i32>) -> Self {
self.flag = input;
self
}
/// <p>A string used to represent the signing algorithm. This value must follow the guidelines provided by <a href="https://tools.ietf.org/html/rfc8624#section-3.1">RFC-8624 Section 3.1</a>. </p>
pub fn signing_algorithm_mnemonic(mut self, input: impl Into<std::string::String>) -> Self {
self.signing_algorithm_mnemonic = Some(input.into());
self
}
/// <p>A string used to represent the signing algorithm. This value must follow the guidelines provided by <a href="https://tools.ietf.org/html/rfc8624#section-3.1">RFC-8624 Section 3.1</a>. </p>
pub fn set_signing_algorithm_mnemonic(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.signing_algorithm_mnemonic = input;
self
}
/// <p>An integer used to represent the signing algorithm. This value must follow the guidelines provided by <a href="https://tools.ietf.org/html/rfc8624#section-3.1">RFC-8624 Section 3.1</a>. </p>
pub fn signing_algorithm_type(mut self, input: i32) -> Self {
self.signing_algorithm_type = Some(input);
self
}
/// <p>An integer used to represent the signing algorithm. This value must follow the guidelines provided by <a href="https://tools.ietf.org/html/rfc8624#section-3.1">RFC-8624 Section 3.1</a>. </p>
pub fn set_signing_algorithm_type(mut self, input: std::option::Option<i32>) -> Self {
self.signing_algorithm_type = input;
self
}
/// <p>A string used to represent the delegation signer digest algorithm. This value must follow the guidelines provided by <a href="https://tools.ietf.org/html/rfc8624#section-3.3">RFC-8624 Section 3.3</a>. </p>
pub fn digest_algorithm_mnemonic(mut self, input: impl Into<std::string::String>) -> Self {
self.digest_algorithm_mnemonic = Some(input.into());
self
}
/// <p>A string used to represent the delegation signer digest algorithm. This value must follow the guidelines provided by <a href="https://tools.ietf.org/html/rfc8624#section-3.3">RFC-8624 Section 3.3</a>. </p>
pub fn set_digest_algorithm_mnemonic(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.digest_algorithm_mnemonic = input;
self
}
/// <p>An integer used to represent the delegation signer digest algorithm. This value must follow the guidelines provided by <a href="https://tools.ietf.org/html/rfc8624#section-3.3">RFC-8624 Section 3.3</a>.</p>
pub fn digest_algorithm_type(mut self, input: i32) -> Self {
self.digest_algorithm_type = Some(input);
self
}
/// <p>An integer used to represent the delegation signer digest algorithm. This value must follow the guidelines provided by <a href="https://tools.ietf.org/html/rfc8624#section-3.3">RFC-8624 Section 3.3</a>.</p>
pub fn set_digest_algorithm_type(mut self, input: std::option::Option<i32>) -> Self {
self.digest_algorithm_type = input;
self
}
/// <p>An integer used to identify the DNSSEC record for the domain name. The process used to calculate the value is described in <a href="https://tools.ietf.org/rfc/rfc4034.txt">RFC-4034 Appendix B</a>.</p>
pub fn key_tag(mut self, input: i32) -> Self {
self.key_tag = Some(input);
self
}
/// <p>An integer used to identify the DNSSEC record for the domain name. The process used to calculate the value is described in <a href="https://tools.ietf.org/rfc/rfc4034.txt">RFC-4034 Appendix B</a>.</p>
pub fn set_key_tag(mut self, input: std::option::Option<i32>) -> Self {
self.key_tag = input;
self
}
/// <p>A cryptographic digest of a DNSKEY resource record (RR). DNSKEY records are used to publish the public key that resolvers can use to verify DNSSEC signatures that are used to secure certain kinds of information provided by the DNS system.</p>
pub fn digest_value(mut self, input: impl Into<std::string::String>) -> Self {
self.digest_value = Some(input.into());
self
}
/// <p>A cryptographic digest of a DNSKEY resource record (RR). DNSKEY records are used to publish the public key that resolvers can use to verify DNSSEC signatures that are used to secure certain kinds of information provided by the DNS system.</p>
pub fn set_digest_value(mut self, input: std::option::Option<std::string::String>) -> Self {
self.digest_value = input;
self
}
/// <p>The public key, represented as a Base64 encoding, as required by <a href="https://tools.ietf.org/rfc/rfc4034.txt"> RFC-4034 Page 5</a>.</p>
pub fn public_key(mut self, input: impl Into<std::string::String>) -> Self {
self.public_key = Some(input.into());
self
}
/// <p>The public key, represented as a Base64 encoding, as required by <a href="https://tools.ietf.org/rfc/rfc4034.txt"> RFC-4034 Page 5</a>.</p>
pub fn set_public_key(mut self, input: std::option::Option<std::string::String>) -> Self {
self.public_key = input;
self
}
/// <p>A string that represents a delegation signer (DS) record.</p>
pub fn ds_record(mut self, input: impl Into<std::string::String>) -> Self {
self.ds_record = Some(input.into());
self
}
/// <p>A string that represents a delegation signer (DS) record.</p>
pub fn set_ds_record(mut self, input: std::option::Option<std::string::String>) -> Self {
self.ds_record = input;
self
}
/// <p>A string that represents a DNSKEY record.</p>
pub fn dnskey_record(mut self, input: impl Into<std::string::String>) -> Self {
self.dnskey_record = Some(input.into());
self
}
/// <p>A string that represents a DNSKEY record.</p>
pub fn set_dnskey_record(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.dnskey_record = input;
self
}
/// <p>A string that represents the current key-signing key (KSK) status.</p>
/// <p>Status can have one of the following values:</p>
/// <dl>
/// <dt>
/// ACTIVE
/// </dt>
/// <dd>
/// <p>The KSK is being used for signing.</p>
/// </dd>
/// <dt>
/// INACTIVE
/// </dt>
/// <dd>
/// <p>The KSK is not being used for signing.</p>
/// </dd>
/// <dt>
/// DELETING
/// </dt>
/// <dd>
/// <p>The KSK is in the process of being deleted.</p>
/// </dd>
/// <dt>
/// ACTION_NEEDED
/// </dt>
/// <dd>
/// <p>There is a problem with the KSK that requires you to take action to resolve. For example, the customer managed key might have been deleted, or the permissions for the customer managed key might have been changed.</p>
/// </dd>
/// <dt>
/// INTERNAL_FAILURE
/// </dt>
/// <dd>
/// <p>There was an error during a request. Before you can continue to work with DNSSEC signing, including actions that involve this KSK, you must correct the problem. For example, you may need to activate or deactivate the KSK.</p>
/// </dd>
/// </dl>
pub fn status(mut self, input: impl Into<std::string::String>) -> Self {
self.status = Some(input.into());
self
}
/// <p>A string that represents the current key-signing key (KSK) status.</p>
/// <p>Status can have one of the following values:</p>
/// <dl>
/// <dt>
/// ACTIVE
/// </dt>
/// <dd>
/// <p>The KSK is being used for signing.</p>
/// </dd>
/// <dt>
/// INACTIVE
/// </dt>
/// <dd>
/// <p>The KSK is not being used for signing.</p>
/// </dd>
/// <dt>
/// DELETING
/// </dt>
/// <dd>
/// <p>The KSK is in the process of being deleted.</p>
/// </dd>
/// <dt>
/// ACTION_NEEDED
/// </dt>
/// <dd>
/// <p>There is a problem with the KSK that requires you to take action to resolve. For example, the customer managed key might have been deleted, or the permissions for the customer managed key might have been changed.</p>
/// </dd>
/// <dt>
/// INTERNAL_FAILURE
/// </dt>
/// <dd>
/// <p>There was an error during a request. Before you can continue to work with DNSSEC signing, including actions that involve this KSK, you must correct the problem. For example, you may need to activate or deactivate the KSK.</p>
/// </dd>
/// </dl>
pub fn set_status(mut self, input: std::option::Option<std::string::String>) -> Self {
self.status = input;
self
}
/// <p>The status message provided for the following key-signing key (KSK) statuses: <code>ACTION_NEEDED</code> or <code>INTERNAL_FAILURE</code>. The status message includes information about what the problem might be and steps that you can take to correct the issue.</p>
pub fn status_message(mut self, input: impl Into<std::string::String>) -> Self {
self.status_message = Some(input.into());
self
}
/// <p>The status message provided for the following key-signing key (KSK) statuses: <code>ACTION_NEEDED</code> or <code>INTERNAL_FAILURE</code>. The status message includes information about what the problem might be and steps that you can take to correct the issue.</p>
pub fn set_status_message(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.status_message = input;
self
}
/// <p>The date when the key-signing key (KSK) was created.</p>
pub fn created_date(mut self, input: aws_smithy_types::DateTime) -> Self {
self.created_date = Some(input);
self
}
/// <p>The date when the key-signing key (KSK) was created.</p>
pub fn set_created_date(
mut self,
input: std::option::Option<aws_smithy_types::DateTime>,
) -> Self {
self.created_date = input;
self
}
/// <p>The last time that the key-signing key (KSK) was changed.</p>
pub fn last_modified_date(mut self, input: aws_smithy_types::DateTime) -> Self {
self.last_modified_date = Some(input);
self
}
/// <p>The last time that the key-signing key (KSK) was changed.</p>
pub fn set_last_modified_date(
mut self,
input: std::option::Option<aws_smithy_types::DateTime>,
) -> Self {
self.last_modified_date = input;
self
}
/// Consumes the builder and constructs a [`KeySigningKey`](crate::model::KeySigningKey)
pub fn build(self) -> crate::model::KeySigningKey {
crate::model::KeySigningKey {
name: self.name,
kms_arn: self.kms_arn,
flag: self.flag.unwrap_or_default(),
signing_algorithm_mnemonic: self.signing_algorithm_mnemonic,
signing_algorithm_type: self.signing_algorithm_type.unwrap_or_default(),
digest_algorithm_mnemonic: self.digest_algorithm_mnemonic,
digest_algorithm_type: self.digest_algorithm_type.unwrap_or_default(),
key_tag: self.key_tag.unwrap_or_default(),
digest_value: self.digest_value,
public_key: self.public_key,
ds_record: self.ds_record,
dnskey_record: self.dnskey_record,
status: self.status,
status_message: self.status_message,
created_date: self.created_date,
last_modified_date: self.last_modified_date,
}
}
}
}
impl KeySigningKey {
/// Creates a new builder-style object to manufacture [`KeySigningKey`](crate::model::KeySigningKey)
pub fn builder() -> crate::model::key_signing_key::Builder {
crate::model::key_signing_key::Builder::default()
}
}
/// <p>A string repesenting the status of DNSSEC signing.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct DnssecStatus {
/// <p>A string that represents the current hosted zone signing status.</p>
/// <p>Status can have one of the following values:</p>
/// <dl>
/// <dt>
/// SIGNING
/// </dt>
/// <dd>
/// <p>DNSSEC signing is enabled for the hosted zone.</p>
/// </dd>
/// <dt>
/// NOT_SIGNING
/// </dt>
/// <dd>
/// <p>DNSSEC signing is not enabled for the hosted zone.</p>
/// </dd>
/// <dt>
/// DELETING
/// </dt>
/// <dd>
/// <p>DNSSEC signing is in the process of being removed for the hosted zone.</p>
/// </dd>
/// <dt>
/// ACTION_NEEDED
/// </dt>
/// <dd>
/// <p>There is a problem with signing in the hosted zone that requires you to take action to resolve. For example, the customer managed key might have been deleted, or the permissions for the customer managed key might have been changed.</p>
/// </dd>
/// <dt>
/// INTERNAL_FAILURE
/// </dt>
/// <dd>
/// <p>There was an error during a request. Before you can continue to work with DNSSEC signing, including with key-signing keys (KSKs), you must correct the problem by enabling or disabling DNSSEC signing for the hosted zone.</p>
/// </dd>
/// </dl>
pub serve_signature: std::option::Option<std::string::String>,
/// <p>The status message provided for the following DNSSEC signing status: <code>INTERNAL_FAILURE</code>. The status message includes information about what the problem might be and steps that you can take to correct the issue.</p>
pub status_message: std::option::Option<std::string::String>,
}
impl DnssecStatus {
/// <p>A string that represents the current hosted zone signing status.</p>
/// <p>Status can have one of the following values:</p>
/// <dl>
/// <dt>
/// SIGNING
/// </dt>
/// <dd>
/// <p>DNSSEC signing is enabled for the hosted zone.</p>
/// </dd>
/// <dt>
/// NOT_SIGNING
/// </dt>
/// <dd>
/// <p>DNSSEC signing is not enabled for the hosted zone.</p>
/// </dd>
/// <dt>
/// DELETING
/// </dt>
/// <dd>
/// <p>DNSSEC signing is in the process of being removed for the hosted zone.</p>
/// </dd>
/// <dt>
/// ACTION_NEEDED
/// </dt>
/// <dd>
/// <p>There is a problem with signing in the hosted zone that requires you to take action to resolve. For example, the customer managed key might have been deleted, or the permissions for the customer managed key might have been changed.</p>
/// </dd>
/// <dt>
/// INTERNAL_FAILURE
/// </dt>
/// <dd>
/// <p>There was an error during a request. Before you can continue to work with DNSSEC signing, including with key-signing keys (KSKs), you must correct the problem by enabling or disabling DNSSEC signing for the hosted zone.</p>
/// </dd>
/// </dl>
pub fn serve_signature(&self) -> std::option::Option<&str> {
self.serve_signature.as_deref()
}
/// <p>The status message provided for the following DNSSEC signing status: <code>INTERNAL_FAILURE</code>. The status message includes information about what the problem might be and steps that you can take to correct the issue.</p>
pub fn status_message(&self) -> std::option::Option<&str> {
self.status_message.as_deref()
}
}
impl std::fmt::Debug for DnssecStatus {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("DnssecStatus");
formatter.field("serve_signature", &self.serve_signature);
formatter.field("status_message", &self.status_message);
formatter.finish()
}
}
/// See [`DnssecStatus`](crate::model::DnssecStatus)
pub mod dnssec_status {
/// A builder for [`DnssecStatus`](crate::model::DnssecStatus)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) serve_signature: std::option::Option<std::string::String>,
pub(crate) status_message: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>A string that represents the current hosted zone signing status.</p>
/// <p>Status can have one of the following values:</p>
/// <dl>
/// <dt>
/// SIGNING
/// </dt>
/// <dd>
/// <p>DNSSEC signing is enabled for the hosted zone.</p>
/// </dd>
/// <dt>
/// NOT_SIGNING
/// </dt>
/// <dd>
/// <p>DNSSEC signing is not enabled for the hosted zone.</p>
/// </dd>
/// <dt>
/// DELETING
/// </dt>
/// <dd>
/// <p>DNSSEC signing is in the process of being removed for the hosted zone.</p>
/// </dd>
/// <dt>
/// ACTION_NEEDED
/// </dt>
/// <dd>
/// <p>There is a problem with signing in the hosted zone that requires you to take action to resolve. For example, the customer managed key might have been deleted, or the permissions for the customer managed key might have been changed.</p>
/// </dd>
/// <dt>
/// INTERNAL_FAILURE
/// </dt>
/// <dd>
/// <p>There was an error during a request. Before you can continue to work with DNSSEC signing, including with key-signing keys (KSKs), you must correct the problem by enabling or disabling DNSSEC signing for the hosted zone.</p>
/// </dd>
/// </dl>
pub fn serve_signature(mut self, input: impl Into<std::string::String>) -> Self {
self.serve_signature = Some(input.into());
self
}
/// <p>A string that represents the current hosted zone signing status.</p>
/// <p>Status can have one of the following values:</p>
/// <dl>
/// <dt>
/// SIGNING
/// </dt>
/// <dd>
/// <p>DNSSEC signing is enabled for the hosted zone.</p>
/// </dd>
/// <dt>
/// NOT_SIGNING
/// </dt>
/// <dd>
/// <p>DNSSEC signing is not enabled for the hosted zone.</p>
/// </dd>
/// <dt>
/// DELETING
/// </dt>
/// <dd>
/// <p>DNSSEC signing is in the process of being removed for the hosted zone.</p>
/// </dd>
/// <dt>
/// ACTION_NEEDED
/// </dt>
/// <dd>
/// <p>There is a problem with signing in the hosted zone that requires you to take action to resolve. For example, the customer managed key might have been deleted, or the permissions for the customer managed key might have been changed.</p>
/// </dd>
/// <dt>
/// INTERNAL_FAILURE
/// </dt>
/// <dd>
/// <p>There was an error during a request. Before you can continue to work with DNSSEC signing, including with key-signing keys (KSKs), you must correct the problem by enabling or disabling DNSSEC signing for the hosted zone.</p>
/// </dd>
/// </dl>
pub fn set_serve_signature(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.serve_signature = input;
self
}
/// <p>The status message provided for the following DNSSEC signing status: <code>INTERNAL_FAILURE</code>. The status message includes information about what the problem might be and steps that you can take to correct the issue.</p>
pub fn status_message(mut self, input: impl Into<std::string::String>) -> Self {
self.status_message = Some(input.into());
self
}
/// <p>The status message provided for the following DNSSEC signing status: <code>INTERNAL_FAILURE</code>. The status message includes information about what the problem might be and steps that you can take to correct the issue.</p>
pub fn set_status_message(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.status_message = input;
self
}
/// Consumes the builder and constructs a [`DnssecStatus`](crate::model::DnssecStatus)
pub fn build(self) -> crate::model::DnssecStatus {
crate::model::DnssecStatus {
serve_signature: self.serve_signature,
status_message: self.status_message,
}
}
}
}
impl DnssecStatus {
/// Creates a new builder-style object to manufacture [`DnssecStatus`](crate::model::DnssecStatus)
pub fn builder() -> crate::model::dnssec_status::Builder {
crate::model::dnssec_status::Builder::default()
}
}
/// <p>A complex type that describes change information about changes made to your hosted zone.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct ChangeInfo {
/// <p>This element contains an ID that you use when performing a <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_GetChange.html">GetChange</a> action to get detailed information about the change.</p>
pub id: std::option::Option<std::string::String>,
/// <p>The current state of the request. <code>PENDING</code> indicates that this request has not yet been applied to all Amazon Route 53 DNS servers.</p>
pub status: std::option::Option<crate::model::ChangeStatus>,
/// <p>The date and time that the change request was submitted in <a href="https://en.wikipedia.org/wiki/ISO_8601">ISO 8601 format</a> and Coordinated Universal Time (UTC). For example, the value <code>2017-03-27T17:48:16.751Z</code> represents March 27, 2017 at 17:48:16.751 UTC.</p>
pub submitted_at: std::option::Option<aws_smithy_types::DateTime>,
/// <p>A comment you can provide.</p>
pub comment: std::option::Option<std::string::String>,
}
impl ChangeInfo {
/// <p>This element contains an ID that you use when performing a <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_GetChange.html">GetChange</a> action to get detailed information about the change.</p>
pub fn id(&self) -> std::option::Option<&str> {
self.id.as_deref()
}
/// <p>The current state of the request. <code>PENDING</code> indicates that this request has not yet been applied to all Amazon Route 53 DNS servers.</p>
pub fn status(&self) -> std::option::Option<&crate::model::ChangeStatus> {
self.status.as_ref()
}
/// <p>The date and time that the change request was submitted in <a href="https://en.wikipedia.org/wiki/ISO_8601">ISO 8601 format</a> and Coordinated Universal Time (UTC). For example, the value <code>2017-03-27T17:48:16.751Z</code> represents March 27, 2017 at 17:48:16.751 UTC.</p>
pub fn submitted_at(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
self.submitted_at.as_ref()
}
/// <p>A comment you can provide.</p>
pub fn comment(&self) -> std::option::Option<&str> {
self.comment.as_deref()
}
}
impl std::fmt::Debug for ChangeInfo {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("ChangeInfo");
formatter.field("id", &self.id);
formatter.field("status", &self.status);
formatter.field("submitted_at", &self.submitted_at);
formatter.field("comment", &self.comment);
formatter.finish()
}
}
/// See [`ChangeInfo`](crate::model::ChangeInfo)
pub mod change_info {
/// A builder for [`ChangeInfo`](crate::model::ChangeInfo)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) id: std::option::Option<std::string::String>,
pub(crate) status: std::option::Option<crate::model::ChangeStatus>,
pub(crate) submitted_at: std::option::Option<aws_smithy_types::DateTime>,
pub(crate) comment: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>This element contains an ID that you use when performing a <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_GetChange.html">GetChange</a> action to get detailed information about the change.</p>
pub fn id(mut self, input: impl Into<std::string::String>) -> Self {
self.id = Some(input.into());
self
}
/// <p>This element contains an ID that you use when performing a <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_GetChange.html">GetChange</a> action to get detailed information about the change.</p>
pub fn set_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.id = input;
self
}
/// <p>The current state of the request. <code>PENDING</code> indicates that this request has not yet been applied to all Amazon Route 53 DNS servers.</p>
pub fn status(mut self, input: crate::model::ChangeStatus) -> Self {
self.status = Some(input);
self
}
/// <p>The current state of the request. <code>PENDING</code> indicates that this request has not yet been applied to all Amazon Route 53 DNS servers.</p>
pub fn set_status(
mut self,
input: std::option::Option<crate::model::ChangeStatus>,
) -> Self {
self.status = input;
self
}
/// <p>The date and time that the change request was submitted in <a href="https://en.wikipedia.org/wiki/ISO_8601">ISO 8601 format</a> and Coordinated Universal Time (UTC). For example, the value <code>2017-03-27T17:48:16.751Z</code> represents March 27, 2017 at 17:48:16.751 UTC.</p>
pub fn submitted_at(mut self, input: aws_smithy_types::DateTime) -> Self {
self.submitted_at = Some(input);
self
}
/// <p>The date and time that the change request was submitted in <a href="https://en.wikipedia.org/wiki/ISO_8601">ISO 8601 format</a> and Coordinated Universal Time (UTC). For example, the value <code>2017-03-27T17:48:16.751Z</code> represents March 27, 2017 at 17:48:16.751 UTC.</p>
pub fn set_submitted_at(
mut self,
input: std::option::Option<aws_smithy_types::DateTime>,
) -> Self {
self.submitted_at = input;
self
}
/// <p>A comment you can provide.</p>
pub fn comment(mut self, input: impl Into<std::string::String>) -> Self {
self.comment = Some(input.into());
self
}
/// <p>A comment you can provide.</p>
pub fn set_comment(mut self, input: std::option::Option<std::string::String>) -> Self {
self.comment = input;
self
}
/// Consumes the builder and constructs a [`ChangeInfo`](crate::model::ChangeInfo)
pub fn build(self) -> crate::model::ChangeInfo {
crate::model::ChangeInfo {
id: self.id,
status: self.status,
submitted_at: self.submitted_at,
comment: self.comment,
}
}
}
}
impl ChangeInfo {
/// Creates a new builder-style object to manufacture [`ChangeInfo`](crate::model::ChangeInfo)
pub fn builder() -> crate::model::change_info::Builder {
crate::model::change_info::Builder::default()
}
}
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum ChangeStatus {
#[allow(missing_docs)] // documentation missing in model
Insync,
#[allow(missing_docs)] // documentation missing in model
Pending,
/// Unknown contains new variants that have been added since this code was generated.
Unknown(String),
}
impl std::convert::From<&str> for ChangeStatus {
fn from(s: &str) -> Self {
match s {
"INSYNC" => ChangeStatus::Insync,
"PENDING" => ChangeStatus::Pending,
other => ChangeStatus::Unknown(other.to_owned()),
}
}
}
impl std::str::FromStr for ChangeStatus {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(ChangeStatus::from(s))
}
}
impl ChangeStatus {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
ChangeStatus::Insync => "INSYNC",
ChangeStatus::Pending => "PENDING",
ChangeStatus::Unknown(s) => s.as_ref(),
}
}
/// Returns all the `&str` values of the enum members.
pub fn values() -> &'static [&'static str] {
&["INSYNC", "PENDING"]
}
}
impl AsRef<str> for ChangeStatus {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>A complex type that contains the type of limit that you specified in the request and the current value for that limit.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct AccountLimit {
/// <p>The limit that you requested. Valid values include the following:</p>
/// <ul>
/// <li> <p> <b>MAX_HEALTH_CHECKS_BY_OWNER</b>: The maximum number of health checks that you can create using the current account.</p> </li>
/// <li> <p> <b>MAX_HOSTED_ZONES_BY_OWNER</b>: The maximum number of hosted zones that you can create using the current account.</p> </li>
/// <li> <p> <b>MAX_REUSABLE_DELEGATION_SETS_BY_OWNER</b>: The maximum number of reusable delegation sets that you can create using the current account.</p> </li>
/// <li> <p> <b>MAX_TRAFFIC_POLICIES_BY_OWNER</b>: The maximum number of traffic policies that you can create using the current account.</p> </li>
/// <li> <p> <b>MAX_TRAFFIC_POLICY_INSTANCES_BY_OWNER</b>: The maximum number of traffic policy instances that you can create using the current account. (Traffic policy instances are referred to as traffic flow policy records in the Amazon Route 53 console.)</p> </li>
/// </ul>
pub r#type: std::option::Option<crate::model::AccountLimitType>,
/// <p>The current value for the limit that is specified by <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_AccountLimit.html#Route53-Type-AccountLimit-Type">Type</a>.</p>
pub value: i64,
}
impl AccountLimit {
/// <p>The limit that you requested. Valid values include the following:</p>
/// <ul>
/// <li> <p> <b>MAX_HEALTH_CHECKS_BY_OWNER</b>: The maximum number of health checks that you can create using the current account.</p> </li>
/// <li> <p> <b>MAX_HOSTED_ZONES_BY_OWNER</b>: The maximum number of hosted zones that you can create using the current account.</p> </li>
/// <li> <p> <b>MAX_REUSABLE_DELEGATION_SETS_BY_OWNER</b>: The maximum number of reusable delegation sets that you can create using the current account.</p> </li>
/// <li> <p> <b>MAX_TRAFFIC_POLICIES_BY_OWNER</b>: The maximum number of traffic policies that you can create using the current account.</p> </li>
/// <li> <p> <b>MAX_TRAFFIC_POLICY_INSTANCES_BY_OWNER</b>: The maximum number of traffic policy instances that you can create using the current account. (Traffic policy instances are referred to as traffic flow policy records in the Amazon Route 53 console.)</p> </li>
/// </ul>
pub fn r#type(&self) -> std::option::Option<&crate::model::AccountLimitType> {
self.r#type.as_ref()
}
/// <p>The current value for the limit that is specified by <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_AccountLimit.html#Route53-Type-AccountLimit-Type">Type</a>.</p>
pub fn value(&self) -> i64 {
self.value
}
}
impl std::fmt::Debug for AccountLimit {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("AccountLimit");
formatter.field("r#type", &self.r#type);
formatter.field("value", &self.value);
formatter.finish()
}
}
/// See [`AccountLimit`](crate::model::AccountLimit)
pub mod account_limit {
/// A builder for [`AccountLimit`](crate::model::AccountLimit)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) r#type: std::option::Option<crate::model::AccountLimitType>,
pub(crate) value: std::option::Option<i64>,
}
impl Builder {
/// <p>The limit that you requested. Valid values include the following:</p>
/// <ul>
/// <li> <p> <b>MAX_HEALTH_CHECKS_BY_OWNER</b>: The maximum number of health checks that you can create using the current account.</p> </li>
/// <li> <p> <b>MAX_HOSTED_ZONES_BY_OWNER</b>: The maximum number of hosted zones that you can create using the current account.</p> </li>
/// <li> <p> <b>MAX_REUSABLE_DELEGATION_SETS_BY_OWNER</b>: The maximum number of reusable delegation sets that you can create using the current account.</p> </li>
/// <li> <p> <b>MAX_TRAFFIC_POLICIES_BY_OWNER</b>: The maximum number of traffic policies that you can create using the current account.</p> </li>
/// <li> <p> <b>MAX_TRAFFIC_POLICY_INSTANCES_BY_OWNER</b>: The maximum number of traffic policy instances that you can create using the current account. (Traffic policy instances are referred to as traffic flow policy records in the Amazon Route 53 console.)</p> </li>
/// </ul>
pub fn r#type(mut self, input: crate::model::AccountLimitType) -> Self {
self.r#type = Some(input);
self
}
/// <p>The limit that you requested. Valid values include the following:</p>
/// <ul>
/// <li> <p> <b>MAX_HEALTH_CHECKS_BY_OWNER</b>: The maximum number of health checks that you can create using the current account.</p> </li>
/// <li> <p> <b>MAX_HOSTED_ZONES_BY_OWNER</b>: The maximum number of hosted zones that you can create using the current account.</p> </li>
/// <li> <p> <b>MAX_REUSABLE_DELEGATION_SETS_BY_OWNER</b>: The maximum number of reusable delegation sets that you can create using the current account.</p> </li>
/// <li> <p> <b>MAX_TRAFFIC_POLICIES_BY_OWNER</b>: The maximum number of traffic policies that you can create using the current account.</p> </li>
/// <li> <p> <b>MAX_TRAFFIC_POLICY_INSTANCES_BY_OWNER</b>: The maximum number of traffic policy instances that you can create using the current account. (Traffic policy instances are referred to as traffic flow policy records in the Amazon Route 53 console.)</p> </li>
/// </ul>
pub fn set_type(
mut self,
input: std::option::Option<crate::model::AccountLimitType>,
) -> Self {
self.r#type = input;
self
}
/// <p>The current value for the limit that is specified by <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_AccountLimit.html#Route53-Type-AccountLimit-Type">Type</a>.</p>
pub fn value(mut self, input: i64) -> Self {
self.value = Some(input);
self
}
/// <p>The current value for the limit that is specified by <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_AccountLimit.html#Route53-Type-AccountLimit-Type">Type</a>.</p>
pub fn set_value(mut self, input: std::option::Option<i64>) -> Self {
self.value = input;
self
}
/// Consumes the builder and constructs a [`AccountLimit`](crate::model::AccountLimit)
pub fn build(self) -> crate::model::AccountLimit {
crate::model::AccountLimit {
r#type: self.r#type,
value: self.value.unwrap_or_default(),
}
}
}
}
impl AccountLimit {
/// Creates a new builder-style object to manufacture [`AccountLimit`](crate::model::AccountLimit)
pub fn builder() -> crate::model::account_limit::Builder {
crate::model::account_limit::Builder::default()
}
}
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum AccountLimitType {
#[allow(missing_docs)] // documentation missing in model
MaxHealthChecksByOwner,
#[allow(missing_docs)] // documentation missing in model
MaxHostedZonesByOwner,
#[allow(missing_docs)] // documentation missing in model
MaxReusableDelegationSetsByOwner,
#[allow(missing_docs)] // documentation missing in model
MaxTrafficPoliciesByOwner,
#[allow(missing_docs)] // documentation missing in model
MaxTrafficPolicyInstancesByOwner,
/// Unknown contains new variants that have been added since this code was generated.
Unknown(String),
}
impl std::convert::From<&str> for AccountLimitType {
fn from(s: &str) -> Self {
match s {
"MAX_HEALTH_CHECKS_BY_OWNER" => AccountLimitType::MaxHealthChecksByOwner,
"MAX_HOSTED_ZONES_BY_OWNER" => AccountLimitType::MaxHostedZonesByOwner,
"MAX_REUSABLE_DELEGATION_SETS_BY_OWNER" => {
AccountLimitType::MaxReusableDelegationSetsByOwner
}
"MAX_TRAFFIC_POLICIES_BY_OWNER" => AccountLimitType::MaxTrafficPoliciesByOwner,
"MAX_TRAFFIC_POLICY_INSTANCES_BY_OWNER" => {
AccountLimitType::MaxTrafficPolicyInstancesByOwner
}
other => AccountLimitType::Unknown(other.to_owned()),
}
}
}
impl std::str::FromStr for AccountLimitType {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(AccountLimitType::from(s))
}
}
impl AccountLimitType {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
AccountLimitType::MaxHealthChecksByOwner => "MAX_HEALTH_CHECKS_BY_OWNER",
AccountLimitType::MaxHostedZonesByOwner => "MAX_HOSTED_ZONES_BY_OWNER",
AccountLimitType::MaxReusableDelegationSetsByOwner => {
"MAX_REUSABLE_DELEGATION_SETS_BY_OWNER"
}
AccountLimitType::MaxTrafficPoliciesByOwner => "MAX_TRAFFIC_POLICIES_BY_OWNER",
AccountLimitType::MaxTrafficPolicyInstancesByOwner => {
"MAX_TRAFFIC_POLICY_INSTANCES_BY_OWNER"
}
AccountLimitType::Unknown(s) => s.as_ref(),
}
}
/// Returns all the `&str` values of the enum members.
pub fn values() -> &'static [&'static str] {
&[
"MAX_HEALTH_CHECKS_BY_OWNER",
"MAX_HOSTED_ZONES_BY_OWNER",
"MAX_REUSABLE_DELEGATION_SETS_BY_OWNER",
"MAX_TRAFFIC_POLICIES_BY_OWNER",
"MAX_TRAFFIC_POLICY_INSTANCES_BY_OWNER",
]
}
}
impl AsRef<str> for AccountLimitType {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>The information for a change request.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct ChangeBatch {
/// <p> <i>Optional:</i> Any comments you want to include about a change batch request.</p>
pub comment: std::option::Option<std::string::String>,
/// <p>Information about the changes to make to the record sets.</p>
pub changes: std::option::Option<std::vec::Vec<crate::model::Change>>,
}
impl ChangeBatch {
/// <p> <i>Optional:</i> Any comments you want to include about a change batch request.</p>
pub fn comment(&self) -> std::option::Option<&str> {
self.comment.as_deref()
}
/// <p>Information about the changes to make to the record sets.</p>
pub fn changes(&self) -> std::option::Option<&[crate::model::Change]> {
self.changes.as_deref()
}
}
impl std::fmt::Debug for ChangeBatch {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("ChangeBatch");
formatter.field("comment", &self.comment);
formatter.field("changes", &self.changes);
formatter.finish()
}
}
/// See [`ChangeBatch`](crate::model::ChangeBatch)
pub mod change_batch {
/// A builder for [`ChangeBatch`](crate::model::ChangeBatch)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) comment: std::option::Option<std::string::String>,
pub(crate) changes: std::option::Option<std::vec::Vec<crate::model::Change>>,
}
impl Builder {
/// <p> <i>Optional:</i> Any comments you want to include about a change batch request.</p>
pub fn comment(mut self, input: impl Into<std::string::String>) -> Self {
self.comment = Some(input.into());
self
}
/// <p> <i>Optional:</i> Any comments you want to include about a change batch request.</p>
pub fn set_comment(mut self, input: std::option::Option<std::string::String>) -> Self {
self.comment = input;
self
}
/// Appends an item to `changes`.
///
/// To override the contents of this collection use [`set_changes`](Self::set_changes).
///
/// <p>Information about the changes to make to the record sets.</p>
pub fn changes(mut self, input: crate::model::Change) -> Self {
let mut v = self.changes.unwrap_or_default();
v.push(input);
self.changes = Some(v);
self
}
/// <p>Information about the changes to make to the record sets.</p>
pub fn set_changes(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::Change>>,
) -> Self {
self.changes = input;
self
}
/// Consumes the builder and constructs a [`ChangeBatch`](crate::model::ChangeBatch)
pub fn build(self) -> crate::model::ChangeBatch {
crate::model::ChangeBatch {
comment: self.comment,
changes: self.changes,
}
}
}
}
impl ChangeBatch {
/// Creates a new builder-style object to manufacture [`ChangeBatch`](crate::model::ChangeBatch)
pub fn builder() -> crate::model::change_batch::Builder {
crate::model::change_batch::Builder::default()
}
}
/// <p>The information for each resource record set that you want to change.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct Change {
/// <p>The action to perform:</p>
/// <ul>
/// <li> <p> <code>CREATE</code>: Creates a resource record set that has the specified values.</p> </li>
/// <li> <p> <code>DELETE</code>: Deletes a existing resource record set.</p> <important>
/// <p>To delete the resource record set that is associated with a traffic policy instance, use <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_DeleteTrafficPolicyInstance.html">DeleteTrafficPolicyInstance</a>. Amazon Route 53 will delete the resource record set automatically. If you delete the resource record set by using <code>ChangeResourceRecordSets</code>, Route 53 doesn't automatically delete the traffic policy instance, and you'll continue to be charged for it even though it's no longer in use. </p>
/// </important> </li>
/// <li> <p> <code>UPSERT</code>: If a resource record set doesn't already exist, Route 53 creates it. If a resource record set does exist, Route 53 updates it with the values in the request.</p> </li>
/// </ul>
pub action: std::option::Option<crate::model::ChangeAction>,
/// <p>Information about the resource record set to create, delete, or update.</p>
pub resource_record_set: std::option::Option<crate::model::ResourceRecordSet>,
}
impl Change {
/// <p>The action to perform:</p>
/// <ul>
/// <li> <p> <code>CREATE</code>: Creates a resource record set that has the specified values.</p> </li>
/// <li> <p> <code>DELETE</code>: Deletes a existing resource record set.</p> <important>
/// <p>To delete the resource record set that is associated with a traffic policy instance, use <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_DeleteTrafficPolicyInstance.html">DeleteTrafficPolicyInstance</a>. Amazon Route 53 will delete the resource record set automatically. If you delete the resource record set by using <code>ChangeResourceRecordSets</code>, Route 53 doesn't automatically delete the traffic policy instance, and you'll continue to be charged for it even though it's no longer in use. </p>
/// </important> </li>
/// <li> <p> <code>UPSERT</code>: If a resource record set doesn't already exist, Route 53 creates it. If a resource record set does exist, Route 53 updates it with the values in the request.</p> </li>
/// </ul>
pub fn action(&self) -> std::option::Option<&crate::model::ChangeAction> {
self.action.as_ref()
}
/// <p>Information about the resource record set to create, delete, or update.</p>
pub fn resource_record_set(&self) -> std::option::Option<&crate::model::ResourceRecordSet> {
self.resource_record_set.as_ref()
}
}
impl std::fmt::Debug for Change {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("Change");
formatter.field("action", &self.action);
formatter.field("resource_record_set", &self.resource_record_set);
formatter.finish()
}
}
/// See [`Change`](crate::model::Change)
pub mod change {
/// A builder for [`Change`](crate::model::Change)
#[non_exhaustive]
#[derive(std::default::Default, std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Builder {
pub(crate) action: std::option::Option<crate::model::ChangeAction>,
pub(crate) resource_record_set: std::option::Option<crate::model::ResourceRecordSet>,
}
impl Builder {
/// <p>The action to perform:</p>
/// <ul>
/// <li> <p> <code>CREATE</code>: Creates a resource record set that has the specified values.</p> </li>
/// <li> <p> <code>DELETE</code>: Deletes a existing resource record set.</p> <important>
/// <p>To delete the resource record set that is associated with a traffic policy instance, use <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_DeleteTrafficPolicyInstance.html">DeleteTrafficPolicyInstance</a>. Amazon Route 53 will delete the resource record set automatically. If you delete the resource record set by using <code>ChangeResourceRecordSets</code>, Route 53 doesn't automatically delete the traffic policy instance, and you'll continue to be charged for it even though it's no longer in use. </p>
/// </important> </li>
/// <li> <p> <code>UPSERT</code>: If a resource record set doesn't already exist, Route 53 creates it. If a resource record set does exist, Route 53 updates it with the values in the request.</p> </li>
/// </ul>
pub fn action(mut self, input: crate::model::ChangeAction) -> Self {
self.action = Some(input);
self
}
/// <p>The action to perform:</p>
/// <ul>
/// <li> <p> <code>CREATE</code>: Creates a resource record set that has the specified values.</p> </li>
/// <li> <p> <code>DELETE</code>: Deletes a existing resource record set.</p> <important>
/// <p>To delete the resource record set that is associated with a traffic policy instance, use <a href="https://docs.aws.amazon.com/Route53/latest/APIReference/API_DeleteTrafficPolicyInstance.html">DeleteTrafficPolicyInstance</a>. Amazon Route 53 will delete the resource record set automatically. If you delete the resource record set by using <code>ChangeResourceRecordSets</code>, Route 53 doesn't automatically delete the traffic policy instance, and you'll continue to be charged for it even though it's no longer in use. </p>
/// </important> </li>
/// <li> <p> <code>UPSERT</code>: If a resource record set doesn't already exist, Route 53 creates it. If a resource record set does exist, Route 53 updates it with the values in the request.</p> </li>
/// </ul>
pub fn set_action(
mut self,
input: std::option::Option<crate::model::ChangeAction>,
) -> Self {
self.action = input;
self
}
/// <p>Information about the resource record set to create, delete, or update.</p>
pub fn resource_record_set(mut self, input: crate::model::ResourceRecordSet) -> Self {
self.resource_record_set = Some(input);
self
}
/// <p>Information about the resource record set to create, delete, or update.</p>
pub fn set_resource_record_set(
mut self,
input: std::option::Option<crate::model::ResourceRecordSet>,
) -> Self {
self.resource_record_set = input;
self
}
/// Consumes the builder and constructs a [`Change`](crate::model::Change)
pub fn build(self) -> crate::model::Change {
crate::model::Change {
action: self.action,
resource_record_set: self.resource_record_set,
}
}
}
}
impl Change {
/// Creates a new builder-style object to manufacture [`Change`](crate::model::Change)
pub fn builder() -> crate::model::change::Builder {
crate::model::change::Builder::default()
}
}
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum ChangeAction {
#[allow(missing_docs)] // documentation missing in model
Create,
#[allow(missing_docs)] // documentation missing in model
Delete,
#[allow(missing_docs)] // documentation missing in model
Upsert,
/// Unknown contains new variants that have been added since this code was generated.
Unknown(String),
}
impl std::convert::From<&str> for ChangeAction {
fn from(s: &str) -> Self {
match s {
"CREATE" => ChangeAction::Create,
"DELETE" => ChangeAction::Delete,
"UPSERT" => ChangeAction::Upsert,
other => ChangeAction::Unknown(other.to_owned()),
}
}
}
impl std::str::FromStr for ChangeAction {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(ChangeAction::from(s))
}
}
impl ChangeAction {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
ChangeAction::Create => "CREATE",
ChangeAction::Delete => "DELETE",
ChangeAction::Upsert => "UPSERT",
ChangeAction::Unknown(s) => s.as_ref(),
}
}
/// Returns all the `&str` values of the enum members.
pub fn values() -> &'static [&'static str] {
&["CREATE", "DELETE", "UPSERT"]
}
}
impl AsRef<str> for ChangeAction {
fn as_ref(&self) -> &str {
self.as_str()
}
}