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
|
Description: omitting Timeout annotation in the tests, as it is a feature of a
not yet Debian-packaged version of junit5
Author: Pierre Gruet <pgt@debian.org>
Forwarded: not-needed
Last-Update: 2022-06-18
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/ClientRequestTimeoutTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/ClientRequestTimeoutTest.java
@@ -38,7 +38,6 @@
import org.apache.zookeeper.test.ClientBase;
import org.apache.zookeeper.test.ClientBase.CountdownWatcher;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
public class ClientRequestTimeoutTest extends QuorumPeerTestBase {
@@ -50,7 +49,6 @@
private ClientCnxn.Packet capturedPacket = null;
@Test
- @Timeout(value = 120)
public void testClientRequestTimeout() throws Exception {
int requestTimeOut = 15000;
System.setProperty("zookeeper.request.timeout", Integer.toString(requestTimeOut));
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/RemoveWatchesCmdTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/RemoveWatchesCmdTest.java
@@ -32,7 +32,6 @@
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -68,7 +67,6 @@
* local=false
*/
@Test
- @Timeout(value = 30)
public void testRemoveWatchesWithNoPassedOptions() throws Exception {
List<EventType> expectedEvents = new ArrayList<>();
expectedEvents.add(EventType.ChildWatchRemoved);
@@ -102,7 +100,6 @@
* Test verifies deletion of NodeDataChanged watches
*/
@Test
- @Timeout(value = 30)
public void testRemoveNodeDataChangedWatches() throws Exception {
LOG.info("Adding data watcher using getData()");
List<EventType> expectedEvents = new ArrayList<>();
@@ -128,7 +125,6 @@
* Test verifies deletion of NodeCreated data watches
*/
@Test
- @Timeout(value = 30)
public void testRemoveNodeCreatedWatches() throws Exception {
List<EventType> expectedEvents = new ArrayList<>();
expectedEvents.add(EventType.DataWatchRemoved);
@@ -160,7 +156,6 @@
* Test verifies deletion of NodeChildrenChanged watches
*/
@Test
- @Timeout(value = 30)
public void testRemoveNodeChildrenChangedWatches() throws Exception {
List<EventType> expectedEvents = new ArrayList<>();
expectedEvents.add(EventType.ChildWatchRemoved);
@@ -182,7 +177,6 @@
* Test verifies deletion of NodeDeleted watches
*/
@Test
- @Timeout(value = 30)
public void testRemoveNodeDeletedWatches() throws Exception {
LOG.info("Adding NodeDeleted watcher");
List<EventType> expectedEvents = new ArrayList<>();
@@ -214,7 +208,6 @@
* Test verifies deletion of any watches
*/
@Test
- @Timeout(value = 30)
public void testRemoveAnyWatches() throws Exception {
verifyRemoveAnyWatches(false);
}
@@ -224,7 +217,6 @@
* connection
*/
@Test
- @Timeout(value = 30)
public void testRemoveWatchesLocallyWhenNoServerConnection() throws Exception {
verifyRemoveAnyWatches(true);
}
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/RemoveWatchesTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/RemoveWatchesTest.java
@@ -51,7 +51,6 @@
import org.apache.zookeeper.test.ClientBase;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeEach;
-import org.junit.jupiter.api.Timeout;
import org.junit.jupiter.params.ParameterizedTest;
import org.junit.jupiter.params.provider.ValueSource;
import org.slf4j.Logger;
@@ -176,7 +175,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveSingleWatcher(boolean useAsync) throws Exception {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.EPHEMERAL);
zk1.create("/node2", null, Ids.OPEN_ACL_UNSAFE, CreateMode.EPHEMERAL);
@@ -209,7 +207,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testMultipleDataWatchers(boolean useAsync) throws IOException, InterruptedException, KeeperException {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.EPHEMERAL);
MyWatcher w1 = new MyWatcher("/node1", 1);
@@ -240,7 +237,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testMultipleChildWatchers(boolean useAsync) throws IOException, InterruptedException, KeeperException {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
MyWatcher w1 = new MyWatcher("/node1", 1);
@@ -276,7 +272,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveAllWatchers(boolean useAsync) throws IOException, InterruptedException, KeeperException {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
MyWatcher w1 = new MyWatcher("/node1", 2);
@@ -302,7 +297,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveAllDataWatchers(boolean useAsync) throws IOException, InterruptedException, KeeperException {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
MyWatcher w1 = new MyWatcher("/node1", 1);
@@ -345,7 +339,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveAllChildWatchers(boolean useAsync) throws IOException, InterruptedException, KeeperException {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
MyWatcher w1 = new MyWatcher("/node1", 1);
@@ -389,7 +382,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveAllPersistentWatchers(boolean useAsync) throws InterruptedException, KeeperException {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
BlockingDeque<WatchedEvent> persistentEvents1 = new LinkedBlockingDeque<>();
@@ -434,7 +426,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveAllPersistentRecursiveWatchers(boolean useAsync) throws InterruptedException, KeeperException {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
BlockingDeque<WatchedEvent> recursiveEvents1 = new LinkedBlockingDeque<>();
@@ -477,7 +468,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testNoWatcherException(boolean useAsync) throws IOException, InterruptedException, KeeperException {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
MyWatcher w1 = new MyWatcher("/node1", 2);
@@ -506,7 +496,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveAnyDataWatcher(boolean useAsync) throws Exception {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
MyWatcher w1 = new MyWatcher("/node1", 1);
@@ -533,7 +522,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveAnyChildWatcher(boolean useAsync) throws Exception {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
MyWatcher w1 = new MyWatcher("/node1", 2);
@@ -559,7 +547,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveWatcherWhenNoConnection(boolean useAsync) throws Exception {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
MyWatcher w1 = new MyWatcher("/node1", 2);
@@ -590,7 +577,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testManyPreNodeWatchers(boolean useAsync) throws Exception {
int count = 50;
List<MyWatcher> wList = new ArrayList<>(count);
@@ -619,7 +605,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testManyChildWatchers(boolean useAsync) throws Exception {
int count = 50;
List<MyWatcher> wList = new ArrayList<>(count);
@@ -655,7 +640,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testManyDataWatchers(boolean useAsync) throws Exception {
int count = 50;
List<MyWatcher> wList = new ArrayList<>(count);
@@ -687,7 +671,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testManyWatchersWhenNoConnection(boolean useAsync) throws Exception {
int count = 3;
List<MyWatcher> wList = new ArrayList<>(count);
@@ -734,7 +717,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testChRootRemoveWatcher(boolean useAsync) throws Exception {
// creating the subtree for chRoot clients.
String chRoot = "/appsX";
@@ -790,7 +772,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testNoWatcherServerException(boolean useAsync) throws KeeperException, InterruptedException, IOException, TimeoutException {
CountdownWatcher watcher = new CountdownWatcher();
ZooKeeper zk = spy(new ZooKeeper(hostPort, CONNECTION_TIMEOUT, watcher));
@@ -809,7 +790,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveAllNoWatcherException(boolean useAsync) throws IOException, InterruptedException, KeeperException {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
removeAllWatches(zk2, "/node1", WatcherType.Any, false, Code.NOWATCHER, useAsync);
@@ -820,7 +800,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 30)
public void testNullWatcherReference(boolean useAsync) throws Exception {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
try {
@@ -841,7 +820,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveWhenMultipleDataWatchesOnAPath(boolean useAsync) throws Exception {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
final CountDownLatch dataWatchCount = new CountDownLatch(1);
@@ -876,7 +854,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveWhenMultipleChildWatchesOnAPath(boolean useAsync) throws Exception {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
final CountDownLatch childWatchCount = new CountDownLatch(1);
@@ -910,7 +887,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveWhenMultiplePersistentWatchesOnAPath(boolean useAsync) throws Exception {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
@@ -934,7 +910,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveWhenMultiplePersistentRecursiveWatchesOnAPath(boolean useAsync) throws Exception {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
@@ -958,7 +933,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemovePersistentWatchesOnAPathPartially(boolean useAsync) throws Exception {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
@@ -988,7 +962,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveAllDataWatchesOnAPath(boolean useAsync) throws Exception {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
@@ -1033,7 +1006,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveAllChildWatchesOnAPath(boolean useAsync) throws Exception {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
@@ -1076,7 +1048,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveAllPersistentWatchesOnAPath(boolean useAsync) throws Exception {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
@@ -1116,7 +1087,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveAllPersistentWatchesOnAPathPartially(boolean useAsync) throws Exception {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
@@ -1145,7 +1115,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveAllPersistentRecursiveWatchesOnAPath(boolean useAsync) throws Exception {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
@@ -1187,7 +1156,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testRemoveAllWatchesOnAPath(boolean useAsync) throws Exception {
zk1.create("/node1", null, Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/client/ZKClientConfigTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/client/ZKClientConfigTest.java
@@ -40,7 +40,6 @@
import org.apache.zookeeper.server.quorum.QuorumPeerConfig.ConfigException;
import org.junit.jupiter.api.BeforeAll;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
public class ZKClientConfigTest {
@@ -54,7 +53,6 @@
}
@Test
- @Timeout(value = 10)
public void testDefaultConfiguration() {
Map<String, String> properties = new HashMap<>();
properties.put(ZK_SASL_CLIENT_USERNAME, "zookeeper1");
@@ -93,7 +91,6 @@
}
@Test
- @Timeout(value = 10)
public void testSystemPropertyValue() {
String clientName = "zookeeper1";
System.setProperty(ZK_SASL_CLIENT_USERNAME, clientName);
@@ -108,7 +105,6 @@
}
@Test
- @Timeout(value = 10)
public void testReadConfigurationFile() throws IOException, ConfigException {
File file = File.createTempFile("clientConfig", ".conf", testData);
file.deleteOnExit();
@@ -139,7 +135,6 @@
}
@Test
- @Timeout(value = 10)
public void testSetConfiguration() {
ZKClientConfig conf = new ZKClientConfig();
String defaultValue = conf.getProperty(ZKClientConfig.ENABLE_CLIENT_SASL_KEY, ZKClientConfig.ENABLE_CLIENT_SASL_DEFAULT);
@@ -152,7 +147,6 @@
}
@Test
- @Timeout(value = 10)
public void testIntegerRetrievalFromProperty() {
ZKClientConfig conf = new ZKClientConfig();
String prop = "UnSetProperty" + System.currentTimeMillis();
@@ -186,7 +180,6 @@
}
@Test
- @Timeout(value = 10)
public void testIntegerRetrievalFromHexadecimalProperty() {
int hexaValue = 0x3000000;
String wrongValue = "0xwel";
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/common/X509UtilTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/common/X509UtilTest.java
@@ -57,7 +57,6 @@
import org.apache.zookeeper.client.ZKClientConfig;
import org.apache.zookeeper.server.ServerCnxnFactory;
import org.junit.jupiter.api.AfterEach;
-import org.junit.jupiter.api.Timeout;
import org.junit.jupiter.params.ParameterizedTest;
import org.junit.jupiter.params.provider.MethodSource;
@@ -101,7 +100,6 @@
@ParameterizedTest
@MethodSource("data")
- @Timeout(value = 5)
public void testCreateSSLContextWithoutCustomProtocol(
X509KeyType caKeyType, X509KeyType certKeyType, String keyPassword, Integer paramIndex)
throws Exception {
@@ -126,7 +124,6 @@
@ParameterizedTest
@MethodSource("data")
- @Timeout(value = 5)
public void testCreateSSLContextWithCustomProtocol(
X509KeyType caKeyType, X509KeyType certKeyType, String keyPassword, Integer paramIndex)
throws Exception {
@@ -139,7 +136,6 @@
@ParameterizedTest
@MethodSource("data")
- @Timeout(value = 5)
public void testCreateSSLContextWithoutKeyStoreLocation(
X509KeyType caKeyType, X509KeyType certKeyType, String keyPassword, Integer paramIndex)
throws Exception {
@@ -150,7 +146,6 @@
@ParameterizedTest
@MethodSource("data")
- @Timeout(value = 5)
public void testCreateSSLContextWithoutKeyStorePassword(
X509KeyType caKeyType, X509KeyType certKeyType, String keyPassword, Integer paramIndex)
throws Exception {
@@ -166,7 +161,6 @@
@ParameterizedTest
@MethodSource("data")
- @Timeout(value = 5)
public void testCreateSSLContext_withKeyStorePasswordFromFile(final X509KeyType caKeyType,
final X509KeyType certKeyType,
final String keyPassword,
@@ -181,7 +175,6 @@
@ParameterizedTest
@MethodSource("data")
- @Timeout(value = 5)
public void testCreateSSLContext_withTrustStorePasswordFromFile(final X509KeyType caKeyType,
final X509KeyType certKeyType,
final String keyPassword,
@@ -195,7 +188,6 @@
@ParameterizedTest
@MethodSource("data")
- @Timeout(value = 5)
public void testCreateSSLContext_withWrongKeyStorePasswordFromFile(final X509KeyType caKeyType,
final X509KeyType certKeyType,
final String keyPassword,
@@ -206,7 +198,6 @@
@ParameterizedTest
@MethodSource("data")
- @Timeout(value = 5)
public void testCreateSSLContext_withWrongTrustStorePasswordFromFile(final X509KeyType caKeyType,
final X509KeyType certKeyType,
final String keyPassword,
@@ -217,7 +208,6 @@
@ParameterizedTest
@MethodSource("data")
- @Timeout(value = 5)
public void testCreateSSLContextWithCustomCipherSuites(
X509KeyType caKeyType, X509KeyType certKeyType, String keyPassword, Integer paramIndex)
throws Exception {
@@ -231,7 +221,6 @@
// possible
@ParameterizedTest
@MethodSource("data")
- @Timeout(value = 5)
public void testCRLEnabled(
X509KeyType caKeyType, X509KeyType certKeyType, String keyPassword, Integer paramIndex)
throws Exception {
@@ -245,7 +234,6 @@
@ParameterizedTest
@MethodSource("data")
- @Timeout(value = 5)
public void testCRLDisabled(
X509KeyType caKeyType, X509KeyType certKeyType, String keyPassword, Integer paramIndex)
throws Exception {
@@ -258,7 +246,6 @@
@ParameterizedTest
@MethodSource("data")
- @Timeout(value = 5)
public void testOCSPEnabled(
X509KeyType caKeyType, X509KeyType certKeyType, String keyPassword, Integer paramIndex)
throws Exception {
@@ -272,7 +259,6 @@
@ParameterizedTest
@MethodSource("data")
- @Timeout(value = 5)
public void testCreateSSLSocket(
X509KeyType caKeyType, X509KeyType certKeyType, String keyPassword, Integer paramIndex)
throws Exception {
@@ -284,7 +270,6 @@
@ParameterizedTest
@MethodSource("data")
- @Timeout(value = 5)
public void testCreateSSLServerSocketWithoutPort(
X509KeyType caKeyType, X509KeyType certKeyType, String keyPassword, Integer paramIndex)
throws Exception {
@@ -297,7 +282,6 @@
@ParameterizedTest
@MethodSource("data")
- @Timeout(value = 5)
public void testCreateSSLServerSocketWithPort(
X509KeyType caKeyType, X509KeyType certKeyType, String keyPassword, Integer paramIndex)
throws Exception {
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/common/ZKConfigTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/common/ZKConfigTest.java
@@ -21,7 +21,6 @@
import static org.junit.jupiter.api.Assertions.assertEquals;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
public class ZKConfigTest {
@@ -34,7 +33,6 @@
// property is not set we should get the default value
@Test
- @Timeout(value = 10)
public void testBooleanRetrievalFromPropertyDefault() {
ZKConfig conf = new ZKConfig();
String prop = "UnSetProperty" + System.currentTimeMillis();
@@ -45,7 +43,6 @@
// property is set to an valid boolean, we should get the set value
@Test
- @Timeout(value = 10)
public void testBooleanRetrievalFromProperty() {
boolean value = true;
boolean defaultValue = false;
@@ -57,7 +54,6 @@
// property is set but with white spaces in the beginning
@Test
- @Timeout(value = 10)
public void testBooleanRetrievalFromPropertyWithWhitespacesInBeginning() {
boolean value = true;
boolean defaultValue = false;
@@ -69,7 +65,6 @@
// property is set but with white spaces at the end
@Test
- @Timeout(value = 10)
public void testBooleanRetrievalFromPropertyWithWhitespacesAtEnd() {
boolean value = true;
boolean defaultValue = false;
@@ -81,7 +76,6 @@
// property is set but with white spaces at the beginning and the end
@Test
- @Timeout(value = 10)
public void testBooleanRetrievalFromPropertyWithWhitespacesAtBeginningAndEnd() {
boolean value = true;
boolean defaultValue = false;
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/CreateContainerTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/CreateContainerTest.java
@@ -48,7 +48,6 @@
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
public class CreateContainerTest extends ClientBase {
@@ -82,14 +81,12 @@
}
@Test
- @Timeout(value = 30)
public void testCreate() throws KeeperException, InterruptedException {
createNoStatVerifyResult("/foo");
createNoStatVerifyResult("/foo/child");
}
@Test
- @Timeout(value = 30)
public void testCreateWithStat() throws KeeperException, InterruptedException {
Stat stat = createWithStatVerifyResult("/foo");
Stat childStat = createWithStatVerifyResult("/foo/child");
@@ -99,7 +96,6 @@
@SuppressWarnings("ConstantConditions")
@Test
- @Timeout(value = 30)
public void testCreateWithNullStat() throws KeeperException, InterruptedException {
final String name = "/foo";
assertNull(zk.exists(name, false));
@@ -113,7 +109,6 @@
}
@Test
- @Timeout(value = 30)
public void testSimpleDeletion() throws KeeperException, InterruptedException {
zk.create("/foo", new byte[0], ZooDefs.Ids.OPEN_ACL_UNSAFE, CreateMode.CONTAINER);
zk.create("/foo/bar", new byte[0], ZooDefs.Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
@@ -127,7 +122,6 @@
}
@Test
- @Timeout(value = 30)
public void testMultiWithContainerSimple() throws KeeperException, InterruptedException {
Op createContainer = Op.create("/foo", new byte[0], ZooDefs.Ids.OPEN_ACL_UNSAFE, CreateMode.CONTAINER);
zk.multi(Collections.singletonList(createContainer));
@@ -137,7 +131,6 @@
}
@Test
- @Timeout(value = 30)
public void testMultiWithContainer() throws KeeperException, InterruptedException {
Op createContainer = Op.create("/foo", new byte[0], ZooDefs.Ids.OPEN_ACL_UNSAFE, CreateMode.CONTAINER);
Op createChild = Op.create("/foo/bar", new byte[0], ZooDefs.Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
@@ -166,7 +159,6 @@
}
@Test
- @Timeout(value = 30)
public void testSimpleDeletionAsync() throws KeeperException, InterruptedException {
final CountDownLatch latch = new CountDownLatch(1);
AsyncCallback.Create2Callback cb = (rc, path, ctx, name, stat) -> {
@@ -186,7 +178,6 @@
}
@Test
- @Timeout(value = 30)
public void testCascadingDeletion() throws KeeperException, InterruptedException {
zk.create("/foo", new byte[0], ZooDefs.Ids.OPEN_ACL_UNSAFE, CreateMode.CONTAINER);
zk.create("/foo/bar", new byte[0], ZooDefs.Ids.OPEN_ACL_UNSAFE, CreateMode.CONTAINER);
@@ -204,7 +195,6 @@
}
@Test
- @Timeout(value = 30)
public void testFalseEmpty() throws KeeperException, InterruptedException {
zk.create("/foo", new byte[0], ZooDefs.Ids.OPEN_ACL_UNSAFE, CreateMode.CONTAINER);
zk.create("/foo/bar", new byte[0], ZooDefs.Ids.OPEN_ACL_UNSAFE, CreateMode.PERSISTENT);
@@ -221,7 +211,6 @@
}
@Test
- @Timeout(value = 30)
public void testMaxPerMinute() throws InterruptedException {
final BlockingQueue<String> queue = new LinkedBlockingQueue<>();
RequestProcessor processor = new RequestProcessor() {
@@ -263,7 +252,6 @@
}
@Test
- @Timeout(value = 30)
public void testMaxNeverUsedInterval() throws KeeperException, InterruptedException {
zk.create("/foo", new byte[0], ZooDefs.Ids.OPEN_ACL_UNSAFE, CreateMode.CONTAINER);
AtomicLong elapsed = new AtomicLong(0);
@@ -291,7 +279,6 @@
}
@Test
- @Timeout(value = 30)
public void testZeroMaxNeverUsedInterval() throws KeeperException, InterruptedException {
zk.create("/foo", new byte[0], ZooDefs.Ids.OPEN_ACL_UNSAFE, CreateMode.CONTAINER);
AtomicInteger deletesQty = new AtomicInteger(0);
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/DataTreeTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/DataTreeTest.java
@@ -53,7 +53,6 @@
import org.apache.zookeeper.txn.CreateTxn;
import org.apache.zookeeper.txn.TxnHeader;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -66,7 +65,6 @@
* removing the session related ephemerals from DataTree structure
*/
@Test
- @Timeout(value = 60)
public void testDumpEphemerals() throws Exception {
int count = 1000;
long session = 1000;
@@ -111,7 +109,6 @@
}
@Test
- @Timeout(value = 60)
public void testRootWatchTriggered() throws Exception {
DataTree dt = new DataTree();
@@ -133,7 +130,6 @@
* For ZOOKEEPER-1046 test if cversion is getting incremented correctly.
*/
@Test
- @Timeout(value = 60)
public void testIncrementCversion() throws Exception {
try {
// digestCalculator gets initialized for the new DataTree constructor based on the system property
@@ -227,7 +223,6 @@
}
@Test
- @Timeout(value = 60)
public void testPathTrieClearOnDeserialize() throws Exception {
//Create a DataTree with quota nodes so PathTrie get updated
@@ -266,7 +261,6 @@
* This test verifies the fix that we should not hold ACL cache during dumping aclcache to snapshots
*/
@Test
- @Timeout(value = 60)
public void testSerializeDoesntLockACLCacheWhileWriting() throws Exception {
DataTree tree = new DataTree();
tree.createNode("/marker", new byte[] { 42 }, null, -1, 1, 1, 1);
@@ -311,7 +305,6 @@
/* ZOOKEEPER-3531 - similarly for aclCache.deserialize, we should not hold lock either
*/
@Test
- @Timeout(value = 60)
public void testDeserializeDoesntLockACLCacheWhileReading() throws Exception {
DataTree tree = new DataTree();
tree.createNode("/marker", new byte[] { 42 }, null, -1, 1, 1, 1);
@@ -369,7 +362,6 @@
* the DataNode lock while calling OutputArchive.writeRecord.
*/
@Test
- @Timeout(value = 60)
public void testSerializeDoesntLockDataNodeWhileWriting() throws Exception {
DataTree tree = new DataTree();
tree.createNode("/marker", new byte[] { 42 }, null, -1, 1, 1, 1);
@@ -418,7 +410,6 @@
}
@Test
- @Timeout(value = 60)
public void testReconfigACLClearOnDeserialize() throws Exception {
DataTree tree = new DataTree();
// simulate the upgrading scenario, where the reconfig znode
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/NIOServerCnxnTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/NIOServerCnxnTest.java
@@ -32,7 +32,6 @@
import org.apache.zookeeper.server.quorum.BufferStats;
import org.apache.zookeeper.test.ClientBase;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -44,7 +43,6 @@
* Test operations on ServerCnxn after socket closure.
*/
@Test
- @Timeout(value = 60)
public void testOperationsAfterCnxnClose() throws IOException, InterruptedException, KeeperException {
final ZooKeeper zk = createClient();
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/NettyServerCnxnTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/NettyServerCnxnTest.java
@@ -66,7 +66,6 @@
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
import org.mockito.Mockito;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -106,7 +105,6 @@
* @see <a href="https://issues.jboss.org/browse/NETTY-412">NETTY-412</a>
*/
@Test
- @Timeout(value = 40)
public void testSendCloseSession() throws Exception {
assertTrue(serverFactory instanceof NettyServerCnxnFactory, "Didn't instantiate ServerCnxnFactory with NettyServerCnxnFactory!");
@@ -146,7 +144,6 @@
* connection fails.
*/
@Test
- @Timeout(value = 40)
public void testMaxConnectionPerIpSurpased() {
assertTrue(serverFactory instanceof NettyServerCnxnFactory, "Did not instantiate ServerCnxnFactory with NettyServerCnxnFactory!");
assertThrows(ProtocolException.class, () -> {
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/SessionTrackerTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/SessionTrackerTest.java
@@ -34,7 +34,6 @@
import org.apache.zookeeper.server.SessionTrackerImpl.SessionImpl;
import org.apache.zookeeper.test.ClientBase;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
/**
* Testing zk client session logic in sessiontracker
@@ -51,7 +50,6 @@
* the session expiration.
*/
@Test
- @Timeout(value = 20)
public void testAddSessionAfterSessionExpiry() throws Exception {
RequestThrottler.setMaxRequests(0);
ZooKeeperServer zks = setupSessionTracker();
@@ -89,7 +87,6 @@
* after session expiration by the session tracker
*/
@Test
- @Timeout(value = 20)
public void testCloseSessionRequestAfterSessionExpiry() throws Exception {
ZooKeeperServer zks = setupSessionTracker();
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/ZooKeeperServerMainTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/ZooKeeperServerMainTest.java
@@ -49,7 +49,6 @@
import org.apache.zookeeper.server.quorum.QuorumPeerConfig.ConfigException;
import org.apache.zookeeper.test.ClientBase;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -178,7 +177,6 @@
* writing transaction log), ZooKeeper is still available.
*/
@Test
- @Timeout(value = 30)
public void testNonRecoverableError() throws Exception {
ClientBase.setupTestEnv();
@@ -229,7 +227,6 @@
* This test will fail if it is executed as root user.
*/
@Test
- @Timeout(value = 30)
public void testReadOnlySnapshotDir() throws Exception {
ClientBase.setupTestEnv();
final int CLIENT_PORT = PortAssignment.unique();
@@ -268,7 +265,6 @@
* This test will fail if it is executed as root user.
*/
@Test
- @Timeout(value = 30)
public void testReadOnlyTxnLogDir() throws Exception {
ClientBase.setupTestEnv();
final int CLIENT_PORT = PortAssignment.unique();
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/ZooKeeperServerMaxCnxnsTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/ZooKeeperServerMaxCnxnsTest.java
@@ -33,7 +33,6 @@
import org.apache.zookeeper.test.ClientBase.CountdownWatcher;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -52,14 +51,12 @@
*/
@Test
- @Timeout(value = 120)
public void testMaxZooKeeperClientsWithNIOServerCnxnFactory() throws Exception {
String serverCnxnFactory = "org.apache.zookeeper.server.NIOServerCnxnFactory";
testMaxZooKeeperClients(serverCnxnFactory);
}
@Test
- @Timeout(value = 120)
public void testMaxZooKeeperClientsWithNettyServerCnxnFactory() throws Exception {
String serverCnxnFactory = "org.apache.zookeeper.server.NettyServerCnxnFactory";
testMaxZooKeeperClients(serverCnxnFactory);
@@ -177,4 +174,4 @@
}
}
}
-}
\ No newline at end of file
+}
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/ZooKeeperServerStartupTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/ZooKeeperServerStartupTest.java
@@ -35,7 +35,6 @@
import org.apache.zookeeper.test.ClientBase.CountdownWatcher;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -77,7 +76,6 @@
* https://issues.apache.org/jira/browse/ZOOKEEPER-2383
*/
@Test
- @Timeout(value = 30)
public void testClientConnectionRequestDuringStartupWithNIOServerCnxn() throws Exception {
tmpDir = ClientBase.createTmpDir();
ClientBase.setupTestEnv();
@@ -108,7 +106,6 @@
* https://issues.apache.org/jira/browse/ZOOKEEPER-2383
*/
@Test
- @Timeout(value = 30)
public void testClientConnectionRequestDuringStartupWithNettyServerCnxn() throws Exception {
tmpDir = ClientBase.createTmpDir();
ClientBase.setupTestEnv();
@@ -148,7 +145,6 @@
* https://issues.apache.org/jira/browse/ZOOKEEPER-2383
*/
@Test
- @Timeout(value = 30)
public void testFourLetterWords() throws Exception {
startSimpleZKServer(startupDelayLatch);
verify("conf", ZK_NOT_SERVING);
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/ZooKeeperThreadTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/ZooKeeperThreadTest.java
@@ -23,7 +23,6 @@
import java.util.concurrent.TimeUnit;
import org.apache.zookeeper.ZKTestCase;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
public class ZooKeeperThreadTest extends ZKTestCase {
@@ -73,7 +72,6 @@
* Test verifies uncaught exception handling of ZooKeeperThread
*/
@Test
- @Timeout(value = 30)
public void testUncaughtException() throws Exception {
MyThread t1 = new MyThread("Test-Thread");
t1.start();
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/CommitProcessorConcurrencyTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/CommitProcessorConcurrencyTest.java
@@ -49,7 +49,6 @@
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -419,7 +418,6 @@
* processed.
*/
@Test
- @Timeout(value = 1)
public void noStarvationOfNonLocalCommittedRequestsTest() throws Exception {
final String path = "/noStarvationOfCommittedRequests";
processor.queuedRequests = new MockRequestsQueue();
@@ -522,7 +520,6 @@
* session queue but it sees a commit for a request that belongs to the previous connection.
*/
@Test
- @Timeout(value = 5)
public void noCrashOnCommittedRequestsOfUnseenRequestTest() throws Exception {
final String path = "/noCrash/OnCommittedRequests/OfUnseenRequestTest";
final int numberofReads = 10;
@@ -584,7 +581,6 @@
* We should commit the requests according to the order we receive from the leader, i.e., wait for the relevant commit.
*/
@Test
- @Timeout(value = 5)
public void noCrashOnOutofOrderCommittedRequestTest() throws Exception {
final String path = "/noCrash/OnCommittedRequests/OfUnSeenRequestTest";
final int sessionid = 0x123456;
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/DIFFSyncConsistencyTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/DIFFSyncConsistencyTest.java
@@ -41,7 +41,6 @@
import org.apache.zookeeper.test.ClientBase.CountdownWatcher;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
public class DIFFSyncConsistencyTest extends QuorumPeerTestBase {
@@ -49,7 +48,6 @@
private MainThread[] mt = new MainThread[SERVER_COUNT];
@Test
- @Timeout(value = 120)
public void testInconsistentDueToUncommittedLog() throws Exception {
final int LEADER_TIMEOUT_MS = 10_000;
final int[] clientPorts = new int[SERVER_COUNT];
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/EphemeralNodeDeletionTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/EphemeralNodeDeletionTest.java
@@ -40,7 +40,6 @@
import org.apache.zookeeper.test.ClientBase.CountdownWatcher;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
public class EphemeralNodeDeletionTest extends QuorumPeerTestBase {
@@ -54,7 +53,6 @@
*/
@Test
- @Timeout(value = 120)
public void testEphemeralNodeDeletion() throws Exception {
final int[] clientPorts = new int[SERVER_COUNT];
StringBuilder sb = new StringBuilder();
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/EpochWriteFailureTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/EpochWriteFailureTest.java
@@ -32,7 +32,6 @@
import org.apache.zookeeper.test.ClientBase.CountdownWatcher;
import org.junit.jupiter.api.AfterAll;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
public class EpochWriteFailureTest extends QuorumPeerTestBase {
private static int SERVER_COUNT = 3;
@@ -47,7 +46,6 @@
* run time values of acceptedEpoch,
*/
@Test
- @Timeout(value = 120)
public void testAcceptedEpochWriteFailure() throws Exception {
StringBuilder sb = new StringBuilder();
sb.append("admin.enableServer=false");
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/QuorumSSLTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/QuorumSSLTest.java
@@ -118,7 +118,6 @@
import org.bouncycastle.util.io.pem.PemWriter;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeEach;
-import org.junit.jupiter.api.Timeout;
import org.junit.jupiter.params.ParameterizedTest;
import org.junit.jupiter.params.provider.ValueSource;
@@ -494,7 +493,6 @@
}
@TestBothFipsModes
- @Timeout(value = 5, unit = TimeUnit.MINUTES)
public void testQuorumSSL(boolean fipsEnabled) throws Exception {
System.setProperty(quorumX509Util.getFipsModeProperty(), Boolean.toString(fipsEnabled));
@@ -517,7 +515,6 @@
}
@TestBothFipsModes
- @Timeout(value = 5, unit = TimeUnit.MINUTES)
public void testQuorumSSL_withPasswordFromFile(boolean fipsEnabled) throws Exception {
System.setProperty(quorumX509Util.getFipsModeProperty(), Boolean.toString(fipsEnabled));
@@ -543,7 +540,6 @@
}
@TestBothFipsModes
- @Timeout(value = 5, unit = TimeUnit.MINUTES)
public void testQuorumSSLWithMultipleAddresses(boolean fipsEnabled) throws Exception {
System.setProperty(quorumX509Util.getFipsModeProperty(), Boolean.toString(fipsEnabled));
@@ -570,7 +566,6 @@
@TestBothFipsModes
- @Timeout(value = 5, unit = TimeUnit.MINUTES)
public void testRollingUpgrade(boolean fipsEnabled) throws Exception {
System.setProperty(quorumX509Util.getFipsModeProperty(), Boolean.toString(fipsEnabled));
@@ -620,7 +615,6 @@
}
@TestNoFipsOnly
- @Timeout(value = 5, unit = TimeUnit.MINUTES)
public void testHostnameVerificationWithInvalidHostname(boolean fipsEnabled) throws Exception {
System.setProperty(quorumX509Util.getFipsModeProperty(), Boolean.toString(fipsEnabled));
String badhostnameKeystorePath = tmpDir + "/badhost.jks";
@@ -638,7 +632,6 @@
}
@TestNoFipsOnly
- @Timeout(value = 5, unit = TimeUnit.MINUTES)
public void testHostnameVerificationWithInvalidIPAddress(boolean fipsEnabled) throws Exception {
System.setProperty(quorumX509Util.getFipsModeProperty(), Boolean.toString(fipsEnabled));
String badhostnameKeystorePath = tmpDir + "/badhost.jks";
@@ -656,7 +649,6 @@
}
@TestNoFipsOnly
- @Timeout(value = 5, unit = TimeUnit.MINUTES)
public void testHostnameVerificationWithInvalidIpAddressAndInvalidHostname(boolean fipsEnabled) throws Exception {
System.setProperty(quorumX509Util.getFipsModeProperty(), Boolean.toString(fipsEnabled));
@@ -675,7 +667,6 @@
}
@TestNoFipsOnly
- @Timeout(value = 5, unit = TimeUnit.MINUTES)
public void testHostnameVerificationForInvalidMultiAddressServerConfig(boolean fipsEnabled) throws Exception {
System.setProperty(quorumX509Util.getFipsModeProperty(), Boolean.toString(fipsEnabled));
@@ -697,7 +688,6 @@
}
@TestNoFipsOnly
- @Timeout(value = 5, unit = TimeUnit.MINUTES)
public void testHostnameVerificationWithInvalidIpAddressAndValidHostname(boolean fipsEnabled) throws Exception {
System.setProperty(quorumX509Util.getFipsModeProperty(), Boolean.toString(fipsEnabled));
@@ -716,7 +706,6 @@
}
@TestNoFipsOnly
- @Timeout(value = 5, unit = TimeUnit.MINUTES)
public void testHostnameVerificationWithValidIpAddressAndInvalidHostname(boolean fipsEnabled) throws Exception {
System.setProperty(quorumX509Util.getFipsModeProperty(), Boolean.toString(fipsEnabled));
@@ -785,75 +774,6 @@
}
@TestBothFipsModes
- @Timeout(value = 5, unit = TimeUnit.MINUTES)
- public void testCertificateRevocationList(boolean fipsEnabled) throws Exception {
- System.setProperty(quorumX509Util.getFipsModeProperty(), Boolean.toString(fipsEnabled));
-
- q1 = new MainThread(1, clientPortQp1, quorumConfiguration, SSL_QUORUM_ENABLED);
- q2 = new MainThread(2, clientPortQp2, quorumConfiguration, SSL_QUORUM_ENABLED);
-
- q1.start();
- q2.start();
-
- assertTrue(ClientBase.waitForServerUp("127.0.0.1:" + clientPortQp1, CONNECTION_TIMEOUT));
- assertTrue(ClientBase.waitForServerUp("127.0.0.1:" + clientPortQp2, CONNECTION_TIMEOUT));
-
- String revokedInCRLKeystorePath = tmpDir + "/crl_revoked.jks";
- String crlPath = tmpDir + "/crl.pem";
- X509Certificate revokedInCRLCert = buildEndEntityCert(
- defaultKeyPair,
- rootCertificate,
- rootKeyPair.getPrivate(),
- HOSTNAME,
- null,
- crlPath,
- null);
- writeKeystore(revokedInCRLCert, defaultKeyPair, revokedInCRLKeystorePath);
- buildCRL(revokedInCRLCert, crlPath);
-
- System.setProperty(quorumX509Util.getSslKeystoreLocationProperty(), revokedInCRLKeystorePath);
-
- // This server should join successfully
- q3 = new MainThread(3, clientPortQp3, quorumConfiguration, SSL_QUORUM_ENABLED);
- q3.start();
-
- assertTrue(ClientBase.waitForServerUp("127.0.0.1:" + clientPortQp3, CONNECTION_TIMEOUT));
-
- q1.shutdown();
- q2.shutdown();
- q3.shutdown();
-
- assertTrue(ClientBase.waitForServerDown("127.0.0.1:" + clientPortQp1, CONNECTION_TIMEOUT));
- assertTrue(ClientBase.waitForServerDown("127.0.0.1:" + clientPortQp2, CONNECTION_TIMEOUT));
- assertTrue(ClientBase.waitForServerDown("127.0.0.1:" + clientPortQp3, CONNECTION_TIMEOUT));
-
- setSSLSystemProperties();
- System.setProperty(quorumX509Util.getSslCrlEnabledProperty(), "true");
-
- X509Certificate validCertificate = buildEndEntityCert(
- defaultKeyPair,
- rootCertificate,
- rootKeyPair.getPrivate(),
- HOSTNAME,
- null,
- crlPath,
- null);
- writeKeystore(validCertificate, defaultKeyPair, validKeystorePath);
-
- q1.start();
- q2.start();
-
- assertTrue(ClientBase.waitForServerUp("127.0.0.1:" + clientPortQp1, CONNECTION_TIMEOUT));
- assertTrue(ClientBase.waitForServerUp("127.0.0.1:" + clientPortQp2, CONNECTION_TIMEOUT));
-
- System.setProperty(quorumX509Util.getSslKeystoreLocationProperty(), revokedInCRLKeystorePath);
- q3.start();
-
- assertFalse(ClientBase.waitForServerUp("127.0.0.1:" + clientPortQp3, CONNECTION_TIMEOUT));
- }
-
- @TestBothFipsModes
- @Timeout(value = 5, unit = TimeUnit.MINUTES)
public void testOCSP(boolean fipsEnabled) throws Exception {
System.setProperty(quorumX509Util.getFipsModeProperty(), Boolean.toString(fipsEnabled));
@@ -929,7 +849,6 @@
}
@TestBothFipsModes
- @Timeout(value = 5, unit = TimeUnit.MINUTES)
public void testCipherSuites(boolean fipsEnabled) throws Exception {
System.setProperty(quorumX509Util.getFipsModeProperty(), Boolean.toString(fipsEnabled));
@@ -972,7 +891,6 @@
}
@TestBothFipsModes
- @Timeout(value = 5, unit = TimeUnit.MINUTES)
public void testProtocolVersion(boolean fipsEnabled) throws Exception {
System.setProperty(quorumX509Util.getFipsModeProperty(), Boolean.toString(fipsEnabled));
System.setProperty(quorumX509Util.getSslProtocolProperty(), "TLSv1.2");
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/RaceConditionTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/RaceConditionTest.java
@@ -40,7 +40,6 @@
import org.apache.zookeeper.txn.DeleteTxn;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -60,7 +59,6 @@
*/
@Test
- @Timeout(value = 30)
public void testRaceConditionBetweenLeaderAndAckRequestProcessor() throws Exception {
mt = startQuorum();
// get leader
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/ReconfigLegacyTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/ReconfigLegacyTest.java
@@ -36,7 +36,6 @@
import org.apache.zookeeper.test.ReconfigTest;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
public class ReconfigLegacyTest extends QuorumPeerTestBase {
@@ -246,7 +245,6 @@
* @throws Exception
*/
@Test
- @Timeout(value = 120)
public void testRestartZooKeeperServer() throws Exception {
final int[] clientPorts = new int[SERVER_COUNT];
StringBuilder sb = new StringBuilder();
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/ReconfigRollingRestartCompatibilityTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/ReconfigRollingRestartCompatibilityTest.java
@@ -37,7 +37,6 @@
import org.apache.zookeeper.test.ClientBase;
import org.apache.zookeeper.test.ReconfigTest;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
/**
* ReconfigRollingRestartCompatibilityTest - we want to make sure that users
@@ -93,7 +92,6 @@
// Verify no zoo.cfg.dynamic and zoo.cfg.bak files existing locally
// when reconfig feature flag is off by default.
@Test
- @Timeout(value = 60)
public void testNoLocalDynamicConfigAndBackupFiles() throws InterruptedException, IOException {
int serverCount = 3;
String config = generateNewQuorumConfig(serverCount);
@@ -123,7 +121,6 @@
// 2. After upgrade, start the node.
// 3. Do this for every node, one at a time.
@Test
- @Timeout(value = 60)
public void testRollingRestartWithoutMembershipChange() throws Exception {
int serverCount = 3;
String config = generateNewQuorumConfig(serverCount);
@@ -156,7 +153,6 @@
// during the process each node has the expected configuration setting pushed
// via updating local zoo.cfg file.
@Test
- @Timeout(value = 90)
public void testExtendingQuorumWithNewMembers() throws Exception {
int serverCount = 3;
String config = generateNewQuorumConfig(serverCount);
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/StandaloneDisabledTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/StandaloneDisabledTest.java
@@ -33,7 +33,6 @@
import org.apache.zookeeper.test.ClientBase;
import org.apache.zookeeper.test.ReconfigTest;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
public class StandaloneDisabledTest extends QuorumPeerTestBase {
@@ -55,7 +54,6 @@
* with just a single server.
*/
@Test
- @Timeout(value = 10, unit = TimeUnit.MINUTES)
public void startSingleServerTest() throws Exception {
setUpData();
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/auth/MiniKdcTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/auth/MiniKdcTest.java
@@ -33,7 +33,6 @@
import org.apache.kerby.kerberos.kerb.type.base.PrincipalName;
import org.apache.zookeeper.server.quorum.auth.KerberosTestUtils.KerberosConfiguration;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
/*
* This code is originally from HDFS, see the file name TestMiniKdc there
@@ -46,14 +45,12 @@
@Test
- @Timeout(value = 60)
public void testMiniKdcStart() {
MiniKdc kdc = getKdc();
assertNotSame(0, kdc.getPort());
}
@Test
- @Timeout(value = 60)
public void testKeytabGen() throws Exception {
MiniKdc kdc = getKdc();
File workDir = getWorkDir();
@@ -72,7 +69,6 @@
@Test
- @Timeout(value = 60)
public void testKerberosLogin() throws Exception {
MiniKdc kdc = getKdc();
File workDir = getWorkDir();
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/auth/QuorumAuthUpgradeTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/auth/QuorumAuthUpgradeTest.java
@@ -35,7 +35,6 @@
import org.junit.jupiter.api.AfterAll;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
/**
* Rolling upgrade should do in three steps:
@@ -85,7 +84,6 @@
* peer1 -> quorum.auth.enableSasl=false
*/
@Test
- @Timeout(value = 30)
public void testNullAuthLearnerServer() throws Exception {
Map<String, String> authConfigs = new HashMap<>();
authConfigs.put(QuorumAuth.QUORUM_SASL_AUTH_ENABLED, "false");
@@ -104,7 +102,6 @@
* peer1 -> quorum.auth.enableSasl=false, quorum.auth.learnerRequireSasl=false, quorum.auth.serverRequireSasl=false
*/
@Test
- @Timeout(value = 30)
public void testAuthLearnerAgainstNullAuthServer() throws Exception {
Map<String, String> authConfigs = new HashMap<>();
authConfigs.put(QuorumAuth.QUORUM_SASL_AUTH_ENABLED, "true");
@@ -123,7 +120,6 @@
* peer1 -> quorum.auth.enableSasl=true, quorum.auth.learnerRequireSasl=false, quorum.auth.serverRequireSasl=false
*/
@Test
- @Timeout(value = 30)
public void testAuthLearnerAgainstNoAuthRequiredServer() throws Exception {
Map<String, String> authConfigs = new HashMap<>();
authConfigs.put(QuorumAuth.QUORUM_SASL_AUTH_ENABLED, "true");
@@ -142,7 +138,6 @@
* peer1 -> quorum.auth.enableSasl=true, quorum.auth.learnerRequireSasl=true, quorum.auth.serverRequireSasl=true
*/
@Test
- @Timeout(value = 30)
public void testAuthLearnerServer() throws Exception {
Map<String, String> authConfigs = new HashMap<>();
authConfigs.put(QuorumAuth.QUORUM_SASL_AUTH_ENABLED, "true");
@@ -173,7 +168,6 @@
* Now, all the servers are fully upgraded and running in secured mode.
*/
@Test
- @Timeout(value = 90)
public void testRollingUpgrade() throws Exception {
// Start peer0,1,2 servers with quorum.auth.enableSasl=false and
// quorum.auth.learnerRequireSasl=false, quorum.auth.serverRequireSasl=false
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/auth/QuorumDigestAuthTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/auth/QuorumDigestAuthTest.java
@@ -37,7 +37,6 @@
import org.junit.jupiter.api.AfterAll;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
public class QuorumDigestAuthTest extends DigestSecurityTestcase {
@@ -79,7 +78,6 @@
* Test to verify that server is able to start with valid credentials
*/
@Test
- @Timeout(value = 30)
public void testValidCredentials() throws Exception {
Map<String, String> authConfigs = new HashMap<>();
authConfigs.put(QuorumAuth.QUORUM_SASL_AUTH_ENABLED, "true");
@@ -101,7 +99,6 @@
* when using multiple Quorum / Election addresses
*/
@Test
- @Timeout(value = 30)
public void testValidCredentialsWithMultiAddresses() throws Exception {
Map<String, String> authConfigs = new HashMap<>();
authConfigs.put(QuorumAuth.QUORUM_SASL_AUTH_ENABLED, "true");
@@ -124,7 +121,6 @@
* Quorum will talk each other even if the authentication is not succeeded
*/
@Test
- @Timeout(value = 30)
public void testSaslNotRequiredWithInvalidCredentials() throws Exception {
Map<String, String> authConfigs = new HashMap<>();
authConfigs.put(QuorumAuth.QUORUM_LEARNER_SASL_LOGIN_CONTEXT, "QuorumLearnerInvalid");
@@ -146,7 +142,6 @@
* quorum.auth.learnerRequireSasl=true
*/
@Test
- @Timeout(value = 30)
public void testSaslRequiredInvalidCredentials() throws Exception {
Map<String, String> authConfigs = new HashMap<>();
authConfigs.put(QuorumAuth.QUORUM_LEARNER_SASL_LOGIN_CONTEXT, "QuorumLearnerInvalid");
@@ -167,7 +162,6 @@
* enabled while enabling quorum server require sasl.
*/
@Test
- @Timeout(value = 10)
public void testEnableQuorumServerRequireSaslWithoutQuorumLearnerRequireSasl() throws Exception {
Map<String, String> authConfigs = new HashMap<>();
authConfigs.put(QuorumAuth.QUORUM_LEARNER_SASL_LOGIN_CONTEXT, "QuorumLearner");
@@ -196,7 +190,6 @@
* enabled while enabling quorum server require sasl.
*/
@Test
- @Timeout(value = 10)
public void testEnableQuorumAuthenticationConfigurations() throws Exception {
Map<String, String> authConfigs = new HashMap<>();
authConfigs.put(QuorumAuth.QUORUM_LEARNER_SASL_LOGIN_CONTEXT, "QuorumLearner");
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/auth/QuorumKerberosAuthTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/auth/QuorumKerberosAuthTest.java
@@ -33,7 +33,6 @@
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeAll;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
public class QuorumKerberosAuthTest extends KerberosSecurityTestcase {
@@ -110,7 +109,6 @@
* Test to verify that server is able to start with valid credentials
*/
@Test
- @Timeout(value = 120)
public void testValidCredentials() throws Exception {
String serverPrincipal = KerberosTestUtils.getServerPrincipal();
serverPrincipal = serverPrincipal.substring(0, serverPrincipal.lastIndexOf("@"));
@@ -134,7 +132,6 @@
* when using multiple Quorum / Election addresses
*/
@Test
- @Timeout(value = 120)
public void testValidCredentialsWithMultiAddresses() throws Exception {
String serverPrincipal = KerberosTestUtils.getServerPrincipal();
serverPrincipal = serverPrincipal.substring(0, serverPrincipal.lastIndexOf("@"));
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/auth/QuorumKerberosHostBasedAuthTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/quorum/auth/QuorumKerberosHostBasedAuthTest.java
@@ -36,7 +36,6 @@
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeAll;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
public class QuorumKerberosHostBasedAuthTest extends KerberosSecurityTestcase {
@@ -153,7 +152,6 @@
* Test to verify that server is able to start with valid credentials
*/
@Test
- @Timeout(value = 120)
public void testValidCredentials() throws Exception {
String serverPrincipal = hostServerPrincipal.substring(0, hostServerPrincipal.lastIndexOf("@"));
Map<String, String> authConfigs = new HashMap<>();
@@ -176,7 +174,6 @@
* when using multiple Quorum / Election addresses
*/
@Test
- @Timeout(value = 120)
public void testValidCredentialsWithMultiAddresses() throws Exception {
String serverPrincipal = hostServerPrincipal.substring(0, hostServerPrincipal.lastIndexOf("@"));
Map<String, String> authConfigs = new HashMap<>();
@@ -198,7 +195,6 @@
* Test to verify that the bad server connection to the quorum should be rejected.
*/
@Test
- @Timeout(value = 120)
public void testConnectBadServer() throws Exception {
String serverPrincipal = hostServerPrincipal.substring(0, hostServerPrincipal.lastIndexOf("@"));
Map<String, String> authConfigs = new HashMap<>();
@@ -246,7 +242,6 @@
* Test to verify that the bad server connection to the quorum should be rejected.
*/
@Test
- @Timeout(value = 120)
public void testConnectHostlessPrincipalBadServer() throws Exception {
String serverPrincipal = hostServerPrincipal.substring(0, hostServerPrincipal.lastIndexOf("@"));
Map<String, String> authConfigs = new HashMap<>();
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/util/JvmPauseMonitorTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/util/JvmPauseMonitorTest.java
@@ -24,7 +24,6 @@
import org.apache.zookeeper.server.quorum.QuorumPeerConfig;
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
public class JvmPauseMonitorTest {
@@ -34,7 +33,6 @@
private JvmPauseMonitor pauseMonitor;
@Test
- @Timeout(value = 5)
public void testJvmPauseMonitorExceedInfoThreshold() throws InterruptedException {
QuorumPeerConfig qpConfig = mock(QuorumPeerConfig.class);
when(qpConfig.getJvmPauseSleepTimeMs()).thenReturn(sleepTime);
@@ -52,7 +50,6 @@
}
@Test
- @Timeout(value = 5)
public void testJvmPauseMonitorExceedWarnThreshold() throws InterruptedException {
QuorumPeerConfig qpConfig = mock(QuorumPeerConfig.class);
when(qpConfig.getJvmPauseSleepTimeMs()).thenReturn(sleepTime);
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/server/watch/WatchManagerTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/server/watch/WatchManagerTest.java
@@ -40,7 +40,6 @@
import org.apache.zookeeper.server.ServerMetrics;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
import org.junit.jupiter.params.ParameterizedTest;
import org.junit.jupiter.params.provider.Arguments;
import org.junit.jupiter.params.provider.MethodSource;
@@ -229,7 +228,6 @@
*/
@ParameterizedTest
@MethodSource("data")
- @Timeout(value = 90)
public void testAddAndTriggerWatcher(String className) throws IOException {
IWatchManager manager = getWatchManager(className);
int paths = 1;
@@ -290,7 +288,6 @@
*/
@ParameterizedTest
@MethodSource("data")
- @Timeout(value = 90)
public void testRemoveWatcherOnPath(String className) throws IOException {
IWatchManager manager = getWatchManager(className);
int paths = 10;
@@ -661,7 +658,6 @@
*/
@ParameterizedTest
@MethodSource("data")
- @Timeout(value = 90)
public void testDeadWatchers(String className) throws IOException {
System.setProperty("zookeeper.watcherCleanThreshold", "10");
System.setProperty("zookeeper.watcherCleanIntervalInSeconds", "1");
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/test/DisconnectedWatcherTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/test/DisconnectedWatcherTest.java
@@ -32,7 +32,6 @@
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -188,7 +187,6 @@
// @see jira issue ZOOKEEPER-706. Test auto reset of a large number of
// watches which require multiple SetWatches calls.
@Test
- @Timeout(value = 14, unit = TimeUnit.MINUTES)
public void testManyChildWatchersAutoReset() throws Exception {
zk2 = createClient(watcher2);
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/test/FourLetterWordsTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/test/FourLetterWordsTest.java
@@ -33,7 +33,6 @@
import org.apache.zookeeper.common.IOUtils;
import org.apache.zookeeper.common.X509Exception.SSLContextException;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -43,7 +42,6 @@
/** Test the various four letter words */
@Test
- @Timeout(value = 30)
public void testFourLetterWords() throws Exception {
verify("ruok", "imok");
verify("envi", "java.version");
@@ -127,7 +125,6 @@
}
@Test
- @Timeout(value = 30)
public void testValidateStatOutput() throws Exception {
ZooKeeper zk1 = createClient();
ZooKeeper zk2 = createClient();
@@ -171,7 +168,6 @@
}
@Test
- @Timeout(value = 30)
public void testValidateConsOutput() throws Exception {
ZooKeeper zk1 = createClient();
ZooKeeper zk2 = createClient();
@@ -193,7 +189,6 @@
}
@Test
- @Timeout(value = 60)
public void testValidateSocketTimeout() throws Exception {
/**
* testing positive scenario that even with timeout parameter the
@@ -204,7 +199,6 @@
}
@Test
- @Timeout(value = 30)
public void testSetTraceMask() throws Exception {
String gtmkResp = sendRequest("gtmk");
assertNotNull(gtmkResp);
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/test/FourLetterWordsWhiteListTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/test/FourLetterWordsWhiteListTest.java
@@ -25,7 +25,6 @@
import org.apache.zookeeper.common.X509Exception.SSLContextException;
import org.apache.zookeeper.server.command.FourLetterCommands;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -40,7 +39,6 @@
* which other tests depend on.).
*/
@Test
- @Timeout(value = 30)
public void testFourLetterWordsAllDisabledByDefault() throws Exception {
stopServer();
FourLetterCommands.resetWhiteList();
@@ -65,7 +63,6 @@
}
@Test
- @Timeout(value = 30)
public void testFourLetterWordsEnableSomeCommands() throws Exception {
stopServer();
FourLetterCommands.resetWhiteList();
@@ -93,7 +90,6 @@
}
@Test
- @Timeout(value = 30)
public void testISROEnabledWhenReadOnlyModeEnabled() throws Exception {
stopServer();
FourLetterCommands.resetWhiteList();
@@ -105,7 +101,6 @@
}
@Test
- @Timeout(value = 30)
public void testFourLetterWordsInvalidConfiguration() throws Exception {
stopServer();
FourLetterCommands.resetWhiteList();
@@ -121,7 +116,6 @@
}
@Test
- @Timeout(value = 30)
public void testFourLetterWordsEnableAllCommandsThroughAsterisk() throws Exception {
stopServer();
FourLetterCommands.resetWhiteList();
@@ -131,7 +125,6 @@
}
@Test
- @Timeout(value = 30)
public void testFourLetterWordsEnableAllCommandsThroughExplicitList() throws Exception {
stopServer();
FourLetterCommands.resetWhiteList();
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/test/MultiOperationTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/test/MultiOperationTest.java
@@ -61,7 +61,6 @@
import org.apache.zookeeper.data.Stat;
import org.apache.zookeeper.server.SyncRequestProcessor;
import org.junit.jupiter.api.BeforeEach;
-import org.junit.jupiter.api.Timeout;
import org.junit.jupiter.params.ParameterizedTest;
import org.junit.jupiter.params.provider.ValueSource;
import org.slf4j.Logger;
@@ -192,7 +191,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testInvalidPath(boolean useAsync) throws Exception {
List<Integer> expectedResultCodes = new ArrayList<>();
expectedResultCodes.add(KeeperException.Code.RUNTIMEINCONSISTENCY.intValue());
@@ -295,7 +293,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testBlankPath(boolean useAsync) throws Exception {
List<Integer> expectedResultCodes = new ArrayList<>();
expectedResultCodes.add(KeeperException.Code.RUNTIMEINCONSISTENCY.intValue());
@@ -318,7 +315,6 @@
*/
@ParameterizedTest
@ValueSource(booleans = {true, false})
- @Timeout(value = 90)
public void testInvalidCreateModeFlag(boolean useAsync) throws Exception {
List<Integer> expectedResultCodes = new ArrayList<>();
expectedResultCodes.add(KeeperException.Code.RUNTIMEINCONSISTENCY.intValue());
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/test/NonRecoverableErrorTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/test/NonRecoverableErrorTest.java
@@ -37,7 +37,6 @@
import org.apache.zookeeper.server.quorum.QuorumPeerTestBase;
import org.apache.zookeeper.test.ClientBase.CountdownWatcher;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
/**
* This class tests the non-recoverable error behavior of quorum server.
@@ -52,7 +51,6 @@
* writing transaction log), ZooKeeper is still available.
*/
@Test
- @Timeout(value = 30)
public void testZooKeeperServiceAvailableOnLeader() throws Exception {
int SERVER_COUNT = 3;
final int[] clientPorts = new int[SERVER_COUNT];
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/test/ReadOnlyModeTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/test/ReadOnlyModeTest.java
@@ -43,7 +43,6 @@
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
import org.slf4j.LoggerFactory;
public class ReadOnlyModeTest extends ZKTestCase {
@@ -67,7 +66,6 @@
* Test write operations using multi request.
*/
@Test
- @Timeout(value = 90)
public void testMultiTransaction() throws Exception {
qu.enableLocalSession(true);
qu.startQuorum();
@@ -111,7 +109,6 @@
* during read-only mode, then regains a quorum and tries to write again.
*/
@Test
- @Timeout(value = 90)
public void testReadOnlyClient() throws Exception {
qu.enableLocalSession(true);
qu.startQuorum();
@@ -165,7 +162,6 @@
* ConnectedReadOnly state notification.
*/
@Test
- @Timeout(value = 90)
public void testConnectionEvents() throws Exception {
qu.enableLocalSession(true);
qu.startQuorum();
@@ -210,7 +206,6 @@
* the user.
*/
@Test
- @Timeout(value = 90)
public void testSessionEstablishment() throws Exception {
qu.enableLocalSession(true);
qu.startQuorum();
@@ -244,7 +239,6 @@
}
@Test
- @Timeout(value = 90)
public void testGlobalSessionInRO() throws Exception {
qu.startQuorum();
@@ -287,7 +281,6 @@
*/
@SuppressWarnings("deprecation")
@Test
- @Timeout(value = 90)
public void testSeekForRwServer() throws Exception {
qu.enableLocalSession(true);
qu.startQuorum();
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/test/ReconfigExceptionTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/test/ReconfigExceptionTest.java
@@ -37,7 +37,6 @@
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -89,7 +88,6 @@
}
@Test
- @Timeout(value = 10)
public void testReconfigDisabled() throws InterruptedException {
QuorumPeerConfig.setReconfigEnabled(false);
@@ -111,7 +109,6 @@
}
@Test
- @Timeout(value = 10)
public void testReconfigFailWithoutAuth() throws InterruptedException {
try {
reconfigPort();
@@ -123,7 +120,6 @@
}
@Test
- @Timeout(value = 10)
public void testReconfigEnabledWithSuperUser() throws InterruptedException {
try {
zkAdmin.addAuthInfo("digest", "super:test".getBytes());
@@ -134,7 +130,6 @@
}
@Test
- @Timeout(value = 10)
public void testReconfigFailWithAuthWithNoACL() throws InterruptedException {
resetZKAdmin();
@@ -149,7 +144,6 @@
}
@Test
- @Timeout(value = 10)
public void testReconfigEnabledWithAuthAndWrongACL() throws InterruptedException {
resetZKAdmin();
@@ -168,7 +162,6 @@
}
@Test
- @Timeout(value = 10)
public void testReconfigEnabledWithAuthAndACL() throws InterruptedException {
resetZKAdmin();
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/test/ReconfigMisconfigTest.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/test/ReconfigMisconfigTest.java
@@ -33,7 +33,6 @@
import org.junit.jupiter.api.AfterEach;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -75,7 +74,6 @@
}
@Test
- @Timeout(value = 10)
public void testReconfigFailWithoutSuperuserPasswordConfiguredOnServer() throws InterruptedException {
// This tests the case where ZK ensemble does not have the super user's password configured.
// Reconfig should fail as the super user has to be explicitly configured via
--- a/zookeeper-server/src/test/java/org/apache/zookeeper/util/TestCircularBlockingQueue.java
+++ b/zookeeper-server/src/test/java/org/apache/zookeeper/util/TestCircularBlockingQueue.java
@@ -24,7 +24,6 @@
import java.util.concurrent.Executors;
import java.util.concurrent.Future;
import org.junit.jupiter.api.Test;
-import org.junit.jupiter.api.Timeout;
public class TestCircularBlockingQueue {
@@ -48,7 +47,6 @@
}
@Test
- @Timeout(value = 10)
public void testCircularBlockingQueueTakeBlock()
throws InterruptedException, ExecutionException {
|