Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add an option of proxy in the configuration. Set proxy for cURL, http, https, socks4, socks4a, socks5 and socks5h are supported. Signed-off-by: Xiaoran Wang <xiwang@pivotal.io>
- Loading branch information
Showing
15 changed files
with
124 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
CREATE READABLE EXTERNAL TABLE s3regress_proxy (date text, time text, open float, high float, | ||
low float, volume int) LOCATION('s3://s3-us-east-1.amazonaws.com/us-east-1.@read_prefix@/small17/data0000 config=@config_file@ section=proxy') FORMAT 'csv'; | ||
|
||
\d s3regress_proxy | ||
|
||
SELECT round(sum(open)) FROM s3regress_proxy; | ||
|
||
DROP EXTERNAL TABLE s3regress_proxy; |
6 changes: 6 additions & 0 deletions
6
gpAux/extensions/gpcloud/regress/input/2_07_wrong_proxy.source
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
CREATE READABLE EXTERNAL TABLE s3regress_wrong_proxy (date text, time text, open float, high float, | ||
low float, volume int) LOCATION('s3://s3-us-east-1.amazonaws.com/us-east-1.@read_prefix@/small17/data0000 config=@config_file@ section=wrong_proxy') FORMAT 'csv'; | ||
|
||
SELECT round(sum(open)) FROM s3regress_wrong_proxy; | ||
|
||
DROP EXTERNAL TABLE s3regress_wrong_proxy; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
CREATE READABLE EXTERNAL TABLE s3regress_proxy (date text, time text, open float, high float, | ||
low float, volume int) LOCATION('s3://s3-us-east-1.amazonaws.com/us-east-1.@read_prefix@/small17/data0000 config=@config_file@ section=proxy') FORMAT 'csv'; | ||
\d s3regress_proxy | ||
External table "public.s3regress_proxy" | ||
Column | Type | Modifiers | ||
--------+------------------+----------- | ||
date | text | | ||
time | text | | ||
open | double precision | | ||
high | double precision | | ||
low | double precision | | ||
volume | integer | | ||
Type: readable | ||
Encoding: UTF8 | ||
Format type: csv | ||
Format options: delimiter ',' null '' escape '"' quote '"' | ||
External options: {} | ||
External location: "s3://s3-us-east-1.amazonaws.com/us-east-1.@read_prefix@/small17/data0000 config=@config_file@ section=proxy" | ||
Execute on: all segments | ||
|
||
SELECT round(sum(open)) FROM s3regress_proxy; | ||
round | ||
--------- | ||
4239338 | ||
(1 row) | ||
|
||
DROP EXTERNAL TABLE s3regress_proxy; |
6 changes: 6 additions & 0 deletions
6
gpAux/extensions/gpcloud/regress/output/2_07_wrong_proxy.source
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
CREATE READABLE EXTERNAL TABLE s3regress_wrong_proxy (date text, time text, open float, high float, | ||
low float, volume int) LOCATION('s3://s3-us-east-1.amazonaws.com/us-east-1.s3test.pivotal.io/regress/small17/data0000 config=/home/gpadmin/s3.conf section=wrong_proxy') FORMAT 'csv'; | ||
SELECT round(sum(open)) FROM s3regress_wrong_proxy; | ||
ERROR: Failed to init gpcloud extension | ||
DETAIL: External table s3regress_wrong_proxy, file s3://s3-us-east-1.amazonaws.com/us-east-1.s3test.pivotal.io/regress/small17/data0000 config=/home/gpadmin/s3.conf section=wrong_proxy | ||
DROP EXTERNAL TABLE s3regress_wrong_proxy; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters