Gokhan Gulbiz
54114f76c1
Merge branch 'multi-tenant-monitoring-annotation-parsing' into multi-tenant-monitoring-annotate-local-queries
2023-03-28 14:32:02 +03:00
Gokhan Gulbiz
b86f2b5607
Indent
2023-03-28 08:33:02 +03:00
Gokhan Gulbiz
508ee987e6
Rewrite ExtractTopComment by using strstr() and stringinfo
2023-03-28 08:33:02 +03:00
Gokhan Gulbiz
0b06e64c3f
Use stringinfo for escaping/unescaping
2023-03-28 08:33:02 +03:00
Gokhan Gulbiz
0744384bac
Update comment
...
Co-authored-by: Jelte Fennema <github-tech@jeltef.nl>
2023-03-28 08:33:02 +03:00
Gokhan Gulbiz
5e9dd3c894
Add an additional comment
...
Co-authored-by: Jelte Fennema <github-tech@jeltef.nl>
2023-03-28 08:33:01 +03:00
Gokhan Gulbiz
2ac56ef955
Revert "Use text_substr for getting top comment"
...
This reverts commit 9531cfd3bf
.
2023-03-28 08:33:01 +03:00
Gokhan Gulbiz
81953d7ac6
Convert char* to text for text_substr call
2023-03-28 08:33:01 +03:00
Gokhan Gulbiz
426cfd3ce5
Indent
2023-03-28 08:33:01 +03:00
Gokhan Gulbiz
8b09a4f8c0
Handle no comment end chars
2023-03-28 08:33:01 +03:00
Gokhan Gulbiz
fc23fd5061
Use text_substr for getting top comment
2023-03-28 08:33:00 +03:00
Gokhan Gulbiz
905cc5b4f3
Use palloc instead of malloc
2023-03-28 08:33:00 +03:00
Gokhan Gulbiz
3ec2994abd
Indent
2023-03-28 08:33:00 +03:00
Gokhan Gulbiz
3a5c7c3280
Indent
2023-03-28 08:33:00 +03:00
Gokhan Gulbiz
486e2a622a
Refactoring to reduce nesting
2023-03-28 08:33:00 +03:00
Gokhan Gulbiz
8e1e827242
Remove unnecessary check
2023-03-28 08:32:59 +03:00
Gokhan Gulbiz
5e6ac25885
Renamings
2023-03-28 08:32:59 +03:00
Gokhan Gulbiz
a355825bfe
Set INVALID_COLOCATION_ID if colocationId doesn't exist in the annotation.
2023-03-28 08:32:59 +03:00
Gokhan Gulbiz
c60de03d6a
Indent
2023-03-28 08:32:21 +03:00
Gokhan Gulbiz
da24f2fd62
Indent
2023-03-28 08:32:20 +03:00
Gokhan Gulbiz
3cfa197f69
Escape/Unescape sql comment chars
2023-03-28 08:32:20 +03:00
Gokhan Gulbiz
80dd73711e
Minor renamings and refactorings
2023-03-28 08:32:20 +03:00
Gokhan Gulbiz
dbc26cacb5
Add comment chars escaping
2023-03-28 08:32:20 +03:00
Gokhan Gulbiz
89e6623960
Fix attribute prefix
2023-03-28 08:32:20 +03:00
Gokhan Gulbiz
e9a6f8a7c5
Indent
2023-03-28 08:32:19 +03:00
Gokhan Gulbiz
21298f6661
Validate attribute prefix existance on query string
2023-03-28 08:32:19 +03:00
Gokhan Gulbiz
6d8cd8a9a0
Validate input string length
2023-03-28 08:31:26 +03:00
Gokhan Gulbiz
517ceb2d22
Use strncpy_s instead of strncpy
2023-03-28 08:31:26 +03:00
Gokhan Gulbiz
fda680d22e
Use palloc instead of malloc
2023-03-28 08:31:26 +03:00
Gokhan Gulbiz
024526ab2f
Introduce JSON based annotation parsing
2023-03-28 08:31:25 +03:00
Gokhan Gulbiz
9d2d97fe67
Add ExtractFieldInt32(..) to jsonbutils
2023-03-28 08:03:26 +03:00
Halil Ozan Akgül
b989e8872c
Citus stats tenants collector view ( #6761 )
...
Add a view that collects statistics from all nodes
2023-03-27 17:42:22 +03:00
Halil Ozan Akgul
d6603390ab
Add multi tenant statistics monitoring
2023-03-27 17:13:24 +03:00
Gokhan Gulbiz
161ec751d1
Validate tenantId and colocationId
2023-03-23 12:22:03 +03:00
Teja Mupparti
da7db53c87
Refactor some of the planning code to accomodate a new planning path for MERGE SQL
2023-03-22 11:29:24 -07:00
Gokhan Gulbiz
46ae3a37d5
Indent
2023-03-22 17:13:24 +03:00
Gokhan Gulbiz
bb2ab9e93c
Move adding tenant statistic attributes to local_executor to keep track of both local shard queries and local cached queries
2023-03-22 16:39:10 +03:00
Onur Tirtir
e1f1d63050
Rename AllRelations.. functions to AllDistributedRelations.. ( #6789 )
...
Because they're only interested in distributed tables. Even more,
this replaces HasDistributionKey() check with
IsCitusTableType(DISTRIBUTED_TABLE) because this doesn't make a
difference on main and sounds slightly more intuitive. Plus, this
would also allow safely using this function in
https://github.com/citusdata/citus/pull/6773 .
2023-03-22 15:15:23 +03:00
Gokhan Gulbiz
9a0ed9844f
Merge branch 'multi-tenant-monitoring-annotation-parsing' into multi-tenant-monitoring-annotate-local-queries
2023-03-22 11:05:15 +03:00
Gokhan Gulbiz
125532e98a
temp - local query monitoring
2023-03-22 11:03:13 +03:00
Ahmet Gedemenli
2713e015d6
Check before logicalrep for rebalancer, error if needed ( #6754 )
...
DESCRIPTION: Check before logicalrep for rebalancer, error if needed
Check if we can use logical replication or not, in case of shard
transfer mode = auto, before executing the shard moves. If we can't,
error out. Before this PR, we used to error out in the middle of shard
moves:
```sql
set citus.shard_count = 4; -- just to get the error sooner
select citus_remove_node('localhost',9702);
create table t1 (a int primary key);
select create_distributed_table('t1','a');
create table t2 (a bigint);
select create_distributed_table('t2','a');
select citus_add_node('localhost',9702);
select rebalance_table_shards();
NOTICE: Moving shard 102008 from localhost:9701 to localhost:9702 ...
NOTICE: Moving shard 102009 from localhost:9701 to localhost:9702 ...
NOTICE: Moving shard 102012 from localhost:9701 to localhost:9702 ...
ERROR: cannot use logical replication to transfer shards of the relation t2 since it doesn't have a REPLICA IDENTITY or PRIMARY KEY
```
Now we check and error out in the beginning, without moving the shards.
fixes : #6727
2023-03-21 16:34:52 +03:00
Onur Tirtir
aa465b6de1
Decide what to do with router planner error at one place ( #6781 )
2023-03-21 14:04:07 +03:00
Gokhan Gulbiz
852db8f2f9
Rewrite ExtractTopComment by using strstr() and stringinfo
2023-03-21 12:34:05 +03:00
Gokhan Gulbiz
16c75165cf
Use stringinfo for escaping/unescaping
2023-03-21 11:27:00 +03:00
Gokhan Gulbiz
26226d0eb4
Update comment
...
Co-authored-by: Jelte Fennema <github-tech@jeltef.nl>
2023-03-21 11:22:29 +03:00
Gokhan Gulbiz
3f61a62420
Add an additional comment
...
Co-authored-by: Jelte Fennema <github-tech@jeltef.nl>
2023-03-21 11:22:08 +03:00
Gokhan Gulbiz
1df9260f82
Revert "Use text_substr for getting top comment"
...
This reverts commit 9531cfd3bf
.
2023-03-20 11:02:34 +03:00
Gokhan Gulbiz
34e1dafb18
Convert char* to text for text_substr call
2023-03-20 09:40:08 +03:00
Gokhan Gulbiz
df3ad5c4f6
Indent
2023-03-20 08:49:39 +03:00
Gokhan Gulbiz
f972b6fae9
Handle no comment end chars
2023-03-20 08:46:52 +03:00