Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
P
picodata
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Container Registry
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
core
picodata
Commits
2ce1f572
Commit
2ce1f572
authored
9 months ago
by
EmirVildanov
Committed by
Maksim Kaitmazian
8 months ago
Browse files
Options
Downloads
Patches
Plain Diff
feat: bump sbroad with mock param and transaction settings
parent
8d4effdc
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!1051
feat: bump sbroad with mock params setting
Pipeline
#43497
passed
8 months ago
Stage: test
Stage: stress-test
Changes
4
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
CHANGELOG.md
+1
-0
1 addition, 0 deletions
CHANGELOG.md
sbroad
+1
-1
1 addition, 1 deletion
sbroad
src/pgproto/backend/describe.rs
+9
-0
9 additions, 0 deletions
src/pgproto/backend/describe.rs
src/sql.rs
+15
-1
15 additions, 1 deletion
src/sql.rs
with
26 additions
and
2 deletions
CHANGELOG.md
+
1
−
0
View file @
2ce1f572
...
...
@@ -59,6 +59,7 @@ columns.
- New function [TRIM][sql_trim]
- New functions `TO_CHAR`, `TO_DATE`
- Allow `PRIMARY KEY` next to column declaration
- Support `SET ...` and `SET TRANSACTION ...` but they are ignored
[CREATE INDEX]: https://docs.picodata.io/picodata/24.4/reference/sql/create_index/
[DROP INDEX]: https://docs.picodata.io/picodata/24.4/reference/sql/drop_index/
...
...
This diff is collapsed.
Click to expand it.
sbroad
@
c508313e
Compare
c6c3b541
...
c508313e
Subproject commit c
6c3b541b21ba08da3843396878f26e49fc65a2b
Subproject commit c
508313e4b3f913e15736f0f36db037a63bae2a9
This diff is collapsed.
Click to expand it.
src/pgproto/backend/describe.rs
+
9
−
0
View file @
2ce1f572
...
...
@@ -50,10 +50,14 @@ pub enum CommandTag {
RevokeRole
=
11
,
#[default]
Select
=
12
,
SetParam
=
20
,
SetTransaction
=
21
,
Update
=
13
,
}
impl
CommandTag
{
/// Note: Should be in accordance with
/// `<https://github.com/postgres/postgres/blob/master/src/include/tcop/cmdtaglist.h>`
pub
fn
as_str
(
&
self
)
->
&
str
{
match
*
self
{
Self
::
AlterRole
=>
"ALTER ROLE"
,
...
...
@@ -82,6 +86,7 @@ impl CommandTag {
Self
::
DropProcedure
=>
"DROP PROCEDURE"
,
Self
::
CallProcedure
=>
"CALL"
,
Self
::
RenameRoutine
=>
"RENAME ROUTINE"
,
Self
::
SetParam
|
Self
::
SetTransaction
=>
"SET"
,
}
}
}
...
...
@@ -102,6 +107,8 @@ impl From<CommandTag> for QueryType {
|
CommandTag
::
CreateIndex
|
CommandTag
::
RenameRoutine
|
CommandTag
::
DropIndex
|
CommandTag
::
SetParam
|
CommandTag
::
SetTransaction
|
CommandTag
::
DropProcedure
=>
QueryType
::
Ddl
,
CommandTag
::
Delete
|
CommandTag
::
Insert
...
...
@@ -142,6 +149,8 @@ impl TryFrom<&Node> for CommandTag {
Ddl
::
DropProc
{
..
}
=>
Ok
(
CommandTag
::
DropProcedure
),
Ddl
::
DropIndex
{
..
}
=>
Ok
(
CommandTag
::
DropIndex
),
Ddl
::
RenameRoutine
{
..
}
=>
Ok
(
CommandTag
::
RenameRoutine
),
Ddl
::
SetParam
{
..
}
=>
Ok
(
CommandTag
::
SetParam
),
Ddl
::
SetTransaction
{
..
}
=>
Ok
(
CommandTag
::
SetTransaction
),
},
Node
::
Relational
(
rel
)
=>
match
rel
{
Relational
::
Delete
{
..
}
=>
Ok
(
CommandTag
::
Delete
),
...
...
This diff is collapsed.
Click to expand it.
src/sql.rs
+
15
−
1
View file @
2ce1f572
...
...
@@ -18,7 +18,6 @@ use crate::util::{duration_from_secs_f64_clamped, effective_user_id};
use
crate
::{
cas
,
unwrap_ok_or
};
use
opentelemetry
::{
baggage
::
BaggageExt
,
Context
,
KeyValue
};
use
sbroad
::
debug
;
use
sbroad
::
errors
::{
Action
,
Entity
,
SbroadError
};
use
sbroad
::
executor
::
engine
::
helpers
::{
decode_msgpack
,
normalize_name_for_space_api
};
use
sbroad
::
executor
::
protocol
::{
EncodedRequiredData
,
RequiredData
};
...
...
@@ -34,6 +33,7 @@ use sbroad::ir::tree::traversal::{PostOrderWithFilter, REL_CAPACITY};
use
sbroad
::
ir
::
value
::{
LuaValue
,
Value
};
use
sbroad
::
ir
::{
Node
as
IrNode
,
Plan
as
IrPlan
};
use
sbroad
::
otm
::{
query_id
,
query_span
};
use
sbroad
::{
debug
,
warn
};
use
smol_str
::{
format_smolstr
,
SmolStr
};
use
tarantool
::
access_control
::{
box_access_check_ddl
,
SchemaObjectType
as
TntSchemaObjectType
};
use
tarantool
::
schema
::
function
::
func_next_reserved_id
;
...
...
@@ -850,6 +850,20 @@ fn reenterable_schema_change_request(
};
Params
::
RenameRoutine
(
params
)
}
IrNode
::
Ddl
(
Ddl
::
SetParam
{
param_value
,
..
})
=>
{
warn!
(
None
,
&
format!
(
"Parameters setting is currently disabled. Skipping update for {}."
,
param_value
.param_name
()
),
);
return
Ok
(
ConsumerResult
{
row_count
:
0
});
}
IrNode
::
Ddl
(
Ddl
::
SetTransaction
{
..
})
=>
{
warn!
(
None
,
"Transaction setting is currently disabled. Skipping."
);
return
Ok
(
ConsumerResult
{
row_count
:
0
});
}
IrNode
::
Acl
(
Acl
::
DropUser
{
name
,
..
})
=>
{
// Nothing to check
Params
::
DropUser
(
name
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment