Delete logs that print sensitive information (#20889)

Signed-off-by: xige-16 <xi.ge@zilliz.com>

Signed-off-by: xige-16 <xi.ge@zilliz.com>
This commit is contained in:
xige-16 2022-12-01 10:35:16 +08:00 committed by GitHub
parent 67390d208b
commit a20770c172
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 9 deletions

View File

@ -102,13 +102,13 @@ MinioChunkManager::MinioChunkManager(const StorageConfig& storage_config)
if (storage_config.useIAM) {
auto provider = std::make_shared<Aws::Auth::DefaultAWSCredentialsProviderChain>();
auto aws_credentials = provider->GetAWSCredentials();
AssertInfo(!aws_credentials.GetAWSAccessKeyId().empty(), "if use iam, access key id should not be empty");
AssertInfo(!aws_credentials.GetAWSSecretKey().empty(), "if use iam, secret key should not be empty");
AssertInfo(!aws_credentials.GetSessionToken().empty(), "if use iam, token should not be empty");
client_ = std::make_shared<Aws::S3::S3Client>(provider, config,
Aws::Client::AWSAuthV4Signer::PayloadSigningPolicy::Never, false);
LOG_SEGCORE_INFO_C << "use iam mode, credentials{ access_id:"
<< provider->GetAWSCredentials().GetAWSAccessKeyId()
<< " access_key:" << provider->GetAWSCredentials().GetAWSSecretKey()
<< " token:" << provider->GetAWSCredentials().GetSessionToken() << "}";
} else {
AssertInfo(!storage_config.access_key_id.empty(), "if not use iam, access key should not be empty");
AssertInfo(!storage_config.access_key_value.empty(), "if not use iam, access value should not be empty");
@ -127,9 +127,8 @@ MinioChunkManager::MinioChunkManager(const StorageConfig& storage_config)
// }
LOG_SEGCORE_INFO_C << "init MinioChunkManager with parameter[endpoint: '" << storage_config.address
<< "', access_key:'" << storage_config.access_key_id << "', access_value:'"
<< storage_config.access_key_value << "', default_bucket_name:'" << storage_config.bucket_name
<< "', use_secure:'" << std::boolalpha << storage_config.useSSL << "']";
<< "', default_bucket_name:'" << storage_config.bucket_name << "', use_secure:'"
<< std::boolalpha << storage_config.useSSL << "']";
}
MinioChunkManager::~MinioChunkManager() {

View File

@ -333,7 +333,6 @@ TEST(Retrieve, Delete) {
Assert(field2.has_vectors());
auto field2_data = field2.vectors().float_vector();
ASSERT_EQ(field2_data.data_size(), DIM * req_size);
}
int64_t row_count = 0;