Skip to content

Commit

Permalink
Merge 90c15df into e463939
Browse files Browse the repository at this point in the history
  • Loading branch information
Hor911 authored Feb 9, 2024
2 parents e463939 + 90c15df commit bdafbe9
Show file tree
Hide file tree
Showing 16 changed files with 56 additions and 12 deletions.
2 changes: 0 additions & 2 deletions ydb/core/fq/libs/actors/proxy_private.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@ namespace NKikimr {

namespace NFq {

NActors::TActorId MakeYqPrivateProxyId();

NActors::IActor* CreateYqlAnalyticsPrivateProxy(
const NConfig::TPrivateProxyConfig& privateProxyConfig,
TIntrusivePtr<ITimeProvider> timeProvider,
Expand Down
16 changes: 16 additions & 0 deletions ydb/core/fq/libs/compute/common/bin/main.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#include <ydb/core/fq/libs/compute/common/utils.h>

int main(int, char **) {
double cpuUsage;
TFileInput in("/home/hor911/q21plan.json");
TString plan = in.ReadAll();
auto processor = NFq::CreateStatProcessor("stat_tree");
plan = processor->ConvertPlan(plan);
{
TUnbufferedFileOutput output("/home/hor911/q21plan_tree.json");
output.Write(plan.c_str(), plan.size());
}
auto stats = processor->GetQueryStat(plan, cpuUsage);
TUnbufferedFileOutput output("/home/hor911/q21stat_tree.json");
output.Write(stats.c_str(), stats.size());
}
17 changes: 17 additions & 0 deletions ydb/core/fq/libs/compute/common/bin/ya.make
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
PROGRAM(plan)

PEERDIR(
ydb/core/fq/libs/compute/common
ydb/core/fq/libs/control_plane_storage/internal
ydb/library/yql/public/udf/service/exception_policy
ydb/library/yql/sql/pg_dummy
)

SRCS(
main.cpp
)

YQL_LAST_ABI_VERSION()

END()

Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
#include "config.h"
#include "control_plane_proxy.h"
#include "probes.h"
#include "utils.h"

#include <ydb/core/fq/libs/actors/logging/log.h>
#include <ydb/core/fq/libs/compute/ydb/control_plane/compute_database_control_plane_service.h>
Expand All @@ -23,6 +22,7 @@
#include <ydb/core/fq/libs/control_plane_proxy/actors/utils.h>
#include <ydb/core/fq/libs/control_plane_proxy/actors/ydb_schema_query_actor.h>
#include <ydb/core/fq/libs/control_plane_proxy/events/events.h>
#include <ydb/core/fq/libs/control_plane_proxy/utils/utils.h>
#include <ydb/public/lib/fq/scope.h>

#include <ydb/library/actors/core/actor.h>
Expand Down
2 changes: 2 additions & 0 deletions ydb/core/fq/libs/control_plane_proxy/events/events.h
Original file line number Diff line number Diff line change
Expand Up @@ -394,4 +394,6 @@ struct TEvControlPlaneProxy {
};
};

NActors::TActorId ControlPlaneProxyActorId();

}
9 changes: 9 additions & 0 deletions ydb/core/fq/libs/control_plane_proxy/utils/ya.make
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
LIBRARY()

PEERDIR(
ydb/public/api/protos
)

YQL_LAST_ABI_VERSION()

END()
1 change: 1 addition & 0 deletions ydb/core/fq/libs/control_plane_proxy/ya.make
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ END()
RECURSE(
actors
events
utils
)

RECURSE_FOR_TESTS(
Expand Down
2 changes: 2 additions & 0 deletions ydb/core/fq/libs/events/events.h
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,8 @@ struct TEvents {
};
};

NActors::TActorId MakeYqPrivateProxyId();

} // namespace NFq

