Исходный код СУБД RuDB — свободной СУБД с открытым исходным кодом на базе PostgreSQL
rudb
3 days ago bd039d1e92813358c5c5a1e346b49074baf513f2
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
#pragma once
 
extern "C" {
#include "fmgr.h"
}
 
// Экспорт SQL-функций (UTL_HTTP)
extern "C" {
 
// SIMPLE FETCH
Datum utl_http_request(PG_FUNCTION_ARGS);
Datum utl_http_request_extended(PG_FUNCTION_ARGS);
Datum utl_http_request_pieces(PG_FUNCTION_ARGS);
 
// REQUEST API
Datum utl_http_begin_request(PG_FUNCTION_ARGS);
Datum utl_http_set_header(PG_FUNCTION_ARGS);
Datum utl_http_set_authentication(PG_FUNCTION_ARGS);
Datum utl_http_set_authentication_from_wallet(PG_FUNCTION_ARGS);
Datum utl_http_set_body_charset_req(PG_FUNCTION_ARGS);
Datum utl_http_set_cookie_support_req(PG_FUNCTION_ARGS);
Datum utl_http_set_follow_redirect_req(PG_FUNCTION_ARGS);
Datum utl_http_set_persistent_conn_support_req(PG_FUNCTION_ARGS);
Datum utl_http_write_line(PG_FUNCTION_ARGS);
Datum utl_http_write_text(PG_FUNCTION_ARGS);
Datum utl_http_write_raw(PG_FUNCTION_ARGS);
Datum utl_http_end_request(PG_FUNCTION_ARGS);
 
// RESPONSE API
Datum utl_http_get_response(PG_FUNCTION_ARGS);
Datum utl_http_end_response(PG_FUNCTION_ARGS);
Datum utl_http_get_authentication(PG_FUNCTION_ARGS);
Datum utl_http_get_header(PG_FUNCTION_ARGS);
Datum utl_http_get_header_by_name(PG_FUNCTION_ARGS);
Datum utl_http_get_header_count(PG_FUNCTION_ARGS);
Datum utl_http_read_line(PG_FUNCTION_ARGS);
Datum utl_http_read_text(PG_FUNCTION_ARGS);
Datum utl_http_read_raw(PG_FUNCTION_ARGS);
Datum utl_http_set_body_charset_resp(PG_FUNCTION_ARGS);
 
// COOKIES
Datum utl_http_add_cookies(PG_FUNCTION_ARGS);
Datum utl_http_clear_cookies(PG_FUNCTION_ARGS);
Datum utl_http_get_cookie_count(PG_FUNCTION_ARGS);
Datum utl_http_get_cookies(PG_FUNCTION_ARGS);
 
// SESSION SETTINGS
Datum utl_http_get_body_charset(PG_FUNCTION_ARGS);
Datum utl_http_set_body_charset_session(PG_FUNCTION_ARGS);
Datum utl_http_get_cookie_support(PG_FUNCTION_ARGS);
Datum utl_http_set_cookie_support_session(PG_FUNCTION_ARGS);
Datum utl_http_get_follow_redirect(PG_FUNCTION_ARGS);
Datum utl_http_set_follow_redirect_session(PG_FUNCTION_ARGS);
Datum utl_http_get_persistent_conn_support(PG_FUNCTION_ARGS);
Datum utl_http_set_persistent_conn_support_session(PG_FUNCTION_ARGS);
Datum utl_http_get_proxy(PG_FUNCTION_ARGS);
Datum utl_http_set_proxy(PG_FUNCTION_ARGS);
Datum utl_http_get_response_error_check(PG_FUNCTION_ARGS);
Datum utl_http_set_response_error_check(PG_FUNCTION_ARGS);
Datum utl_http_get_transfer_timeout(PG_FUNCTION_ARGS);
Datum utl_http_set_transfer_timeout(PG_FUNCTION_ARGS);
Datum utl_http_set_wallet(PG_FUNCTION_ARGS);
Datum utl_http_get_detailed_excp_support(PG_FUNCTION_ARGS);
Datum utl_http_set_detailed_excp_support(PG_FUNCTION_ARGS);
 
// PERSISTENT CONNECTIONS
Datum utl_http_get_persistent_conn_count(PG_FUNCTION_ARGS);
Datum utl_http_get_persistent_conns(PG_FUNCTION_ARGS);
Datum utl_http_close_persistent_conn(PG_FUNCTION_ARGS);
Datum utl_http_close_persistent_conns(PG_FUNCTION_ARGS);
 
// REQUEST CONTEXT
Datum utl_http_create_request_context(PG_FUNCTION_ARGS);
Datum utl_http_destroy_request_context(PG_FUNCTION_ARGS);
 
// DIAGNOSTICS
Datum utl_http_get_detailed_sqlcode(PG_FUNCTION_ARGS);
Datum utl_http_get_detailed_sqlerrm(PG_FUNCTION_ARGS);
Datum utl_http_get_response_error_check_fn(PG_FUNCTION_ARGS);
Datum utl_http_get_detailed_excp_support_fn(PG_FUNCTION_ARGS);
 
// VERSION
Datum utl_http_get_version(PG_FUNCTION_ARGS);
 
} // extern "C"