{"id":311581,"date":"2024-05-20T22:18:18","date_gmt":"2024-05-20T14:18:18","guid":{"rendered":"https:\/\/docs.pingcode.com\/ask\/ask-ask\/311581.html"},"modified":"2024-05-20T22:18:24","modified_gmt":"2024-05-20T14:18:24","slug":"%e6%80%8e%e4%b9%88%e6%b7%bb%e5%8a%a0noverify%e5%88%b0java%e8%bf%90%e8%a1%8c%e7%8e%af%e5%a2%83%e9%85%8d%e7%bd%ae","status":"publish","type":"post","link":"https:\/\/docs.pingcode.com\/ask\/311581.html","title":{"rendered":"\u600e\u4e48\u6dfb\u52a0noverify\u5230Java\u8fd0\u884c\u73af\u5883\u914d\u7f6e"},"content":{"rendered":"<p style=\"text-align:center\"><img decoding=\"async\" src=\"https:\/\/cdn-kb.worktile.com\/kb\/wp-content\/uploads\/2024\/04\/26232327\/ab6a9f99-80ab-40b8-a2bc-d3489c7a1f43.webp\" alt=\"\u600e\u4e48\u6dfb\u52a0noverify\u5230Java\u8fd0\u884c\u73af\u5883\u914d\u7f6e\" \/><\/p>\n<p><p>\u4e3a\u4e86\u7981\u7528Java\u7c7b\u7684\u9a8c\u8bc1\u8fc7\u7a0b\uff0c\u53ef\u4ee5\u901a\u8fc7\u6dfb\u52a0noverify JVM\u53c2\u6570\u6765\u5b9e\u73b0\u3002<strong>\u542f\u52a8Java\u5e94\u7528\u65f6\uff0c\u6dfb\u52a0noverify\u53c2\u6570\u6709\u52a9\u4e8e\u63d0\u9ad8\u542f\u52a8\u901f\u5ea6\u3001\u51cf\u8f7b\u542f\u52a8\u65f6\u7684\u7cfb\u7edf\u8d44\u6e90\u6d88\u8017<\/strong>\u3002\u8fd9\u662f\u56e0\u4e3a\u7c7b\u9a8c\u8bc1\u6b65\u9aa4\u4e3b\u8981\u8d1f\u8d23\u68c0\u67e5\u5b57\u8282\u7801\u5bf9\u4e8e\u865a\u62df\u673a\u662f\u5426\u5b89\u5168\uff0c\u82e5\u4f60\u7684Java\u5e94\u7528\u6765\u81ea\u53ef\u4fe1\u6765\u6e90\uff0c\u7981\u7528\u9a8c\u8bc1\u53ef\u4ee5\u5728\u4e0d\u5f71\u54cd\u5e94\u7528\u8fd0\u884c\u7684\u524d\u63d0\u4e0b\u51cf\u5c11\u8fd9\u90e8\u5206\u6d88\u8017\u3002<\/p>\n<\/p>\n<p><p>\u4e00\u3001<strong>\u6dfb\u52a0NOVERIFY\u5230\u547d\u4ee4\u884c\u542f\u52a8<\/strong><\/p>\n<\/p>\n<p><p>\u5728Java\u5e94\u7528\u542f\u52a8\u65f6\uff0c\u53ef\u4ee5\u76f4\u63a5\u5728\u547d\u4ee4\u884c\u4e2d\u6dfb\u52a0noverify\u53c2\u6570\u3002\u4f8b\u5982\uff0c\u5982\u679c\u4f60\u6709\u4e00\u4e2a\u540d\u4e3aMyApplication\u7684Java\u7a0b\u5e8f\uff0c\u4f60\u901a\u5e38\u4f1a\u4f7f\u7528\u5982\u4e0b\u547d\u4ee4\u6765\u542f\u52a8\u5b83\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-shell\">java MyApplication<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u8981\u6dfb\u52a0noverify\u53c2\u6570\uff0c\u4fee\u6539\u4e0a\u8ff0\u547d\u4ee4\u5982\u4e0b\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-shell\">java -noverify MyApplication<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u8fd9\u6837\uff0c\u6bcf\u6b21\u4f7f\u7528\u547d\u4ee4\u884c\u542f\u52a8Java\u7a0b\u5e8f\u65f6\uff0cJVM\u5c31\u4f1a\u8df3\u8fc7\u7c7b\u9a8c\u8bc1\u8fc7\u7a0b\u3002<\/p>\n<\/p>\n<p><p>\u4e8c\u3001<strong>\u914d\u7f6eIDE\u4ee5\u4f7f\u7528NOVERIFY\u53c2\u6570<\/strong><\/p>\n<\/p>\n<p><p>\u5982\u679c\u4f60\u4f7f\u7528\u96c6\u6210\u5f00\u53d1\u73af\u5883\uff08IDE\uff09\u5982Eclipse\u3001IntelliJ IDEA\u7b49\u5f00\u53d1Java\u7a0b\u5e8f\uff0c\u5927\u591a\u6570IDE\u90fd\u5141\u8bb8\u4f60\u914d\u7f6e\u8fd0\u884c\u73af\u5883\u53ca\u53c2\u6570\u3002\u5177\u4f53\u6b65\u9aa4\u5982\u4e0b\uff1a<\/p>\n<\/p>\n<ul>\n<li>\u5728Eclipse\u4e2d\uff0c\u5728\u201cRun Configurations\u201d\u7a97\u53e3\u4e2d\u627e\u5230\u4f60\u7684\u5e94\u7528\u7a0b\u5e8f\uff0c\u7136\u540e\u5230\u201cArguments\u201d\u9009\u9879\u5361\uff0c\u5728\u201cVM arguments\u201d\u6bb5\u843d\u4e2d\u8f93\u5165-noverify\u3002<\/li>\n<li>\u5728IntelliJ IDEA\u4e2d\uff0c\u5728\u201cRun\/Debug Configurations\u201d\u7a97\u53e3\u4e2d\u627e\u5230\u4f60\u7684\u5e94\u7528\u7a0b\u5e8f\uff0c\u540c\u6837\u5728\u201cVM options\u201d\u90e8\u5206\u4e2d\u6dfb\u52a0-noverify\u3002<\/li>\n<\/ul>\n<p><p>\u4e09\u3001<strong>\u5728\u7cfb\u7edf\u73af\u5883\u53d8\u91cf\u4e2d\u914d\u7f6eNOVERIFY<\/strong><\/p>\n<\/p>\n<p><p>\u5982\u679c\u4f60\u5e0c\u671b\u6240\u6709\u901a\u8fc7\u547d\u4ee4\u884c\u542f\u52a8\u7684Java\u5e94\u7528\u9ed8\u8ba4\u4f7f\u7528noverify\u53c2\u6570\uff0c\u53ef\u4ee5\u5c06\u5176\u6dfb\u52a0\u5230\u7cfb\u7edf\u7684\u73af\u5883\u53d8\u91cf\u4e2d\u3002\u4ee5Windows\u4e3a\u4f8b\uff0c\u6b65\u9aa4\u5982\u4e0b\uff1a<\/p>\n<\/p>\n<ol>\n<li>\u6253\u5f00\u7cfb\u7edf\u201c\u73af\u5883\u53d8\u91cf\u201d\u8bbe\u7f6e\u754c\u9762\u3002<\/li>\n<li>\u5728\u201c\u7cfb\u7edf\u53d8\u91cf\u201d\u4e2d\u627e\u5230\u540d\u4e3a\u201cJAVA_TOOL_OPTIONS\u201d\u7684\u53d8\u91cf\uff08\u5982\u679c\u4e0d\u5b58\u5728\uff0c\u5219\u65b0\u5efa\u6b64\u53d8\u91cf\uff09\u3002<\/li>\n<li>\u7f16\u8f91\u53d8\u91cf\u503c\uff0c\u6dfb\u52a0\u201c-noverify\u201d\u81f3\u53d8\u91cf\u503c\u5b57\u7b26\u4e32\u4e2d\uff0c\u4f8b\uff1a\u201c-noverify\u201d\u3002<\/li>\n<\/ol>\n<p><p><strong>\u786e\u4fdd\u53ea\u8fdb\u884c\u4e86\u5fc5\u8981\u7684\u66f4\u6539\uff0c\u5e76\u4fdd\u5b58\u8bbe\u7f6e\u3002<\/strong><\/p>\n<\/p>\n<p><p>\u56db\u3001<strong>\u5728\u5e94\u7528\u670d\u52a1\u5668\u4e2d\u8bbe\u7f6eNOVERIFY\u53c2\u6570<\/strong><\/p>\n<\/p>\n<p><p>\u90e8\u7f72Java WEB\u5e94\u7528\u7684\u670d\u52a1\u5668\uff08\u5982Tomcat\u3001JBoss\u3001WebLogic\u7b49\uff09\u4e5f\u5141\u8bb8\u4f60\u6dfb\u52a0JVM\u53c2\u6570\u3002\u4f8b\u5982\uff0c\u5728Tomcat\u4e2d\uff0c\u4f60\u53ef\u4ee5\u5728catalina.sh\uff08\u6216catalina.bat\uff09\u6587\u4ef6\u4e2d\u8bbe\u7f6eJAVA_OPTS\u53d8\u91cf\uff0c\u52a0\u4e0a-noverify\u53c2\u6570\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-shell\">export JAVA_OPTS=&quot;$JAVA_OPTS -noverify&quot;<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p><strong>\u8fd9\u5c06\u4f7f\u5f97Tomcat\u542f\u52a8\u65f6\u6240\u6709\u7684Java\u5e94\u7528\u90fd\u5c06\u8df3\u8fc7\u7c7b\u9a8c\u8bc1\u3002<\/strong><\/p>\n<\/p>\n<p><p>\u4e94\u3001<strong>\u6ce8\u610f\u4e8b\u9879<\/strong><\/p>\n<\/p>\n<p><p>\u5728\u51b3\u5b9a\u6dfb\u52a0noverify\u53c2\u6570\u65f6\u5fc5\u9700\u8003\u8651\u5b89\u5168\u98ce\u9669\u3002\u56e0\u4e3a\u7981\u7528\u7c7b\u9a8c\u8bc1\u53ef\u80fd\u4f1a\u4f7fJava\u5e94\u7528\u9762\u4e34\u672a\u9a8c\u8bc1\u7684\u5b57\u8282\u7801\u6267\u884c\u7684\u98ce\u9669\uff0c\u8fd9\u5728\u67d0\u4e9b\u60c5\u51b5\u4e0b\u53ef\u80fd\u4f1a\u5bfc\u81f4\u5b89\u5168\u6f0f\u6d1e\u3002\u56e0\u6b64\uff0c<strong>\u63a8\u8350\u4ec5\u5728\u5f00\u53d1\u73af\u5883\u53ca\u5b8c\u5168\u4fe1\u4efb\u4ee3\u7801\u6e90\u7684\u73af\u5883\u4e0b\u4f7f\u7528noverify\u53c2\u6570\uff0c\u5e76\u5728\u90e8\u7f72\u81f3\u751f\u4ea7\u73af\u5883\u524d\u8fdb\u884c\u9002\u5f53\u7684\u5b89\u5168\u5ba1\u67e5\u4e0e\u6d4b\u8bd5\u3002<\/strong><\/p>\n<\/p>\n<p><p>\u4ee5\u4e0a\u662f\u4e3aJava\u8fd0\u884c\u73af\u5883\u914d\u7f6e\u65e0\u9a8c\u8bc1\u542f\u52a8\uff08noverify\uff09\u7684\u4e3b\u8981\u65b9\u6cd5\u548c\u6ce8\u610f\u4e8b\u9879\u3002\u901a\u8fc7\u8df3\u8fc7\u8017\u65f6\u7684\u9a8c\u8bc1\u6b65\u9aa4\uff0c\u53ef\u4ee5\u663e\u8457\u52a0\u901fJava\u5e94\u7528\u7684\u542f\u52a8\u65f6\u95f4\uff0c\u7279\u522b\u662f\u5bf9\u4e8e\u62e5\u6709\u5927\u91cf\u7c7b\u7684\u590d\u6742\u5e94\u7528\u800c\u8a00\u3002\u7136\u800c\uff0c\u5f3a\u8c03\u5b89\u5168\u9996\u8981\u539f\u5219\uff0c\u5728\u4efb\u4f55\u9700\u8981\u8003\u8651\u5b89\u5168\u6027\u7684\u73af\u5883\u4e2d\uff0c\u8c28\u614e\u4f7f\u7528\u8fd9\u4e00\u53c2\u6570\u4ee5\u9632\u6b62\u6f5c\u5728\u7684\u5b89\u5168\u9690\u60a3\u3002<\/p>\n<\/p>\n<h2><strong>\u76f8\u5173\u95ee\u7b54FAQs\uff1a<\/strong><\/h2>\n<p><strong>\u5982\u4f55\u5728Java\u8fd0\u884c\u73af\u5883\u914d\u7f6e\u4e2d\u6dfb\u52a0noverify\uff1f<\/strong><\/p>\n<ol>\n<li>\n<p><strong>\u4e3a\u4ec0\u4e48\u9700\u8981\u5728Java\u8fd0\u884c\u73af\u5883\u914d\u7f6e\u4e2d\u6dfb\u52a0noverify\uff1f<\/strong><br \/>\nnoverify\u662f\u4e00\u4e2aJava\u865a\u62df\u673a\u53c2\u6570\uff0c\u7528\u4e8e\u7981\u7528\u7c7b\u6587\u4ef6\u9a8c\u8bc1\uff0c\u53ef\u4ee5\u63d0\u9ad8Java\u7a0b\u5e8f\u7684\u542f\u52a8\u901f\u5ea6\u3002\u4f46\u9700\u8981\u6ce8\u610f\u7684\u662f\uff0c\u53ea\u6709\u5728\u4f60\u5bf9\u6240\u8981\u8fd0\u884c\u7684\u7a0b\u5e8f\u975e\u5e38\u4fe1\u4efb\uff0c\u5e76\u4e14\u65e0\u9700\u8fdb\u884c\u7c7b\u6587\u4ef6\u9a8c\u8bc1\u65f6\uff0c\u624d\u5e94\u8be5\u4f7f\u7528noverify\u3002<\/p>\n<\/li>\n<li>\n<p><strong>\u5982\u4f55\u6dfb\u52a0noverify\u5230Java\u8fd0\u884c\u73af\u5883\u914d\u7f6e\uff1f<\/strong><br \/>\n\u7b2c\u4e00\u79cd\u65b9\u6cd5\u662f\u5728\u542f\u52a8Java\u7a0b\u5e8f\u65f6\u6dfb\u52a0\u865a\u62df\u673a\u53c2\u6570\u3002\u53ef\u4ee5\u5728\u547d\u4ee4\u884c\u4e2d\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\u6765\u6dfb\u52a0noverify\u53c2\u6570\uff1a<\/p>\n<pre><code>java -noverify YourProgram\n<\/code><\/pre>\n<p>\u8fd9\u5c06\u4f7f\u7528noverify\u53c2\u6570\u8fd0\u884cYourProgram\u3002<\/p>\n<p>\u7b2c\u4e8c\u79cd\u65b9\u6cd5\u662f\u901a\u8fc7\u7f16\u8f91Java\u8fd0\u884c\u73af\u5883\u914d\u7f6e\u6587\u4ef6\u6765\u6dfb\u52a0noverify\u53c2\u6570\u3002\u9996\u5148\uff0c\u627e\u5230\u4f60\u7684Java\u5b89\u88c5\u76ee\u5f55\u4e2d\u7684&quot;jre\/lib\/&quot;\u6587\u4ef6\u5939\uff0c\u7136\u540e\u627e\u5230&quot;jvm.cfg&quot;\u6587\u4ef6\u3002\u4f7f\u7528\u6587\u672c\u7f16\u8f91\u5668\u6253\u5f00\u8be5\u6587\u4ef6\uff0c\u627e\u5230\u4e00\u884c\u4ee5&quot;-client&quot;\u6216&quot;-server&quot;\u5f00\u5934\u7684\u884c\uff0c\u5e76\u5728\u8be5\u884c\u7684\u672b\u5c3e\u6dfb\u52a0\u53c2\u6570&quot;-noverify&quot;\u3002\u4fdd\u5b58\u6587\u4ef6\u540e\uff0c\u91cd\u65b0\u542f\u52a8Java\u7a0b\u5e8f\u5373\u53ef\u5e94\u7528\u66f4\u6539\u3002<\/p>\n<\/li>\n<li>\n<p><strong>\u6709\u54ea\u4e9b\u9700\u8981\u6ce8\u610f\u7684\u4e8b\u9879\uff1f<\/strong><br \/>\n\u4f7f\u7528noverify\u53c2\u6570\u662f\u9700\u8981\u614e\u91cd\u8003\u8651\u7684\uff0c\u56e0\u4e3a\u5b83\u7981\u7528\u4e86\u7c7b\u6587\u4ef6\u7684\u9a8c\u8bc1\u673a\u5236\u3002\u8fd9\u610f\u5473\u7740\uff0c\u5982\u679c\u4f60\u8fd0\u884c\u7684\u7a0b\u5e8f\u662f\u6765\u81ea\u4e0d\u53d7\u4fe1\u4efb\u7684\u6765\u6e90\u6216\u5305\u542b\u672a\u77e5\u7684\u4ee3\u7801\uff0c\u90a3\u4e48\u8fd0\u884c\u7a0b\u5e8f\u53ef\u80fd\u4f1a\u5e26\u6765\u6f5c\u5728\u7684\u5b89\u5168\u98ce\u9669\u3002\u56e0\u6b64\uff0c\u5728\u4f7f\u7528noverify\u53c2\u6570\u4e4b\u524d\uff0c\u8bf7\u786e\u4fdd\u4f60\u7406\u89e3\u5e76\u4fe1\u4efb\u8981\u8fd0\u884c\u7684\u7a0b\u5e8f\uff0c\u4ee5\u907f\u514d\u6f5c\u5728\u7684\u5b89\u5168\u95ee\u9898\u3002<\/p>\n<\/li>\n<\/ol>\n","protected":false},"excerpt":{"rendered":"\u4e3a\u4e86\u7981\u7528Java\u7c7b\u7684\u9a8c\u8bc1\u8fc7\u7a0b\uff0c\u53ef\u4ee5\u901a\u8fc7\u6dfb\u52a0noverify JVM\u53c2\u6570\u6765\u5b9e\u73b0\u3002\u542f\u52a8Java\u5e94\u7528\u65f6\uff0c\u6dfb\u52a0nove [&hellip;]","protected":false},"author":3,"featured_media":311592,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[37],"tags":[],"acf":[],"_links":{"self":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/311581"}],"collection":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/comments?post=311581"}],"version-history":[{"count":0,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/311581\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media\/311592"}],"wp:attachment":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media?parent=311581"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/categories?post=311581"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/tags?post=311581"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}