Skip to content

Commit

Permalink
feat redis: remove legacy namespace and macro for its usage
Browse files Browse the repository at this point in the history
Tests: протестировано CI
commit_hash:cfdd87dd3793bc6dc1c1c9fe86413a72754d2e8d
  • Loading branch information
apolukhin committed Jan 10, 2025
1 parent 58b0089 commit 89dc74e
Show file tree
Hide file tree
Showing 10 changed files with 0 additions and 101 deletions.
1 change: 0 additions & 1 deletion .mapping.json
Original file line number Diff line number Diff line change
Expand Up @@ -2930,7 +2930,6 @@
"redis/include/userver/storages/redis/expire_reply.hpp":"taxi/uservices/userver/redis/include/userver/storages/redis/expire_reply.hpp",
"redis/include/userver/storages/redis/fwd.hpp":"taxi/uservices/userver/redis/include/userver/storages/redis/fwd.hpp",
"redis/include/userver/storages/redis/hedged_request.hpp":"taxi/uservices/userver/redis/include/userver/storages/redis/hedged_request.hpp",
"redis/include/userver/storages/redis/impl/base.hpp":"taxi/uservices/userver/redis/include/userver/storages/redis/impl/base.hpp",
"redis/include/userver/storages/redis/impl/keyshard.hpp":"taxi/uservices/userver/redis/include/userver/storages/redis/impl/keyshard.hpp",
"redis/include/userver/storages/redis/impl/secdist_redis.hpp":"taxi/uservices/userver/redis/include/userver/storages/redis/impl/secdist_redis.hpp",
"redis/include/userver/storages/redis/impl/transaction_subrequest_data.hpp":"taxi/uservices/userver/redis/include/userver/storages/redis/impl/transaction_subrequest_data.hpp",
Expand Down
17 changes: 0 additions & 17 deletions redis/include/userver/storages/redis/command_control.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -154,21 +154,4 @@ std::string_view StrategyToString(CommandControl::Strategy s);

} // namespace storages::redis

#ifdef USERVER_FEATURE_LEGACY_REDIS_NAMESPACE
namespace redis {
using storages::redis::kDefaultMaxRetries;
using storages::redis::kDefaultTimeoutAll;
using storages::redis::kDefaultTimeoutSingle;

using storages::redis::kRetryNilFromMaster;
using storages::redis::RetryNilFromMaster;
using storages::redis::ServerIdHasher;

using storages::redis::CommandControl;
using storages::redis::ServerId;
using storages::redis::StrategyFromString;
using storages::redis::StrategyToString;
} // namespace redis
#endif

USERVER_NAMESPACE_END
12 changes: 0 additions & 12 deletions redis/include/userver/storages/redis/exception.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -64,16 +64,4 @@ class ClientNotConnectedException : public Exception {

} // namespace storages::redis

#ifdef USERVER_FEATURE_LEGACY_REDIS_NAMESPACE
namespace redis {
using storages::redis::ClientNotConnectedException;
using storages::redis::Exception;
using storages::redis::InvalidArgumentException;
using storages::redis::ParseConfigException;
using storages::redis::ParseReplyException;
using storages::redis::RequestCancelledException;
using storages::redis::RequestFailedException;
} // namespace redis
#endif

USERVER_NAMESPACE_END
6 changes: 0 additions & 6 deletions redis/include/userver/storages/redis/expire_reply.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,4 @@ class ExpireReply final {

} // namespace storages::redis

#ifdef USERVER_FEATURE_LEGACY_REDIS_NAMESPACE
namespace redis {
using storages::redis::ExpireReply;
}
#endif

USERVER_NAMESPACE_END
10 changes: 0 additions & 10 deletions redis/include/userver/storages/redis/hedged_request.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -189,14 +189,4 @@ MakeBulkHedgedRedisRequestAsync(

} // namespace storages::redis

#ifdef USERVER_FEATURE_LEGACY_REDIS_NAMESPACE
namespace redis {
using USERVER_NAMESPACE::storages::redis::HedgedRedisRequest;
using USERVER_NAMESPACE::storages::redis::MakeBulkHedgedRedisRequest;
using USERVER_NAMESPACE::storages::redis::MakeBulkHedgedRedisRequestAsync;
using USERVER_NAMESPACE::storages::redis::MakeHedgedRedisRequest;
using USERVER_NAMESPACE::storages::redis::MakeHedgedRedisRequestAsync;
} // namespace redis
#endif

USERVER_NAMESPACE_END
26 changes: 0 additions & 26 deletions redis/include/userver/storages/redis/impl/base.hpp

This file was deleted.

8 changes: 0 additions & 8 deletions redis/include/userver/storages/redis/reply_fwd.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,4 @@ using ReplyPtr = std::shared_ptr<Reply>;

} // namespace storages::redis

#ifdef USERVER_FEATURE_LEGACY_REDIS_NAMESPACE
namespace redis {
using storages::redis::Reply;
using storages::redis::ReplyData;
using storages::redis::ReplyPtr;
} // namespace redis
#endif

USERVER_NAMESPACE_END
6 changes: 0 additions & 6 deletions redis/include/userver/storages/redis/reply_status.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,4 @@ enum class ReplyStatus {

} // namespace storages::redis

#ifdef USERVER_FEATURE_LEGACY_REDIS_NAMESPACE
namespace redis {
using storages::redis::ReplyStatus;
}
#endif

USERVER_NAMESPACE_END
7 changes: 0 additions & 7 deletions redis/include/userver/storages/redis/ttl_reply.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,4 @@ class KeyHasNoExpirationException : public Exception {

} // namespace storages::redis

#ifdef USERVER_FEATURE_LEGACY_REDIS_NAMESPACE
namespace redis {
using storages::redis::KeyHasNoExpirationException;
using storages::redis::TtlReply;
} // namespace redis
#endif

USERVER_NAMESPACE_END
8 changes: 0 additions & 8 deletions redis/include/userver/storages/redis/wait_connected_mode.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -34,12 +34,4 @@ struct RedisWaitConnected {

} // namespace storages::redis

#ifdef USERVER_FEATURE_LEGACY_REDIS_NAMESPACE
namespace redis {
using storages::redis::kRedisWaitConnectedDefaultTimeout;
using storages::redis::RedisWaitConnected;
using storages::redis::WaitConnectedMode;
} // namespace redis
#endif

USERVER_NAMESPACE_END

0 comments on commit 89dc74e

Please sign in to comment.