template<>
Expand Down
3 changes: 1 addition & 2 deletions ydb/core/grpc_services/rpc_fq.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,8 @@
#include <ydb/core/grpc_services/service_fq.h>
#include <ydb/core/fq/libs/audit/events/events.h>
#include <ydb/core/fq/libs/audit/yq_audit_service.h>
#include <ydb/core/fq/libs/control_plane_proxy/control_plane_proxy.h>
#include <ydb/core/fq/libs/control_plane_proxy/events/events.h>
#include <ydb/core/fq/libs/control_plane_proxy/utils.h>
#include <ydb/core/fq/libs/control_plane_proxy/utils/utils.h>
#include <ydb/public/api/protos/draft/fq.pb.h>
#include <ydb/public/lib/fq/scope.h>

Expand Down
1 change: 0 additions & 1 deletion ydb/core/grpc_services/rpc_fq_internal.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
#include "rpc_deferrable.h"

#include <ydb/core/fq/libs/events/events.h>
#include <ydb/core/fq/libs/actors/proxy_private.h>
#include <ydb/core/fq/libs/protos/fq_private.pb.h>

#include <ydb/library/actors/core/hfunc.h>
Expand Down
2 changes: 1 addition & 1 deletion ydb/core/grpc_services/service_fq.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#include <memory>

#include <ydb/core/base/ticket_parser.h>
#include <ydb/core/fq/libs/control_plane_proxy/utils.h>
#include <ydb/core/fq/libs/control_plane_proxy/utils/utils.h>

namespace NKikimr {
namespace NGRpcService {
Expand Down
3 changes: 1 addition & 2 deletions ydb/core/grpc_services/ya.make
Original file line number Diff line number Diff line change
Expand Up @@ -95,8 +95,7 @@ PEERDIR(
ydb/core/discovery
ydb/core/engine
ydb/core/formats
ydb/core/fq/libs/actors
ydb/core/fq/libs/control_plane_proxy
ydb/core/fq/libs/events
ydb/core/fq/libs/control_plane_proxy/events
ydb/core/grpc_services/base
ydb/core/grpc_services/counters
Expand Down
1 change: 1 addition & 0 deletions ydb/core/kqp/executer_actor/ya.make
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ PEERDIR(
ydb/core/client/minikql_compile
ydb/core/formats
ydb/core/kqp/common
ydb/core/kqp/compute_actor
ydb/core/kqp/query_compiler
ydb/core/kqp/rm_service
ydb/core/kqp/topics
Expand Down
6 changes: 3 additions & 3 deletions ydb/core/kqp/host/kqp_host.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1476,11 +1476,11 @@ class TKqpHost : public IKqpHost {
state->Configuration->WriteThroughDqIntegration = true;
state->Configuration->AllowAtomicUploadCommit = queryType == EKikimrQueryType::Script;
state->MaxTasksPerStage = SessionCtx->ConfigPtr()->MaxTasksPerStage.Get();

state->Configuration->Init(FederatedQuerySetup->S3GatewayConfig, TypesCtx);
state->Gateway = FederatedQuerySetup->HttpGateway;

auto dataSource = NYql::CreateS3DataSource(state, FederatedQuerySetup->HttpGateway);
auto dataSink = NYql::CreateS3DataSink(state, FederatedQuerySetup->HttpGateway);
auto dataSource = NYql::CreateS3DataSource(state);
auto dataSink = NYql::CreateS3DataSink(state);

TypesCtx->AddDataSource(NYql::S3ProviderName, std::move(dataSource));
TypesCtx->AddDataSink(NYql::S3ProviderName, std::move(dataSink));
Expand Down
1 change: 1 addition & 0 deletions ydb/core/kqp/node_service/ya.make
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ PEERDIR(
ydb/core/base
ydb/core/cms/console
ydb/core/kqp/common
ydb/core/kqp/compute_actor
ydb/core/kqp/counters
ydb/core/mind
ydb/core/protos
Expand Down

0 comments on commit bdafbe9

Please sign in to comment.