File tree 2 files changed +4
-3
lines changed
services/persqueue_v1/actors 2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -207,6 +207,8 @@ message TPQConfig {
207
207
208
208
optional uint64 BalancerWakeupIntervalSec = 54 [default = 30 ];
209
209
optional uint64 BalancerStatsWakeupIntervalSec = 55 [default = 5 ];
210
+
211
+ optional uint64 MaxWriteSessionBytesInflight = 57 [default = 1000000 ];
210
212
}
211
213
212
214
message TChannelProfile {
Original file line number Diff line number Diff line change @@ -159,7 +159,6 @@ namespace NGRpcProxy::V1 {
159
159
160
160
using namespace Ydb ::PersQueue::V1;
161
161
162
- static const ui32 MAX_BYTES_INFLIGHT = 1_MB;
163
162
static const TDuration SOURCEID_UPDATE_PERIOD = TDuration::Hours(1 );
164
163
165
164
// metering
@@ -942,7 +941,7 @@ void TWriteSessionActor<UseMigrationProtocol>::Handle(NPQ::TEvPartitionWriter::T
942
941
if (BytesInflight) {
943
942
BytesInflight.Dec (diff);
944
943
}
945
- if (!NextRequestInited && BytesInflight_ < MAX_BYTES_INFLIGHT ) { // allow only one big request to be readed but not sended
944
+ if (!NextRequestInited && BytesInflight_ < AppData (ctx)-> PQConfig . GetMaxWriteSessionBytesInflight () ) { // allow only one big request to be readed but not sended
946
945
NextRequestInited = true ;
947
946
if (!Request->GetStreamCtx ()->Read ()) {
948
947
LOG_INFO_S (ctx, NKikimrServices::PQ_WRITE_PROXY, " session v1 cookie: " << Cookie << " sessionId: " << OwnerCookie << " grpc read failed" );
@@ -1498,7 +1497,7 @@ void TWriteSessionActor<UseMigrationProtocol>::Handle(typename TEvWrite::TPtr& e
1498
1497
BytesInflightTotal.Inc (diff);
1499
1498
}
1500
1499
1501
- if (BytesInflight_ < MAX_BYTES_INFLIGHT ) { // allow only one big request to be readed but not sended
1500
+ if (BytesInflight_ < AppData (ctx)-> PQConfig . GetMaxWriteSessionBytesInflight () ) { // allow only one big request to be readed but not sended
1502
1501
Y_ABORT_UNLESS (NextRequestInited);
1503
1502
if (!Request->GetStreamCtx ()->Read ()) {
1504
1503
LOG_INFO_S (ctx, NKikimrServices::PQ_WRITE_PROXY, " session v1 cookie: " << Cookie << " sessionId: " << OwnerCookie << " grpc read failed" );
You can’t perform that action at this time.
0 commit comments