{"id":3042,"date":"2023-07-31T09:59:27","date_gmt":"2023-07-31T01:59:27","guid":{"rendered":"https:\/\/xinchewhd.com.cn\/index.php\/uncategorized\/%e4%bd%bf%e7%94%a8%e4%b8%8a-spring-%e7%9a%84%e4%ba%8b%e4%bb%b6%e6%9c%ba%e5%88%b6%ef%bc%8c%e7%9c%9f%e9%a6%99%ef%bc%81\/"},"modified":"2023-07-31T09:59:27","modified_gmt":"2023-07-31T01:59:27","slug":"%e4%bd%bf%e7%94%a8%e4%b8%8a-spring-%e7%9a%84%e4%ba%8b%e4%bb%b6%e6%9c%ba%e5%88%b6%ef%bc%8c%e7%9c%9f%e9%a6%99%ef%bc%81","status":"publish","type":"post","link":"https:\/\/xinchewhd.com.cn\/index.php\/spring\/%e4%bd%bf%e7%94%a8%e4%b8%8a-spring-%e7%9a%84%e4%ba%8b%e4%bb%b6%e6%9c%ba%e5%88%b6%ef%bc%8c%e7%9c%9f%e9%a6%99%ef%bc%81\/","title":{"rendered":"\u4f7f\u7528\u4e0a Spring \u7684\u4e8b\u4ef6\u673a\u5236\uff0c\u771f\u9999\uff01"},"content":{"rendered":"<section data-tool=\"mdnice\u7f16\u8f91\u5668\" data-website=\"https:\/\/www.mdnice.com\" style=\"font-size: 16px;color: black;padding-right: 10px;padding-left: 10px;line-height: 1.6;letter-spacing: 0px;word-break: break-word;text-align: left;font-family: Optima-Regular, Optima, PingFangSC-light, PingFangTC-light, &quot;PingFang SC&quot;, Cambria, Cochin, Georgia, Times, &quot;Times New Roman&quot;, serif;\" data-mpa-powered-by=\"yiban.io\">\n<h2 data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"font-weight: bold;font-size: 22px;color: rgb(0, 150, 136);padding-left: 10px;margin: 1em auto;border-left: 3px solid rgb(0, 150, 136);\"><span style=\"display: none;\"><\/span>\u524d\u8a00<\/h2>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u672c\u6587\u4e3b\u8981\u662f\u7b80\u5355\u7684\u8bb2\u8ff0\u4e86Spring\u7684\u4e8b\u4ef6\u673a\u5236\uff0c\u57fa\u672c\u6982\u5ff5\uff0c\u8bb2\u8ff0\u4e86\u4e8b\u4ef6\u673a\u5236\u7684\u4e09\u8981\u7d20\u4e8b\u4ef6\u3001\u4e8b\u4ef6\u53d1\u5e03\u3001\u4e8b\u4ef6\u76d1\u542c\u5668\u3002\u5982\u4f55\u5b9e\u73b0\u4e00\u4e2a\u4e8b\u4ef6\u673a\u5236\uff0c\u5e94\u7528\u7684\u573a\u666f\uff0c\u642d\u914d@Async\u6ce8\u89e3\u5b9e\u73b0\u5f02\u6b65\u7684\u64cd\u4f5c\u7b49\u7b49\u3002\u5e0c\u671b\u5bf9\u5927\u5bb6\u6709\u6240\u5e2e\u52a9\u3002<\/p>\n<h2 data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"font-weight: bold;font-size: 22px;color: rgb(0, 150, 136);padding-left: 10px;margin: 1em auto;border-left: 3px solid rgb(0, 150, 136);\"><span style=\"display: none;\"><\/span>Spring\u7684\u4e8b\u4ef6\u673a\u5236\u7684\u57fa\u672c\u6982\u5ff5<\/h2>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">Spring\u7684\u4e8b\u4ef6\u673a\u5236\u662fSpring\u6846\u67b6\u4e2d\u7684\u4e00\u4e2a\u91cd\u8981\u7279\u6027\uff0c\u57fa\u4e8e\u89c2\u5bdf\u8005\u6a21\u5f0f\u5b9e\u73b0\uff0c\u5b83\u53ef\u4ee5\u5b9e\u73b0\u5e94\u7528\u7a0b\u5e8f\u4e2d\u7684\u89e3\u8026\uff0c\u63d0\u9ad8\u4ee3\u7801\u7684\u53ef\u7ef4\u62a4\u6027\u548c\u53ef\u6269\u5c55\u6027\u3002Spring\u7684\u4e8b\u4ef6\u673a\u5236\u5305\u62ec\u4e8b\u4ef6\u3001\u4e8b\u4ef6\u53d1\u5e03\u3001\u4e8b\u4ef6\u76d1\u542c\u5668\u7b49\u51e0\u4e2a\u57fa\u672c\u6982\u5ff5\u3002<\/p>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u5176\u4e2d\uff0c\u4e8b\u4ef6\u662f\u4e00\u4e2a\u62bd\u8c61\u7684\u6982\u5ff5\uff0c\u5b83\u4ee3\u8868\u7740\u5e94\u7528\u7a0b\u5e8f\u4e2d\u7684\u67d0\u4e2a\u52a8\u4f5c\u6216\u72b6\u6001\u7684\u53d1\u751f\u3002\u4e8b\u4ef6\u53d1\u5e03\u662f\u4e8b\u4ef6\u53d1\u751f\u7684\u5730\u65b9\uff0c\u5b83\u8d1f\u8d23\u4ea7\u751f\u4e8b\u4ef6\u5e76\u901a\u77e5\u4e8b\u4ef6\u76d1\u542c\u5668\u3002\u4e8b\u4ef6\u76d1\u542c\u5668\u662f\u4e8b\u4ef6\u7684\u63a5\u6536\u8005\uff0c\u5b83\u8d1f\u8d23\u5904\u7406\u4e8b\u4ef6\u5e76\u6267\u884c\u76f8\u5e94\u7684\u64cd\u4f5c\u3002\u5728Spring\u7684\u4e8b\u4ef6\u673a\u5236\u4e2d\uff0c\u4e8b\u4ef6\u6e90\u548c\u4e8b\u4ef6\u76d1\u542c\u5668\u4e4b\u95f4\u901a\u8fc7\u4e8b\u4ef6\u8fdb\u884c\u901a\u4fe1\uff0c\u4ece\u800c\u5b9e\u73b0\u4e86\u6a21\u5757\u4e4b\u95f4\u7684\u89e3\u8026\u3002<\/p>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u4e3e\u4e2a\u4f8b\u5b50\uff1a\u7528\u6237\u4fee\u6539\u5bc6\u7801\uff0c\u4fee\u6539\u5b8c\u5bc6\u7801\u540e\u9700\u8981\u77ed\u4fe1\u901a\u77e5\u7528\u6237\uff0c\u8bb0\u5f55\u5173\u952e\u6027\u65e5\u5fd7\uff0c\u7b49\u7b49\u5176\u4ed6\u4e1a\u52a1\u64cd\u4f5c\u3002<\/p>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u5982\u4e0b\u56fe\uff0c\u5c31\u662f\u6211\u4eec\u9700\u8981\u8c03\u7528\u591a\u4e2a\u670d\u52a1\u6765\u8fdb\u884c\u5b9e\u73b0\u4e00\u4e2a\u4fee\u6539\u5bc6\u7801\u7684\u529f\u80fd\u3002<\/p>\n<figure data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 10px;margin-bottom: 10px;display: flex;flex-direction: column;justify-content: center;align-items: center;\">\n  <img decoding=\"async\" class=\"rich_pages wxw-img lazyload\" data-ratio=\"0.4308755760368664\" data-src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-15\/20230731095915f9f92908a.png\" src=\"https:\/\/s.nmxc.ltd\/sakurairo_vision\/@2.6\/load_svg\/inload.svg\" onerror=\"imgError(this)\" data-type=\"png\" data-w=\"868\" style=\"display: block;margin-right: auto;margin-left: auto;\"><noscript><img decoding=\"async\" class=\"rich_pages wxw-img\" data-ratio=\"0.4308755760368664\" src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-15\/20230731095915f9f92908a.png\" data-type=\"png\" data-w=\"868\" style=\"display: block;margin-right: auto;margin-left: auto;\"><\/noscript><br \/>\n <\/figure>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u4f7f\u7528\u4e86\u4e8b\u4ef6\u673a\u5236\u540e\uff0c\u6211\u4eec\u53ea\u9700\u8981\u53d1\u5e03\u4e00\u4e2a\u4e8b\u4ef6\uff0c\u65e0\u9700\u5173\u5fc3\u5176\u6269\u5c55\u7684\u903b\u8f91\uff0c\u8ba9\u6211\u4eec\u7684\u4e8b\u4ef6\u76d1\u542c\u5668\u53bb\u5904\u7406\uff0c\u4ece\u800c\u5b9e\u73b0\u4e86\u6a21\u5757\u4e4b\u95f4\u7684\u89e3\u8026\u3002<\/p>\n<figure data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 10px;margin-bottom: 10px;display: flex;flex-direction: column;justify-content: center;align-items: center;\">\n  <img decoding=\"async\" class=\"rich_pages wxw-img lazyload\" data-ratio=\"0.24351851851851852\" data-src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-16\/2023073109591696962852e.png\" src=\"https:\/\/s.nmxc.ltd\/sakurairo_vision\/@2.6\/load_svg\/inload.svg\" onerror=\"imgError(this)\" data-type=\"png\" data-w=\"1080\" style=\"display: block;margin-right: auto;margin-left: auto;\"><noscript><img decoding=\"async\" class=\"rich_pages wxw-img\" data-ratio=\"0.24351851851851852\" src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-16\/2023073109591696962852e.png\" data-type=\"png\" data-w=\"1080\" style=\"display: block;margin-right: auto;margin-left: auto;\"><\/noscript><br \/>\n <\/figure>\n<h3 data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"font-weight: bold;font-size: 20px;margin: 0.6em auto;padding-left: 10px;border-left: 2px solid rgb(0, 150, 136);\"><span style=\"display: none;\"><\/span>\u4e8b\u4ef6<span style=\"display: none;\"><\/span><\/h3>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u901a\u8fc7\u7ee7\u627fApplicationEvent\uff0c\u5b9e\u73b0\u81ea\u5b9a\u4e49\u4e8b\u4ef6\u3002\u662f\u5bf9 <code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">Java EventObject<\/code> \u7684\u6269\u5c55\uff0c\u8868\u793a Spring \u7684\u4e8b\u4ef6\uff0cSpring \u4e2d\u7684\u6240\u6709\u4e8b\u4ef6\u90fd\u8981\u57fa\u4e8e\u5176\u8fdb\u884c\u6269\u5c55\u3002\u5176\u6e90\u7801\u5982\u4e0b\u3002<\/p>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u6211\u4eec\u53ef\u4ee5\u83b7\u53d6\u5230timestamp\u5c5e\u6027\u6307\u7684\u662f\u53d1\u751f\u65f6\u95f4\u3002<\/p>\n<figure data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 10px;margin-bottom: 10px;display: flex;flex-direction: column;justify-content: center;align-items: center;\">\n  <img decoding=\"async\" class=\"rich_pages wxw-img lazyload\" data-ratio=\"0.6342592592592593\" data-src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-17\/20230731095917fefe25dc3.png\" src=\"https:\/\/s.nmxc.ltd\/sakurairo_vision\/@2.6\/load_svg\/inload.svg\" onerror=\"imgError(this)\" data-type=\"png\" data-w=\"1080\" style=\"display: block;margin-right: auto;margin-left: auto;\"><noscript><img decoding=\"async\" class=\"rich_pages wxw-img\" data-ratio=\"0.6342592592592593\" src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-17\/20230731095917fefe25dc3.png\" data-type=\"png\" data-w=\"1080\" style=\"display: block;margin-right: auto;margin-left: auto;\"><\/noscript><br \/>\n <\/figure>\n<h3 data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"font-weight: bold;font-size: 20px;margin: 0.6em auto;padding-left: 10px;border-left: 2px solid rgb(0, 150, 136);\"><span style=\"display: none;\"><\/span>\u4e8b\u4ef6\u53d1\u5e03<span style=\"display: none;\"><\/span><\/h3>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u4e8b\u4ef6\u53d1\u5e03\u662f\u4e8b\u4ef6\u53d1\u751f\u7684\u5730\u65b9\uff0c\u5b83\u8d1f\u8d23\u4ea7\u751f\u4e8b\u4ef6\u5e76\u901a\u77e5\u4e8b\u4ef6\u76d1\u542c\u5668\u3002<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">ApplicationEventPublisher<\/code>\u7528\u4e8e\u7528\u4e8e\u53d1\u5e03 <code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">ApplicationEvent<\/code> \u4e8b\u4ef6\uff0c\u53d1\u5e03\u540e <code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">ApplicationListener<\/code> \u624d\u80fd\u76d1\u542c\u5230\u4e8b\u4ef6\u8fdb\u884c\u5904\u7406\u3002\u6e90\u7801\u5982\u4e0b\u3002<\/p>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u9700\u8981\u4e00\u4e2a<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">ApplicationEvent<\/code>\uff0c\u5c31\u662f\u6211\u4eec\u7684\u4e8b\u4ef6\uff0c\u6765\u8fdb\u884c\u53d1\u5e03\u4e8b\u4ef6\u3002<\/p>\n<figure data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 10px;margin-bottom: 10px;display: flex;flex-direction: column;justify-content: center;align-items: center;\">\n  <img decoding=\"async\" class=\"rich_pages wxw-img lazyload\" data-ratio=\"0.5685185185185185\" data-src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-18\/202307310959189898697eb.png\" src=\"https:\/\/s.nmxc.ltd\/sakurairo_vision\/@2.6\/load_svg\/inload.svg\" onerror=\"imgError(this)\" data-type=\"png\" data-w=\"1080\" style=\"display: block;margin-right: auto;margin-left: auto;\"><noscript><img decoding=\"async\" class=\"rich_pages wxw-img\" data-ratio=\"0.5685185185185185\" src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-18\/202307310959189898697eb.png\" data-type=\"png\" data-w=\"1080\" style=\"display: block;margin-right: auto;margin-left: auto;\"><\/noscript><br \/>\n <\/figure>\n<h3 data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"font-weight: bold;font-size: 20px;margin: 0.6em auto;padding-left: 10px;border-left: 2px solid rgb(0, 150, 136);\"><span style=\"display: none;\"><\/span>\u4e8b\u4ef6\u76d1\u542c\u5668<span style=\"display: none;\"><\/span><\/h3>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\"><code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">ApplicationListener<\/code> \u662f Spring \u4e8b\u4ef6\u7684\u76d1\u542c\u5668\uff0c\u7528\u6765\u63a5\u53d7\u4e8b\u4ef6\uff0c\u6240\u6709\u7684\u76d1\u542c\u5668\u90fd\u5fc5\u987b\u5b9e\u73b0\u8be5\u63a5\u53e3\u3002\u8be5\u63a5\u53e3\u6e90\u7801\u5982\u4e0b\u3002<\/p>\n<figure data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 10px;margin-bottom: 10px;display: flex;flex-direction: column;justify-content: center;align-items: center;\">\n  <img decoding=\"async\" class=\"rich_pages wxw-img lazyload\" data-ratio=\"0.5175925925925926\" data-src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-19\/20230731095919949481b78.png\" src=\"https:\/\/s.nmxc.ltd\/sakurairo_vision\/@2.6\/load_svg\/inload.svg\" onerror=\"imgError(this)\" data-type=\"png\" data-w=\"1080\" style=\"display: block;margin-right: auto;margin-left: auto;\"><noscript><img decoding=\"async\" class=\"rich_pages wxw-img\" data-ratio=\"0.5175925925925926\" src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-19\/20230731095919949481b78.png\" data-type=\"png\" data-w=\"1080\" style=\"display: block;margin-right: auto;margin-left: auto;\"><\/noscript><br \/>\n <\/figure>\n<h2 data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"font-weight: bold;font-size: 22px;color: rgb(0, 150, 136);padding-left: 10px;margin: 1em auto;border-left: 3px solid rgb(0, 150, 136);\"><span style=\"display: none;\"><\/span>Spring\u7684\u4e8b\u4ef6\u673a\u5236\u7684\u4f7f\u7528\u65b9\u6cd5<\/h2>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u4e0b\u9762\u4f1a\u7ed9\u5927\u5bb6\u6f14\u793a\u5982\u4f55\u53bb\u4f7f\u7528Spring\u7684\u4e8b\u4ef6\u673a\u5236\u3002\u5c31\u62ff\u4fee\u6539\u5bc6\u7801\u4f5c\u4e3a\u6f14\u793a\u3002<\/p>\n<h3 data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"font-weight: bold;font-size: 20px;margin: 0.6em auto;padding-left: 10px;border-left: 2px solid rgb(0, 150, 136);\"><span style=\"display: none;\"><\/span>\u5982\u4f55\u5b9a\u4e49\u4e00\u4e2a\u4e8b\u4ef6<span style=\"display: none;\"><\/span><\/h3>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u65b0\u589e\u4e00\u4e2a\u7c7b\uff0c\u7ee7\u627f\u6211\u4eec\u7684<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">ApplicationEvent<\/code>\u3002<\/p>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u5982\u4e0b\u9762\u4ee3\u7801\uff0c\u7ee7\u627f\u540e\u5b9a\u4e49\u4e86\u4e00\u4e2auserId\uff0c\u6709\u4e00\u4e2a<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">UserChangePasswordEvent<\/code>\u65b9\u6cd5\u3002\u8fd9\u91cc\u5c31\u5b9a\u4e49\u6211\u4eec\u76d1\u542c\u5668\u9700\u8981\u7684\u4e1a\u52a1\u53c2\u6570\uff0c\u76d1\u542c\u5668\u9700\u8981\u90a3\u4e9b\u53c2\u6570\uff0c\u6211\u4eec\u8fd9\u91cc\u5c31\u5b9a\u4e49\u90a3\u4e9b\u53c2\u6570\u3002<\/p>\n<pre data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 10px;margin-bottom: 10px;border-radius: 5px;box-shadow: rgba(0, 0, 0, 0.55) 0px 2px 10px;\"><span style=\"display: block;background: url(&quot;https:\/\/mmbiz.qpic.cn\/mmbiz_svg\/bofA1vl6EUZR9BtL4F0qwnRS7BMVdib53B0zZ7CwuHEXMOXsubOPuRiaeg03w770JQAIXKLznVdJFFGPNxhUWdicXNfkN4uQbo5\/640?wx_fmt=svg&quot;) 10px 10px \/ 40px no-repeat rgb(40, 44, 52);height: 30px;width: 100%;margin-bottom: -7px;border-radius: 5px;\"><\/span><code style=\"overflow-x: auto;padding: 16px;color: #abb2bf;display: -webkit-box;font-family: Operator Mono, Consolas, Monaco, Menlo, monospace;font-size: 12px;-webkit-overflow-scrolling: touch;padding-top: 15px;background: #282c34;border-radius: 5px;\"><span style=\"color: #5c6370;font-style: italic;line-height: 26px;\">\/**<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@Author<\/span>&nbsp;JiaQIng<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@Description<\/span>&nbsp;\u4fee\u6539\u5bc6\u7801\u4e8b\u4ef6<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@ClassName<\/span>&nbsp;UserChangePasswordEvent<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@Date<\/span>&nbsp;2023\/3\/26&nbsp;13:55<br>&nbsp;**\/<\/span><br><span style=\"color: #61aeee;line-height: 26px;\">@Getter<\/span><br><span style=\"color: #61aeee;line-height: 26px;\">@Setter<\/span><br><span style=\"color: #c678dd;line-height: 26px;\">public<\/span>&nbsp;<span style=\"line-height: 26px;\"><span style=\"color: #c678dd;line-height: 26px;\">class<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">UserChangePasswordEvent<\/span>&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">extends<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">ApplicationEvent<\/span>&nbsp;<\/span>{<br>&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">private<\/span>&nbsp;String&nbsp;userId;<br><br>&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"line-height: 26px;\"><span style=\"color: #c678dd;line-height: 26px;\">public<\/span>&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">UserChangePasswordEvent<\/span><span style=\"line-height: 26px;\">(String&nbsp;userId)<\/span>&nbsp;<\/span>{<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">super<\/span>(<span style=\"color: #c678dd;line-height: 26px;\">new<\/span>&nbsp;Object());<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">this<\/span>.userId&nbsp;=&nbsp;userId;<br>&nbsp;&nbsp;&nbsp;&nbsp;}<br>}<br><\/code><\/pre>\n<h3 data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"font-weight: bold;font-size: 20px;margin: 0.6em auto;padding-left: 10px;border-left: 2px solid rgb(0, 150, 136);\"><span style=\"display: none;\"><\/span>\u5982\u4f55\u76d1\u542c\u4e8b\u4ef6<span style=\"display: none;\"><\/span><\/h3>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u5b9e\u73b0\u76d1\u542c\u5668\u6709\u4e24\u79cd\u65b9\u6cd5<\/p>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">1\u3001\u65b0\u5efa\u4e00\u4e2a\u7c7b\u5b9e\u73b0<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">ApplicationListener<\/code>\u63a5\u53e3\uff0c\u5e76\u4e14\u91cd\u5199<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">onApplicationEvent<\/code>\u65b9\u6cd5\u3002\u6ce8\u5165\u5230Spring\u5bb9\u5668\u4e2d\uff0c\u4ea4\u7ed9Spring\u7ba1\u7406\u3002\u5982\u4e0b\u4ee3\u7801\u3002\u65b0\u5efa\u4e86\u4e00\u4e2a\u53d1\u9001\u77ed\u4fe1\u76d1\u542c\u5668\uff0c\u6536\u5230\u4e8b\u4ef6\u540e\u6267\u884c\u4e1a\u52a1\u64cd\u4f5c\u3002<\/p>\n<pre data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 10px;margin-bottom: 10px;border-radius: 5px;box-shadow: rgba(0, 0, 0, 0.55) 0px 2px 10px;\"><span style=\"display: block;background: url(&quot;https:\/\/mmbiz.qpic.cn\/mmbiz_svg\/bofA1vl6EUZR9BtL4F0qwnRS7BMVdib53B0zZ7CwuHEXMOXsubOPuRiaeg03w770JQAIXKLznVdJFFGPNxhUWdicXNfkN4uQbo5\/640?wx_fmt=svg&quot;) 10px 10px \/ 40px no-repeat rgb(40, 44, 52);height: 30px;width: 100%;margin-bottom: -7px;border-radius: 5px;\"><\/span><code style=\"overflow-x: auto;padding: 16px;color: #abb2bf;display: -webkit-box;font-family: Operator Mono, Consolas, Monaco, Menlo, monospace;font-size: 12px;-webkit-overflow-scrolling: touch;padding-top: 15px;background: #282c34;border-radius: 5px;\"><span style=\"color: #5c6370;font-style: italic;line-height: 26px;\">\/**<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@Author<\/span>&nbsp;JiaQIng<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@Description<\/span>&nbsp;\u53d1\u9001\u77ed\u4fe1\u76d1\u542c\u5668<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@ClassName<\/span>&nbsp;MessageListener<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@Date<\/span>&nbsp;2023\/3\/26&nbsp;14:16<br>&nbsp;**\/<\/span><br><span style=\"color: #61aeee;line-height: 26px;\">@Component<\/span><br><span style=\"color: #c678dd;line-height: 26px;\">public<\/span>&nbsp;<span style=\"line-height: 26px;\"><span style=\"color: #c678dd;line-height: 26px;\">class<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">MessageListener<\/span>&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">implements<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">ApplicationListener<\/span>&lt;<span style=\"color: #e6c07b;line-height: 26px;\">UserChangePasswordEvent<\/span>&gt;&nbsp;<\/span>{<br><br>&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">@Override<\/span><br>&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"line-height: 26px;\"><span style=\"color: #c678dd;line-height: 26px;\">public<\/span>&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">void<\/span>&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">onApplicationEvent<\/span><span style=\"line-height: 26px;\">(UserChangePasswordEvent&nbsp;event)<\/span>&nbsp;<\/span>{<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;System.out.println(<span style=\"color: #98c379;line-height: 26px;\">\"\u6536\u5230\u4e8b\u4ef6:\"<\/span>&nbsp;+&nbsp;event);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;System.out.println(<span style=\"color: #98c379;line-height: 26px;\">\"\u5f00\u59cb\u6267\u884c\u4e1a\u52a1\u64cd\u4f5c\u7ed9\u7528\u6237\u53d1\u9001\u77ed\u4fe1\u3002\u7528\u6237userId\u4e3a\uff1a\"<\/span>&nbsp;+&nbsp;event.getUserId());<br>&nbsp;&nbsp;&nbsp;&nbsp;}<br>}<br><\/code><\/pre>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">2\u3001\u4f7f\u7528 <code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">@EventListener<\/code> \u6ce8\u89e3\u6807\u6ce8\u5904\u7406\u4e8b\u4ef6\u7684\u65b9\u6cd5\uff0c\u6b64\u65f6 Spring \u5c06\u521b\u5efa\u4e00\u4e2a <code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">ApplicationListener bean<\/code> \u5bf9\u8c61\uff0c\u4f7f\u7528\u7ed9\u5b9a\u7684\u65b9\u6cd5\u5904\u7406\u4e8b\u4ef6\u3002\u6e90\u7801\u5982\u4e0b\u3002\u53c2\u6570\u53ef\u4ee5\u7ed9\u6307\u5b9a\u7684\u4e8b\u4ef6\u3002<\/p>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u8fd9\u91cc\u5de7\u5999\u7684\u7528\u5230\u4e86@AliasFor\u7684\u80fd\u529b\uff0c\u653e\u5230\u4e86<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">@EventListener<\/code>\u8eab\u4e0a \u6ce8\u610f\uff1a\u4e00\u822c\u5efa\u8bae\u90fd\u9700\u8981\u6307\u5b9a\u6b64\u503c\uff0c\u5426\u5219\u9ed8\u8ba4\u53ef\u4ee5\u5904\u7406\u6240\u6709\u7c7b\u578b\u7684\u4e8b\u4ef6\uff0c\u8303\u56f4\u592a\u5e7f\u4e86\u3002<\/p>\n<figure data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 10px;margin-bottom: 10px;display: flex;flex-direction: column;justify-content: center;align-items: center;\">\n  <img decoding=\"async\" class=\"rich_pages wxw-img lazyload\" data-ratio=\"0.4888888888888889\" data-src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-21\/202307310959212929e19aa.png\" src=\"https:\/\/s.nmxc.ltd\/sakurairo_vision\/@2.6\/load_svg\/inload.svg\" onerror=\"imgError(this)\" data-type=\"png\" data-w=\"1080\" style=\"display: block;margin-right: auto;margin-left: auto;\"><noscript><img decoding=\"async\" class=\"rich_pages wxw-img\" data-ratio=\"0.4888888888888889\" src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-21\/202307310959212929e19aa.png\" data-type=\"png\" data-w=\"1080\" style=\"display: block;margin-right: auto;margin-left: auto;\"><\/noscript><br \/>\n <\/figure>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u4ee3\u7801\u5982\u4e0b\u3002\u65b0\u5efa\u4e00\u4e2a\u4e8b\u4ef6\u76d1\u542c\u5668\uff0c\u6ce8\u5165\u5230Spring\u5bb9\u5668\u4e2d\uff0c\u4ea4\u7ed9Spring\u7ba1\u7406\u3002\u5728\u6307\u5b9a\u65b9\u6cd5\u4e0a\u6dfb\u52a0<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">@EventListener<\/code>\u53c2\u6570\u4e3a\u76d1\u542c\u7684\u4e8b\u4ef6\u3002\u65b9\u6cd5\u4e3a\u4e1a\u52a1\u4ee3\u7801\u3002\u4f7f\u7528 <code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">@EventListener<\/code> \u6ce8\u89e3\u7684\u597d\u5904\u662f\u4e00\u4e2a\u7c7b\u53ef\u4ee5\u5199\u5f88\u591a\u76d1\u542c\u5668\uff0c\u5b9a\u5411\u76d1\u542c\u4e0d\u540c\u7684\u4e8b\u4ef6\uff0c\u6216\u8005\u540c\u4e00\u4e2a\u4e8b\u4ef6\u3002<\/p>\n<pre data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 10px;margin-bottom: 10px;border-radius: 5px;box-shadow: rgba(0, 0, 0, 0.55) 0px 2px 10px;\"><span style=\"display: block;background: url(&quot;https:\/\/mmbiz.qpic.cn\/mmbiz_svg\/bofA1vl6EUZR9BtL4F0qwnRS7BMVdib53B0zZ7CwuHEXMOXsubOPuRiaeg03w770JQAIXKLznVdJFFGPNxhUWdicXNfkN4uQbo5\/640?wx_fmt=svg&quot;) 10px 10px \/ 40px no-repeat rgb(40, 44, 52);height: 30px;width: 100%;margin-bottom: -7px;border-radius: 5px;\"><\/span><code style=\"overflow-x: auto;padding: 16px;color: #abb2bf;display: -webkit-box;font-family: Operator Mono, Consolas, Monaco, Menlo, monospace;font-size: 12px;-webkit-overflow-scrolling: touch;padding-top: 15px;background: #282c34;border-radius: 5px;\"><span style=\"color: #5c6370;font-style: italic;line-height: 26px;\">\/**<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@Author<\/span>&nbsp;JiaQIng<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@Description<\/span>&nbsp;\u4e8b\u4ef6\u76d1\u542c\u5668<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@ClassName<\/span>&nbsp;LogListener<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@Date<\/span>&nbsp;2023\/3\/26&nbsp;14:22<br>&nbsp;**\/<\/span><br><span style=\"color: #61aeee;line-height: 26px;\">@Component<\/span><br><span style=\"color: #c678dd;line-height: 26px;\">public<\/span>&nbsp;<span style=\"line-height: 26px;\"><span style=\"color: #c678dd;line-height: 26px;\">class<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">ListenerEvent<\/span>&nbsp;<\/span>{<br><br>&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">@EventListener<\/span>({&nbsp;UserChangePasswordEvent<span style=\"line-height: 26px;\">.<span style=\"color: #c678dd;line-height: 26px;\">class<\/span>&nbsp;})<br>&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">public<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">void<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">LogListener<\/span>(<span style=\"color: #e6c07b;line-height: 26px;\">UserChangePasswordEvent<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">event<\/span>)&nbsp;<\/span>{<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;System.out.println(<span style=\"color: #98c379;line-height: 26px;\">\"\u6536\u5230\u4e8b\u4ef6:\"<\/span>&nbsp;+&nbsp;event);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;System.out.println(<span style=\"color: #98c379;line-height: 26px;\">\"\u5f00\u59cb\u6267\u884c\u4e1a\u52a1\u64cd\u4f5c\u751f\u6210\u5173\u952e\u65e5\u5fd7\u3002\u7528\u6237userId\u4e3a\uff1a\"<\/span>&nbsp;+&nbsp;event.getUserId());<br>&nbsp;&nbsp;&nbsp;&nbsp;}<br><br>&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">@EventListener<\/span>({&nbsp;UserChangePasswordEvent<span style=\"line-height: 26px;\">.<span style=\"color: #c678dd;line-height: 26px;\">class<\/span>&nbsp;})<br>&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">public<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">void<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">messageListener<\/span>(<span style=\"color: #e6c07b;line-height: 26px;\">UserChangePasswordEvent<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">event<\/span>)&nbsp;<\/span>{<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;System.out.println(<span style=\"color: #98c379;line-height: 26px;\">\"\u6536\u5230\u4e8b\u4ef6:\"<\/span>&nbsp;+&nbsp;event);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;System.out.println(<span style=\"color: #98c379;line-height: 26px;\">\"\u5f00\u59cb\u6267\u884c\u4e1a\u52a1\u64cd\u4f5c\u7ed9\u7528\u6237\u53d1\u9001\u77ed\u4fe1\u3002\u7528\u6237userId\u4e3a\uff1a\"<\/span>&nbsp;+&nbsp;event.getUserId());<br>&nbsp;&nbsp;&nbsp;&nbsp;}<br>}<br><\/code><\/pre>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">3\u3001<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">@TransactionalEventListener<\/code>\u6765\u5b9a\u4e49\u4e00\u4e2a\u76d1\u542c\u5668\uff0c\u4ed6\u4e0e<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">@EventListener<\/code>\u4e0d\u540c\u7684\u5c31\u662f<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">@EventListener<\/code>\u6807\u8bb0\u4e00\u4e2a\u65b9\u6cd5\u4f5c\u4e3a\u76d1\u542c\u5668\uff0c\u4ed6\u9ed8\u8ba4\u662f\u540c\u6b65\u6267\u884c\uff0c\u5982\u679c\u53d1\u5e03\u4e8b\u4ef6\u7684\u65b9\u6cd5\u5904\u4e8e\u4e8b\u52a1\u4e2d\uff0c\u90a3\u4e48\u4e8b\u52a1\u4f1a\u5728\u76d1\u542c\u5668\u65b9\u6cd5\u6267\u884c\u5b8c\u6bd5\u4e4b\u540e\u624d\u63d0\u4ea4\u3002\u4e8b\u4ef6\u53d1\u5e03\u4e4b\u540e\u5c31\u7531\u76d1\u542c\u5668\u53bb\u5904\u7406\uff0c\u800c\u4e0d\u8981\u5f71\u54cd\u539f\u6709\u7684\u4e8b\u52a1\uff0c\u4e5f\u5c31\u662f\u8bf4\u5e0c\u671b\u4e8b\u52a1\u53ca\u65f6\u63d0\u4ea4\u3002\u6211\u4eec\u5c31\u53ef\u4ee5\u4f7f\u7528\u8be5\u6ce8\u89e3\u6765\u6807\u8bc6\u3002\u6ce8\u610f\u6b64\u6ce8\u89e3\u9700\u8981spring-tx\u7684\u4f9d\u8d56\u3002<\/p>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u6ce8\u89e3\u6e90\u7801\u5982\u4e0b\uff1a\u4e3b\u8981\u662f\u770b\u4e00\u4e0b\u6ce8\u91ca\u5185\u5bb9\u3002<\/p>\n<pre data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 10px;margin-bottom: 10px;border-radius: 5px;box-shadow: rgba(0, 0, 0, 0.55) 0px 2px 10px;\"><span style=\"display: block;background: url(&quot;https:\/\/mmbiz.qpic.cn\/mmbiz_svg\/bofA1vl6EUZR9BtL4F0qwnRS7BMVdib53B0zZ7CwuHEXMOXsubOPuRiaeg03w770JQAIXKLznVdJFFGPNxhUWdicXNfkN4uQbo5\/640?wx_fmt=svg&quot;) 10px 10px \/ 40px no-repeat rgb(40, 44, 52);height: 30px;width: 100%;margin-bottom: -7px;border-radius: 5px;\"><\/span><code style=\"overflow-x: auto;padding: 16px;color: #abb2bf;display: -webkit-box;font-family: Operator Mono, Consolas, Monaco, Menlo, monospace;font-size: 12px;-webkit-overflow-scrolling: touch;padding-top: 15px;background: #282c34;border-radius: 5px;\"><span style=\"color: #5c6370;font-style: italic;line-height: 26px;\">\/\/&nbsp;\u5728\u8fd9\u4e2a\u6ce8\u89e3\u4e0a\u9762\u6709\u4e00\u4e2a\u6ce8\u89e3\uff1a`@EventListener`\uff0c\u6240\u4ee5\u8868\u660e\u5176\u5b9e\u8fd9\u4e2a\u6ce8\u89e3\u4e5f\u662f\u4e2a\u4e8b\u4ef6\u76d1\u542c\u5668\u3002&nbsp;<\/span><br><span style=\"color: #61aeee;line-height: 26px;\">@Target<\/span>({ElementType.METHOD,&nbsp;ElementType.ANNOTATION_TYPE})<br><span style=\"color: #61aeee;line-height: 26px;\">@Retention<\/span>(RetentionPolicy.RUNTIME)<br><span style=\"color: #61aeee;line-height: 26px;\">@Documented<\/span><br><span style=\"color: #61aeee;line-height: 26px;\">@EventListener<\/span><br><span style=\"color: #c678dd;line-height: 26px;\">public<\/span>&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">@interface<\/span>&nbsp;TransactionalEventListener&nbsp;{<br><br>&nbsp;<span style=\"color: #5c6370;font-style: italic;line-height: 26px;\">\/**<br>&nbsp;&nbsp;*&nbsp;\u8fd9\u4e2a\u6ce8\u89e3\u53d6\u503c\u6709\uff1aBEFORE_COMMIT(\u6307\u5b9a\u76ee\u6807\u65b9\u6cd5\u5728\u4e8b\u52a1commit\u4e4b\u524d\u6267\u884c)\u3001AFTER_COMMIT(\u6307\u5b9a\u76ee\u6807\u65b9\u6cd5\u5728\u4e8b\u52a1commit\u4e4b\u540e\u6267\u884c)\u3001<br>&nbsp;&nbsp;*&nbsp;AFTER_ROLLBACK(\u6307\u5b9a\u76ee\u6807\u65b9\u6cd5\u5728\u4e8b\u52a1rollback\u4e4b\u540e\u6267\u884c)\u3001AFTER_COMPLETION(\u6307\u5b9a\u76ee\u6807\u65b9\u6cd5\u5728\u4e8b\u52a1\u5b8c\u6210\u65f6\u6267\u884c\uff0c\u8fd9\u91cc\u7684\u5b8c\u6210\u662f\u6307\u65e0\u8bba\u4e8b\u52a1\u662f\u6210\u529f\u63d0\u4ea4\u8fd8\u662f\u4e8b\u52a1\u56de\u6eda\u4e86)<br>&nbsp;&nbsp;*&nbsp;\u5404\u4e2a\u503c\u90fd\u4ee3\u8868\u4ec0\u4e48\u610f\u601d\u8868\u8fbe\u4ec0\u4e48\u529f\u80fd\uff0c\u975e\u5e38\u6e05\u6670\uff0c<br>&nbsp;&nbsp;*&nbsp;\u9700\u8981\u6ce8\u610f\u7684\u662f\uff1aAFTER_COMMIT + AFTER_COMPLETION\u662f\u53ef\u4ee5\u540c\u65f6\u751f\u6548\u7684<br>&nbsp;&nbsp;*&nbsp;AFTER_ROLLBACK&nbsp;+&nbsp;AFTER_COMPLETION\u662f\u53ef\u4ee5\u540c\u65f6\u751f\u6548\u7684<br>&nbsp;&nbsp;*\/<\/span><br>&nbsp;<span style=\"line-height: 26px;\">TransactionPhase&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">phase<\/span><span style=\"line-height: 26px;\">()<\/span>&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">default<\/span>&nbsp;TransactionPhase.AFTER_COMMIT<\/span>;<br><br>&nbsp;<span style=\"color: #5c6370;font-style: italic;line-height: 26px;\">\/**<br>&nbsp;&nbsp;*&nbsp;\u8868\u660e\u82e5\u6ca1\u6709\u4e8b\u52a1\u7684\u65f6\u5019\uff0c\u5bf9\u5e94\u7684event\u662f\u5426\u9700\u8981\u6267\u884c\uff0c\u9ed8\u8ba4\u503c\u4e3afalse\u8868\u793a\uff0c\u6ca1\u4e8b\u52a1\u5c31\u4e0d\u6267\u884c\u4e86\u3002<br>&nbsp;&nbsp;*\/<\/span><br>&nbsp;<span style=\"line-height: 26px;\"><span style=\"color: #c678dd;line-height: 26px;\">boolean<\/span>&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">fallbackExecution<\/span><span style=\"line-height: 26px;\">()<\/span>&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">default<\/span>&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">false<\/span><\/span>;<br><br>&nbsp;<span style=\"color: #5c6370;font-style: italic;line-height: 26px;\">\/**<br>&nbsp;&nbsp;*&nbsp;&nbsp;\u8fd9\u91cc\u5de7\u5999\u7684\u7528\u5230\u4e86<span style=\"color: #c678dd;line-height: 26px;\">@AliasFor<\/span>\u7684\u80fd\u529b\uff0c\u653e\u5230\u4e86<span style=\"color: #c678dd;line-height: 26px;\">@EventListener<\/span>\u8eab\u4e0a<br>&nbsp;&nbsp;*&nbsp;&nbsp;\u6ce8\u610f\uff1a\u4e00\u822c\u5efa\u8bae\u90fd\u9700\u8981\u6307\u5b9a\u6b64\u503c\uff0c\u5426\u5219\u9ed8\u8ba4\u53ef\u4ee5\u5904\u7406\u6240\u6709\u7c7b\u578b\u7684\u4e8b\u4ef6\uff0c\u8303\u56f4\u592a\u5e7f\u4e86\u3002<br>&nbsp;&nbsp;*\/<\/span><br>&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">@AliasFor<\/span>(annotation&nbsp;=&nbsp;EventListener<span style=\"line-height: 26px;\">.<span style=\"color: #c678dd;line-height: 26px;\">class<\/span>,&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">attribute<\/span>&nbsp;<\/span>=&nbsp;<span style=\"color: #98c379;line-height: 26px;\">\"classes\"<\/span>)<br>&nbsp;Class&lt;?&gt;[]&nbsp;value()&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">default<\/span>&nbsp;{};<br><br>&nbsp;<span style=\"color: #5c6370;font-style: italic;line-height: 26px;\">\/**<br>&nbsp;&nbsp;*&nbsp;The&nbsp;event&nbsp;classes&nbsp;that&nbsp;this&nbsp;listener&nbsp;handles.<br>&nbsp;&nbsp;*&nbsp;&lt;p&gt;If&nbsp;this&nbsp;attribute&nbsp;is&nbsp;specified&nbsp;with&nbsp;a&nbsp;single&nbsp;value,&nbsp;the&nbsp;annotated<br>&nbsp;&nbsp;*&nbsp;method&nbsp;may&nbsp;optionally&nbsp;accept&nbsp;a&nbsp;single&nbsp;parameter.&nbsp;However,&nbsp;if&nbsp;this<br>&nbsp;&nbsp;*&nbsp;attribute&nbsp;is&nbsp;specified&nbsp;with&nbsp;multiple&nbsp;values,&nbsp;the&nbsp;annotated&nbsp;method<br>&nbsp;&nbsp;*&nbsp;must&nbsp;&lt;em&gt;not&lt;\/em&gt;&nbsp;declare&nbsp;any&nbsp;parameters.<br>&nbsp;&nbsp;*\/<\/span><br>&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">@AliasFor<\/span>(annotation&nbsp;=&nbsp;EventListener<span style=\"line-height: 26px;\">.<span style=\"color: #c678dd;line-height: 26px;\">class<\/span>,&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">attribute<\/span>&nbsp;<\/span>=&nbsp;<span style=\"color: #98c379;line-height: 26px;\">\"classes\"<\/span>)<br>&nbsp;Class&lt;?&gt;[]&nbsp;classes()&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">default<\/span>&nbsp;{};<br><br>&nbsp;<span style=\"color: #5c6370;font-style: italic;line-height: 26px;\">\/**<br>&nbsp;&nbsp;*&nbsp;Spring&nbsp;Expression&nbsp;Language&nbsp;(SpEL)&nbsp;attribute&nbsp;used&nbsp;for&nbsp;making&nbsp;the&nbsp;event<br>&nbsp;&nbsp;*&nbsp;handling&nbsp;conditional.<br>&nbsp;&nbsp;*&nbsp;&lt;p&gt;The&nbsp;default&nbsp;is&nbsp;{<span style=\"color: #c678dd;line-height: 26px;\">@code<\/span>&nbsp;\"\"},&nbsp;meaning&nbsp;the&nbsp;event&nbsp;is&nbsp;always&nbsp;handled.<br>&nbsp;&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@see<\/span>&nbsp;EventListener#condition<br>&nbsp;&nbsp;*\/<\/span><br>&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">@AliasFor<\/span>(annotation&nbsp;=&nbsp;EventListener<span style=\"line-height: 26px;\">.<span style=\"color: #c678dd;line-height: 26px;\">class<\/span>,&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">attribute<\/span>&nbsp;<\/span>=&nbsp;<span style=\"color: #98c379;line-height: 26px;\">\"condition\"<\/span>)<br>&nbsp;<span style=\"line-height: 26px;\">String&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">condition<\/span><span style=\"line-height: 26px;\">()<\/span>&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">default<\/span>&nbsp;\"\"<\/span>;<br><br>&nbsp;<span style=\"color: #5c6370;font-style: italic;line-height: 26px;\">\/**<br>&nbsp;&nbsp;*&nbsp;An&nbsp;optional&nbsp;identifier&nbsp;for&nbsp;the&nbsp;listener,&nbsp;defaulting&nbsp;to&nbsp;the&nbsp;fully-qualified<br>&nbsp;&nbsp;*&nbsp;signature&nbsp;of&nbsp;the&nbsp;declaring&nbsp;method&nbsp;(e.g.&nbsp;\"mypackage.MyClass.myMethod()\").<br>&nbsp;&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@since<\/span>&nbsp;5.3<br>&nbsp;&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@see<\/span>&nbsp;EventListener#id<br>&nbsp;&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@see<\/span>&nbsp;TransactionalApplicationListener#getListenerId()<br>&nbsp;&nbsp;*\/<\/span><br>&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">@AliasFor<\/span>(annotation&nbsp;=&nbsp;EventListener<span style=\"line-height: 26px;\">.<span style=\"color: #c678dd;line-height: 26px;\">class<\/span>,&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">attribute<\/span>&nbsp;<\/span>=&nbsp;<span style=\"color: #98c379;line-height: 26px;\">\"id\"<\/span>)<br>&nbsp;<span style=\"line-height: 26px;\">String&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">id<\/span><span style=\"line-height: 26px;\">()<\/span>&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">default<\/span>&nbsp;\"\"<\/span>;<br><br>}<br><\/code><\/pre>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u4f7f\u7528\u65b9\u5f0f\u5982\u4e0b\u3002phase\u4e8b\u52a1\u7c7b\u578b\uff0cvalue\u6307\u5b9a\u4e8b\u4ef6\u3002<\/p>\n<pre data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 10px;margin-bottom: 10px;border-radius: 5px;box-shadow: rgba(0, 0, 0, 0.55) 0px 2px 10px;\"><span style=\"display: block;background: url(&quot;https:\/\/mmbiz.qpic.cn\/mmbiz_svg\/bofA1vl6EUZR9BtL4F0qwnRS7BMVdib53B0zZ7CwuHEXMOXsubOPuRiaeg03w770JQAIXKLznVdJFFGPNxhUWdicXNfkN4uQbo5\/640?wx_fmt=svg&quot;) 10px 10px \/ 40px no-repeat rgb(40, 44, 52);height: 30px;width: 100%;margin-bottom: -7px;border-radius: 5px;\"><\/span><code style=\"overflow-x: auto;padding: 16px;color: #abb2bf;display: -webkit-box;font-family: Operator Mono, Consolas, Monaco, Menlo, monospace;font-size: 12px;-webkit-overflow-scrolling: touch;padding-top: 15px;background: #282c34;border-radius: 5px;\"><span style=\"color: #5c6370;font-style: italic;line-height: 26px;\">\/**<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@Author<\/span>&nbsp;JiaQIng<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@Description<\/span>&nbsp;\u4e8b\u4ef6\u76d1\u542c\u5668<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@ClassName<\/span>&nbsp;LogListener<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@Date<\/span>&nbsp;2023\/3\/26&nbsp;14:22<br>&nbsp;**\/<\/span><br><span style=\"color: #61aeee;line-height: 26px;\">@Component<\/span><br><span style=\"color: #c678dd;line-height: 26px;\">public<\/span>&nbsp;<span style=\"line-height: 26px;\"><span style=\"color: #c678dd;line-height: 26px;\">class<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">ListenerEvent<\/span>&nbsp;<\/span>{<br><br>&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">@EventListener<\/span>({&nbsp;UserChangePasswordEvent<span style=\"line-height: 26px;\">.<span style=\"color: #c678dd;line-height: 26px;\">class<\/span>&nbsp;})<br>&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">public<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">void<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">logListener<\/span>(<span style=\"color: #e6c07b;line-height: 26px;\">UserChangePasswordEvent<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">event<\/span>)&nbsp;<\/span>{<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;System.out.println(<span style=\"color: #98c379;line-height: 26px;\">\"\u6536\u5230\u4e8b\u4ef6:\"<\/span>&nbsp;+&nbsp;event);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;System.out.println(<span style=\"color: #98c379;line-height: 26px;\">\"\u5f00\u59cb\u6267\u884c\u4e1a\u52a1\u64cd\u4f5c\u751f\u6210\u5173\u952e\u65e5\u5fd7\u3002\u7528\u6237userId\u4e3a\uff1a\"<\/span>&nbsp;+&nbsp;event.getUserId());<br>&nbsp;&nbsp;&nbsp;&nbsp;}<br><br>&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">@TransactionalEventListener<\/span>(phase&nbsp;=&nbsp;TransactionPhase.AFTER_COMMIT,value&nbsp;=&nbsp;{&nbsp;UserChangePasswordEvent<span style=\"line-height: 26px;\">.<span style=\"color: #c678dd;line-height: 26px;\">class<\/span>&nbsp;})<br>&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">public<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">void<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">messageListener<\/span>(<span style=\"color: #e6c07b;line-height: 26px;\">UserChangePasswordEvent<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">event<\/span>)&nbsp;<\/span>{<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;System.out.println(<span style=\"color: #98c379;line-height: 26px;\">\"\u6536\u5230\u4e8b\u4ef6:\"<\/span>&nbsp;+&nbsp;event);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;System.out.println(<span style=\"color: #98c379;line-height: 26px;\">\"\u5f00\u59cb\u6267\u884c\u4e1a\u52a1\u64cd\u4f5c\u7ed9\u7528\u6237\u53d1\u9001\u77ed\u4fe1\u3002\u7528\u6237userId\u4e3a\uff1a\"<\/span>&nbsp;+&nbsp;event.getUserId());<br>&nbsp;&nbsp;&nbsp;&nbsp;}<br>}<br><\/code><\/pre>\n<h3 data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"font-weight: bold;font-size: 20px;margin: 0.6em auto;padding-left: 10px;border-left: 2px solid rgb(0, 150, 136);\"><span style=\"display: none;\"><\/span>\u5982\u4f55\u53d1\u5e03\u4e00\u4e2a\u4e8b\u4ef6<span style=\"display: none;\"><\/span><\/h3>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">1\u3001\u4f7f\u7528<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">ApplicationContext<\/code>\u8fdb\u884c\u53d1\u5e03\uff0c\u7531\u4e8e<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">ApplicationContext <\/code>\u5df2\u7ecf\u7ee7\u627f\u4e86 <code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">ApplicationEventPublisher<\/code> \uff0c\u56e0\u6b64\u53ef\u4ee5\u76f4\u63a5\u4f7f\u7528\u53d1\u5e03\u4e8b\u4ef6\u3002\u6e90\u7801\u5982\u4e0b<\/p>\n<figure data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 10px;margin-bottom: 10px;display: flex;flex-direction: column;justify-content: center;align-items: center;\">\n  <img decoding=\"async\" class=\"rich_pages wxw-img lazyload\" data-ratio=\"0.4740740740740741\" data-src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-21\/2023073109592140407b067.png\" src=\"https:\/\/s.nmxc.ltd\/sakurairo_vision\/@2.6\/load_svg\/inload.svg\" onerror=\"imgError(this)\" data-type=\"png\" data-w=\"1080\" style=\"display: block;margin-right: auto;margin-left: auto;\"><noscript><img decoding=\"async\" class=\"rich_pages wxw-img\" data-ratio=\"0.4740740740740741\" src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-21\/2023073109592140407b067.png\" data-type=\"png\" data-w=\"1080\" style=\"display: block;margin-right: auto;margin-left: auto;\"><\/noscript><br \/>\n <\/figure>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">2\u3001\u76f4\u63a5\u6ce8\u5165\u6211\u4eec\u7684<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">ApplicationEventPublisher<\/code>\uff0c\u4f7f\u7528<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">@Autowired<\/code>\u6ce8\u5165\u4e00\u4e0b\u3002<\/p>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u4e09\u79cd\u53d1\u5e03\u4e8b\u4ef6\u7684\u65b9\u6cd5\uff0c\u6211\u7ed9\u5927\u5bb6\u6f14\u793a\u4e00\u4e0b<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">@Autowired<\/code>\u6ce8\u5165\u7684\u65b9\u5f0f\u53d1\u5e03\u6211\u4eec\u7684\u4e8b\u4ef6\u3002<\/p>\n<pre data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 10px;margin-bottom: 10px;border-radius: 5px;box-shadow: rgba(0, 0, 0, 0.55) 0px 2px 10px;\"><span style=\"display: block;background: url(&quot;https:\/\/mmbiz.qpic.cn\/mmbiz_svg\/bofA1vl6EUZR9BtL4F0qwnRS7BMVdib53B0zZ7CwuHEXMOXsubOPuRiaeg03w770JQAIXKLznVdJFFGPNxhUWdicXNfkN4uQbo5\/640?wx_fmt=svg&quot;) 10px 10px \/ 40px no-repeat rgb(40, 44, 52);height: 30px;width: 100%;margin-bottom: -7px;border-radius: 5px;\"><\/span><code style=\"overflow-x: auto;padding: 16px;color: #abb2bf;display: -webkit-box;font-family: Operator Mono, Consolas, Monaco, Menlo, monospace;font-size: 12px;-webkit-overflow-scrolling: touch;padding-top: 15px;background: #282c34;border-radius: 5px;\"><span style=\"color: #61aeee;line-height: 26px;\">@SpringBootTest<\/span><br><span style=\"line-height: 26px;\"><span style=\"color: #c678dd;line-height: 26px;\">class<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">SpirngEventApplicationTests<\/span>&nbsp;<\/span>{<br>&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">@Autowired<\/span><br>&nbsp;&nbsp;&nbsp;&nbsp;ApplicationEventPublisher&nbsp;appEventPublisher;<br>&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">@Test<\/span><br>&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"line-height: 26px;\"><span style=\"color: #c678dd;line-height: 26px;\">void<\/span>&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">contextLoads<\/span><span style=\"line-height: 26px;\">()<\/span>&nbsp;<\/span>{<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;appEventPublisher.publishEvent(<span style=\"color: #c678dd;line-height: 26px;\">new<\/span>&nbsp;UserChangePasswordEvent(<span style=\"color: #98c379;line-height: 26px;\">\"1111111\"<\/span>));<br>&nbsp;&nbsp;&nbsp;&nbsp;}<br><br>}<br><\/code><\/pre>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u6211\u4eec\u6267\u884c\u4e00\u4e0b\u770b\u4e00\u4e0b\u63a5\u53e3\u3002<\/p>\n<figure data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 10px;margin-bottom: 10px;display: flex;flex-direction: column;justify-content: center;align-items: center;\">\n  <img decoding=\"async\" class=\"rich_pages wxw-img lazyload\" data-ratio=\"0.5361111111111111\" data-src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-22\/2023073109592288887b895.png\" src=\"https:\/\/s.nmxc.ltd\/sakurairo_vision\/@2.6\/load_svg\/inload.svg\" onerror=\"imgError(this)\" data-type=\"png\" data-w=\"1080\" style=\"display: block;margin-right: auto;margin-left: auto;\"><noscript><img decoding=\"async\" class=\"rich_pages wxw-img\" data-ratio=\"0.5361111111111111\" src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-22\/2023073109592288887b895.png\" data-type=\"png\" data-w=\"1080\" style=\"display: block;margin-right: auto;margin-left: auto;\"><\/noscript><br \/>\n <\/figure>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u6d4b\u8bd5\u6210\u529f\u3002<\/p>\n<h2 data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"font-weight: bold;font-size: 22px;color: rgb(0, 150, 136);padding-left: 10px;margin: 1em auto;border-left: 3px solid rgb(0, 150, 136);\"><span style=\"display: none;\"><\/span>\u642d\u914d@Async\u6ce8\u89e3\u5b9e\u73b0\u5f02\u6b65\u64cd\u4f5c<\/h2>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u76d1\u542c\u5668\u9ed8\u8ba4\u662f\u540c\u6b65\u6267\u884c\u7684\uff0c\u5982\u679c\u6211\u4eec\u60f3\u5b9e\u73b0\u5f02\u6b65\u6267\u884c\uff0c\u53ef\u4ee5\u642d\u914d@Async\u6ce8\u89e3\u4f7f\u7528\uff0c\u4f46\u662f\u524d\u63d0\u6761\u4ef6\u662f\u4f60\u771f\u7684\u61c2@Async\u6ce8\u89e3\uff0c\u4f7f\u7528\u4e0d\u5f53\u4f1a\u51fa\u73b0\u95ee\u9898\u7684\u3002\u540e\u7eed\u6211\u4f1a\u51fa\u4e00\u7bc7\u6709\u5173<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">@Async<\/code>\u6ce8\u89e3\u4f7f\u7528\u7684\u6587\u7ae0\u3002\u8fd9\u91cc\u5c31\u4e0d\u7ed9\u5927\u5bb6\u8be6\u7ec6\u7684\u89e3\u91ca\u4e86\u3002\u6709\u60f3\u4e86\u89e3\u7684\u540c\u5b66\u53ef\u4ee5\u53bb\u7f51\u4e0a\u5b66\u4e60\u4e00\u4e0b\u6709\u5173@Async\u6ce8\u89e3\u4f7f\u7528\u3002<\/p>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u4f7f\u7528<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">@Async<\/code>\u65f6\uff0c\u9700\u8981\u914d\u7f6e\u7ebf\u7a0b\u6c60\uff0c\u5426\u5219\u7528\u7684\u8fd8\u662f\u9ed8\u8ba4\u7684\u7ebf\u7a0b\u6c60\u4e5f\u5c31\u662f\u4e3b\u7ebf\u7a0b\u6c60\uff0c\u7ebf\u7a0b\u6c60\u4f7f\u7528\u4e0d\u5f53\u4f1a\u6d6a\u8d39\u8d44\u6e90\uff0c\u4e25\u91cd\u7684\u4f1a\u51fa\u73b0OOM\u4e8b\u6545\u3002<\/p>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u4e0b\u56fe\u662f\u963f\u91cc\u5df4\u5df4\u5f00\u53d1\u624b\u518c\u7684\u5f3a\u5236\u8981\u6c42\u3002<\/p>\n<figure data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 10px;margin-bottom: 10px;display: flex;flex-direction: column;justify-content: center;align-items: center;\">\n  <img decoding=\"async\" class=\"rich_pages wxw-img lazyload\" data-ratio=\"0.43817787418655096\" data-src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-23\/20230731095923bcbc5d2f9.png\" src=\"https:\/\/s.nmxc.ltd\/sakurairo_vision\/@2.6\/load_svg\/inload.svg\" onerror=\"imgError(this)\" data-type=\"png\" data-w=\"922\" style=\"display: block;margin-right: auto;margin-left: auto;\"><noscript><img decoding=\"async\" class=\"rich_pages wxw-img\" data-ratio=\"0.43817787418655096\" src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-23\/20230731095923bcbc5d2f9.png\" data-type=\"png\" data-w=\"922\" style=\"display: block;margin-right: auto;margin-left: auto;\"><\/noscript><br \/>\n <\/figure>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u7b80\u5355\u7684\u6f14\u793a\u4e00\u4e0b\uff1a\u8fd9\u91cc\u58f0\u660e\u4e00\u4e0b\u4ffa\u6ca1\u6709\u4f7f\u7528\u7ebf\u7a0b\u6c60\uff0c\u53ea\u662f\u7b80\u5355\u7684\u6f14\u793a\u4e00\u4e0b\u3002<\/p>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">1\u3001\u5728\u6211\u4eec\u7684\u542f\u52a8\u7c7b\u4e0a\u6dfb\u52a0<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">@EnableAsync<\/code>\u5f00\u542f\u5f02\u6b65\u6267\u884c\u914d\u7f6e<\/p>\n<pre data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 10px;margin-bottom: 10px;border-radius: 5px;box-shadow: rgba(0, 0, 0, 0.55) 0px 2px 10px;\"><span style=\"display: block;background: url(&quot;https:\/\/mmbiz.qpic.cn\/mmbiz_svg\/bofA1vl6EUZR9BtL4F0qwnRS7BMVdib53B0zZ7CwuHEXMOXsubOPuRiaeg03w770JQAIXKLznVdJFFGPNxhUWdicXNfkN4uQbo5\/640?wx_fmt=svg&quot;) 10px 10px \/ 40px no-repeat rgb(40, 44, 52);height: 30px;width: 100%;margin-bottom: -7px;border-radius: 5px;\"><\/span><code style=\"overflow-x: auto;padding: 16px;color: #abb2bf;display: -webkit-box;font-family: Operator Mono, Consolas, Monaco, Menlo, monospace;font-size: 12px;-webkit-overflow-scrolling: touch;padding-top: 15px;background: #282c34;border-radius: 5px;\"><span style=\"color: #61aeee;line-height: 26px;\">@EnableAsync<\/span><br><span style=\"color: #61aeee;line-height: 26px;\">@SpringBootApplication<\/span><br><span style=\"color: #c678dd;line-height: 26px;\">public<\/span>&nbsp;<span style=\"line-height: 26px;\"><span style=\"color: #c678dd;line-height: 26px;\">class<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">SpirngEventApplication<\/span>&nbsp;<\/span>{<br><br>&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"line-height: 26px;\"><span style=\"color: #c678dd;line-height: 26px;\">public<\/span>&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">static<\/span>&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">void<\/span>&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">main<\/span><span style=\"line-height: 26px;\">(String[]&nbsp;args)<\/span>&nbsp;<\/span>{<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;SpringApplication.run(SpirngEventApplication<span style=\"line-height: 26px;\">.<span style=\"color: #c678dd;line-height: 26px;\">class<\/span>,&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">args<\/span>)<\/span>;<br>&nbsp;&nbsp;&nbsp;&nbsp;}<br><br>}<br><\/code><\/pre>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">2\u3001\u5728\u6211\u4eec\u60f3\u8981\u5f02\u6b65\u6267\u884c\u7684\u76d1\u542c\u5668\u4e0a\u6dfb\u52a0<code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">@Async<\/code>\u6ce8\u89e3\u3002<\/p>\n<pre data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 10px;margin-bottom: 10px;border-radius: 5px;box-shadow: rgba(0, 0, 0, 0.55) 0px 2px 10px;\"><span style=\"display: block;background: url(&quot;https:\/\/mmbiz.qpic.cn\/mmbiz_svg\/bofA1vl6EUZR9BtL4F0qwnRS7BMVdib53B0zZ7CwuHEXMOXsubOPuRiaeg03w770JQAIXKLznVdJFFGPNxhUWdicXNfkN4uQbo5\/640?wx_fmt=svg&quot;) 10px 10px \/ 40px no-repeat rgb(40, 44, 52);height: 30px;width: 100%;margin-bottom: -7px;border-radius: 5px;\"><\/span><code style=\"overflow-x: auto;padding: 16px;color: #abb2bf;display: -webkit-box;font-family: Operator Mono, Consolas, Monaco, Menlo, monospace;font-size: 12px;-webkit-overflow-scrolling: touch;padding-top: 15px;background: #282c34;border-radius: 5px;\"><span style=\"color: #5c6370;font-style: italic;line-height: 26px;\">\/**<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@Author<\/span>&nbsp;JiaQIng<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@Description<\/span>&nbsp;\u4e8b\u4ef6\u76d1\u542c\u5668<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@ClassName<\/span>&nbsp;LogListener<br>&nbsp;*&nbsp;<span style=\"color: #c678dd;line-height: 26px;\">@Date<\/span>&nbsp;2023\/3\/26&nbsp;14:22<br>&nbsp;**\/<\/span><br><span style=\"color: #61aeee;line-height: 26px;\">@Component<\/span><br><span style=\"color: #c678dd;line-height: 26px;\">public<\/span>&nbsp;<span style=\"line-height: 26px;\"><span style=\"color: #c678dd;line-height: 26px;\">class<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">ListenerEvent<\/span>&nbsp;<\/span>{<br>&nbsp;&nbsp;&nbsp;&nbsp;<br>&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">@Async<\/span><br>&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"color: #61aeee;line-height: 26px;\">@EventListener<\/span>({&nbsp;UserChangePasswordEvent<span style=\"line-height: 26px;\">.<span style=\"color: #c678dd;line-height: 26px;\">class<\/span>&nbsp;})<br>&nbsp;&nbsp;&nbsp;&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">public<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">void<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">logListener<\/span>(<span style=\"color: #e6c07b;line-height: 26px;\">UserChangePasswordEvent<\/span>&nbsp;<span style=\"color: #e6c07b;line-height: 26px;\">event<\/span>)&nbsp;<\/span>{<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;System.out.println(<span style=\"color: #98c379;line-height: 26px;\">\"\u6536\u5230\u4e8b\u4ef6:\"<\/span>&nbsp;+&nbsp;event);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;System.out.println(<span style=\"color: #98c379;line-height: 26px;\">\"\u5f00\u59cb\u6267\u884c\u4e1a\u52a1\u64cd\u4f5c\u751f\u6210\u5173\u952e\u65e5\u5fd7\u3002\u7528\u6237userId\u4e3a\uff1a\"<\/span>&nbsp;+&nbsp;event.getUserId());<br>&nbsp;&nbsp;&nbsp;&nbsp;}<br>}<br><\/code><\/pre>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u8fd9\u6837\u6211\u4eec\u7684\u5f02\u6b65\u6267\u884c\u76d1\u542c\u5668\u7684\u4e1a\u52a1\u64cd\u4f5c\u5c31\u5b8c\u6210\u4e86\u3002<\/p>\n<h2 data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"font-weight: bold;font-size: 22px;color: rgb(0, 150, 136);padding-left: 10px;margin: 1em auto;border-left: 3px solid rgb(0, 150, 136);\"><span style=\"display: none;\"><\/span>Spring\u7684\u4e8b\u4ef6\u673a\u5236\u7684\u5e94\u7528\u573a\u666f<\/h2>\n<ul data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 8px;margin-bottom: 8px;padding-left: 25px;\" class=\"list-paddingleft-1\">\n<li>\n<section style=\"margin-top: 5px;margin-bottom: 5px;line-height: 26px;color: rgb(1, 1, 1);\">\n<p style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;color: black;text-align: justify;\">\u544a\u8b66\u64cd\u4f5c\uff0c\u6bd4\u55bb\u9489\u9489\u544a\u8b66\uff0c\u5f02\u5e38\u544a\u8b66\uff0c\u53ef\u4ee5\u901a\u8fc7\u4e8b\u4ef6\u673a\u5236\u8fdb\u884c\u89e3\u8026\u3002<\/p>\n<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 5px;margin-bottom: 5px;line-height: 26px;color: rgb(1, 1, 1);\">\n<p style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;color: black;text-align: justify;\">\u5173\u952e\u6027\u65e5\u5fd7\u8bb0\u5f55\u548c\u4e1a\u52a1\u57cb\u70b9\uff0c\u6bd4\u55bb\u8bf4\u6211\u4eec\u7684\u5173\u952e\u65e5\u5fd7\u9700\u8981\u5165\u5e93\uff0c\u8bb0\u5f55\u4e00\u4e0b\u64cd\u4f5c\u65f6\u95f4\uff0c\u64cd\u4f5c\u4eba\uff0c\u53d8\u66f4\u5185\u5bb9\u7b49\u7b49\uff0c\u53ef\u4ee5\u901a\u8fc7\u4e8b\u4ef6\u673a\u5236\u8fdb\u884c\u89e3\u8026\u3002<\/p>\n<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 5px;margin-bottom: 5px;line-height: 26px;color: rgb(1, 1, 1);\">\n<p style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;color: black;text-align: justify;\">\u6027\u80fd\u76d1\u63a7\uff0c\u6bd4\u55bb\u8bf4\u4e00\u4e9b\u63a5\u53e3\u7684\u65f6\u957f\uff0c\u6027\u80fd\u65b9\u4fbf\u7684\u57cb\u70b9\u7b49\u3002\u53ef\u4ee5\u901a\u8fc7\u4e8b\u4ef6\u673a\u5236\u8fdb\u884c\u89e3\u8026\u3002<\/p>\n<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 5px;margin-bottom: 5px;line-height: 26px;color: rgb(1, 1, 1);\">\n<p style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;color: black;text-align: justify;\">.......\u4e00\u5207\u4e0e\u4e3b\u4e1a\u52a1\u65e0\u5173\u7684\u64cd\u4f5c\u90fd\u53ef\u4ee5\u901a\u8fc7\u8fd9\u79cd\u65b9\u5f0f\u8fdb\u884c\u89e3\u8026\uff0c\u5e38\u7528\u7684\u573a\u666f\u5927\u6982\u5c31\u4e0a\u8ff0\u63d0\u5230\u7684\uff0c\u800c\u4e14\u5f88\u591a\u67b6\u6784\u7684\u6e90\u7801\u90fd\u6709\u4f7f\u7528\u8fd9\u79cd\u673a\u5236\uff0c\u5982GateWay\uff0cSpring\u7b49\u7b49\u3002<\/p>\n<\/section>\n<\/li>\n<\/ul>\n<h2 data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"font-weight: bold;font-size: 22px;color: rgb(0, 150, 136);padding-left: 10px;margin: 1em auto;border-left: 3px solid rgb(0, 150, 136);\"><span style=\"display: none;\"><\/span>Spring\u7684\u4e8b\u4ef6\u673a\u5236\u7684\u6ce8\u610f\u4e8b\u9879<\/h2>\n<ul data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 8px;margin-bottom: 8px;padding-left: 25px;\" class=\"list-paddingleft-1\">\n<li>\n<section style=\"margin-top: 5px;margin-bottom: 5px;line-height: 26px;color: rgb(1, 1, 1);\">\n<p style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;color: black;text-align: justify;\">\u5bf9\u4e8e\u540c\u4e00\u4e2a\u4e8b\u4ef6\uff0c\u6709\u591a\u4e2a\u76d1\u542c\u5668\u7684\u65f6\u5019\uff0c\u6ce8\u610f\u53ef\u4ee5\u901a\u8fc7@Order\u6ce8\u89e3\u6307\u5b9a\u987a\u5e8f\uff0cOrder\u7684value\u503c\u8d8a\u5c0f\uff0c\u6267\u884c\u7684\u4f18\u5148\u7ea7\u5c31\u8d8a\u9ad8\u3002<\/p>\n<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 5px;margin-bottom: 5px;line-height: 26px;color: rgb(1, 1, 1);\">\n<p style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;color: black;text-align: justify;\">\u5982\u679c\u53d1\u5e03\u4e8b\u4ef6\u7684\u65b9\u6cd5\u5904\u4e8e\u4e8b\u52a1\u4e2d\uff0c\u90a3\u4e48\u4e8b\u52a1\u4f1a\u5728\u76d1\u542c\u5668\u65b9\u6cd5\u6267\u884c\u5b8c\u6bd5\u4e4b\u540e\u624d\u63d0\u4ea4\u3002\u4e8b\u4ef6\u53d1\u5e03\u4e4b\u540e\u5c31\u7531\u76d1\u542c\u5668\u53bb\u5904\u7406\uff0c\u800c\u4e0d\u8981\u5f71\u54cd\u539f\u6709\u7684\u4e8b\u52a1\uff0c\u4e5f\u5c31\u662f\u8bf4\u5e0c\u671b\u4e8b\u52a1\u53ca\u65f6\u63d0\u4ea4\u3002\u6211\u4eec\u5c31\u53ef\u4ee5 <code style=\"font-size: 14px;padding: 2px 4px;border-radius: 4px;margin-right: 2px;margin-left: 2px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);\">@TransactionalEventListener<\/code>\u6765\u5b9a\u4e49\u4e00\u4e2a\u76d1\u542c\u5668\u3002<\/p>\n<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 5px;margin-bottom: 5px;line-height: 26px;color: rgb(1, 1, 1);\">\n<p style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;color: black;text-align: justify;\">\u76d1\u542c\u5668\u9ed8\u8ba4\u662f\u540c\u6b65\u6267\u884c\u7684\uff0c\u5982\u679c\u6211\u4eec\u60f3\u5b9e\u73b0\u5f02\u6b65\u6267\u884c\uff0c\u53ef\u4ee5\u642d\u914d@Async\u6ce8\u89e3\u4f7f\u7528\uff0c\u4f46\u662f\u524d\u63d0\u6761\u4ef6\u662f\u4f60\u771f\u7684\u61c2@Async\u6ce8\u89e3\uff0c\u4f7f\u7528\u4e0d\u5f53\u4f1a\u51fa\u73b0\u95ee\u9898\u7684\u3002<\/p>\n<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 5px;margin-bottom: 5px;line-height: 26px;color: rgb(1, 1, 1);\">\n<p style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;color: black;text-align: justify;\">\u5bf9\u4e8e\u540c\u4e00\u4e2a\u4e8b\u4ef6\uff0c\u6709\u591a\u4e2a\u76d1\u542c\u5668\u7684\u65f6\u5019\uff0c\u5982\u679c\u51fa\u73b0\u4e86\u5f02\u5e38\uff0c\u540e\u7eed\u7684\u76d1\u542c\u5668\u5c31\u5931\u6548\u4e86\uff0c\u56e0\u4e3a\u4ed6\u662f\u628a\u540c\u4e00\u4e2a\u4e8b\u4ef6\u7684\u76d1\u542c\u5668add\u5728\u4e00\u4e2a\u96c6\u5408\u91cc\u9762\u5faa\u73af\u6267\u884c\uff0c\u5982\u679c\u51fa\u73b0\u5f02\u5e38\uff0c\u9700\u8981\u6ce8\u610f\u6355\u83b7\u5f02\u5e38\u5904\u7406\u5f02\u5e38\u3002<\/p>\n<\/section>\n<\/li>\n<\/ul>\n<h2 data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"font-weight: bold;font-size: 22px;color: rgb(0, 150, 136);padding-left: 10px;margin: 1em auto;border-left: 3px solid rgb(0, 150, 136);\"><span style=\"display: none;\"><\/span>\u540e\u8bb0<\/h2>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"padding-top: 8px;padding-bottom: 8px;line-height: 26px;text-align: justify;\">\u6b64\u6587\u7ae0\u4e3b\u8981\u662f\u8bb2\u89e3\u4ec0\u4e48\u662fSpring\u7684\u4e8b\u4ef6\u673a\u5236\uff0c\u600e\u4e48\u4f7f\u7528Spring\u4e8b\u4ef6\u673a\u5236\uff0c\u5de5\u4f5c\u4e2d\u7684\u573a\u666f\u6709\u54ea\u4e9b\u3002<\/p>\n<blockquote data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"border-top: none;border-bottom: none;font-size: 0.9em;overflow: auto;background: rgba(0, 0, 0, 0.05);padding: 10px 10px 10px 1em;margin-bottom: 20px;margin-top: 20px;border-left-width: 2px;border-left-color: rgb(136, 136, 136);border-right: 2px solid rgb(136, 136, 136);color: rgb(119, 119, 119);\">\n<ul style=\"margin-top: 8px;margin-bottom: 8px;padding-left: 25px;color: black;\" class=\"list-paddingleft-1\">\n<li>\n<section style=\"margin-top: 5px;margin-bottom: 5px;line-height: 26px;color: rgb(1, 1, 1);\">\n     \u6e90\u7801\uff1ahttps:\/\/github.com\/hujiaqing789\/spring-boot-study.git<br \/>\n    <\/section>\n<\/li>\n<\/ul>\n<\/blockquote>\n<\/section>\n<blockquote class=\"js_blockquote_wrap\" data-type=\"2\" data-url=\"\" data-author-name=\"\" data-content-utf8-length=\"37\" data-source-title=\"\" style=\"outline: 0px;color: var(--weui-FG-1);white-space: normal;font-family: Optima-Regular, Optima, PingFangSC-light, PingFangTC-light, &quot;PingFang SC&quot;, Cambria, Cochin, Georgia, Times, &quot;Times New Roman&quot;, serif;letter-spacing: normal;text-align: left;background-color: rgb(255, 255, 255);\">\n<section class=\"js_blockquote_digest\" style=\"outline: 0px;\">\n<section style=\"outline: 0px;\">\n   <span style=\"outline: 0px;font-family: system-ui, -apple-system, BlinkMacSystemFont, &quot;Helvetica Neue&quot;, &quot;PingFang SC&quot;, &quot;Hiragino Sans GB&quot;, &quot;Microsoft YaHei UI&quot;, &quot;Microsoft YaHei&quot;, Arial, sans-serif;letter-spacing: 0.544px;color: rgb(136, 136, 136);cursor: pointer;font-size: 11px;\">\u6765\u6e90\uff1ajuejin.cn\/post\/7214699255507959869<\/span><br \/>\n  <\/section>\n<\/section>\n<\/blockquote>\n<section data-tool=\"mdnice\u7f16\u8f91\u5668\" data-website=\"https:\/\/www.mdnice.com\" style=\"margin-bottom: 0px;padding-right: 10px;padding-left: 10px;outline: 0px;white-space: normal;color: black;font-family: Optima-Regular, Optima, PingFangSC-light, PingFangTC-light, &quot;PingFang SC&quot;, Cambria, Cochin, Georgia, Times, &quot;Times New Roman&quot;, serif;font-size: 16px;letter-spacing: 0px;text-align: left;background-color: rgb(255, 255, 255);line-height: 1.6;word-break: break-word;visibility: visible;\">\n<figure data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 10px;margin-bottom: 10px;outline: 0px;display: flex;flex-direction: column;justify-content: center;align-items: center;\">\n  <strong style=\"outline: 0px;color: rgb(255, 0, 0);font-size: 20px;font-family: mp-quote, -apple-system-font, BlinkMacSystemFont, Arial, sans-serif;letter-spacing: 0.544px;text-align: center;widows: 1;caret-color: rgb(60, 60, 60);\">\u540e\u7aef\u4e13\u5c5e\u6280\u672f\u7fa4<\/strong><br \/>\n <\/figure>\n<\/section>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-bottom: 0px;padding-top: 8px;padding-bottom: 8px;outline: 0px;white-space: normal;color: rgb(0, 0, 0);font-family: Optima-Regular, Optima, PingFangSC-light, PingFangTC-light, &quot;PingFang SC&quot;, Cambria, Cochin, Georgia, Times, &quot;Times New Roman&quot;, serif;font-size: 16px;letter-spacing: normal;caret-color: rgb(60, 60, 60);text-align: center;widows: 1;background-color: rgb(255, 255, 255);line-height: 26px;visibility: visible;\">\u6784\u5efa\u9ad8\u8d28\u91cf\u7684\u6280\u672f\u4ea4\u6d41\u793e\u7fa4\uff0c\u6b22\u8fce\u4ece\u4e8b\u7f16\u7a0b\u5f00\u53d1\u3001\u6280\u672f\u62db\u8058HR\u8fdb\u7fa4\uff0c\u4e5f\u6b22\u8fce\u5927\u5bb6\u5206\u4eab\u81ea\u5df1\u516c\u53f8\u7684\u5185\u63a8\u4fe1\u606f\uff0c\u76f8\u4e92\u5e2e\u52a9\uff0c\u4e00\u8d77\u8fdb\u6b65\uff01<\/p>\n<blockquote data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 20px;margin-bottom: 20px;padding: 10px 10px 10px 1em;outline: 0px;border-left-width: 2px;border-left-color: rgb(136, 136, 136);color: rgb(119, 119, 119);font-size: 0.9em;white-space: normal;font-family: Optima-Regular, Optima, PingFangSC-light, PingFangTC-light, &quot;PingFang SC&quot;, Cambria, Cochin, Georgia, Times, &quot;Times New Roman&quot;, serif;letter-spacing: normal;text-align: left;caret-color: rgb(60, 60, 60);widows: 1;border-top: none;border-bottom: none;overflow: auto;background: rgba(0, 0, 0, 0.05);border-right: 2px solid rgb(136, 136, 136);visibility: visible;\">\n<p style=\"padding-top: 8px;padding-bottom: 8px;outline: 0px;font-size: 16px;text-align: justify;color: black;line-height: 26px;visibility: visible;\">\u6587\u660e\u53d1\u8a00\uff0c\u4ee5<code style=\"margin-right: 2px;margin-left: 2px;padding: 2px 4px;outline: 0px;font-size: 14px;border-radius: 4px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);visibility: visible;\">\u4ea4\u6d41\u6280\u672f<\/code>\u3001<code style=\"margin-right: 2px;margin-left: 2px;padding: 2px 4px;outline: 0px;font-size: 14px;border-radius: 4px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);visibility: visible;\">\u804c\u4f4d\u5185\u63a8<\/code>\u3001<code style=\"margin-right: 2px;margin-left: 2px;padding: 2px 4px;outline: 0px;font-size: 14px;border-radius: 4px;background-color: rgba(27, 31, 35, 0.05);font-family: &quot;Operator Mono&quot;, Consolas, Monaco, Menlo, monospace;word-break: break-all;color: rgb(0, 150, 136);visibility: visible;\">\u884c\u4e1a\u63a2\u8ba8<\/code>\u4e3a\u4e3b<\/p>\n<\/blockquote>\n<p data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-bottom: 0px;padding-top: 8px;padding-bottom: 8px;outline: 0px;white-space: normal;color: rgb(0, 0, 0);font-family: Optima-Regular, Optima, PingFangSC-light, PingFangTC-light, &quot;PingFang SC&quot;, Cambria, Cochin, Georgia, Times, &quot;Times New Roman&quot;, serif;font-size: 16px;letter-spacing: normal;caret-color: rgb(60, 60, 60);text-align: center;widows: 1;background-color: rgb(255, 255, 255);line-height: 26px;visibility: visible;\">\u5e7f\u544a\u4eba\u58eb\u52ff\u5165\uff0c\u5207\u52ff\u8f7b\u4fe1\u79c1\u804a\uff0c\u9632\u6b62\u88ab\u9a97<\/p>\n<p style=\"margin-bottom: 0px;outline: 0px;font-family: system-ui, -apple-system, BlinkMacSystemFont, &quot;Helvetica Neue&quot;, &quot;PingFang SC&quot;, &quot;Hiragino Sans GB&quot;, &quot;Microsoft YaHei UI&quot;, &quot;Microsoft YaHei&quot;, Arial, sans-serif;letter-spacing: 0.544px;white-space: normal;color: rgb(0, 0, 0);font-size: 16px;background-color: rgb(255, 255, 255);text-align: center;\"><img decoding=\"async\" class=\"rich_pages wxw-img lazyload\" data-galleryid=\"\" data-ratio=\"1.0212201591511936\" data-s=\"300,640\" data-src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-24\/20230731095924a3a38e0f7.png\" src=\"https:\/\/s.nmxc.ltd\/sakurairo_vision\/@2.6\/load_svg\/inload.svg\" onerror=\"imgError(this)\" data-type=\"png\" data-w=\"377\" style=\"outline: 0px;visibility: visible !important;width: 204px !important;\"><noscript><img decoding=\"async\" class=\"rich_pages wxw-img\" data-galleryid=\"\" data-ratio=\"1.0212201591511936\" data-s=\"300,640\" src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-24\/20230731095924a3a38e0f7.png\" data-type=\"png\" data-w=\"377\" style=\"outline: 0px;visibility: visible !important;width: 204px !important;\"><\/noscript><\/p>\n<figure data-tool=\"mdnice\u7f16\u8f91\u5668\" style=\"margin-top: 10px;margin-bottom: 10px;outline: 0px;white-space: normal;color: rgb(0, 0, 0);font-family: Optima-Regular, Optima, PingFangSC-light, PingFangTC-light, &quot;PingFang SC&quot;, Cambria, Cochin, Georgia, Times, &quot;Times New Roman&quot;, serif;font-size: 16px;letter-spacing: normal;text-align: left;caret-color: rgb(60, 60, 60);widows: 1;background-color: rgb(255, 255, 255);display: flex;flex-direction: column;justify-content: center;align-items: center;visibility: visible;\"><figcaption style=\"margin-top: 5px;outline: 0px;text-align: center;color: rgb(136, 136, 136);font-size: 14px;visibility: visible;\">\n  \u52a0\u6211\u597d\u53cb\uff0c\u62c9\u4f60\u8fdb\u7fa4<br \/>\n <\/figcaption><\/figure>\n<p style=\"display: none;\">\n <mp-style-type data-value=\"3\"><\/mp-style-type><\/p>\n<p>\u672c\u7bc7\u6587\u7ae0\u6765\u6e90\u4e8e\u5fae\u4fe1\u516c\u4f17\u53f7\uff1a\u4f5c\u8005\uff1a\u4f73\u5e86 Java\u7b14\u8bb0\u867e Java\u7b14\u8bb0\u867e \u5fae\u4fe1\u53f7 it_coders \u529f\u80fd\u4ecb\u7ecd \u4e13\u6ce8\u4e8eJava\u6280\u672f\u6808\uff0c\u63a8\u9001 Spring\u5168\u5bb6\u6876\uff0cDubbo\uff0cZookeeper\uff0cRedis\uff0cLinux\uff0c\u591a\u7ebf\u7a0b\u7b49\u76f8\u5173\u6280\u672f\u77e5\u8bc6\uff0c\u6587\u7ae0\u4ee5\u89e3\u51b3\u5b9e\u9645\u95ee\u9898\u4e3a\u4e3b\uff0c\u6b22\u8fce\u63a2\u8ba8\u3002 \u53d1\u8868\u4e8e<br \/>\u8f6c\u8f7d\u5730\u5740\uff1ahttps:\/\/mp.weixin.qq.com\/s\/G4vdw4ux0-Yb2ula7kLn1g<\/p>\n","raw":"","protected":false},"excerpt":{"rendered":"<p>\u524d\u8a00 \u672c\u6587\u4e3b\u8981\u662f\u7b80\u5355\u7684\u8bb2\u8ff0\u4e86Spring\u7684\u4e8b\u4ef6\u673a\u5236\uff0c\u57fa\u672c\u6982\u5ff5\uff0c\u8bb2\u8ff0\u4e86\u4e8b\u4ef6\u673a\u5236\u7684\u4e09\u8981\u7d20\u4e8b\u4ef6\u3001\u4e8b\u4ef6\u53d1\u5e03\u3001\u4e8b\u4ef6\u76d1\u542c\u5668\u3002\u5982\u4f55\u5b9e\u73b0\u4e00\u4e2a\u4e8b\u4ef6\u673a &#8230;<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"emotion":"","emotion_color":"","title_style":"","license":"","footnotes":""},"categories":[6,7],"tags":[],"class_list":["post-3042","post","type-post","status-publish","format-standard","hentry","category-spring","category-spring-boot"],"post_thumbnail_image":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-15\/20230731095915f9f92908a.png","content_first_image":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-15\/20230731095915f9f92908a.png","post_medium_image_300":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-15\/20230731095915f9f92908a.png","post_thumbnail_image_624":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-15\/20230731095915f9f92908a.png","post_frist_image":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-15\/20230731095915f9f92908a.png","post_medium_image":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-15\/20230731095915f9f92908a.png","post_large_image":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-15\/20230731095915f9f92908a.png","post_full_image":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-15\/20230731095915f9f92908a.png","post_all_images":[{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-15\/20230731095915f9f92908a.png","id":"image0"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-15\/20230731095915f9f92908a.png","id":"image1"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-16\/2023073109591696962852e.png","id":"image2"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-16\/2023073109591696962852e.png","id":"image3"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-17\/20230731095917fefe25dc3.png","id":"image4"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-17\/20230731095917fefe25dc3.png","id":"image5"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-18\/202307310959189898697eb.png","id":"image6"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-18\/202307310959189898697eb.png","id":"image7"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-19\/20230731095919949481b78.png","id":"image8"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-19\/20230731095919949481b78.png","id":"image9"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-21\/202307310959212929e19aa.png","id":"image10"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-21\/202307310959212929e19aa.png","id":"image11"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-21\/2023073109592140407b067.png","id":"image12"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-21\/2023073109592140407b067.png","id":"image13"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-22\/2023073109592288887b895.png","id":"image14"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-22\/2023073109592288887b895.png","id":"image15"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-23\/20230731095923bcbc5d2f9.png","id":"image16"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-23\/20230731095923bcbc5d2f9.png","id":"image17"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-24\/20230731095924a3a38e0f7.png","id":"image18"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/default\/nine\/2023-07-31\/09-59-24\/20230731095924a3a38e0f7.png","id":"image19"}],"videoAdId":"","listAd":"0","listAdId":"","listAdEvery":6,"total_comments":0,"category_name":"Spring","post_date":"2023-07-31","like_count":"0","praiseWord":"\u9f13\u52b1","copyright_state":"","excitationAd":"0","rewardedVideoAdId":"","detailAdId":"","detailAd":"0","enterpriseMinapp":"0","audios":[],"postImageUrl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2023\/05\/20230519082947553.jpg","avatarurls":[],"related_posts":null,"pageviews":858,"next_post_id":3043,"next_post_title":"\u7262\u8bb0\u8fd916\u4e2aSpringBoot \u6269\u5c55\u63a5\u53e3\uff0c\u5199\u51fa\u66f4\u52a0\u6f02\u4eae\u7684\u4ee3\u7801","previous_post_id":3022,"previous_post_title":"\u63a5\u53e3handlerinterceptor\u4e2d preHandle\u3001postHandle\u4e0eafterCompletion\u7684\u4f7f\u7528","_links":{"self":[{"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/posts\/3042","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/comments?post=3042"}],"version-history":[{"count":0,"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/posts\/3042\/revisions"}],"wp:attachment":[{"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/media?parent=3042"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/categories?post=3042"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/tags?post=3042"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}