Comments (1)
/*
-
Builds up a connection string
*/
char *
PGXCNodeConnStr(char *host, int port, char *dbname,
char *user, char *pgoptions, char *remote_type, char *parent_node)
{// #lizard forgives
char *out,
connstr[1024];
int num;
#ifdef TBASE
bool same_host = false;if (host && (strcmp(PGXCNodeHost, host) == 0))
{
same_host = true;
}
#endif
/*- Build up connection string
- remote type can be Coordinator, Datanode or application.
*/
#ifdef MLS
if (strcmp(user, MLS_USER) == 0 || strcmp(user, AUDIT_USER))
{
if (same_host)
{
num = snprintf(connstr, sizeof(connstr),
"port=%d dbname=%s user=%s application_name='pgxc:%s' sslmode=disable options='-c remotetype=%s -c parentnode=%s %s %s'",
port, dbname, user, parent_node, remote_type, parent_node,
pgoptions, MLS_CONN_OPTION);
}
change :
/*
-
Builds up a connection string
*/
char *
PGXCNodeConnStr(char *host, int port, char *dbname,
char *user, char *pgoptions, char *remote_type, char *parent_node)
{// #lizard forgives
char *out,
connstr[1024];
int num;
#ifdef TBASE
bool same_host = false;if (host && (strcmp(PGXCNodeHost, host) == 0))
{
same_host = true;
}
#endif
/*- Build up connection string
- remote type can be Coordinator, Datanode or application.
*/
#ifdef MLS
if (strcmp(user, MLS_USER) == 0 || strcmp(user, AUDIT_USER)==0)
{
if (same_host)
{
num = snprintf(connstr, sizeof(connstr),
"port=%d dbname=%s user=%s application_name='pgxc:%s' sslmode=disable options='-c remotetype=%s -c parentnode=%s %s %s'",
port, dbname, user, parent_node, remote_type, parent_node,
pgoptions, MLS_CONN_OPTION);
}
from tbase.
Related Issues (20)
- Regression for `insert .. select..` in 2.3.0 HOT 4
- Unable to use immutable function in the partial functional index. HOT 3
- pgxc_ctl init all失败 HOT 1
- benchmark 5.0 压测 tbase 报错 HOT 1
- 至今还在PostgreSQL10的级别。TBase有考虑升级吗? HOT 1
- postgres迁移到TBase时uuid类型的字段如何处理?
- some solutions to share HOT 3
- Oriole storage engine compatibility
- 推出社区官网,丰富文档 HOT 1
- complie error
- TBase开源版本是否不支持存储过程?
- 表无法删除
- postGis插件加载不了 HOT 2
- spatial_ref_sys表有数据但查不出来 HOT 1
- Create Discord/Slack Channel for Project Communication HOT 1
- TBase data compare
- TBase是否有支持存储海量的非结构化文件数据的特性或组件?
- OLAP leading to SIGSEV based crashes
- Build Error: Multiple Definition
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tbase.