Skip to content

Commit 0706950

Browse files
committed
8323089: networkaddress.cache.ttl is not a system property
Reviewed-by: mdoerr Backport-of: efa071dd06deca6f49a22ddde02d13401e583a46
1 parent b9023ce commit 0706950

2 files changed

Lines changed: 7 additions & 7 deletions

File tree

src/java.base/share/classes/java/net/InetAddress.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 1995, 2023, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 1995, 2024, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -165,8 +165,8 @@
165165
* caching. Likewise, a system admin can configure a different
166166
* negative caching TTL value when needed.
167167
*
168-
* <p> Two Java security properties control the TTL values used for
169-
* positive and negative host name resolution caching:
168+
* <p> Two Java {@linkplain java.security.Security security} properties control
169+
* the TTL values used for positive and negative host name resolution caching:
170170
*
171171
* <dl style="margin-left:2em">
172172
* <dt><b>networkaddress.cache.ttl</b></dt>

src/java.base/share/classes/java/net/doc-files/net-properties.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<!DOCTYPE HTML>
22
<!--
3-
Copyright (c) 1998, 2020, Oracle and/or its affiliates. All rights reserved.
3+
Copyright (c) 1998, 2024, Oracle and/or its affiliates. All rights reserved.
44
DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
55
66
This code is free software; you can redistribute it and/or modify it
@@ -261,22 +261,22 @@ <H2>Address Cache</H2>
261261
have to access the naming service. These properties allow for some
262262
tuning on how the cache is operating.</P>
263263
<UL>
264-
<LI><P><B>{@systemProperty networkaddress.cache.ttl}</B> (default: see below)<BR>
264+
<LI><P><B>{@code networkaddress.cache.ttl}</B> (default: see below)<BR>
265265
Value is an integer corresponding to the number of seconds successful
266266
name lookups will be kept in the cache. A value of -1, or any other
267267
negative value for that matter, indicates a &ldquo;cache forever&rdquo;
268268
policy, while a value of 0 (zero) means no caching. The default value
269269
is -1 (forever) if a security manager is installed, and implementation-specific
270270
when no security manager is installed.</P>
271-
<LI><P><B>{@systemProperty networkaddress.cache.negative.ttl}</B> (default: {@code 10})<BR>
271+
<LI><P><B>{@code networkaddress.cache.negative.ttl}</B> (default: {@code 10})<BR>
272272
Value is an integer corresponding to the number of seconds an
273273
unsuccessful name lookup will be kept in the cache. A value of -1,
274274
or any negative value, means &ldquo;cache forever&rdquo;, while a
275275
value of 0 (zero) means no caching.</P>
276276
</UL>
277277
<P>Since these 2 properties are part of the security policy, they are
278278
not set by either the -D option or the {@code System.setProperty()} API,
279-
instead they are set as security properties.</P>
279+
instead they are set as {@linkplain java.security.Security security} properties.</P>
280280
<a id="Unixdomain"></a>
281281
<H2>Unix domain sockets</H2>
282282
<p>

0 commit comments

Comments
 (0)