public SpotInstanceRequest withValidUntil(java.util.Date validUntil) {
        setValidUntil(validUntil);
        return this;
    }
<p>
The end date of the request, in UTC format (<i>YYYY</i>-<i>MM</i>-<i>DD</i>T<i>HH</i>:<i>MM</i>:<i>SS</i>Z).
</p>
<ul>
<li>
<p>
For a persistent request, the request remains active until the <code>validUntil</code> date and time is reached.
Otherwise, the request remains active until you cancel it.
</p>
</li>
<li>
<p>
For a one-time request, the request remains active until all instances launch, the request is canceled, or the
<code>validUntil</code> date and time is reached. By default, the request is valid for 7 days from the date the
request was created.
</p>
</li>
</ul>

@param validUntil
       The end date of the request, in UTC format
       (<i>YYYY</i>-<i>MM</i>-<i>DD</i>T<i>HH</i>:<i>MM</i>:<i>SS</i>Z).</p>
       <ul>
       <li>
       <p>
       For a persistent request, the request remains active until the <code>validUntil</code> date and time is
       reached. Otherwise, the request remains active until you cancel it.
       </p>
       </li>
       <li>
       <p>
       For a one-time request, the request remains active until all instances launch, the request is canceled, or
       the <code>validUntil</code> date and time is reached. By default, the request is valid for 7 days from the
       date the request was created.
       </p>
       </li>
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-ec2/src/main/java/com/amazonaws/services/ec2/model/SpotInstanceRequest.java