public CreateDataSourceRequest withDataDeletionPolicy(String dataDeletionPolicy) {
        setDataDeletionPolicy(dataDeletionPolicy);
        return this;
    }
<p>
The data deletion policy for the data source.
</p>
<p>
You can set the data deletion policy to:
</p>
<ul>
<li>
<p>
DELETE: Deletes all underlying data belonging to the data source from the vector store upon deletion of a
knowledge base or data source resource. Note that the vector store itself is not deleted, only the underlying
data. This flag is ignored if an Amazon Web Services account is deleted.
</p>
</li>
<li>
<p>
RETAIN: Retains all underlying data in your vector store upon deletion of a knowledge base or data source
resource.
</p>
</li>
</ul>

@param dataDeletionPolicy
       The data deletion policy for the data source.</p>
       <p>
       You can set the data deletion policy to:
       </p>
       <ul>
       <li>
       <p>
       DELETE: Deletes all underlying data belonging to the data source from the vector store upon deletion of a
       knowledge base or data source resource. Note that the vector store itself is not deleted, only the
       underlying data. This flag is ignored if an Amazon Web Services account is deleted.
       </p>
       </li>
       <li>
       <p>
       RETAIN: Retains all underlying data in your vector store upon deletion of a knowledge base or data source
       resource.
       </p>
       </li>
@return Returns a reference to this object so that method calls can be chained together.
@see DataDeletionPolicy
aws-java-sdk-bedrockagent/src/main/java/com/amazonaws/services/bedrockagent/model/CreateDataSourceRequest.java