78 #define NET_COPY_AREA_SENDRECV_SIZE (OR_INT_SIZE * 3) 79 #define NET_SENDRECV_BUFFSIZE (OR_INT_SIZE) 82 #define NET_DEFER_END_QUERIES_MAX 5 84 static int net_Deferred_end_queries_count = 0;
94 static char *pack_const_string (
char *buffer,
const char *cstring);
95 static char *pack_string_with_null_padding (
char *buffer,
const char *stream,
int len);
96 static int length_const_string (
const char *cstring,
int *
strlen);
97 static int length_string_with_null_padding (
int len);
100 static void enter_server_no_thread_entry (
void);
102 static void exit_server_no_thread_entry (
void);
103 static void exit_server (
const THREAD_ENTRY & thread_ref);
104 #endif // SERVER_MODE 106 #if defined (SA_MODE) 111 enter_server_no_thread_entry (
void)
131 enter_server_no_thread_entry ();
139 exit_server_no_thread_entry (
void)
159 exit_server_no_thread_entry ();
175 pack_const_string (
char *buffer,
const char *cstring)
193 pack_string_with_null_padding (
char *buffer,
const char *stream,
int len)
210 pack_const_string_with_length (
char *buffer,
const char *cstring,
int strlen)
224 length_const_string (
const char *cstring,
int *
strlen)
237 length_string_with_null_padding (
int len)
282 *fetch_copyarea =
NULL;
294 *fetch_copyarea =
NULL;
304 xlocator_fetch (thread_p, oidp, chn, lock, fetch_version_type, fetch_version_type, class_oid, class_chn, prefetch,
307 exit_server (*thread_p);
348 *fetch_copyarea =
NULL;
361 *fetch_copyarea =
NULL;
370 success =
xlocator_get_class (thread_p, class_oid, class_chn, oid, lock, prefetching, fetch_copyarea);
372 exit_server (*thread_p);
396 int *nobjects,
int *nfetched,
OID * last_oidp,
LC_COPYAREA ** fetch_copyarea)
417 *fetch_copyarea =
NULL;
433 *fetch_copyarea =
NULL;
443 xlocator_fetch_all (thread_p, hfid, lock, fetch_version_type, class_oidp, nobjects, nfetched, last_oidp,
446 exit_server (*thread_p);
494 if (fetch_copyarea !=
NULL && need_fetching)
496 *fetch_copyarea =
NULL;
507 if (does_exist ==
LC_EXIST && class_oid)
512 else if (fetch_copyarea !=
NULL)
514 *fetch_copyarea =
NULL;
524 xlocator_does_exist (thread_p, oidp, chn, lock, fetch_version_type, class_oid, class_chn, need_fetching, prefetch,
527 exit_server (*thread_p);
554 *synch_copyarea =
NULL;
566 *synch_copyarea =
NULL;
577 exit_server (*thread_p);
603 char *desc_ptr =
NULL;
616 request_ptr =
or_pack_int (request_ptr, desc_size);
617 request_ptr =
or_pack_int (request_ptr, content_size);
666 char *desc_ptr =
NULL;
676 request_size =
OR_INT_SIZE * (5 + num_ignore_error_list);
677 request = (
char *) malloc (request_size);
697 request_ptr =
or_pack_int (request_ptr, desc_size);
698 request_ptr =
or_pack_int (request_ptr, content_size);
700 request_ptr =
or_pack_int (request_ptr, num_ignore_error_list);
701 for (i = 0; i < num_ignore_error_list; i++)
703 request_ptr =
or_pack_int (request_ptr, ignore_error_list[i]);
733 if (copy_area_clone ==
NULL)
738 memcpy (copy_area_clone->
mem, copy_area->
mem, copy_area->
length);
742 error_code =
xlocator_force (thread_p, copy_area, num_ignore_error_list, ignore_error_list);
744 exit_server (*thread_p);
749 memcpy (copy_area->
mem, copy_area_clone->
mem, copy_area->
length);
804 fetch_copyarea, &eid);
813 packed_size, fetch_copyarea, eid);
827 *fetch_copyarea =
NULL;
845 exit_server (*thread_p);
886 *fetch_copyarea =
NULL;
906 if (packed_size > 0 && packed !=
NULL)
922 *fetch_copyarea =
NULL;
935 lockset, fetch_copyarea);
937 exit_server (*thread_p);
970 request = (
char *) malloc (request_size);
977 ptr = pack_const_string_with_length (request, class_name, strlen);
999 exit_server (*thread_p);
1019 #if defined(CS_MODE) 1024 char *request, *ptr;
1032 for (i = 0; i < num_classes; ++
i)
1034 request_size += length_const_string (class_names[i],
NULL) +
OR_OID_SIZE;
1036 request = (
char *) malloc (request_size);
1037 if (request ==
NULL)
1044 for (i = 0; i < num_classes; ++
i)
1046 ptr = pack_const_string (ptr, class_names[i]);
1068 exit_server (*thread_p);
1084 #if defined(CS_MODE) 1087 char *request =
NULL;
1098 request_size = length_const_string (classname,
NULL);
1099 request = (
char *) malloc (request_size);
1100 if (request ==
NULL)
1106 (void) pack_const_string (request, classname);
1114 return request_error;
1127 exit_server (*thread_p);
1145 #if defined(CS_MODE) 1148 int req_error, request_size,
strlen;
1155 request_size = length_const_string (class_name, &strlen);
1156 request = (
char *) malloc (request_size);
1157 if (request ==
NULL)
1163 (void) pack_const_string_with_length (request, class_name, strlen);
1182 exit_server (*thread_p);
1202 #if defined(CS_MODE) 1205 int request_size, strlen1, strlen2;
1207 char *request, *ptr;
1213 request_size = length_const_string (old_name, &strlen1) + length_const_string (new_name, &strlen2) +
OR_OID_SIZE;
1214 request = (
char *) malloc (request_size);
1215 if (request ==
NULL)
1221 ptr = pack_const_string_with_length (request, old_name, strlen1);
1222 ptr = pack_const_string_with_length (ptr, new_name, strlen2);
1242 exit_server (*thread_p);
1264 #if defined(CS_MODE) 1266 int request_size,
strlen;
1268 char *request, *ptr;
1275 request = (
char *) malloc (request_size);
1276 if (request ==
NULL)
1285 ptr = pack_const_string_with_length (ptr, class_name, strlen);
1302 success =
xlocator_assign_oid (thread_p, hfid, perm_oid, expected_length, class_oid, class_name);
1304 exit_server (*thread_p);
1322 #if defined(CS_MODE) 1334 buffer = (
char *) malloc (packed_size);
1376 exit_server (*thread_p);
1404 int *guessed_class_chns,
int quit_on_errors,
LOCK lock_rr_tran,
1407 #if defined(CS_MODE) 1413 char *request, *packed;
1422 *fetch_copyarea =
NULL;
1425 for (i = 0; i < num_classes; i++)
1427 request_size += (length_const_string (many_classnames[i],
NULL) + OR_INT_SIZE + OR_INT_SIZE + OR_INT_SIZE
1431 request = (
char *) malloc (request_size);
1432 if (request ==
NULL)
1441 for (i = 0; i < num_classes; i++)
1443 ptr = pack_const_string (ptr, many_classnames[i]);
1461 if (packed_size > 0 && packed !=
NULL)
1478 *fetch_copyarea =
NULL;
1481 if (request !=
NULL)
1496 many_flags, guessed_class_oids, guessed_class_chns, quit_on_errors, lockhint,
1499 exit_server (*thread_p);
1518 #if defined(CS_MODE) 1527 char *packed =
NULL;
1534 *fetch_copyarea =
NULL;
1540 packed = lockhint->
packed;
1553 packed, send_size, packed, packed_size, fetch_copyarea, &eid);
1558 packed = lockhint->
packed;
1562 packed_size, fetch_copyarea, eid);
1576 *fetch_copyarea =
NULL;
1590 exit_server (*thread_p);
1610 #if defined(CS_MODE) 1640 success =
xheap_create (thread_p, hfid, class_oid, reuse_oid);
1642 exit_server (*thread_p);
1648 #if defined(ENABLE_UNUSED_FUNCTION) 1661 #if defined(CS_MODE) 1691 exit_server (*thread_p);
1710 #if defined(CS_MODE) 1741 exit_server (*thread_p);
1760 #if defined(CS_MODE) 1790 exit_server (*thread_p);
1808 #if defined(CS_MODE) 1837 exit_server (*thread_p);
1843 #ifdef UNSTABLE_TDE_FOR_REPLICATION_LOG 1854 tde_get_data_keys ()
1856 #if defined(CS_MODE) 1858 int req_error, area_size;
1900 #if defined(CS_MODE) 1902 int req_error, area_size;
1944 #if defined(CS_MODE) 1946 int req_error, area_size;
1972 exit_server (*thread_p);
1990 #if defined(CS_MODE) 2019 exit_server (*thread_p);
2037 #if defined(CS_MODE) 2066 exit_server (*thread_p);
2084 #if defined(CS_MODE) 2114 exit_server (*thread_p);
2132 #if defined(CS_MODE) 2150 if (!req_error && area !=
NULL)
2163 char *remark =
NULL;
2169 exit_server (*thread_p);
2188 #if defined(CS_MODE) 2206 if (!req_error && area !=
NULL)
2212 strcpy (vol_fullname, name);
2218 vol_fullname =
NULL;
2221 return vol_fullname;
2228 exit_server (*thread_p);
2230 return vol_fullname;
2246 #if defined(CS_MODE) 2275 exit_server (*thread_p);
2293 #if defined(CS_MODE) 2296 char *request, *ptr;
2321 exit_server (*thread_p);
2339 #if defined(CS_MODE) 2353 exit_server (*thread_p);
2367 #if defined(CS_MODE) 2403 #if defined(CS_MODE) 2418 exit_server (*thread_p);
2434 #if defined(CS_MODE) 2438 char *request, *reply;
2460 exit_server (*thread_p);
2466 #if defined(CS_MODE) 2478 log_find_lob_locator (
const char *locator,
char *real_locator)
2481 int req_error, state_int, request_size,
strlen;
2482 char *request, *reply, *ptr;
2488 request_size = length_const_string (locator, &strlen);
2489 request = (
char *) malloc (request_size);
2490 if (request ==
NULL)
2496 (void) pack_const_string_with_length (request, locator, strlen);
2524 char *request, *reply;
2530 request_size = length_const_string (locator, &strlen) +
OR_INT_SIZE;
2531 request = (
char *) malloc (request_size);
2532 if (request ==
NULL)
2538 ptr = pack_const_string_with_length (request, locator, strlen);
2562 log_change_state_of_locator (
const char *locator,
const char *new_locator,
LOB_LOCATOR_STATE state)
2565 int request_size,
strlen, strlen2;
2566 char *request, *reply;
2572 request_size = length_const_string (locator, &strlen) + length_const_string (new_locator, &strlen2) +
OR_INT_SIZE;
2573 request = (
char *) malloc (request_size);
2574 if (request ==
NULL)
2580 ptr = pack_const_string_with_length (request, locator, strlen);
2581 ptr = pack_const_string_with_length (ptr, new_locator, strlen2);
2604 log_drop_lob_locator (
const char *locator)
2607 int request_size,
strlen;
2608 char *request, *reply;
2614 request_size = length_const_string (locator, &strlen);
2615 request = (
char *) malloc (request_size);
2616 if (request ==
NULL)
2622 ptr = pack_const_string_with_length (request, locator, strlen);
2647 #if defined(CS_MODE) 2649 int req_error, tran_state_int, should_conn_reset;
2673 ptr =
or_pack_int (ptr, net_Deferred_end_queries_count);
2674 for (i = 0; i < net_Deferred_end_queries_count; i++)
2676 ptr =
or_pack_ptr (ptr, net_Deferred_end_queries[i]);
2678 net_Deferred_end_queries_count = 0;
2710 exit_server (*thread_p);
2726 #if defined(CS_MODE) 2728 int req_error, tran_state_int, should_conn_reset;
2736 net_Deferred_end_queries_count = 0;
2766 exit_server (*thread_p);
2783 return "(RECOVERY)";
2787 return "(COMMITTED)";
2789 return "(COMMITTING)";
2791 return "(COMMITTED1)";
2793 return "(COMMITTED3)";
2807 return "(COMMITTED5)";
2809 return "(ABORTED3)";
2830 #if defined(CS_MODE) 2831 bool blocked =
false;
2850 blocked = (temp == 1) ?
true :
false;
2855 bool blocked =
false;
2861 exit_server (*thread_p);
2877 #if defined(CS_MODE) 2878 int has_updated = 0;
2895 int has_updated = 0;
2901 exit_server (*thread_p);
2917 #if defined(CS_MODE) 2918 int isactive_and_has_updated = 0;
2933 return isactive_and_has_updated;
2935 int isactive_and_has_updated = 0;
2947 exit_server (*thread_p);
2949 return (isactive_and_has_updated);
2963 #if defined(CS_MODE) 2999 #if defined(CS_MODE) 3028 exit_server (*thread_p);
3048 #if defined(CS_MODE) 3079 exit_server (*thread_p);
3095 #if defined(CS_MODE) 3119 exit_server (*thread_p);
3135 #if defined(CS_MODE) 3159 exit_server (*thread_p);
3178 #if defined(CS_MODE) 3188 reply = (
char *) malloc (reply_size);
3198 reply, reply_size,
NULL, 0,
NULL, 0);
3202 for (
i = 0;
i < count &&
i < size;
i++)
3217 exit_server (*thread_p);
3235 #if defined(CS_MODE) 3264 exit_server (*thread_p);
3282 #if defined(CS_MODE) 3284 int req_error, tran_state_int;
3312 exit_server (*thread_p);
3318 #if defined (ENABLE_UNUSED_FUNCTION) 3329 tran_server_start_topop (
LOG_LSA * topop_lsa)
3331 #if defined(CS_MODE) 3363 exit_server (*thread_p);
3382 #if defined(CS_MODE) 3384 int req_error, tran_state_int;
3412 exit_server (*thread_p);
3414 return (tran_state);
3432 #if defined(CS_MODE) 3434 int req_error, request_size,
strlen;
3435 char *request, *reply;
3441 request_size = length_const_string (savept_name, &strlen);
3442 request = (
char *) malloc (request_size);
3443 if (request ==
NULL)
3449 ptr = pack_const_string_with_length (request, savept_name, strlen);
3468 exit_server (*thread_p);
3487 #if defined(CS_MODE) 3489 int req_error, tran_state_int, request_size,
strlen;
3490 char *request, *reply;
3496 request_size = length_const_string (savept_name, &strlen);
3497 request = (
char *) malloc (request_size);
3498 if (request ==
NULL)
3504 ptr = pack_const_string_with_length (request, savept_name, strlen);
3523 exit_server (*thread_p);
3538 #if defined(CS_MODE) 3569 #if defined(CS_MODE) 3591 #if defined(CS_MODE) 3606 exit_server (*thread_p);
3640 bool db_overwrite,
const char *file_addmore_vols,
DKNPAGES db_npages,
3642 OID * rootclass_oid,
HFID * rootclass_hfid,
int client_lock_wait,
3645 #if defined(CS_MODE) 3652 enter_server_no_thread_entry ();
3656 db_desired_pagesize, log_npages, db_desired_log_page_size, rootclass_oid, rootclass_hfid,
3657 client_lock_wait, client_isolation);
3659 exit_server_no_thread_entry ();
3661 return (tran_index);
3680 #if defined(CS_MODE) 3682 int area_size, req_error, temp_int;
3683 char *reply, *
area, *ptr;
3690 int clisol_toint = (int) client_isolation;
3700 int ha_state_to_int;
3735 enter_server_no_thread_entry ();
3738 xboot_register_client (NULL, client_credential, client_lock_wait, client_isolation, tran_state, server_credential);
3739 exit_server_no_thread_entry ();
3757 #if defined(CS_MODE) 3778 error_code = req_error;
3797 exit_server_no_thread_entry ();
3801 exit_server (*thread_p);
3828 int skip_activelog,
int sleep_msecs,
bool separate_keys)
3830 #if defined(CS_MODE) 3832 int request_size, strlen1, strlen2;
3833 char *request, *ptr;
3847 request = (
char *) malloc (request_size);
3848 if (request ==
NULL)
3854 ptr = pack_const_string_with_length (request, backup_path, strlen1);
3856 ptr =
or_pack_int (ptr, delete_unneeded_logarchives ? 1 : 0);
3857 ptr = pack_const_string_with_length (ptr, backup_verbose_file, strlen2);
3866 OR_ALIGNED_BUF_SIZE (a_reply),
NULL, 0,
NULL, 0, &rd1, &d1, &rd2, &d2,
NULL,
3878 int success =
false;
3882 success =
xboot_backup (thread_p, backup_path, backup_level, delete_unneeded_logarchives, backup_verbose_file,
3883 num_threads, zip_method, zip_level, skip_activelog, sleep_msecs, separate_keys);
3885 exit_server (*thread_p);
3903 #if defined(CS_MODE) 3906 int request_size, strlen1, strlen2, strlen3;
3907 char *request, *ptr;
3914 request_size = (length_const_string (ext_info->
path, &strlen1)
3915 + length_const_string (ext_info->
name, &strlen2)
3916 + length_const_string (ext_info->
comments, &strlen3)
3919 request = (
char *) malloc (request_size);
3920 if (request ==
NULL)
3926 ptr = pack_const_string_with_length (request, ext_info->
path, strlen1);
3927 ptr = pack_const_string_with_length (ptr, ext_info->
name, strlen2);
3928 ptr = pack_const_string_with_length (ptr, ext_info->
comments, strlen3);
3950 exit_server (*thread_p);
3968 #if defined(CS_MODE) 3976 char *request, *ptr;
3977 size_t request_size;
3985 request = (
char *) malloc (request_size);
3986 if (request ==
NULL)
3994 for (i = 0; i < num_oids; i++)
4020 exit_server (*thread_p);
4036 #if defined(CS_MODE) 4059 exit_server (*thread_p);
4075 #if defined(CS_MODE) 4098 exit_server (*thread_p);
4115 #if defined(CS_MODE) 4128 volid = (
VOLID) int_volid;
4137 exit_server (*thread_p);
4153 #if defined(CS_MODE) 4176 exit_server (*thread_p);
4192 #if defined(CS_MODE) 4198 enter_server_no_thread_entry ();
4202 exit_server_no_thread_entry ();
4208 #if defined (SA_MODE) 4221 enter_server_no_thread_entry ();
4225 exit_server_no_thread_entry ();
4241 #if defined(CS_MODE) 4252 exit_server_no_thread_entry ();
4271 #if defined (CS_MODE) 4277 int request_size, area_size;
4278 int db_user_len, host_len, program_name_len;
4286 request_size += length_const_string (db_user, &db_user_len);
4287 request_size += length_const_string (host, &host_len);
4288 request_size += length_const_string (program_name, &program_name_len);
4292 request = (
char *) malloc (request_size);
4293 if (request ==
NULL)
4302 ptr = pack_const_string_with_length (ptr, db_user, db_user_len);
4303 ptr = pack_const_string_with_length (ptr, host, host_len);
4304 ptr = pack_const_string_with_length (ptr, program_name, program_name_len);
4308 NULL, 0, &area, &area_size);
4326 if (update_parameter_values)
4333 if (update_parameter_values)
4336 if (session_params ==
NULL)
4348 sysprm_update_client_session_parameters (session_params);
4353 sysprm_update_client_session_parameters (cached_session_parameters);
4392 exit_server (*thread_p);
4407 #if defined (CS_MODE) 4436 exit_server (*thread_p);
4453 #if defined (CS_MODE) 4483 exit_server (*thread_p);
4500 #if defined (CS_MODE) 4528 exit_server (*thread_p);
4543 #if defined (CS_MODE) 4550 char *data_reply =
NULL;
4558 ptr =
or_pack_int (request, update_last_insert_id);
4574 if (req_error !=
NO_ERROR || data_size == 0)
4583 if (data_reply !=
NULL)
4595 exit_server (*thread_p);
4608 #if defined (CS_MODE) 4632 exit_server (*thread_p);
4649 #if defined (CS_MODE) 4652 char *request =
NULL;
4655 int req_size = 0, name_len = 0, alias_print_len = 0;
4662 req_size += length_const_string (name, &name_len);
4664 req_size += length_const_string (alias_print, &alias_print_len);
4667 if (alias_print !=
NULL)
4673 request = (
char *) malloc (req_size);
4674 if (request ==
NULL)
4682 ptr = pack_const_string_with_length (request, name, name_len);
4684 ptr = pack_const_string_with_length (ptr, alias_print, alias_print_len);
4690 req_error =
SHA1Compute ((
const unsigned char *) alias_print, (
unsigned)
strlen (alias_print), &alias_sha1);
4709 if (request !=
NULL)
4716 char *local_name =
NULL;
4717 char *local_alias_print =
NULL;
4718 char *local_stmt_info =
NULL;
4730 local_name = (
char *) malloc (len + 1);
4731 if (local_name ==
NULL)
4737 memcpy (local_name, name, len);
4738 local_name[len] = 0;
4742 if (alias_print !=
NULL)
4744 len =
strlen (alias_print);
4745 local_alias_print = (
char *) malloc (len + 1);
4746 if (local_alias_print ==
NULL)
4752 memcpy (local_alias_print, alias_print, len);
4753 local_alias_print[len] = 0;
4755 result =
SHA1Compute ((
const unsigned char *) alias_print, (
unsigned)
strlen (alias_print), &alias_sha1);
4764 if (stmt_info !=
NULL)
4766 local_stmt_info = (
char *) malloc (info_length);
4767 if (local_stmt_info ==
NULL)
4773 memcpy (local_stmt_info, stmt_info, info_length);
4784 exit_server (*thread_p);
4790 if (local_name !=
NULL)
4794 if (local_alias_print !=
NULL)
4798 if (local_stmt_info !=
NULL)
4803 exit_server (*thread_p);
4821 #if defined (CS_MODE) 4825 char *reply_data =
NULL;
4826 char *request =
NULL;
4828 int req_size = 0, len = 0;
4830 int get_xasl_header = xasl_header_p !=
NULL;
4836 request = (
char *) malloc (req_size);
4837 if (request ==
NULL)
4868 if (*stmt_info ==
NULL)
4873 if (get_xasl_header)
4878 if (request !=
NULL)
4882 if (reply_data !=
NULL)
4889 if (request !=
NULL)
4893 if (reply_data !=
NULL)
4901 int stmt_info_len = 0;
4908 exit_server (*thread_p);
4922 #if defined (CS_MODE) 4925 char *request =
NULL;
4926 int name_len, req_len;
4928 req_len = length_const_string (name, &name_len);
4930 request = (
char *) malloc (req_len);
4931 if (request ==
NULL)
4937 pack_const_string_with_length (request, name, name_len);
4942 if (request !=
NULL)
4962 exit_server (*thread_p);
4976 #if defined (CS_MODE) 4979 char *request =
NULL;
4980 int username_len, req_len;
4982 req_len = length_const_string (username, &username_len);
4984 request = (
char *) malloc (req_len);
4985 if (request ==
NULL)
4991 pack_const_string_with_length (request, username, username_len);
4996 if (request !=
NULL)
5016 exit_server (*thread_p);
5031 #if defined (CS_MODE) 5034 char *request =
NULL, *data_request =
NULL, *ptr =
NULL;
5046 data_request = (
char *) malloc (req_size);
5047 if (data_request ==
NULL)
5063 data_request, req_size,
NULL, 0);
5072 if (data_request !=
NULL)
5085 exit_server (*thread_p);
5100 #if defined (CS_MODE) 5103 char *request =
NULL, *data_request =
NULL, *ptr =
NULL;
5115 data_request = (
char *) malloc (req_size);
5116 if (data_request ==
NULL)
5132 data_request, req_size,
NULL, 0);
5141 if (data_request !=
NULL)
5154 exit_server (*thread_p);
5169 #if defined (CS_MODE) 5178 request = (
char *) malloc (req_size);
5179 if (request ==
NULL)
5207 if (request !=
NULL)
5225 exit_server (*thread_p);
5249 boot_soft_rename (
const char *old_db_name,
const char *new_db_name,
const char *new_db_path,
const char *new_log_path,
5250 const char *new_db_server_host,
const char *new_volext_path,
const char *fileof_vols_and_renamepaths,
5251 bool new_db_overwrite,
bool extern_rename,
bool force_delete)
5253 #if defined(CS_MODE) 5262 xboot_soft_rename (thread_p, old_db_name, new_db_name, new_db_path, new_log_path, new_db_server_host,
5263 new_volext_path, fileof_vols_and_renamepaths, new_db_overwrite, extern_rename, force_delete);
5265 exit_server (*thread_p);
5293 boot_copy (
const char *from_dbname,
const char *new_db_name,
const char *new_db_path,
const char *new_log_path,
5294 const char *new_lob_path,
const char *new_db_server_host,
5295 const char *new_volext_path,
const char *fileof_vols_and_copypaths,
bool new_db_overwrite)
5297 #if defined(CS_MODE) 5306 xboot_copy (thread_p, from_dbname, new_db_name, new_db_path, new_log_path, new_lob_path, new_db_server_host,
5307 new_volext_path, fileof_vols_and_copypaths, new_db_overwrite);
5310 exit_server_no_thread_entry ();
5326 #if defined(CS_MODE) 5332 enter_server_no_thread_entry ();
5336 exit_server_no_thread_entry ();
5349 #if defined(CS_MODE) 5390 #if defined(CS_MODE) 5434 #if defined(CS_MODE) 5444 *stats_buffer =
NULL;
5458 *stats_buffer = area;
5467 exit_server (*thread_p);
5486 #if defined(CS_MODE) 5517 exit_server (*thread_p);
5534 #if defined(CS_MODE) 5564 exit_server (*thread_p);
5586 #if defined(CS_MODE) 5599 request = (
char *) malloc (request_size);
5600 if (request ==
NULL)
5637 btid =
xbtree_add_index (thread_p, btid, key_type, class_oid, attr_id, unique_pk, 0, 0, 0);
5644 exit_server (*thread_p);
5672 int *attr_ids,
int *attrs_prefix_length,
HFID * hfids,
int unique_pk,
int not_null_flag,
5673 OID * fk_refcls_oid,
BTID * fk_refcls_pk_btid,
const char *fk_name,
char *pred_stream,
5674 int pred_stream_size,
char *expr_stream,
int expr_stream_size,
int func_col_id,
5677 #if defined(CS_MODE) 5683 int i, total_attrs, bt_strlen, fk_strlen;
5684 int index_info_size = 0;
5685 char *stream =
NULL;
5686 int stream_size = 0;
5694 if (pred_stream && expr_stream)
5709 + (n_classes * n_attrs * OR_INT_SIZE)
5710 + ((n_classes == 1) ? (n_attrs * OR_INT_SIZE) : 0)
5721 request = (
char *) malloc (request_size);
5722 if (request ==
NULL)
5734 for (i = 0; i < n_classes; i++)
5739 total_attrs = n_classes * n_attrs;
5740 for (i = 0; i < total_attrs; i++)
5747 for (i = 0; i < n_attrs; i++)
5749 if (attrs_prefix_length)
5760 for (i = 0; i < n_classes; i++)
5776 stream = pred_stream;
5777 stream_size = pred_stream_size;
5779 else if (expr_stream)
5785 stream = expr_stream;
5786 stream_size = expr_stream_size;
5798 stream, stream_size,
NULL, 0);
5807 curr_cls_lock = (
LOCK) t;
5840 if (class_mop !=
NULL)
5858 attrs_prefix_length, hfids, unique_pk, not_null_flag, fk_refcls_oid,
5859 fk_refcls_pk_btid, fk_name, pred_stream, pred_stream_size, expr_stream,
5860 expr_stream_size, func_col_id, func_attr_index_start, 1);
5865 xbtree_load_index (thread_p, btid, bt_name, key_type, class_oids, n_classes, n_attrs, attr_ids,
5866 attrs_prefix_length, hfids, unique_pk, not_null_flag, fk_refcls_oid, fk_refcls_pk_btid,
5867 fk_name, pred_stream, pred_stream_size, expr_stream, expr_stream_size, func_col_id,
5868 func_attr_index_start);
5881 exit_server (*thread_p);
5899 #if defined(CS_MODE) 5931 exit_server (*thread_p);
5947 #if defined(CS_MODE) 5957 exit_server (*thread_p);
5977 #if defined(CS_MODE) 5978 char *request, *reply, *ptr;
6010 exit_server (*thread_p);
6031 #if defined(CS_MODE) 6033 int req_error, request_size, key_size;
6051 request = (
char *) malloc (request_size);
6052 if (request ==
NULL)
6096 exit_server (*thread_p);
6118 #if defined (CS_MODE) 6119 int req_error, req_size, area_size,
i;
6133 for (i = 0; i <
count; i++)
6138 request = (
char *) malloc (req_size);
6139 if (request ==
NULL)
6155 for (i = 0; i <
count; i++)
6160 for (i = 0; i <
count; i++)
6195 if (*oids_count == 0)
6204 assert (*oids_count > 0);
6208 *oids = (
OID *) malloc ((*oids_count) *
sizeof (
OID));
6216 for (i = 0; i < *oids_count; i++)
6222 if (request !=
NULL)
6240 int local_count = 0;
6249 exit_server (*thread_p);
6254 if (local_count > 0)
6256 *oids = (
OID *) malloc (local_count *
sizeof (
OID));
6260 exit_server (*thread_p);
6263 *oids_count = local_count;
6264 memcpy (*oids, local_oids, local_count *
sizeof (
OID));
6268 exit_server (*thread_p);
6287 #if defined(CS_MODE) 6314 exit_server (*thread_p);
6336 #if defined(CS_MODE) 6369 exit_server (*thread_p);
6393 #if defined(CS_MODE) 6395 int req_error, request_size = 0;
6396 int sql_hash_text_len, sql_plan_text_len, reply_buffer_size = 0;
6406 request_size += length_const_string (context->
sql_hash_text, &sql_hash_text_len);
6409 request_size += length_const_string (context->
sql_plan_text, &sql_plan_text_len);
6421 request = (
char *) malloc (request_size);
6422 if (request ==
NULL)
6429 ptr = pack_const_string_with_length (request, context->
sql_hash_text, sql_hash_text_len);
6431 ptr = pack_const_string_with_length (ptr, context->
sql_plan_text, sql_plan_text_len);
6448 (
char *) stream->
buffer, stream->
buffer_size, &reply_buffer, &reply_buffer_size);
6459 if (reply_buffer !=
NULL && reply_buffer_size != 0)
6462 if (get_xasl_header)
6466 if (ptr < reply_buffer + reply_buffer_size)
6485 if (request !=
NULL)
6490 if (reply_buffer !=
NULL)
6514 exit_server (*thread_p);
6540 exit_server (*thread_p);
6575 #if defined(CS_MODE) 6577 int req_error, senddata_size, replydata_size_listid, replydata_size_page, replydata_size_plan;
6578 char *request, *reply, *senddata =
NULL;
6579 char *replydata_listid =
NULL, *replydata_page =
NULL, *replydata_plan =
NULL, *ptr;
6586 int should_conn_reset, end_query_result, tran_state;
6593 for (i = 0, dbval = dbvals; i < dbval_cnt; i++, dbval++)
6597 if (senddata_size != 0)
6599 senddata = (
char *) malloc (senddata_size);
6600 if (senddata ==
NULL)
6607 for (i = 0, dbval = dbvals; i < dbval_cnt; i++, dbval++)
6634 ptr =
or_pack_int (ptr, net_Deferred_end_queries_count);
6635 for (i = 0; i < net_Deferred_end_queries_count; i++)
6637 ptr =
or_pack_ptr (ptr, net_Deferred_end_queries[i]);
6641 net_Deferred_end_queries_count = 0;
6660 assert (senddata !=
NULL && 0 < senddata_size);
6662 memcpy (ptr, senddata, senddata_size);
6663 request_len += senddata_size;
6675 &replydata_listid, &replydata_size_listid, &replydata_page,
6676 &replydata_size_page, &replydata_plan, &replydata_size_plan);
6677 if (replydata_plan !=
NULL)
6683 if (senddata !=
NULL)
6699 memcpy (srv_cache_time, &local_srv_cache_time,
sizeof (
CACHE_TIME));
6717 if (replydata_listid && replydata_size_listid)
6722 if (replydata_size_page)
6746 size_t s = dbval_cnt *
sizeof (
DB_VALUE);
6749 if (server_db_values ==
NULL)
6753 for (i = 0; i < dbval_cnt; i++)
6757 for (i = 0; i < dbval_cnt; i++)
6783 server_db_values =
NULL;
6788 xqmgr_execute_query (thread_p, xasl_id, query_idp, dbval_cnt, server_db_values, &flag, clt_cache_time,
6789 srv_cache_time, query_timeout,
NULL);
6792 if (server_db_values !=
NULL)
6794 for (i = 0; i < dbval_cnt; i++)
6801 exit_server (*thread_p);
6826 #if defined(CS_MODE) 6828 int req_error, senddata_size, replydata_size_listid, replydata_size_page;
6830 char *ptr, *senddata, *replydata;
6844 for (i = 0, dbval = dbval_ptr; i < dbval_cnt; i++, dbval++)
6849 if (senddata_size != 0)
6851 senddata = (
char *) malloc (senddata_size);
6852 if (senddata ==
NULL)
6865 for (i = 0, dbval = dbval_ptr; i < dbval_cnt; i++, dbval++)
6875 xasl_stream, xasl_stream_size, senddata, senddata_size, &replydata,
6876 &replydata_size_listid, &page_ptr, &replydata_size_page,
NULL,
NULL);
6886 if (replydata !=
NULL && size)
6899 if (senddata !=
NULL)
6914 exit_server (*thread_p);
6932 #if defined(CS_MODE) 6944 net_Deferred_end_queries[net_Deferred_end_queries_count++] = query_id;
6952 net_Deferred_end_queries_count = 0;
6960 ptr =
or_pack_ptr (ptr, net_Deferred_end_queries[i]);
6984 exit_server (*thread_p);
7007 #if defined(CS_MODE) 7009 int req_error, request_size;
7010 char *request, *reply;
7039 exit_server (*thread_p);
7057 #if defined(CS_MODE) 7072 exit_server (*thread_p);
7088 #if defined(CS_MODE) 7103 exit_server (*thread_p);
7107 #if defined(ENABLE_UNUSED_FUNCTION) 7118 qp_get_sys_timestamp (
DB_VALUE * value)
7120 #if defined(CS_MODE) 7136 (void) or_unpack_utime (reply, &sysutime);
7147 exit_server (*thread_p);
7167 #if defined(CS_MODE) 7184 if (!req_error && area !=
NULL)
7200 exit_server (*thread_p);
7219 #if defined(CS_MODE) 7238 if (!req_error && area !=
NULL)
7258 exit_server (*thread_p);
7276 #if defined(CS_MODE) 7303 exit_server (*thread_p);
7319 #if defined(CS_MODE) 7339 perfmon_start_watch (thread_p);
7341 exit_server (*thread_p);
7357 #if defined(CS_MODE) 7376 perfmon_stop_watch (thread_p);
7378 exit_server (*thread_p);
7395 #if defined(CS_MODE) 7398 int nr_statistic_values;
7401 reply = (
char *) malloc (nr_statistic_values *
OR_INT64_SIZE);
7406 (
size_t) nr_statistic_values * OR_INT64_SIZE);
7419 perfmon_Iscollecting_stats =
false;
7431 exit_server (*thread_p);
7448 #if defined(CS_MODE) 7451 int nr_statistic_values;
7454 reply = (
char *) malloc (nr_statistic_values *
OR_INT64_SIZE);
7458 (
size_t) nr_statistic_values * OR_INT64_SIZE);
7463 nr_statistic_values * OR_INT64_SIZE,
NULL, 0,
NULL, 0);
7470 perfmon_Iscollecting_stats =
false;
7481 exit_server (*thread_p);
7499 #if defined(CS_MODE) 7500 int req_error, status;
7534 exit_server (*thread_p);
7555 #if defined(CS_MODE) 7557 int request_size, strlen1, strlen2;
7566 + length_const_string (kill_host, &strlen2));
7568 request = (
char *) malloc (request_size);
7569 if (request ==
NULL)
7576 ptr = pack_const_string_with_length (ptr, kill_user, strlen1);
7577 ptr = pack_const_string_with_length (ptr, kill_host, strlen2);
7613 #if defined(CS_MODE) 7624 request_size =
OR_INT_SIZE * (2 + num_tran_index);
7627 request = (
char *) malloc (request_size);
7628 if (request ==
NULL)
7634 ptr =
or_pack_int (request, (
int) is_dba_group_member);
7637 for (i = 0; i < num_tran_index; i++)
7642 ptr =
or_pack_int (ptr, (interrupt_only) ? 1 : 0);
7673 #if defined(CS_MODE) 7702 #if defined(CS_MODE) 7713 or_pack_int (request, ((include_query_exec_info) ? 1 : 0));
7740 exit_server (*thread_p);
7815 int num_trans, bufsize,
i;
7841 memset (info,
'\0', i);
7845 for (i = 0; i < num_trans; i++)
7847 int unpack_int_value;
7862 if (include_query_exec_info)
7878 if (((
int) (ptr - buffer)) != bufsize)
7913 #if defined(CS_MODE) 7928 exit_server (*thread_p);
7947 #if defined(CS_MODE) 7948 int req_error, status =
ER_FAILED, num_objs, num_pages;
7969 *nobjs = (int) num_objs;
7970 *npages = (int) num_pages;
7981 exit_server (*thread_p);
8000 #if defined(CS_MODE) 8054 exit_server (*thread_p);
8070 #if defined(CS_MODE) 8077 char *reply_data =
NULL;
8078 int reply_data_size = 0;
8100 if (reply_data !=
NULL)
8118 exit_server (*thread_p);
8136 #if defined(CS_MODE) 8137 int req_error, trid = 0;
8162 exit_server (*thread_p);
8180 #if defined(CS_MODE) 8251 exit_server (*thread_p);
8266 #if defined(CS_MODE) 8268 int request_size = 0, req_error =
NO_ERROR;
8269 char *request =
NULL, *reply =
NULL;
8275 request = (
char *) malloc (request_size);
8276 if (request ==
NULL)
8303 exit_server (*thread_p);
8318 #if defined(CS_MODE) 8320 int req_error =
NO_ERROR, request_size = 0, receive_size = 0;
8322 char *reply =
NULL, *request_data =
NULL, *receive_data =
NULL;
8331 request_data = (
char *) malloc (request_size);
8332 if (request_data ==
NULL)
8362 *prm_values_ptr = updated_prm_values;
8366 if (request_data !=
NULL)
8371 if (receive_data !=
NULL)
8380 exit_server (*thread_p);
8396 #if defined (CS_MODE) 8399 int area_size,
error;
8403 *change_values =
NULL;
8440 *change_values =
NULL;
8453 #if defined(CS_MODE) 8467 exit_server (*thread_p);
8485 #if defined(CS_MODE) 8514 exit_server (*thread_p);
8530 #if defined(CS_MODE) 8554 exit_server (*thread_p);
8571 #if defined(CS_MODE) 8605 exit_server (*thread_p);
8623 #if defined(CS_MODE) 8625 int request_size = 0, strlen1, strlen2, strlen3, strlen4;
8626 char *request =
NULL, *ptr;
8639 + length_const_string (repl_schema->
name, &strlen1)
8640 + length_const_string (repl_schema->
stmt_text, &strlen2)
8641 + length_const_string (repl_schema->
db_user, &strlen3)
8644 request = (
char *) malloc (request_size);
8645 if (request ==
NULL)
8653 ptr = pack_const_string_with_length (ptr, repl_schema->
name, strlen1);
8654 ptr = pack_const_string_with_length (ptr, repl_schema->
stmt_text, strlen2);
8655 ptr = pack_const_string_with_length (ptr, repl_schema->
db_user, strlen3);
8656 ptr = pack_const_string_with_length (ptr, repl_schema->
sys_prm_context, strlen4);
8678 exit_server (*thread_p);
8701 OID * pk_cls_oid,
BTID * pk_btid,
char *fk_name)
8703 #if defined(CS_MODE) 8718 request = (
char *) malloc (request_size);
8719 if (request ==
NULL)
8729 for (i = 0; i < n_attrs; i++)
8759 exit_server (*thread_p);
8776 #if defined(CS_MODE) 8779 char *request, *reply;
8780 char *replydata1, *replydata2;
8781 int replydata_size1, replydata_size2;
8790 assert (logwr_Gl.last_recv_pageid <= logwr_Gl.hdr.eof_lsa.pageid);
8791 if (logwr_Gl.last_recv_pageid == logwr_Gl.hdr.eof_lsa.pageid)
8794 first_pageid_torecv = logwr_Gl.last_recv_pageid;
8812 first_pageid_torecv = logwr_Gl.last_recv_pageid;
8816 first_pageid_torecv = logwr_Gl.last_recv_pageid + 1;
8820 if (first_pageid_torecv == logwr_Gl.ori_nxarv_pageid)
8822 mode = logwr_Gl.mode;
8833 save_mode = logwr_Gl.mode;
8834 logwr_Gl.mode =
mode;
8855 0,
NULL, 0, &replydata1, &replydata_size1, &replydata2, &replydata_size2);
8857 logwr_Gl.mode = save_mode;
8866 logwr_Gl.force_flush =
true;
8867 logwr_write_log_pages ();
8871 logwr_flush_header_page ();
8878 logwr_Gl.force_flush =
true;
8879 logwr_write_log_pages ();
8888 if (logwr_Gl.start_pageid >=
NULL_PAGEID && logwr_Gl.hdr.eof_lsa.pageid == logwr_Gl.hdr.append_lsa.pageid
8912 #if defined (CS_MODE) 8915 return perfmon_start_stats (for_all_trans);
8922 #if defined (CS_MODE) 8925 return perfmon_stop_stats ();
8934 #if defined (CS_MODE) 8937 err = perfmon_print_stats (stream);
8948 #if defined (CS_MODE) 8951 err = perfmon_print_global_stats (stream, cumulative, substr);
8960 #if defined (CS_MODE) 8963 perfmon_reset_stats ();
8990 int class_lock_timeout,
bool delete_old_repr,
OID * last_processed_class_oid,
8992 int *big_objects,
int *ids_repr)
8994 #if defined(CS_MODE) 8998 if (class_oids ==
NULL || num_classes < 0 || space_to_process < 0 || last_processed_class_oid ==
NULL 8999 || last_processed_oid ==
NULL || total_objects ==
NULL || failed_objects ==
NULL || modified_objects ==
NULL 9000 || big_objects ==
NULL || ids_repr ==
NULL)
9007 request = (
char *) malloc (request_size);
9008 if (request ==
NULL)
9015 reply = (
char *) malloc (reply_size);
9024 for (i = 0; i < num_classes; i++)
9033 ptr =
or_pack_oid (ptr, last_processed_class_oid);
9036 for (i = 0; i < num_classes; i++)
9041 for (i = 0; i < num_classes; i++)
9046 for (i = 0; i < num_classes; i++)
9051 for (i = 0; i < num_classes; i++)
9056 for (i = 0; i < num_classes; i++)
9068 for (i = 0; i < num_classes; i++)
9073 for (i = 0; i < num_classes; i++)
9078 for (i = 0; i < num_classes; i++)
9083 for (i = 0; i < num_classes; i++)
9088 for (i = 0; i < num_classes; i++)
9115 #if defined(CS_MODE) 9123 if (class_oid ==
NULL)
9158 #if defined(CS_MODE) 9187 #if defined(CS_MODE) 9216 #if defined(CS_MODE) 9218 int req_error, path_size;
9226 new_path, &path_size);
9251 #if defined(CS_MODE) 9253 int req_error, request_size,
strlen;
9254 char *request, *reply;
9261 request = (
char *) malloc (request_size);
9262 if (request ==
NULL)
9268 ptr = pack_const_string_with_length (request, path, strlen);
9298 #if defined(CS_MODE) 9300 int req_error, request_size,
strlen;
9301 char *request, *reply;
9308 request = (
char *) malloc (request_size);
9309 if (request ==
NULL)
9315 ptr = pack_const_string_with_length (request, path, strlen);
9320 NULL, 0, (
char *) buf, (
int) count);
9343 #if defined(CS_MODE) 9345 int req_error, request_size,
strlen;
9346 char *request, *reply;
9352 request_size = length_const_string (path, &strlen);
9353 request = (
char *) malloc (request_size);
9354 if (request ==
NULL)
9360 ptr = pack_const_string_with_length (request, path, strlen);
9388 #if defined(CS_MODE) 9390 int req_error, request_size, path_size, srclen, metalen;
9391 char *request, *reply;
9397 request_size = length_const_string (src_path, &srclen) + length_const_string (metaname, &metalen);
9398 request = (
char *) malloc (request_size);
9399 if (request ==
NULL)
9406 ptr = pack_const_string_with_length (request, src_path, srclen);
9407 ptr = pack_const_string_with_length (ptr, metaname, metalen);
9437 #if defined(CS_MODE) 9439 int req_error, request_size, path_size, srclen, metalen;
9440 char *request, *reply;
9446 request_size = length_const_string (src_path, &srclen) + length_const_string (metaname, &metalen);
9447 request = (
char *) malloc (request_size);
9448 if (request ==
NULL)
9454 ptr = pack_const_string_with_length (request, src_path, srclen);
9455 ptr = pack_const_string_with_length (ptr, metaname, metalen);
9483 #if defined(CS_MODE) 9485 off_t file_size = -1;
9486 int req_error, request_size,
strlen;
9487 char *request, *reply;
9493 request_size = length_const_string (path, &strlen);
9494 request = (
char *) malloc (request_size);
9495 if (request ==
NULL)
9501 ptr = pack_const_string_with_length (request, path, strlen);
9508 file_size = (off_t) tmp_int64;
9527 #if defined(CS_MODE) 9552 exit_server (*thread_p);
9568 #if defined(CS_MODE) 9583 exit_server (*thread_p);
9595 #if defined(CS_MODE) 9616 exit_server (*thread_p);
9634 #if defined(CS_MODE) 9637 char *request, *reply, *ptr;
9643 if (class_oid ==
NULL ||
OID_ISNULL (class_oid) || attribute_id < 0)
9668 exit_server (*thread_p);
9680 int *server_coll_cnt,
int *server_locales_cnt)
9682 #if defined(CS_MODE) 9686 char *reply_data =
NULL;
9688 int reply_size = 0, temp_int,
i, dummy;
9697 *server_collations =
NULL;
9698 *server_locales =
NULL;
9699 *server_coll_cnt = 0;
9700 *server_locales_cnt = 0;
9728 if (*server_collations ==
NULL)
9737 if (*server_locales ==
NULL)
9744 for (i = 0; i < *server_coll_cnt; i++)
9762 for (i = 0; i < *server_locales_cnt; i++)
9778 if (reply_data !=
NULL)
9785 if (reply_data !=
NULL)
9806 #if defined(CS_MODE) 9809 char *request, *reply, *ptr;
9845 #if defined(CS_MODE) 9849 char *reply_data =
NULL;
9851 int reply_size = 0, dummy;
9878 if (reply_data !=
NULL)
9885 if (reply_data !=
NULL)
9899 #if defined(CS_MODE) 9901 int request_size = 0, strlen1, strlen2, strlen3, strlen4;
9902 char *request =
NULL, *ptr;
9916 + length_const_string (repl_stmt->
name, &strlen1)
9917 + length_const_string (repl_stmt->
stmt_text, &strlen2)
9918 + length_const_string (repl_stmt->
db_user, &strlen3)
9921 request = (
char *) malloc (request_size);
9922 if (request ==
NULL)
9931 ptr = pack_const_string_with_length (ptr, repl_stmt->
name, strlen1);
9932 ptr = pack_const_string_with_length (ptr, repl_stmt->
stmt_text, strlen2);
9933 ptr = pack_const_string_with_length (ptr, repl_stmt->
db_user, strlen3);
9934 ptr = pack_const_string_with_length (ptr, repl_stmt->
sys_prm_context, strlen4);
9958 exit_server (*thread_p);
9974 #if defined(CS_MODE) 9977 int req_error, request_size,
strlen;
9986 request_size = length_const_string (user_name, &strlen);
9987 request = (
char *) malloc (request_size);
9988 if (request ==
NULL)
9994 (void) pack_const_string_with_length (request, user_name, strlen);
10001 if ((
bool) xexisted)
10037 #if defined(CS_MODE) 10039 char *request, *reply, *ptr;
10040 int request_size = 0;
10046 if (oid_list ==
NULL || no_oids < 1)
10053 request = (
char *) malloc (request_size);
10054 if (request ==
NULL)
10064 for (i = 0; i < no_oids; i++)
10088 exit_server (*thread_p);
10105 #if defined (CS_MODE) 10111 char *data_reply =
NULL;
10112 int data_reply_size = 0;
10136 if (data_reply ==
NULL)
10147 assert ((ptr - data_reply) == data_reply_size);
10156 error_code =
disk_spacedb (thread_p, spaceall, spacevols);
10161 else if (spacefiles !=
NULL)
10169 exit_server (*thread_p);
10178 #if defined(CS_MODE) 10206 if (class_mop !=
NULL)
10221 #if defined(CS_MODE) 10247 #if defined(CS_MODE) 10251 int class_ignored = 0;
10269 class_name = std::string (area, area_size);
10272 class_is_ignored = class_ignored != 0;
10284 #if defined(CS_MODE) 10285 char *data_reply =
NULL;
10286 int data_reply_size = 0;
10293 if (use_temp_batch)
10319 int is_batch_accepted_;
10321 is_batch_accepted = is_batch_accepted_ != 0;
10324 status.
unpack (unpacker);
10337 #if defined(CS_MODE) 10338 char *data_reply =
NULL;
10339 int data_reply_size = 0;
10344 0, &data_reply, &data_reply_size);
10352 if (data_reply_size <= 0)
10358 status.
unpack (unpacker);
10371 #if defined(CS_MODE) 10392 #if defined(CS_MODE) 10402 #if defined(CS_MODE) TRAN_STATE xtran_server_2pc_prepare_global_tran(THREAD_ENTRY *thread_p, int gtrid)
char * locator_pack_oid_set(char *buffer, LC_OIDSET *oidset)
LC_FIND_CLASSNAME xlocator_delete_class_name(THREAD_ENTRY *thread_p, const char *classname)
void set_buffer_and_pack_all(ExtBlk &eb, Args &&...args)
bool xlocator_notify_isolation_incons(THREAD_ENTRY *thread_p, LC_COPYAREA **synch_area)
int locator_does_exist(OID *oidp, int chn, LOCK lock, OID *class_oid, int class_chn, int need_fetching, int prefetch, LC_COPYAREA **fetch_copyarea, LC_FETCH_VERSION_TYPE fetch_version_type)
int xsession_delete_prepared_statement(THREAD_ENTRY *thread_p, const char *name)
int btree_load_index(BTID *btid, const char *bt_name, TP_DOMAIN *key_type, OID *class_oids, int n_classes, int n_attrs, int *attr_ids, int *attrs_prefix_length, HFID *hfids, int unique_pk, int not_null_flag, OID *fk_refcls_oid, BTID *fk_refcls_pk_btid, const char *fk_name, char *pred_stream, int pred_stream_size, char *expr_stream, int expr_stream_size, int func_col_id, int func_attr_index_start, SM_INDEX_STATUS index_status)
int perfmon_server_start_stats(void)
char * or_unpack_oid(char *ptr, OID *oid)
#define OR_BTID_ALIGNED_SIZE
DKNPAGES disk_get_total_numpages(VOLID volid)
int btree_add_index(BTID *btid, TP_DOMAIN *key_type, OID *class_oid, int attr_id, int unique_pk)
char * or_pack_btid(char *buf, const BTID *btid)
int xheap_get_class_num_objects_pages(THREAD_ENTRY *thread_p, const HFID *hfid, int approximation, int *nobjs, int *npages)
cubthread::entry * thread_get_thread_entry_info(void)
int repl_set_info(REPL_INFO *repl_info)
off_t es_posix_get_file_size(const char *path)
int thread_kill_or_interrupt_tran(int *tran_index_list, int num_tran_index, bool is_dba_group_member, bool interrupt_only, int *num_killed)
int heap_get_class_num_objects_pages(HFID *hfid, int approximation, int *nobjs, int *npages)
int xsession_get_prepared_statement(THREAD_ENTRY *thread_p, const char *name, char **info, int *info_len, XASL_ID *xasl_id, xasl_node_header *xasl_header_p)
int net_client_request_2recv_copyarea(int request, char *argbuf, int argsize, char *replybuf, int replysize, char *databuf, int datasize, char *recvbuffer, int recvbuffer_size, LC_COPYAREA **reply_copy_area, int *eid)
int perfmon_server_copy_global_stats(UINT64 *to_stats)
int xlogtb_get_mvcc_snapshot(THREAD_ENTRY *thread_p)
int serial_get_next_value(DB_VALUE *value, OID *oid_p, int cached_num, int num_alloc, int is_auto_increment)
int xheap_has_instance(THREAD_ENTRY *thread_p, const HFID *hfid, OID *class_oid, int has_visible_instance)
char lang_name[LANG_MAX_LANGNAME]
int file_spacedb(THREAD_ENTRY *thread_p, SPACEDB_FILES *spacedb)
LC_FIND_CLASSNAME locator_find_lockhint_class_oids(int num_classes, const char **many_classnames, LOCK *many_locks, int *many_need_subclasses, LC_PREFETCH_FLAGS *many_flags, OID *guessed_class_oids, int *guessed_class_chns, int quit_on_errors, LOCK lock_rr_tran, LC_LOCKHINT **lockhint, LC_COPYAREA **fetch_copyarea)
#define BO_IS_SERVER_RESTARTED()
XASL_NODE_HEADER * xasl_header
SYSPRM_ERR sysprm_obtain_server_parameters(SYSPRM_ASSIGN_VALUE **prm_values_ptr)
int btree_class_test_unique(char *buf, int buf_size)
char * or_unpack_string(char *ptr, char **string)
int xboot_check_db_consistency(THREAD_ENTRY *thread_p, int check_flag, OID *oids, int num_oids, BTID *index_btid)
struct trans_info TRANS_INFO
MOP ws_mop(const OID *oid, MOP class_mop)
int sysprm_packed_assign_values_length(const SYSPRM_ASSIGN_VALUE *assign_values, int offset)
int es_posix_create_file(char *new_path)
int xlocator_fetch_lockhint_classes(THREAD_ENTRY *thread_p, LC_LOCKHINT *lockhint, LC_COPYAREA **fetch_area)
int locator_notify_isolation_incons(LC_COPYAREA **synch_copyarea)
int locator_get_packed_oid_set_size(LC_OIDSET *oidset)
void xsysprm_obtain_server_parameters(SYSPRM_ASSIGN_VALUE *prm_values)
int es_posix_delete_file(const char *path)
int boot_copy(const char *from_dbname, const char *new_db_name, const char *new_db_path, const char *new_log_path, const char *new_lob_path, const char *new_db_server_host, const char *new_volext_path, const char *fileof_vols_and_copypaths, bool new_db_overwrite)
void LSA_COPY(log_lsa *plsa1, const log_lsa *plsa2)
int stats_update_all_statistics(int with_fullscan)
#define SHA1_HASH_INITIALIZER
void locator_free_copy_area(LC_COPYAREA *copyarea)
int tde_change_mk_on_server(int mk_index)
int locator_assign_oid_batch(LC_OIDSET *oidset)
int qmgr_end_query(QUERY_ID query_id)
int boot_notify_ha_log_applier_state(HA_LOG_APPLIER_STATE state)
char * or_unpack_unbound_listid(char *ptr, void **listid_ptr)
int locator_fetch_lockset(LC_LOCKSET *lockset, LC_COPYAREA **fetch_copyarea)
int btree_get_stats(THREAD_ENTRY *thread_p, BTREE_STATS *stat_info_p, bool with_fullscan)
LC_LOCKHINT * locator_allocate_and_unpack_lockhint(char *unpacked, int unpacked_size, bool unpack_classes, bool reg_unpacked)
int xsession_get_row_count(THREAD_ENTRY *thread_p, int *row_count)
int xfile_apply_tde_to_class_files(THREAD_ENTRY *thread_p, const OID *class_oid)
TRAN_STATE xtran_server_partial_abort(THREAD_ENTRY *thread_p, const char *savept_name, LOG_LSA *savept_lsa)
int locator_redistribute_partition_data(OID *class_oid, int no_oids, OID *oid_list)
int log_does_active_user_exist(const char *user_name, bool *existed)
int csession_reset_cur_insert_id(void)
int net_client_request2(int request, char *argbuf, int argsize, char *replybuf, int replysize, char *databuf, int datasize, char **replydata_ptr, int *replydatasize_ptr)
bool boot_shutdown_server(ER_FINAL_CODE iserfinal)
int boot_soft_rename(const char *old_db_name, const char *new_db_name, const char *new_db_path, const char *new_log_path, const char *new_db_server_host, const char *new_volext_path, const char *fileof_vols_and_renamepaths, bool new_db_overwrite, bool extern_rename, bool force_delete)
char * xdisk_get_remarks(THREAD_ENTRY *thread_p, VOLID volid)
char * or_unpack_string_alloc(char *ptr, char **string)
const char * tran_get_tranlist_state_name(TRAN_STATE state)
int csession_set_row_count(int rows)
void sysprm_dump_server_parameters(FILE *outfp)
char * locator_unpack_copy_area_descriptor(int num_objs, LC_COPYAREA *copyarea, char *desc)
char * or_pack_db_value(char *buffer, DB_VALUE *var)
int thread_kill_tran_index(int kill_tran_index, char *kill_user, char *kill_host, int kill_pid)
int xboot_register_client(THREAD_ENTRY *thread_p, BOOT_CLIENT_CREDENTIAL *client_credential, int client_lock_wait, TRAN_ISOLATION client_isolation, TRAN_STATE *tran_state, BOOT_SERVER_CREDENTIAL *server_credential)
LOG_LSA * xrepl_log_get_append_lsa(void)
int locator_repl_force(LC_COPYAREA *copy_area, LC_COPYAREA **reply_copy_area)
int tran_server_savepoint(const char *savept_name, LOG_LSA *savept_lsa)
int db_value_clone(DB_VALUE *src, DB_VALUE *dest)
int xserial_get_current_value(THREAD_ENTRY *thread_p, DB_VALUE *result_num, const OID *oid_p, int cached_num)
int tran_lock_rep_read(LOCK lock_rr_tran)
char * or_pack_string(char *ptr, const char *string)
#define OR_UNPACK_XASL_NODE_HEADER(PTR, X)
void xlogtb_dump_trantable(THREAD_ENTRY *thread_p, FILE *out_fp)
const LOG_PAGEID LOGPB_HEADER_PAGE_ID
int xcatalog_check_rep_dir(THREAD_ENTRY *thread_p, OID *class_id, OID *rep_dir_p)
char * or_pack_value(char *buf, DB_VALUE *value)
int net_client_request_no_reply(int request, char *argbuf, int argsize)
#define ASSERT_ERROR_AND_SET(error_code)
int xlocator_force(THREAD_ENTRY *thread_p, LC_COPYAREA *copy_area, int num_ignore_error_list, int *ignore_error_list)
BTID * xbtree_add_index(THREAD_ENTRY *thread_p, BTID *btid, TP_DOMAIN *key_type, OID *class_oid, int attr_id, int unique_pk, int num_oids, int num_nulls, int num_keys)
void qmgr_dump_query_plans(FILE *outfp)
#define assert_release(e)
TRAN_STATE tran_server_2pc_prepare_global_tran(int gtrid)
int xtran_server_start_topop(THREAD_ENTRY *thread_p, LOG_LSA *topop_lsa)
int xrepl_set_info(THREAD_ENTRY *thread_p, REPL_INFO *repl_info)
void logtb_dump_trantable(FILE *outfp)
VOLID boot_find_last_permanent(void)
unsigned int db_on_server
int qmgr_drop_all_query_plans(void)
TRANS_INFO * logtb_get_trans_info(bool include_query_exec_info)
int sysprm_get_force_server_parameters(SYSPRM_ASSIGN_VALUE **change_values)
int tran_server_2pc_recovery_prepared(int gtrids[], int size)
char * or_unpack_spacedb(char *ptr, SPACEDB_ALL *all, SPACEDB_ONEVOL **vols, SPACEDB_FILES *files)
VOLID xboot_find_last_permanent(THREAD_ENTRY *thread_p)
#define OR_ALIGNED_BUF(size)
int locator_get_reserved_class_name_oid(const char *classname, OID *class_oid)
int locator_fetch_lockhint_classes(LC_LOCKHINT *lockhint, LC_COPYAREA **fetch_copyarea)
BTREE_SEARCH xbtree_find_multi_uniques(THREAD_ENTRY *thread_p, OID *class_oid, int pruning_type, BTID *btids, DB_VALUE *values, int count, SCAN_OPERATION_TYPE op_type, OID **oids, int *oids_count)
OID * ws_identifier(MOP mop)
TRAN_STATE xtran_server_commit(THREAD_ENTRY *thrd, bool retain_lock)
#define OID_SET_NULL(oidp)
int csession_get_row_count(int *rows)
int xbtree_delete_index(THREAD_ENTRY *thread_p, BTID *btid)
int xqmgr_end_query(THREAD_ENTRY *thrd, QUERY_ID query_id)
int xlocator_fetch_all(THREAD_ENTRY *thread_p, const HFID *hfid, LOCK *lock, LC_FETCH_VERSION_TYPE fetch_type, OID *class_oid, int *nobjects, int *nfetched, OID *last_oid, LC_COPYAREA **fetch_area)
int logwr_get_log_pages(LOGWR_CONTEXT *ctx_ptr)
char * sysprm_pack_assign_values(char *ptr, const SYSPRM_ASSIGN_VALUE *assign_values)
int tde_get_mk_file_path(char *mk_path)
bool is_xasl_pinned_reference
int locator_fetch(OID *oidp, int chn, LOCK lock, LC_FETCH_VERSION_TYPE fetch_version_type, OID *class_oid, int class_chn, int prefetch, LC_COPYAREA **fetch_copyarea)
void log_set_interrupt(int set)
int xtran_server_2pc_attach_global_tran(THREAD_ENTRY *thread_p, int gtrid)
int xtran_server_set_global_tran_info(THREAD_ENTRY *thread_p, int gtrid, void *info, int size)
int xboot_initialize_server(const BOOT_CLIENT_CREDENTIAL *client_credential, BOOT_DB_PATH_INFO *db_path_info, bool db_overwrite, const char *file_addmore_vols, volatile DKNPAGES db_npages, PGLENGTH db_desired_pagesize, volatile DKNPAGES xlog_npages, PGLENGTH db_desired_log_page_size, OID *rootclass_oid, HFID *rootclass_hfid, int client_lock_wait, TRAN_ISOLATION client_isolation)
char * or_unpack_string_nocopy(char *ptr, char **string)
enum lc_prefetch_flags LC_PREFETCH_FLAGS
int xlocator_redistribute_partition_data(THREAD_ENTRY *thread_p, OID *class_oid, int no_oids, OID *oid_list)
int SHA1Compute(const unsigned char *message_array, size_t length, SHA1Hash *hash)
int xqfile_get_list_file_page(THREAD_ENTRY *thread_p, QUERY_ID query_id, VOLID volid, PAGEID pageid, char *page_bufp, int *page_sizep)
int es_posix_rename_file(const char *src_path, const char *metaname, char *new_path)
int xboot_restart_from_backup(THREAD_ENTRY *thread_p, int print_restart, const char *db_name, BO_RESTART_ARG *r_args)
#define OR_ALIGNED_BUF_SIZE(abuf)
void er_restore_last_error(void)
char * or_pack_oid(char *ptr, const OID *oid)
int compact_db_start(void)
int tran_server_set_global_tran_info(int gtrid, void *info, int size)
void sysprm_free_assign_values(SYSPRM_ASSIGN_VALUE **assign_values_ptr)
TRAN_STATE xtran_server_abort(THREAD_ENTRY *thrd)
void xserial_decache(THREAD_ENTRY *thread_p, OID *oidp)
int or_packed_domain_size(struct tp_domain *domain, int include_classoids)
ssize_t es_posix_read_file(const char *path, void *buf, size_t count, off_t offset)
#define er_log_debug(...)
int xsession_create_new(THREAD_ENTRY *thread_p, SESSION_ID *id)
int net_client_request_recv_stream(int request, char *argbuf, int argsize, char *replybuf, int replybuf_size, char *databuf, int datasize, FILE *outfp)
void vacuum_dump(FILE *outfp)
char * or_unpack_log_lsa(char *ptr, struct log_lsa *lsa)
void xlogpb_dump_stat(FILE *outfp)
int locator_upgrade_instances_domain(OID *class_oid, int attribute_id)
int xboot_emergency_patch(const char *db_name, bool recreate_log, DKNPAGES log_npages, const char *db_locale, FILE *out_fp)
int ib_get_thread_count()
#define ER_ONLY_IN_STANDALONE
int net_client_request2_no_malloc(int request, char *argbuf, int argsize, char *replybuf, int replysize, char *databuf, int datasize, char *replydata, int *replydatasize_ptr)
char * or_unpack_errcode(char *ptr, int *error)
struct lang_locale_compat LANG_LOCALE_COMPAT
int tran_server_2pc_start(void)
#define COPY_OID(dest_oid_ptr, src_oid_ptr)
char * sysprm_pack_session_parameters(char *ptr, SESSION_PARAM *session_parameters)
int histo_print(FILE *stream)
int xboot_find_number_temp_volumes(THREAD_ENTRY *thread_p)
int boot_register_client(BOOT_CLIENT_CREDENTIAL *client_credential, int client_lock_wait, TRAN_ISOLATION client_isolation, TRAN_STATE *tran_state, BOOT_SERVER_CREDENTIAL *server_credential)
int heap_destroy_newly_created(const HFID *hfid, const OID *class_oid)
int xtde_get_mk_info(THREAD_ENTRY *thread_p, int *mk_index, time_t *created_time, time_t *set_time)
int xlogtb_reset_wait_msecs(THREAD_ENTRY *thread_p, int wait_msecs)
int btree_get_statistics(BTID *btid, BTREE_STATS *stat_info)
int xlogin_user(THREAD_ENTRY *thread_p, const char *username)
int tde_get_mk_info(int *mk_index, time_t *created_time, time_t *set_time)
bool include_query_exec_info
struct lang_coll_compat LANG_COLL_COMPAT
#define NET_SENDRECV_BUFFSIZE
int xlocator_assign_oid_batch(THREAD_ENTRY *thread_p, LC_OIDSET *oidset)
void xlogtb_set_interrupt(THREAD_ENTRY *thread_p, int set)
int or_packed_stream_length(size_t len)
int qp_get_server_info(PARSER_CONTEXT *parser, int server_info_bits)
#define OR_ALIGNED_BUF_START(abuf)
void net_histo_clear(void)
LC_FIND_CLASSNAME locator_find_class_oid(const char *class_name, OID *class_oid, LOCK lock)
int csession_get_variable(DB_VALUE *name, DB_VALUE *value)
int boot_heap_compact(OID *class_oid)
int locator_remove_class_from_index(OID *oid, BTID *btid, HFID *hfid)
BTREE_SEARCH xbtree_find_unique(THREAD_ENTRY *thread_p, BTID *btid, SCAN_OPERATION_TYPE scan_op_type, DB_VALUE *key, OID *class_oid, OID *oid, bool is_all_class_srch)
char * or_pack_int64(char *ptr, INT64 number)
int file_apply_tde_to_class_files(const OID *class_oid)
int es_posix_copy_file(const char *src_path, const char *metaname, char *new_path)
unsigned int DB_TIMESTAMP
int boot_check_db_consistency(int check_flag, OID *oids, int num_oids, BTID *index_btid)
const char * boot_db_full_name()
LC_FIND_CLASSNAME xlocator_reserve_class_names(THREAD_ENTRY *thread_p, const int num_classes, const char **classname, OID *class_oid)
void acl_dump(FILE *outfp)
int histo_print_global_stats(FILE *stream, bool cumulative, const char *substr)
void er_set(int severity, const char *file_name, const int line_no, int err_id, int num_args,...)
char * xdisk_get_fullname(THREAD_ENTRY *thread_p, VOLID volid, char *vol_fullname)
int xlocator_does_exist(THREAD_ENTRY *thread_p, OID *oid, int chn, LOCK lock, LC_FETCH_VERSION_TYPE fetch_version_type, OID *class_oid, int class_chn, int need_fetching, int prefetching, LC_COPYAREA **fetch_area)
int xboot_find_number_permanent_volumes(THREAD_ENTRY *thread_p)
char * or_pack_hfid(const char *ptr, const HFID *hfid)
int xbtree_class_test_unique(THREAD_ENTRY *thread_p, char *buf, int buf_size)
char * or_pack_stream(char *ptr, const char *stream, size_t len)
void locator_manyobj_flag_remove(LC_COPYAREA_MANYOBJS *copyarea, enum MULTI_UPDATE_FLAG muf)
int log_set_no_logging(void)
int xlocator_fetch(THREAD_ENTRY *thrd, OID *oid, int chn, LOCK lock, LC_FETCH_VERSION_TYPE fetch_version_type, LC_FETCH_VERSION_TYPE initial_fetch_version_type, OID *class_oid, int class_chn, int prefetching, LC_COPYAREA **fetch_area)
void net_cleanup_client_queues(void)
#define ER_QPROC_INVALID_PARAMETER
void tran_set_latest_query_status(int end_query_result, int tran_state, int should_conn_reset)
void xqmgr_dump_query_plans(THREAD_ENTRY *thread_p, FILE *outfp)
void db_clear_private_heap(THREAD_ENTRY *thread_p, HL_HEAPID heap_id)
int xheap_destroy_newly_created(THREAD_ENTRY *thread_p, const HFID *hfid, const OID *class_oid)
int heap_reclaim_addresses(const HFID *hfid)
int xchksum_insert_repl_log_and_demote_table_lock(THREAD_ENTRY *thread_p, REPL_INFO *repl_info, const OID *class_oidp)
int or_packed_string_length(const char *string, int *strlen)
int net_client_request_recv_copyarea(int request, char *argbuf, int argsize, char *replybuf, int replysize, LC_COPYAREA **reply_copy_area)
HL_HEAPID db_create_private_heap(void)
void log_dump_stat(FILE *outfp)
char * or_unpack_btid(char *buf, BTID *btid)
int xlocator_assign_oid(THREAD_ENTRY *thread_p, const HFID *hfid, OID *perm_oid, int expected_length, OID *class_oid, const char *classname)
char * perfmon_unpack_stats(char *buf, UINT64 *stats)
#define DB_CONNECTION_STATUS_RESET
int loaddb_install_class(const cubload::batch &batch, bool &class_is_ignored, std::string &class_name)
size_t get_current_size(void)
int net_histo_print(FILE *stream)
int qmgr_prepare_query(COMPILE_CONTEXT *context, xasl_stream *stream)
int xlocator_remove_class_from_index(THREAD_ENTRY *thread_p, OID *oid, BTID *btid, HFID *hfid)
int locator_demote_class_lock(const OID *class_oid, LOCK lock, LOCK *ex_lock)
LC_FIND_CLASSNAME xlocator_find_class_oid(THREAD_ENTRY *thread_p, const char *classname, OID *class_oid, LOCK lock)
#define TDE_DATA_KEY_LENGTH
#define ER_OUT_OF_VIRTUAL_MEMORY
int tran_server_has_updated(void)
HL_HEAPID private_heap_id
char * or_unpack_hfid(char *ptr, HFID *hfid)
#define OR_VALUE_ALIGNED_SIZE(value)
char * sysprm_unpack_assign_values(char *ptr, SYSPRM_ASSIGN_VALUE **assign_values_ptr)
int xsession_get_last_insert_id(THREAD_ENTRY *thread_p, DB_VALUE *value, bool update_last_insert_id)
char * or_unpack_lock(char *ptr, LOCK *lock)
int db_sys_date_and_epoch_time(DB_VALUE *dt_dbval, DB_VALUE *ts_dbval)
int sysprm_packed_session_parameters_length(SESSION_PARAM *session_parameters, int offset)
char * or_pack_sha1(char *ptr, const SHA1Hash *sha1)
#define IS_QUERY_EXECUTED_WITHOUT_DATA_BUFFERS(flag)
DB_VALUE local_transaction_id
char * wait_for_tran_index_string
void tde_make_keys_file_fullname(char *keys_vol_fullname, const char *db_full_name, bool ignore_parm)
#define DB_MAX_IDENTIFIER_LENGTH
LC_COPYAREA * locator_allocate_copy_area_by_length(int min_length)
TRAN_STATE tran_server_commit(bool retain_lock)
char * or_pack_string_with_null_padding(char *ptr, const char *stream, size_t len)
int xsession_create_prepared_statement(THREAD_ENTRY *thread_p, char *name, char *alias_print, SHA1Hash *sha1, char *info, int info_len)
LC_LOCKSET * locator_allocate_and_unpack_lockset(char *unpacked, int unpacked_size, bool unpack_classes, bool unpack_objects, bool reg_unpacked)
static enum scanner_mode mode
void xsysprm_change_server_parameters(const SYSPRM_ASSIGN_VALUE *assignments)
void xlogtb_set_suppress_repl_on_transaction(THREAD_ENTRY *thread_p, int set)
unsigned char perm_key[TDE_DATA_KEY_LENGTH]
char * disk_get_remarks(VOLID volid)
bool first_fetch_lockhint_call
TRAN_STATE xtran_server_end_topop(THREAD_ENTRY *thread_p, LOG_RESULT_TOPOP result, LOG_LSA *topop_lsa)
int xboot_backup(THREAD_ENTRY *thread_p, const char *backup_path, FILEIO_BACKUP_LEVEL backup_level, bool delete_unneeded_logarchives, const char *backup_verbose_file, int num_threads, FILEIO_ZIP_METHOD zip_method, FILEIO_ZIP_LEVEL zip_level, int skip_activelog, int sleep_msecs, bool separate_keys)
int net_histo_print_global_stats(FILE *stream, bool cumulative, const char *substr)
enum ha_log_applier_state HA_LOG_APPLIER_STATE
int perfmon_get_number_of_statistic_values(void)
void thread_dump_cs_stat(FILE *outfp)
DB_OBJECT * db_get_object(const DB_VALUE *value)
int substr(std::string &result, bool &is_matched, const cub_regex_object ®, const std::string &src, const int position, const int occurrence, const INTL_CODESET codeset)
#define LOGWR_COPY_FROM_FIRST_PHY_PAGE_MASK
int xheap_create(THREAD_ENTRY *thread_p, HFID *hfid, const OID *class_oid, bool reuse_oid)
struct one_tran_info ONE_TRAN_INFO
#define DB_MAX_PATH_LENGTH
int xlogtb_reset_isolation(THREAD_ENTRY *thread_p, TRAN_ISOLATION isolation)
int xsession_check_session(THREAD_ENTRY *thread_p, const SESSION_ID id)
int loaddb_update_stats()
char * disk_get_fullname(VOLID volid, char *vol_fullname)
static void cleanup(int signo)
int xtde_change_mk_without_flock(THREAD_ENTRY *thread_p, const int mk_index)
TRAN_STATE tran_server_2pc_prepare(void)
int db_sys_timestamp(DB_VALUE *result_timestamp)
int heap_create(HFID *hfid, const OID *class_oid, bool reuse_oid)
int csession_set_session_variables(DB_VALUE *variables, const int count)
int boot_unregister_client(int tran_index)
char * or_unpack_float(char *ptr, float *number)
bool locator_unpack_oid_set_to_exist(char *buffer, LC_OIDSET *use)
int net_client_request_3_data(int request, char *argbuf, int argsize, char *databuf1, int datasize1, char *databuf2, int datasize2, char *reply0, int replysize0, char *reply1, int replysize1, char *reply2, int replysize2)
LC_FIND_CLASSNAME xlocator_rename_class_name(THREAD_ENTRY *thread_p, const char *oldname, const char *newname, OID *class_oid)
int xqmgr_prepare_query(THREAD_ENTRY *thrd, compile_context *ctx, xasl_stream *stream)
int boot_backup(const char *backup_path, FILEIO_BACKUP_LEVEL backup_level, bool delete_unneeded_logarchives, const char *backup_verbose_file, int num_threads, FILEIO_ZIP_METHOD zip_method, FILEIO_ZIP_LEVEL zip_level, int skip_activelog, int sleep_msecs, bool separate_keys)
int csession_create_prepared_statement(const char *name, const char *alias_print, char *stmt_info, int info_length)
int xbtree_get_key_type(THREAD_ENTRY *thread_p, BTID btid, TP_DOMAIN **key_type)
DKNPAGES xdisk_get_total_numpages(THREAD_ENTRY *thread_p, VOLID volid)
void logtb_free_trans_info(TRANS_INFO *info)
#define db_private_free_and_init(thrd, ptr)
int xserial_get_next_value(THREAD_ENTRY *thread_p, DB_VALUE *result_num, const OID *oid_p, int cached_num, int num_alloc, int is_auto_increment, bool force_set_last_insert_id)
int csession_get_last_insert_id(DB_VALUE *value, bool update_last_insert_id)
int boot_find_number_permanent_volumes(void)
int xvacuum(THREAD_ENTRY *thread_p)
static int failed_objects
int locator_assign_oid(const HFID *hfid, OID *perm_oid, int expected_length, OID *class_oid, const char *class_name)
ssize_t es_posix_write_file(const char *path, const void *buf, size_t count, off_t offset)
int xsession_set_session_variables(THREAD_ENTRY *thread_p, DB_VALUE *values, const int count)
int tran_server_2pc_attach_global_tran(int gtrid)
void xvacuum_dump(THREAD_ENTRY *thread_p, FILE *outfp)
char * or_unpack_int(char *ptr, int *number)
#define db_private_free(thrd, ptr)
HA_SERVER_STATE ha_server_state
int stats_get_statistics_from_server(OID *classoid, unsigned int timestamp, int *length_ptr, char **stats_buffer)
void db_set_execution_plan(char *plan, int length)
int log_set_suppress_repl_on_transaction(int set)
#define db_private_alloc(thrd, size)
int csession_delete_prepared_statement(const char *name)
char * or_unpack_int64(char *ptr, INT64 *number)
void xperfmon_server_copy_stats(THREAD_ENTRY *thread_p, UINT64 *to_stats)
#define OR_PTR_ALIGNED_SIZE
LC_FIND_CLASSNAME locator_reserve_class_names(const int num_classes, const char **class_names, OID *class_oids)
#define OR_LOG_LSA_ALIGNED_SIZE
#define OR_PACK_CACHE_TIME(PTR, T)
LOCK tm_Tran_rep_read_lock
int btree_get_index_key_type(BTID btid, TP_DOMAIN **key_type_p)
int xtran_server_get_global_tran_info(THREAD_ENTRY *thread_p, int gtrid, void *buffer, int size)
void xlock_dump(THREAD_ENTRY *thread_p, FILE *outfp)
int count(int &result, const cub_regex_object ®, const std::string &src, const int position, const INTL_CODESET codeset)
int perfmon_server_stop_stats(void)
int stats_update_statistics(OID *classoid, int with_fullscan)
int xtran_server_is_active_and_has_updated(THREAD_ENTRY *thread_p)
LC_FIND_CLASSNAME xlocator_find_lockhint_class_oids(THREAD_ENTRY *thread_p, int num_classes, const char **many_classnames, LOCK *many_locks, int *many_need_subclasses, LC_PREFETCH_FLAGS *many_flags, OID *guessed_class_oids, int *guessed_class_chns, bool quit_on_errors, LC_LOCKHINT **hlock, LC_COPYAREA **fetch_area)
int xsession_drop_session_variables(THREAD_ENTRY *thread_p, DB_VALUE *values, const int count)
void sysprm_free_session_parameters(SESSION_PARAM **session_parameters_ptr)
bool histo_is_supported(void)
int xsession_reset_cur_insert_id(THREAD_ENTRY *thread_p)
HA_SERVER_STATE boot_change_ha_mode(HA_SERVER_STATE state, bool force, int timeout)
TRAN_STATE tran_server_abort(void)
int locator_get_class(OID *class_oid, int class_chn, const OID *oid, LOCK lock, int prefetching, LC_COPYAREA **fetch_copyarea)
int csession_drop_session_variables(DB_VALUE *variables, const int count)
int xsession_end_session(THREAD_ENTRY *thread, const SESSION_ID id)
#define OR_UNPACK_XASL_ID(PTR, X)
static void error(const char *msg)
void ws_set_lock(MOP mop, LOCK lock)
int xsession_set_row_count(THREAD_ENTRY *thread_p, int row_count)
char * or_pack_int(char *ptr, int number)
int xsession_get_session_variable_no_copy(THREAD_ENTRY *thread_p, const DB_VALUE *name, DB_VALUE **value)
int perfmon_server_copy_stats(UINT64 *to_stats)
int xtran_server_savepoint(THREAD_ENTRY *thread_p, const char *savept_name, LOG_LSA *savept_lsa)
int locator_check_fk_validity(OID *cls_oid, HFID *hfid, TP_DOMAIN *key_type, int n_attrs, int *attr_ids, OID *pk_cls_oid, BTID *pk_btid, char *fk_name)
int histo_start(bool for_all_trans)
#define IS_TRAN_AUTO_COMMIT(flag)
bool locator_manyobj_flag_is_set(LC_COPYAREA_MANYOBJS *copyarea, enum MULTI_UPDATE_FLAG muf)
int tran_server_get_global_tran_info(int gtrid, void *buffer, int size)
int xstats_update_all_statistics(THREAD_ENTRY *thread_p, bool with_fullscan)
#define ER_NOT_IN_STANDALONE
#define NET_DEFER_END_QUERIES_MAX
int net_client_request_3recv_copyarea(int request, char *argbuf, int argsize, char *replybuf, int replysize, char *databuf, int datasize, char **recvbuffer, int *recvbuffer_size, LC_COPYAREA **reply_copy_area)
int xheap_destroy(THREAD_ENTRY *thread_p, const HFID *hfid, const OID *class_oid)
int compact_db_stop(void)
int pr_clone_value(const DB_VALUE *src, DB_VALUE *dest)
SYSPRM_ERR sysprm_change_server_parameters(const SYSPRM_ASSIGN_VALUE *assignments)
BTREE_SEARCH btree_find_multi_uniques(OID *class_oid, int pruning_type, BTID *btids, DB_VALUE *keys, int count, SCAN_OPERATION_TYPE op_type, OID **oids, int *oids_count)
unsigned char temp_key[TDE_DATA_KEY_LENGTH]
int locator_pack_lockhint(LC_LOCKHINT *lockhint, bool pack_classes)
int xboot_soft_rename(THREAD_ENTRY *thread_p, const char *old_db_name, const char *new_db_name, const char *new_db_path, const char *new_log_path, const char *new_db_server_host, const char *new_volext_path, const char *fileof_vols_and_renamepaths, bool new_db_overwrite, bool extern_rename, bool force_delete)
BTID * xbtree_load_online_index(THREAD_ENTRY *thread_p, BTID *btid, const char *bt_name, TP_DOMAIN *key_type, OID *class_oids, int n_classes, int n_attrs, int *attr_ids, int *attrs_prefix_length, HFID *hfids, int unique_pk, int not_null_flag, OID *fk_refcls_oid, BTID *fk_refcls_pk_btid, const char *fk_name, char *pred_stream, int pred_stream_size, char *expr_stream, int expr_steram_size, int func_col_id, int func_attr_index_start, int ib_thread_count)
#define OR_CACHE_TIME_SIZE
int clogin_user(const char *username)
int net_client_request(int request, char *argbuf, int argsize, char *replybuf, int replysize, char *databuf, int datasize, char *replydata, int replydatasize)
#define free_and_init(ptr)
#define OR_UNPACK_CACHE_TIME(PTR, T)
#define DB_ALIGN(offset, align)
#define BTID_COPY(btid_ptr1, btid_ptr2)
char * or_pack_lock(char *ptr, LOCK lock)
char * or_unpack_ptr(char *ptr, UINTPTR *ptrval)
int xstats_update_statistics(THREAD_ENTRY *thread_p, OID *classoid, bool with_fullscan)
bool xboot_shutdown_server(REFPTR(THREAD_ENTRY, thread_p), ER_FINAL_CODE is_er_final)
QFILE_LIST_ID * qmgr_prepare_and_execute_query(char *xasl_stream, int xasl_stream_size, QUERY_ID *query_idp, int dbval_cnt, DB_VALUE *dbval_ptr, QUERY_FLAG flag, int query_timeout)
int xlogtb_get_pack_tran_table(THREAD_ENTRY *thread_p, char **buffer_p, int *size_p, int include_query_exec_info)
bool recompile_xasl_pinned
int net_client_request_with_logwr_context(LOGWR_CONTEXT *ctx_ptr, int request, char *argbuf, int argsize, char *replybuf, int replysize, char *databuf1, int datasize1, char *databuf2, int datasize2, char **replydata_ptr1, int *replydatasize_ptr1, char **replydata_ptr2, int *replydatasize_ptr2)
char * or_pack_string_with_length(char *ptr, const char *string, int length)
#define STATS_WITH_FULLSCAN
int csession_find_or_create_session(SESSION_ID *session_id, int *row_count, char *server_session_key, const char *db_user, const char *host, const char *program_name)
void xsysprm_dump_server_parameters(FILE *outfp)
#define ER_OBJ_INVALID_ARGUMENTS
#define ER_HA_LW_FAILED_GET_LOG_PAGE
char * or_pack_domain(char *ptr, struct tp_domain *domain, int include_classoids, int is_null)
bool xtran_server_has_updated(THREAD_ENTRY *thread_p)
int db_get_row_count_cache(void)
int disk_spacedb(THREAD_ENTRY *thread_p, SPACEDB_ALL *spaceall, SPACEDB_ONEVOL **spacevols)
int log_get_mvcc_snapshot(void)
enum intl_codeset INTL_CODESET
DKNPAGES xdisk_get_free_numpages(THREAD_ENTRY *thread_p, VOLID volid)
void lock_dump(FILE *outfp)
char * xstats_get_statistics_from_server(THREAD_ENTRY *thread_p, OID *class_id, unsigned int timestamp, int *length)
VOLID boot_add_volume_extension(DBDEF_VOL_EXT_INFO *ext_info)
bool prm_get_bool_value(PARAM_ID prm_id)
int boot_get_server_timezone_checksum(char *timezone_checksum)
#define LC_MANYOBJS_PTR_IN_COPYAREA(copy_areaptr)
int catalog_check_rep_dir(OID *class_id, OID *rep_dir_p)
BTREE_SEARCH btree_find_unique(BTID *btid, DB_VALUE *key, OID *class_oid, OID *oid)
int locator_force(LC_COPYAREA *copy_area, int num_ignore_error_list, int *ignore_error_list, int content_size)
int loaddb_load_batch(const cubload::batch &batch, bool use_temp_batch, bool &is_batch_accepted, load_status &status)
int jsp_server_port(void)
char * or_unpack_value(const char *buf, DB_VALUE *value)
LC_FIND_CLASSNAME locator_delete_class_name(const char *class_name)
DKNPAGES disk_get_free_numpages(VOLID volid)
int xlocator_fetch_lockset(THREAD_ENTRY *thread_p, LC_LOCKSET *lockset, LC_COPYAREA **fetch_area)
LC_FIND_CLASSNAME locator_rename_class_name(const char *old_name, const char *new_name, OID *class_oid)
char * or_pack_ptr(char *ptr, UINTPTR ptrval)
enum logwr_mode LOGWR_MODE
int serial_decache(OID *oid)
int locator_fetch_all(const HFID *hfid, LOCK *lock, LC_FETCH_VERSION_TYPE fetch_version_type, OID *class_oidp, int *nobjects, int *nfetched, OID *last_oidp, LC_COPYAREA **fetch_copyarea)
int logtb_get_pack_tran_table(char **buffer_p, int *size_p, bool include_query_exec_info)
#define DB_VALUE_TYPE(value)
int locator_fetch_all_reference_lockset(OID *oid, int chn, OID *class_oid, int class_chn, LOCK lock, int quit_on_errors, int prune_level, LC_LOCKSET **lockset, LC_COPYAREA **fetch_copyarea)
int heap_has_instance(HFID *hfid, OID *class_oid, int has_visible_instance)
QFILE_LIST_ID * xqmgr_execute_query(THREAD_ENTRY *thrd, const XASL_ID *xasl_id, QUERY_ID *query_idp, int dbval_cnt, void *data, QUERY_FLAG *flagp, CACHE_TIME *clt_cache_time, CACHE_TIME *srv_cache_time, int query_timeout, xasl_cache_ent **ret_cache_entry_p)
int db_make_null(DB_VALUE *value)
enum lob_locator_state LOB_LOCATOR_STATE
#define NET_COPY_AREA_SENDRECV_SIZE
TDE_DATA_KEY_SET data_keys
#define ER_NET_SERVER_CRASHED
bool xtran_is_blocked(THREAD_ENTRY *thread_p, int tran_index)
int serial_get_current_value(DB_VALUE *value, OID *oid_p, int cached_num)
int locator_unpack_lockset(LC_LOCKSET *lockset, bool unpack_classes, bool unpack_objects)
#define SERVER_SESSION_KEY_SIZE
int net_client_recv_copyarea(int request, char *replybuf, int replysize, char *recvbuffer, int recvbuffer_size, LC_COPYAREA **reply_copy_area, int rc)
int boot_find_last_temp(void)
char * strdup(const char *str)
int xboot_delete(const char *db_name, bool force_delete, BOOT_SERVER_SHUTDOWN_MODE shutdown_common_modules)
int boot_emergency_patch(const char *db_name, bool recreate_log, DKNPAGES log_npages, const char *db_locale, FILE *out_fp)
int repl_log_get_append_lsa(LOG_LSA *lsa)
int chksum_insert_repl_log_and_demote_table_lock(REPL_INFO *repl_info, const OID *class_oidp)
int boot_find_number_temp_volumes(void)
void xperfmon_server_copy_global_stats(UINT64 *to_stats)
#define BTID_IS_NULL(btid)
BTID * xbtree_load_index(THREAD_ENTRY *thread_p, BTID *btid, const char *bt_name, TP_DOMAIN *key_type, OID *class_oids, int n_classes, int n_attrs, int *attr_ids, int *attrs_prefix_length, HFID *hfids, int unique_pk, int not_null_flag, OID *fk_refcls_oid, BTID *fk_refcls_pk_btid, const char *fk_name, char *pred_stream, int pred_stream_size, char *expr_stream, int expr_steram_size, int func_col_id, int func_attr_index_start)
int db_value_clear(DB_VALUE *value)
int db_make_timestamp(DB_VALUE *value, const DB_C_TIMESTAMP timeval)
int db_make_int(DB_VALUE *value, const int num)
char * sysprm_unpack_session_parameters(char *ptr, SESSION_PARAM **session_parameters_ptr)
unsigned char log_key[TDE_DATA_KEY_LENGTH]
int csession_end_session(SESSION_ID session_id)
void xqmgr_dump_query_cache(THREAD_ENTRY *thread_p, FILE *outfp)
int db_make_oid(DB_VALUE *value, const OID *oid)
char * or_unpack_stream(char *ptr, char *stream, size_t len)
VOLID xboot_add_volume_extension(THREAD_ENTRY *thread_p, DBDEF_VOL_EXT_INFO *ext_info)
#define STATS_WITH_SAMPLING
enum ha_server_state HA_SERVER_STATE
#define INIT_XASL_NODE_HEADER(X)
void er_stack_push_if_exists(void)
TRAN_STATE tran_server_partial_abort(const char *savept_name, LOG_LSA *savept_lsa)
int log_reset_isolation(TRAN_ISOLATION isolation)
bool log_does_allow_replication(void)
QFILE_LIST_ID * xqmgr_prepare_and_execute_query(THREAD_ENTRY *thrd, char *xasl_stream, int xasl_stream_size, QUERY_ID *query_id, int dbval_cnt, void *data, QUERY_FLAG *flag, int query_timeout)
TRAN_STATE xtran_server_2pc_prepare(THREAD_ENTRY *thread_p)
int net_client_request_with_callback(int request, char *argbuf, int argsize, char *replybuf, int replysize, char *databuf1, int datasize1, char *databuf2, int datasize2, char **replydata_listid, int *replydatasize_listid, char **replydata_page, int *replydatasize_page, char **replydata_plan, int *replydatasize_plan)
const char * program_name
int loaddb_init(cubload::load_args &args)
int tran_wait_server_active_trans(void)
void qmgr_dump_query_cache(FILE *outfp)
char * or_unpack_domain(char *ptr, struct tp_domain **domain_ptr, int *is_null)
int xlocator_check_fk_validity(THREAD_ENTRY *thread_p, OID *cls_oid, HFID *hfid, TP_DOMAIN *key_type, int n_attrs, int *attr_ids, OID *pk_cls_oid, BTID *pk_btid, char *fk_name)
int boot_compact_classes(OID **class_oids, int num_classes, int space_to_process, int instance_lock_timeout, int class_lock_timeout, bool delete_old_repr, OID *last_processed_class_oid, OID *last_processed_oid, int *total_objects, int *failed_objects, int *modified_objects, int *big_objects, int *ids_repr)
int csession_get_prepared_statement(const char *name, XASL_ID *xasl_id, char **stmt_info, xasl_node_header *xasl_header_p)
int xlocator_get_reserved_class_name_oid(THREAD_ENTRY *thread_p, const char *classname, OID *class_oid)
void unpack(cubpacking::unpacker &deserializator) override
int xtran_server_2pc_start(THREAD_ENTRY *thread_p)
int netcl_spacedb(SPACEDB_ALL *spaceall, SPACEDB_ONEVOL **spacevols, SPACEDB_FILES *spacefiles)
int xheap_reclaim_addresses(THREAD_ENTRY *thread_p, const HFID *hfid)
bool first_fetch_lockset_call
int net_client_request_3_data_recv_copyarea(int request, char *argbuf, int argsize, char *databuf1, int datasize1, char *databuf2, int datasize2, char *replybuf, int replysize, LC_COPYAREA **reply_copy_area)
int net_histo_start(bool for_all_trans)
int btree_delete_index(BTID *btid)
int xboot_copy(REFPTR(THREAD_ENTRY, thread_p), const char *from_dbname, const char *new_db_name, const char *new_db_path, const char *new_log_path, const char *new_lob_path, const char *new_db_server_host, const char *new_volext_path, const char *fileof_vols_and_copypaths, bool new_db_overwrite)
#define EXECUTE_QUERY_MAX_ARGUMENT_DATA_SIZE
int xboot_unregister_client(REFPTR(THREAD_ENTRY, thread_p), int tran_index)
int xlocator_fetch_all_reference_lockset(THREAD_ENTRY *thread_p, OID *oid, int chn, OID *class_oid, int class_chn, LOCK lock, int quit_on_errors, int prune_level, LC_LOCKSET **lockset, LC_COPYAREA **fetch_area)
char coll_name[COLL_NAME_SIZE]
TRAN_QUERY_EXEC_INFO query_exec_info
int locator_unpack_lockhint(LC_LOCKHINT *lockhint, bool unpack_classes)
int xqmgr_drop_all_query_plans(THREAD_ENTRY *thread_p)
int xlocator_upgrade_instances_domain(THREAD_ENTRY *thread_p, OID *class_oid, int att_id)
int boot_delete(const char *db_name, bool force_delete)
int boot_get_server_locales(LANG_COLL_COMPAT **server_collations, LANG_LOCALE_COMPAT **server_locales, int *server_coll_cnt, int *server_locales_cnt)
char * or_unpack_db_value(char *buffer, DB_VALUE *val)
QFILE_LIST_ID * qmgr_execute_query(const XASL_ID *xasl_id, QUERY_ID *query_idp, int dbval_cnt, const DB_VALUE *dbvals, QUERY_FLAG flag, CACHE_TIME *clt_cache_time, CACHE_TIME *srv_cache_time, int query_timeout)
enum er_final_code ER_FINAL_CODE
int tran_server_is_active_and_has_updated(void)
int xtran_get_local_transaction_id(THREAD_ENTRY *thread_p, DB_VALUE *trid)
int locator_pack_lockset(LC_LOCKSET *lockset, bool pack_classes, bool pack_objects)
#define IS_QUERY_EXECUTE_WITH_COMMIT(flag)
int jsp_get_server_port(void)
int boot_initialize_server(const BOOT_CLIENT_CREDENTIAL *client_credential, BOOT_DB_PATH_INFO *db_path_info, bool db_overwrite, const char *file_addmore_vols, DKNPAGES db_npages, PGLENGTH db_desired_pagesize, DKNPAGES log_npages, PGLENGTH db_desired_log_page_size, OID *rootclass_oid, HFID *rootclass_hfid, int client_lock_wait, TRAN_ISOLATION client_isolation)
int xlocator_get_class(THREAD_ENTRY *thread_p, OID *class_oid, int class_chn, const OID *oid, LOCK lock, int prefetching, LC_COPYAREA **fetch_area)
VOLID xboot_find_last_temp(THREAD_ENTRY *thread_p)
int qfile_get_list_file_page(QUERY_ID query_id, VOLID volid, PAGEID pageid, char *buffer, int *buffer_size)
int loaddb_fetch_status(load_status &status)
int locator_log_force_nologging(void)
int xtran_server_2pc_recovery_prepared(THREAD_ENTRY *thread_p, int gtrids[], int size)
#define ER_NET_CLIENT_DATA_RECEIVE
int log_reset_wait_msecs(int wait_msecs)
int db_local_transaction_id(DB_VALUE *result_trid)
#define OR_PACK_XASL_ID(PTR, X)
int locator_send_copy_area(LC_COPYAREA *copyarea, char **contents_ptr, int *contents_length, char **desc_ptr, int *desc_length)
bool tran_is_blocked(int tran_index)