我正在使用 icedtea javaws(版本:icedtea-web 1.6.2 (1.6.2-3ubuntu1))来分发我的 java 应用程序。
我的 jnlp 文件如下所示:
<jnlp spec="1.0+" codebase="/">
<information>
<title>My Application</title>
<vendor>Software Studio</vendor>
<offline-allowed/>
</information>
<resources>
<!-- Application Resources -->
<jar href="MyApplication-1.0.jar"></jar>
</resources>
<application-desc main-class="com.myapp.application.Application">
<!-- Application Arguments -->
</application-desc>
<security>
<all-permissions/>
</security>
</jnlp>
应用程序 jnlp 文件和资源 MyApplication-1.0.jar 文件托管在 apache Web 服务器中。我在访问日志中注意到,一些客户端在短时间内多次请求 jar 文件。下面是我的 apache access_log 文件的内容片段,显示了这个问题:
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:48:24 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:48:30 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:48:36 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:48:43 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:48:49 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:48:55 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:49:01 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:49:07 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:49:13 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:49:20 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:49:26 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:49:33 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:49:39 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:49:45 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:49:51 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:49:57 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:50:03 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:50:10 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:50:16 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:50:22 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:50:28 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:50:34 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:50:42 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
172.3.95.128 (85.58.55.24) - - [03/Jan/2020:12:50:46 +0000] "GET /MyApplication-1.0.jar HTTP/1.1" 200 20308737 "-" "Java/1.8.0_222"
客户端通过执行将 jnlp url 作为参数传递的 javaws 命令来运行应用程序。
javaws -headless https://myapplication.com/MyApplication.jnlp
什么可能导致这种行为?