public CreateIndexRequest withRoleArn(String roleArn) {
        setRoleArn(roleArn);
        return this;
    }
<p>
The Amazon Resource Name (ARN) of an IAM role with permission to access your Amazon CloudWatch logs and metrics.
For more information, see <a href="https://docs.aws.amazon.com/kendra/latest/dg/iam-roles.html">IAM access roles
for Amazon Kendra</a>.
</p>

@param roleArn
       The Amazon Resource Name (ARN) of an IAM role with permission to access your Amazon CloudWatch logs and
       metrics. For more information, see <a
       href="https://docs.aws.amazon.com/kendra/latest/dg/iam-roles.html">IAM access roles for Amazon Kendra</a>.
@return Returns a reference to this object so that method calls can be chained together.
aws-java-sdk-kendra/src/main/java/com/amazonaws/services/kendra/model/CreateIndexRequest.java