-
Notifications
You must be signed in to change notification settings - Fork 606
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Yq 3322 Shared reading (to stable) (#9915)
Co-authored-by: Pisarenko Grigoriy <grigoriypisar@ydb.tech>
- Loading branch information
1 parent
97e9a76
commit afee6e2
Showing
104 changed files
with
7,578 additions
and
247 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
syntax = "proto3"; | ||
option cc_enable_arenas = true; | ||
|
||
package NFq.NConfig; | ||
option java_package = "ru.yandex.kikimr.proto"; | ||
|
||
import "ydb/core/fq/libs/config/protos/storage.proto"; | ||
|
||
//////////////////////////////////////////////////////////// | ||
|
||
message TRowDispatcherCoordinatorConfig { | ||
TYdbStorageConfig Database = 1; | ||
string CoordinationNodePath = 2; | ||
} | ||
message TRowDispatcherConfig { | ||
bool Enabled = 1; | ||
uint64 TimeoutBeforeStartSessionSec = 2; | ||
uint64 SendStatusPeriodSec = 3; | ||
uint64 MaxSessionUsedMemory = 4; | ||
bool WithoutConsumer = 5; | ||
TRowDispatcherCoordinatorConfig Coordinator = 6; | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
#include <ydb/core/fq/libs/row_dispatcher/actors_factory.h> | ||
|
||
#include <ydb/core/fq/libs/row_dispatcher/topic_session.h> | ||
|
||
namespace NFq::NRowDispatcher { | ||
|
||
|
||
struct TActorFactory : public IActorFactory { | ||
TActorFactory() {} | ||
|
||
NActors::TActorId RegisterTopicSession( | ||
const TString& topicPath, | ||
const NConfig::TRowDispatcherConfig& config, | ||
NActors::TActorId rowDispatcherActorId, | ||
ui32 partitionId, | ||
NYdb::TDriver driver, | ||
std::shared_ptr<NYdb::ICredentialsProviderFactory> credentialsProviderFactory, | ||
const ::NMonitoring::TDynamicCounterPtr& counters) const override { | ||
|
||
auto actorPtr = NFq::NewTopicSession( | ||
topicPath, | ||
config, | ||
rowDispatcherActorId, | ||
partitionId, | ||
std::move(driver), | ||
credentialsProviderFactory, | ||
counters | ||
); | ||
return NActors::TlsActivationContext->ExecutorThread.RegisterActor(actorPtr.release(), NActors::TMailboxType::HTSwap, Max<ui32>()); | ||
} | ||
}; | ||
|
||
IActorFactory::TPtr CreateActorFactory() { | ||
return MakeIntrusive<TActorFactory>(); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
#pragma once | ||
|
||
#include <ydb/core/fq/libs/config/protos/row_dispatcher.pb.h> | ||
#include <util/generic/ptr.h> | ||
#include <ydb/library/actors/core/actor.h> | ||
#include <ydb/public/sdk/cpp/client/ydb_driver/driver.h> | ||
|
||
namespace NFq::NRowDispatcher { | ||
|
||
struct IActorFactory : public TThrRefBase { | ||
using TPtr = TIntrusivePtr<IActorFactory>; | ||
|
||
virtual NActors::TActorId RegisterTopicSession( | ||
const TString& topicPath, | ||
const NConfig::TRowDispatcherConfig& config, | ||
NActors::TActorId rowDispatcherActorId, | ||
ui32 partitionId, | ||
NYdb::TDriver driver, | ||
std::shared_ptr<NYdb::ICredentialsProviderFactory> credentialsProviderFactory, | ||
const ::NMonitoring::TDynamicCounterPtr& counters) const = 0; | ||
}; | ||
|
||
IActorFactory::TPtr CreateActorFactory(); | ||
|
||
} |
Oops, something went wrong.