CUBRID Engine
latest
|
#include "config.h"
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <assert.h>
#include "memory_alloc.h"
#include "area_alloc.h"
#include "message_catalog.h"
#include "memory_hash.h"
#include "error_manager.h"
#include "oid.h"
#include "work_space.h"
#include "schema_manager.h"
#include "authenticate.h"
#include "object_accessor.h"
#include "locator_cl.h"
#include "storage_common.h"
#include "system_parameter.h"
#include "set_object.h"
#include "virtual_object.h"
#include "object_primitive.h"
#include "object_representation.h"
#include "class_object.h"
#include "environment_variable.h"
#include "db.h"
#include "transaction_cl.h"
#include "object_template.h"
#include "server_interface.h"
#include "view_transform.h"
#include "dbtype.h"
Go to the source code of this file.
Macros | |
#define | OBJLIST_AREA_COUNT 4096 |
Variables | |
unsigned int | db_on_server |
MOP | ws_Commit_mops = NULL |
WS_MOP_TABLE_ENTRY * | ws_Mop_table = NULL |
unsigned int | ws_Mop_table_size = 0 |
DB_OBJLIST * | ws_Resident_classes = NULL |
WS_STATISTICS | ws_Stats = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } |
int | ws_Num_dirty_mop = 0 |
static bool | Ws_dirty |
static MOP | Null_object |
static MHT_TABLE * | Classname_cache = NULL |
static AREA * | Objlist_area = NULL |
static unsigned int | ws_MVCC_snapshot_version = 0 |
int | ws_Error_ignore_list [-ER_LAST_ERROR] |
int | ws_Error_ignore_count = 0 |
static WS_REPL_FLUSH_ERR * | ws_Repl_error_link = NULL |
static WS_REPL_LIST | ws_Repl_objs |
#define OBJLIST_AREA_COUNT 4096 |
Definition at line 163 of file work_space.c.
Referenced by ws_area_init().
Definition at line 1880 of file work_space.c.
References ARG_FILE_LINE, db_object::class_link, db_object::class_mop, db_object::dirty_link, ER_ERROR_SEVERITY, er_set(), ER_WS_CHANGING_OBJECT_CLASS, ER_WS_CLASS_NOT_CACHED, error(), ws_statistics::ignored_class_assignments, ml_add(), NO_ERROR, NULL, Null_object, db_object::object, sm_Root_class_mop, and ws_statistics::uncached_classes.
Referenced by ws_cache(), ws_mop(), ws_new_mop(), ws_set_class(), ws_update_oid_and_class(), and ws_vmop().
|
static |
Definition at line 1301 of file work_space.c.
References db_object::class_mop, db_object::dirty_link, and NULL.
Referenced by ws_cull_mops().
|
static |
Definition at line 2167 of file work_space.c.
References db_object::pinned, WS_MAP_CONTINUE, and WS_SET_DELETED.
Referenced by ws_mark_instances_deleted().
int ml_add | ( | DB_OBJLIST ** | list, |
MOP | mop, | ||
int * | added_ptr | ||
) |
Definition at line 4493 of file work_space.c.
References assert, db_ws_alloc(), er_errid(), error(), db_objlist::next, NO_ERROR, NULL, db_objlist::op, and ws_is_same_object().
Referenced by add_class_object(), db_preload_classes(), sm_get_class_repid(), tr_add_cache_trigger(), tr_copy_schema_cache(), tr_get_cache_objects(), and tr_merge_schema_cache().
int ml_append | ( | DB_OBJLIST ** | list, |
MOP | mop, | ||
int * | added_ptr | ||
) |
Definition at line 4548 of file work_space.c.
References assert, db_ws_alloc(), er_errid(), error(), db_objlist::next, NO_ERROR, NULL, db_objlist::op, and ws_is_same_object().
Referenced by emit_query_specs(), get_object_set(), lock_supers(), sm_fetch_all_base_classes(), sm_fetch_all_classes(), smt_add_super(), smt_delete_super_connect(), and update_supers().
DB_OBJLIST* ml_copy | ( | DB_OBJLIST * | list | ) |
Definition at line 4671 of file work_space.c.
References db_ws_alloc(), ml_free(), db_objlist::next, NULL, and db_objlist::op.
Referenced by classobj_make_template(), flatten_template(), sm_delete_class_mop(), and tr_copy_schema_cache().
int ml_ext_add | ( | DB_OBJLIST ** | list, |
MOP | mop, | ||
int * | added_ptr | ||
) |
Definition at line 4877 of file work_space.c.
References area_alloc(), assert, er_errid(), error(), db_objlist::next, NO_ERROR, NULL, db_objlist::op, and ws_is_same_object().
Referenced by cache_validation(), classobj_copy_constraint_like(), clist_init(), convert_speclist_to_objlist(), find_all_triggers(), get_ordered_classes(), get_schema_trigger_objects(), get_user_trigger_objects(), and sch_trigger().
DB_OBJLIST* ml_ext_alloc_link | ( | void | ) |
Definition at line 4777 of file work_space.c.
References area_alloc().
Referenced by db_get_all_chosen_classes(), ml_ext_copy(), sm_fetch_all_base_classes(), sm_fetch_all_classes(), sm_fetch_all_objects_internal(), and vid_getall_mops().
DB_OBJLIST* ml_ext_copy | ( | DB_OBJLIST * | list | ) |
Definition at line 4832 of file work_space.c.
References ml_ext_alloc_link(), ml_ext_free(), db_objlist::next, NULL, and db_objlist::op.
Referenced by get_schema_trigger_objects().
void ml_ext_free | ( | DB_OBJLIST * | list | ) |
Definition at line 4806 of file work_space.c.
References area_validate(), ml_ext_free_link(), tr_schema_cache::next, db_objlist::next, NO_ERROR, and NULL.
Referenced by au_force_write_new_auth(), classobj_free_descriptor(), classobj_free_template(), clist_final(), convert_speclist_to_objlist(), db_get_all_chosen_classes(), db_objlist_free(), do_alter_trigger(), do_drop_trigger(), do_execute_trigger(), do_remove_trigger(), find_all_triggers(), get_ordered_classes(), get_schema_trigger_objects(), get_user_trigger_objects(), merge_mop_list_extension(), ml_ext_copy(), sch_trigger(), sm_fetch_all_base_classes(), sm_fetch_all_classes(), sm_fetch_all_objects_internal(), tr_get_class_name(), and vid_getall_mops().
void ml_ext_free_link | ( | DB_OBJLIST * | link | ) |
Definition at line 4790 of file work_space.c.
References area_free(), NULL, and db_objlist::op.
Referenced by filter_system_classes(), filter_unrequired_classes(), and ml_ext_free().
int ml_find | ( | DB_OBJLIST * | list, |
MOP | mop | ||
) |
Definition at line 4465 of file work_space.c.
References db_objlist::next, NULL, db_objlist::op, and ws_is_same_object().
Referenced by check_resolution_target(), emit_query_specs(), is_dependent_class(), is_internal_class(), lock_subclasses_internal(), lock_supers(), merge_mop_list_extension(), quick_validate(), sm_get_class_repid(), and smt_add_super().
void ml_free | ( | DB_OBJLIST * | list | ) |
Definition at line 4654 of file work_space.c.
References db_ws_free(), tr_schema_cache::next, db_objlist::next, and NULL.
Referenced by classobj_free_template(), classobj_install_template(), ml_copy(), sm_delete_class_mop(), sm_fetch_all_base_classes(), sm_fetch_all_classes(), sm_get_class_repid(), tr_free_schema_cache(), tr_validate_schema_cache(), update_class(), and ws_final().
int ml_remove | ( | DB_OBJLIST ** | list, |
MOP | mop | ||
) |
Definition at line 4613 of file work_space.c.
References db_ws_free(), db_objlist::next, NULL, db_objlist::op, and ws_is_same_object().
Referenced by flatten_template(), smt_delete_super(), smt_delete_super_connect(), tr_drop_cache_trigger(), update_supers(), update_supers_drop(), and ws_remove_resident_class().
int ml_size | ( | DB_OBJLIST * | list | ) |
Definition at line 4711 of file work_space.c.
References tr_schema_cache::next, db_objlist::next, NULL, db_objlist::op, and ws_list_length().
Referenced by classobj_class_size().
int nlist_add | ( | DB_NAMELIST ** | list, |
const char * | name, | ||
NLSEARCHER | fcn, | ||
int * | added_ptr | ||
) |
Definition at line 4147 of file work_space.c.
References assert, db_ws_alloc(), db_ws_free(), er_errid(), error(), db_namelist::name, db_namelist::next, nlist_find(), NO_ERROR, NULL, and ws_copy_string().
Referenced by db_namelist_add().
int nlist_append | ( | DB_NAMELIST ** | list, |
const char * | name, | ||
NLSEARCHER | fcn, | ||
int * | added_ptr | ||
) |
Definition at line 4198 of file work_space.c.
References assert, db_ws_alloc(), db_ws_free(), er_errid(), error(), db_namelist::name, db_namelist::next, nlist_find_or_append(), NO_ERROR, NULL, and ws_copy_string().
Referenced by db_get_attribute_names(), db_get_class_attribute_names(), db_get_class_method_names(), db_get_method_file_names(), db_get_method_names(), db_get_ordered_attribute_names(), db_get_shared_attribute_names(), db_get_subclass_names(), db_get_superclass_names(), db_namelist_append(), and sm_prelink_methods().
DB_NAMELIST* nlist_copy | ( | DB_NAMELIST * | list | ) |
Definition at line 4362 of file work_space.c.
References db_ws_alloc(), db_ws_free(), db_namelist::name, db_namelist::next, nlist_free(), NULL, and ws_copy_string().
Referenced by db_namelist_copy().
DB_NAMELIST* nlist_filter | ( | DB_NAMELIST ** | root, |
const char * | name, | ||
NLSEARCHER | fcn | ||
) |
Definition at line 4410 of file work_space.c.
References db_namelist::name, tr_schema_cache::next, db_namelist::next, and NULL.
Referenced by prune_candidate().
DB_NAMELIST* nlist_find | ( | DB_NAMELIST * | list, |
const char * | name, | ||
NLSEARCHER | fcn | ||
) |
Definition at line 4066 of file work_space.c.
References db_namelist::name, db_namelist::next, and NULL.
Referenced by nlist_add().
void nlist_free | ( | DB_NAMELIST * | list | ) |
Definition at line 4344 of file work_space.c.
References db_ws_free(), db_namelist::name, tr_schema_cache::next, db_namelist::next, and NULL.
Referenced by db_get_attribute_names(), db_get_class_attribute_names(), db_get_class_method_names(), db_get_method_file_names(), db_get_method_names(), db_get_ordered_attribute_names(), db_get_shared_attribute_names(), db_get_subclass_names(), db_get_superclass_names(), db_namelist_free(), db_namelist_remove(), nlist_copy(), pt_find_value_of_label(), sm_prelink_methods(), and tran_free_savepoint_list().
DB_NAMELIST* nlist_remove | ( | DB_NAMELIST ** | root, |
const char * | name, | ||
NLSEARCHER | fcn | ||
) |
Definition at line 4100 of file work_space.c.
References db_namelist::name, db_namelist::next, and NULL.
Referenced by db_namelist_remove().
Definition at line 1951 of file work_space.c.
References db_object::class_link, db_object::class_mop, and NULL.
Referenced by ws_cache(), ws_cull_mops(), ws_decache(), ws_insert_mop_on_hash_link(), ws_mop(), and ws_update_oid_and_class().
void ws_abort_mops | ( | bool | only_unpinned | ) |
Definition at line 3353 of file work_space.c.
References au_reset_authorization_caches(), db_object::commit_link, tr_schema_cache::next, NULL, db_object::pinned, prm_get_bool_value(), PRM_ID_EXAMINE_CLIENT_CACHED_LOCKS, ws_clear_hints(), ws_Commit_mops, ws_decache(), ws_examine_no_mop_has_cached_lock(), and ws_Num_dirty_mop.
Referenced by tran_abort(), tran_abort_only_client(), and tran_internal_abort_upto_savepoint().
void ws_abort_transaction | ( | void | ) |
Definition at line 201 of file work_space.c.
References ARG_FILE_LINE, db_Disable_modifications, er_errid(), ER_ERROR_SEVERITY, ER_OUT_OF_VIRTUAL_MEMORY, er_set(), and tran_unilaterally_abort().
Referenced by area_create(), and ws_make_mop().
Definition at line 2212 of file work_space.c.
References mht_get(), mht_put(), mht_rem(), NULL, and sm_ch_name().
Referenced by locator_prepare_rename_class(), and ws_cache().
Definition at line 5237 of file work_space.c.
References assert, db_ws_alloc(), er_errid(), db_object::label_value_list, ws_value_list::next, NO_ERROR, NULL, and ws_value_list::val.
Referenced by pt_associate_label_with_value().
int ws_add_to_repl_obj_list | ( | OID * | class_oid, |
char * | packed_pkey_value, | ||
int | packed_pkey_value_length, | ||
RECDES * | recdes, | ||
int | operation, | ||
bool | has_index | ||
) |
Definition at line 5408 of file work_space.c.
References ARG_FILE_LINE, assert, ws_repl_obj::class_oid, COPY_OID, ER_ERROR_SEVERITY, ER_OUT_OF_VIRTUAL_MEMORY, er_set(), ws_repl_obj::has_index, ws_repl_list::head, ws_repl_obj::next, NO_ERROR, NULL, ws_repl_list::num_items, OID_ISNULL, ws_repl_obj::operation, ws_repl_obj::packed_pkey_value, ws_repl_obj::packed_pkey_value_length, ws_repl_obj::recdes, and ws_repl_list::tail.
Referenced by la_repl_add_object().
void ws_area_final | ( | void | ) |
Definition at line 3840 of file work_space.c.
References area_destroy(), and NULL.
Referenced by ws_init().
int ws_area_init | ( | void | ) |
Definition at line 3823 of file work_space.c.
References area_create(), assert, er_errid(), NO_ERROR, NULL, and OBJLIST_AREA_COUNT.
Referenced by ws_init().
Definition at line 2575 of file work_space.c.
References add_class_object(), ARG_FILE_LINE, db_object::class_link, db_object::class_mop, classobj_free_class(), ER_ERROR_SEVERITY, er_print_callstack(), er_set(), ER_WARNING_SEVERITY, ER_WS_CHANGING_OBJECT_CLASS, ER_WS_CLASS_NOT_CACHED, NULL, obj_free_memory(), db_object::object, prm_get_bool_value(), PRM_ID_CLIENT_CLASS_CACHE_DEBUG, remove_class_object(), sm_ch_name(), sm_Root_class, sm_Root_class_mop, ws_statistics::uncached_classes, ws_add_classname(), ws_class_has_object_dependencies(), ws_decache_all_instances(), ws_drop_classname(), and ws_oid().
Referenced by locator_add_root(), locator_cache_object_class(), locator_cache_object_instance(), and ws_cache_with_oid().
Definition at line 2675 of file work_space.c.
References NULL, ws_cache(), and ws_mop().
Referenced by locator_add_class(), and locator_add_instance().
|
static |
Definition at line 366 of file work_space.c.
References assert, db_object::hash_link, ws_mop_table_entry::head, NO_ERROR, NULL, oid_compare(), p, ws_mop_table_entry::tail, and WS_OID.
Referenced by ws_cull_mops(), ws_mop(), ws_new_mop(), ws_rehash_vmop(), ws_update_oid(), and ws_vmop().
int ws_chn | ( | MOBJ | obj | ) |
Definition at line 2922 of file work_space.c.
References ws_object_header::chn, and NULL_CHN.
Referenced by locator_get_cache_coherency_number(), locator_lock(), locator_lock_and_doesexist(), locator_lock_class_of_instance(), locator_lock_nested(), locator_lock_set(), locator_lockhint_classes(), and locator_set_chn_classes_objects().
int ws_class_has_cached_objects | ( | MOP | class_mop | ) |
Definition at line 3180 of file work_space.c.
References db_object::class_link, db_object::hash_link, NULL, db_object::object, WS_MAP_CONTINUE, WS_MAP_FAIL, WS_MAP_SUCCESS, and ws_Mop_table_size.
Referenced by install_new_representation().
void ws_class_has_object_dependencies | ( | MOP | class_mop | ) |
Definition at line 3166 of file work_space.c.
References db_object::no_objects, and NULL.
Referenced by access_object(), construct_instance(), create_template_object(), find_shared_attribute(), ldr_reset_context(), obj_locate_attribute(), obj_set_att(), and ws_cache().
Definition at line 2907 of file work_space.c.
References db_object::class_mop.
Referenced by assign_set_value(), fetch_class(), find_shared_attribute(), get_set_value(), object_description::init(), locator_add_oidset_object(), locator_add_to_oidset_when_temp_oid(), locator_assign_permanent_oid(), locator_cache(), locator_cache_lock(), locator_cache_lock_set(), locator_cache_not_have_object(), locator_can_skip_fetch_from_server(), locator_check_object_and_get_class(), locator_does_exist_object(), locator_fetch_class(), locator_fetch_instance(), locator_fetch_nested(), locator_fetch_object(), locator_fetch_set(), locator_get_cache_coherency_number(), locator_is_class(), locator_lock(), locator_lock_and_doesexist(), locator_lock_class_of_instance(), locator_lock_nested(), locator_lock_set(), locator_mflush(), locator_save_nested_mops(), obj_copy(), obj_delete(), obj_get_att(), obj_is_instance_of(), obj_locate_attribute(), obj_set_att(), set_add_element(), set_drop_element(), set_drop_seq_element(), set_insert_element(), set_put_element(), sm_check_object_domain(), sm_coerce_object_domain(), sm_fetch_all_objects_internal(), sm_flush_and_decache_objects(), sm_get_attribute_descriptor(), sm_get_class(), sm_get_descriptor_component(), sm_get_method_descriptor(), update_object_tuple(), vid_build_non_upd_object(), vid_fetch_instance(), vid_is_new_oobj(), ws_identifier_with_check(), and ws_update_oid_and_class().
void ws_clean | ( | MOP | op | ) |
Definition at line 1681 of file work_space.c.
References db_object::pinned, ws_statistics::pinned_cleanings, and WS_RESET_DIRTY.
Referenced by locator_mflush(), vid_flush_instance(), and ws_decache().
void ws_clean_label_value_list | ( | MOP | mop | ) |
Definition at line 5301 of file work_space.c.
References db_ws_free(), db_object::label_value_list, ws_value_list::next, NULL, and ws_value_list::val.
Referenced by ws_free_mop().
void ws_clear | ( | void | ) |
Definition at line 2526 of file work_space.c.
References ws_clear_internal().
Referenced by tran_abort(), tran_internal_abort_upto_savepoint(), and ws_final().
void ws_clear_all_hints | ( | bool | retain_lock | ) |
Definition at line 3305 of file work_space.c.
References au_reset_authorization_caches(), db_object::commit_link, tr_schema_cache::next, NULL, prm_get_bool_value(), PRM_ID_EXAMINE_CLIENT_CACHED_LOCKS, ws_clear_hints(), ws_Commit_mops, ws_examine_no_mop_has_cached_lock(), and ws_Num_dirty_mop.
Referenced by tran_2pc_prepare(), tran_2pc_prepare_global_tran(), and tran_commit().
void ws_clear_all_repl_errors_of_error_link | ( | void | ) |
Definition at line 5096 of file work_space.c.
References ws_repl_flush_err::error_link, tr_schema_cache::next, NULL, and ws_free_repl_flush_error().
Referenced by la_flush_repl_items(), and ws_final().
void ws_clear_all_repl_objs | ( | void | ) |
Definition at line 5377 of file work_space.c.
References ws_repl_list::head, ws_repl_obj::next, NULL, ws_repl_list::num_items, ws_repl_list::tail, and ws_free_repl_obj().
Referenced by la_flush_repl_items(), and la_shutdown().
Definition at line 3257 of file work_space.c.
References ARG_FILE_LINE, db_object::class_mop, db_object::composition_fetch, db_object::deleted, er_print_callstack(), db_object::lock, db_object::no_objects, NULL, NULL_LOCK, db_object::object, db_object::pinned, prm_get_bool_value(), PRM_ID_CLIENT_CLASS_CACHE_DEBUG, sm_ch_name(), sm_Root_class_mop, vid_is_updatable(), ws_decache(), WS_ISVID, ws_oid(), and WS_RESET_DIRTY.
Referenced by tr_drop_trigger_internal(), ws_abort_mops(), ws_clear_all_hints(), and ws_decache_allxlockmops_but_norealclasses().
|
static |
Definition at line 2495 of file work_space.c.
References db_object::deleted, db_object::hash_link, db_object::is_vid, db_object::lock, NULL, NULL_LOCK, pr_clear_value(), ws_decache(), ws_filter_dirty(), ws_Mop_table_size, and WS_VID_INFO.
Referenced by ws_clear(), and ws_final().
char* ws_copy_string | ( | const char * | str | ) |
Definition at line 3457 of file work_space.c.
References db_ws_alloc(), NULL, and strlen.
Referenced by add_resolution(), au_get_user_name(), au_user_name(), classobj_cache_not_null_constraints(), classobj_copy_attribute(), classobj_copy_default_expr(), classobj_copy_methfile(), classobj_copy_method(), classobj_copy_method_signature(), classobj_copy_partition_info(), classobj_init_attribute(), classobj_init_method(), classobj_make_attribute(), classobj_make_class(), classobj_make_constraint(), classobj_make_method(), classobj_make_method_file(), classobj_make_method_signature(), classobj_make_query_spec(), classobj_make_resolution(), classobj_make_template(), db_get_database_comments(), db_get_database_name(), db_get_database_version(), disk_to_attribute(), disk_to_methsig(), do_add_attribute(), do_alter_change_col_comment(), do_change_att_schema_only(), flatten_template(), get_string(), make_component_from_candidate(), nlist_add(), nlist_append(), nlist_copy(), pt_associate_label_with_value(), pt_find_value_of_label(), pt_node_to_partition_info(), sm_build_function_nlist(), sm_expand_method_files(), sm_get_method_source_file(), sm_rename_class(), sm_set_class_comment(), sm_split_loader_commands(), smt_add_attribute_any(), smt_change_attribute(), smt_change_method_implementation(), smt_rename_any(), smt_rename_method_file(), smt_set_loader_commands(), tr_trigger_action(), tr_trigger_attribute(), tr_trigger_comment(), tr_trigger_condition(), tr_trigger_name(), and tran_add_savepoint().
void ws_cull_mops | ( | void | ) |
Definition at line 1406 of file work_space.c.
References ARG_FILE_LINE, assert, db_object::class_link, db_object::class_mop, ws_statistics::corruptions, cubregex::count(), db_object::dirty, db_object::dirty_link, ws_statistics::dirty_list_emergencies, emergency_remove_dirty(), ER_ERROR_SEVERITY, er_set(), ER_WS_CORRUPTED, ER_WS_GC_DIRTY_MOP, db_object::hash_link, ws_mop_table_entry::head, ws_statistics::instance_list_emergencies, db_object::is_vid, ws_statistics::mops_freed, tr_schema_cache::next, db_objlist::next, NO_ERROR, NULL, db_objlist::op, pr_clear_value(), db_object::released, remove_class_object(), sm_Root_class_mop, ws_mop_table_entry::tail, ws_check_hash_link(), ws_decache(), ws_free_mop(), ws_Mop_table_size, ws_remove_resident_class(), ws_unlink_from_commit_mops_list(), and WS_VID_INFO.
Referenced by la_commit_transaction(), la_create_repl_filter(), and ws_intern_instances().
void ws_decache | ( | MOP | mop | ) |
Definition at line 2701 of file work_space.c.
References ARG_FILE_LINE, db_object::class_mop, classobj_free_class(), db_object::composition_fetch, db_object::decached, ER_ERROR_SEVERITY, er_print_callstack(), er_set(), ER_WS_CLASS_NOT_CACHED, ER_WS_PIN_VIOLATION, NULL, obj_free_memory(), db_object::object, db_object::pinned, prm_get_bool_value(), PRM_ID_CLIENT_CLASS_CACHE_DEBUG, remove_class_object(), sm_ch_name(), sm_Root_class, sm_Root_class_mop, ws_statistics::uncached_classes, ws_clean(), ws_decache_all_instances(), ws_drop_classname(), WS_IS_DELETED, and ws_oid().
Referenced by dbt_finish_object_and_decache_when_failure(), do_alter_serial(), do_update_auto_increment_serial_on_rename(), do_update_maxvalue_of_auto_increment_serial(), la_apply_insert_log(), la_apply_update_log(), la_create_repl_filter(), locator_cache_not_have_object(), locator_instance_decache(), locator_internal_flush_instance(), locator_lock(), locator_mflush(), obt_apply_assignments(), sm_decache_mop(), tr_drop_trigger_internal(), vid_decache_instance(), vid_fetch_instance(), vid_flush_and_rehash(), vid_flush_instance(), ws_abort_mops(), ws_clear_hints(), ws_clear_internal(), ws_cull_mops(), ws_decache_all_instances(), ws_decache_allxlockmops_but_norealclasses(), and ws_insert_mop_on_hash_link().
void ws_decache_all_instances | ( | MOP | mop | ) |
Definition at line 2765 of file work_space.c.
References db_object::class_link, db_object::class_mop, db_objlist::next, NULL, db_objlist::op, sm_Root_class_mop, and ws_decache().
Referenced by cubload::sa_object_loader::finish_line(), ws_cache(), and ws_decache().
void ws_decache_allxlockmops_but_norealclasses | ( | void | ) |
Definition at line 3426 of file work_space.c.
References db_object::class_mop, db_object::hash_link, IS_WRITE_EXCLUSIVE_LOCK, NULL, db_object::object, db_object::pinned, SM_CLASS_CT, sm_Root_class_mop, ws_clear_hints(), ws_decache(), ws_get_lock(), WS_ISDIRTY, and ws_Mop_table_size.
Referenced by tran_internal_abort_upto_savepoint().
void ws_dirty | ( | MOP | op | ) |
Definition at line 1622 of file work_space.c.
References ARG_FILE_LINE, db_object::class_mop, db_object::dirty_link, er_errid(), ER_ERROR_SEVERITY, ER_MVCC_SERIALIZABLE_CONFLICT, er_set(), ER_WS_CLASS_NOT_CACHED, NULL, sm_Root_class_mop, ws_statistics::uncached_classes, and WS_SET_DIRTY.
Referenced by locator_add_class(), locator_add_instance(), locator_add_root(), locator_create_heap_if_needed(), locator_mflush_set_dirty(), locator_prepare_rename_class(), locator_remove_class(), locator_update_class(), locator_update_instance(), obt_apply_assignments(), sm_force_write_all_classes(), sm_truncate_using_delete(), smt_change_query_spec(), tr_get_class_name(), vid_att_in_obj_id(), vid_fetch_instance(), and ws_mark_deleted().
void ws_disconnect_deleted_instances | ( | MOP | classop | ) |
Definition at line 1230 of file work_space.c.
References ARG_FILE_LINE, db_object::class_link, db_object::class_mop, ER_ERROR_SEVERITY, er_set(), ER_WS_CORRUPTED, tr_schema_cache::next, NULL, Null_object, db_object::object, and sm_Root_class_mop.
Referenced by locator_flush_all_instances(), sm_decache_instances_after_query_executed_with_commit(), and ws_remove_resident_class().
void ws_drop_classname | ( | MOBJ | classobj | ) |
Definition at line 2247 of file work_space.c.
References mht_rem(), NULL, and sm_ch_name().
Referenced by locator_prepare_rename_class(), ws_cache(), and ws_decache().
void ws_dump | ( | FILE * | fpp | ) |
Definition at line 3600 of file work_space.c.
References area_dump(), db_object::class_link, db_object::class_mop, classobj_class_size(), ws_statistics::corruptions, cubregex::count(), db_object::dirty, db_object::dirty_link, ws_statistics::dirty_list_emergencies, db_object::hash_link, ws_statistics::ignored_class_assignments, ws_statistics::mops_allocated, ws_statistics::mops_freed, db_objlist::next, NULL, db_object::object, db_objlist::op, ws_statistics::pinned_cleanings, ws_statistics::set_mops_allocated, ws_statistics::set_mops_freed, sm_ch_name(), sm_object_size_quick(), sm_Root_class_mop, ws_statistics::uncached_classes, WS_IS_DELETED, and ws_Mop_table_size.
Referenced by db_print_stats(), help_print_info(), and ws_final().
|
static |
Definition at line 5271 of file work_space.c.
References assert, db_object::class_link, db_object::hash_link, db_object::lock, db_objlist::next, NULL, NULL_LOCK, db_objlist::op, and ws_Mop_table_size.
Referenced by ws_abort_mops(), and ws_clear_all_hints().
void ws_filter_dirty | ( | void | ) |
Definition at line 1859 of file work_space.c.
References NULL, and ws_map_dirty_internal().
Referenced by la_commit_transaction(), tran_abort(), tran_abort_only_client(), tran_internal_abort_upto_savepoint(), ws_clear_internal(), ws_has_updated(), and ws_intern_instances().
void ws_final | ( | void | ) |
Definition at line 2429 of file work_space.c.
References db_destroy_workspace_heap(), free_and_init, db_object::hash_link, mht_destroy(), ml_free(), tr_schema_cache::next, NULL, prm_get_bool_value(), PRM_ID_WS_MEMORY_REPORT, tr_final(), ws_clear(), ws_clear_all_repl_errors_of_error_link(), ws_clear_internal(), Ws_dirty, ws_dump(), ws_free_mop(), and ws_Mop_table_size.
Referenced by boot_client_all_finalize(), boot_initialize_client(), and boot_restart_client().
Definition at line 3112 of file work_space.c.
References NULL, db_object::object, WS_FIND_MOP_DELETED, WS_FIND_MOP_NOTDELETED, and WS_IS_DELETED.
Referenced by assign_null_value(), compactdb_start(), extract_objects(), locator_add_to_oidset_when_temp_oid(), locator_assign_permanent_oid(), locator_cache_have_object(), locator_cache_lock_lockhint_classes(), locator_cache_not_have_object(), locator_can_skip_fetch_from_server(), locator_fetch_class(), locator_fetch_class_of_instance(), locator_fetch_instance(), locator_fetch_nested(), locator_fetch_object(), locator_fetch_set(), locator_flush_class(), locator_get_cache_coherency_number(), locator_internal_flush_instance(), locator_lock(), locator_lock_and_doesexist(), locator_lock_class_of_instance(), locator_lock_nested(), locator_lock_set(), locator_lockhint_classes(), locator_mflush(), locator_set_chn_classes_objects(), obj_assign_value(), obj_get_value(), process_class(), process_value(), set_referenced_subclasses(), sm_decache_instances_after_query_executed_with_commit(), unloaddb(), util_get_class_oids_and_index_btid(), vid_fetch_instance(), vid_get_class_object(), vid_is_new_oobj(), vid_upd_instance(), and ws_rehash_vmop().
Definition at line 2278 of file work_space.c.
References mht_get().
Referenced by do_create_partition(), locator_add_class(), locator_find_class_by_name(), locator_lockhint_classes(), and locator_prepare_rename_class().
|
static |
Definition at line 296 of file work_space.c.
References db_object::commit_link, db_object::is_vid, NULL, pr_clear_value(), ws_clean_label_value_list(), ws_keys(), ws_unlink_from_commit_mops_list(), and WS_VID_INFO.
Referenced by ws_cull_mops(), ws_final(), ws_free_temp_mop(), ws_init(), ws_mop(), ws_new_mop(), and ws_vmop().
void ws_free_repl_flush_error | ( | WS_REPL_FLUSH_ERR * | flush_err | ) |
Definition at line 5115 of file work_space.c.
References assert, db_value_clear(), ws_repl_flush_err::error_msg, free_and_init, NULL, and ws_repl_flush_err::pkey_value.
Referenced by la_flush_repl_items(), and ws_clear_all_repl_errors_of_error_link().
void ws_free_repl_obj | ( | WS_REPL_OBJ * | obj | ) |
Definition at line 5361 of file work_space.c.
References assert, free_and_init, NULL, and ws_repl_obj::packed_pkey_value.
Referenced by locator_repl_mflush(), and ws_clear_all_repl_objs().
void ws_free_string | ( | const char * | str | ) |
Definition at line 3480 of file work_space.c.
References db_ws_free(), and NULL.
Referenced by au_export_grants(), au_export_users(), au_perform_login(), boot_restart_client(), classobj_clear_attribute(), classobj_clear_method(), classobj_copy_attribute(), classobj_copy_method(), classobj_free_class_constraints(), classobj_free_function_index_ref(), classobj_free_method_file(), classobj_free_method_signature(), classobj_free_partition_info(), classobj_free_query_spec(), classobj_free_resolution(), classobj_free_template(), classobj_install_template(), disk_to_methsig(), do_change_att_schema_only(), help_trigger_names(), trigger_description::init(), issue_grant_statement(), make_component_from_candidate(), pt_free_label(), sc_set_current_schema(), sm_expand_method_files(), sm_rename_class(), sm_set_class_comment(), smt_change_attribute(), smt_change_method_implementation(), smt_rename_any(), smt_rename_method_file(), and smt_set_loader_commands().
void ws_free_temp_mop | ( | MOP | op | ) |
Definition at line 356 of file work_space.c.
References db_object::is_temp, NULL, ws_statistics::temp_mops_freed, and ws_free_mop().
Referenced by free_temp_object().
Definition at line 2942 of file work_space.c.
References db_object::lock.
Referenced by locator_add_class(), locator_cache(), locator_cache_lock(), locator_cache_lock_lockhint_classes(), locator_cache_lock_set(), locator_can_skip_fetch_from_server(), locator_find_class_by_name(), locator_fun_get_all_mops(), locator_keep_mops(), locator_lock(), locator_lock_and_doesexist(), locator_lock_class_of_instance(), locator_lock_nested(), locator_lock_set(), locator_lockhint_classes(), locator_prepare_rename_class(), set_add_element(), set_drop_element(), set_drop_seq_element(), set_insert_element(), set_put_element(), vid_build_non_upd_object(), and ws_decache_allxlockmops_but_norealclasses().
unsigned int ws_get_mvcc_snapshot_version | ( | void | ) |
Definition at line 4976 of file work_space.c.
References ws_MVCC_snapshot_version.
Referenced by sm_virtual_queries(), and ws_make_mop().
WS_REPL_FLUSH_ERR* ws_get_repl_error_from_error_link | ( | void | ) |
Definition at line 5075 of file work_space.c.
References ws_repl_flush_err::error_link, NULL, and ws_Repl_error_link.
Referenced by la_flush_repl_items().
WS_REPL_OBJ* ws_get_repl_obj_from_list | ( | void | ) |
Definition at line 5335 of file work_space.c.
References assert, ws_repl_list::head, ws_repl_obj::next, NULL, ws_repl_list::num_items, and ws_repl_list::tail.
Referenced by locator_repl_mflush().
int ws_has_dirty_objects | ( | MOP | op, |
int * | isvirt | ||
) |
Definition at line 3752 of file work_space.c.
References class_type(), db_object::dirty_link, Null_object, db_object::object, SM_VCLASS_CT, and WS_IS_DELETED.
Referenced by pt_flush_classes(), and vid_allflush().
bool ws_has_updated | ( | void | ) |
Definition at line 2536 of file work_space.c.
References Ws_dirty, and ws_filter_dirty().
Referenced by do_execute_select(), do_execute_session_statement(), pt_flush_class_and_null_xasl(), tran_has_updated(), and tran_is_active_and_has_updated().
int ws_hide_new_old_trigger_obj | ( | MOP | op | ) |
Definition at line 3765 of file work_space.c.
References db_object::dirty, db_object::is_temp, db_object::is_vid, db_object::pinned, and WS_RESET_DIRTY.
Referenced by pt_exec_trigger_stmt().
Definition at line 2805 of file work_space.c.
References ws_identifier_with_check().
Referenced by dbt_drop_attribute(), do_change_att_schema_only(), do_get_serial_obj_id(), parser_generate_do_stmt_xasl(), parser_generate_xasl(), parser_print_user(), pt_link_regu_to_selupd_list(), pt_spec_to_xasl_class_oid_list(), pt_to_delete_xasl(), pt_to_insert_xasl(), pt_to_merge_insert_xasl(), pt_to_merge_update_xasl(), pt_to_merge_xasl(), pt_to_update_xasl(), qmgr_execute_query(), regu_make_constant_vid(), and sm_delete_class_mop().
Definition at line 2820 of file work_space.c.
References DB_FETCH_READ, db_real_instance(), is_class(), locator_flush_instance(), locator_is_class(), NULL, OID_ISTEMP, sm_is_reuse_oid_class(), ws_class_mop(), WS_IS_DELETED, WS_ISVID, and ws_oid().
Referenced by db_identifier(), and ws_identifier().
void ws_increment_mvcc_snapshot_version | ( | void | ) |
Definition at line 4987 of file work_space.c.
References ws_MVCC_snapshot_version.
Referenced by db_invalidate_mvcc_snapshot_before_statement(), tran_abort(), and tran_commit().
int ws_init | ( | void | ) |
Definition at line 2299 of file work_space.c.
References ARG_FILE_LINE, assert, classobj_area_final(), classobj_area_init(), db_create_workspace_heap(), db_destroy_workspace_heap(), er_errid(), ER_ERROR_SEVERITY, ER_FAILED, ER_GENERIC_ERROR, ER_OUT_OF_VIRTUAL_MEMORY, er_set(), error(), ws_mop_table_entry::head, i, mht_1strhash(), mht_compare_strings_are_equal(), mht_create(), mht_destroy(), NO_ERROR, NULL, obt_area_final(), obt_area_init(), pr_area_final(), pr_area_init(), prm_get_integer_value(), PRM_ID_WS_HASHTABLE_SIZE, set_area_final(), set_area_init(), ws_mop_table_entry::tail, ws_area_final(), ws_area_init(), Ws_dirty, ws_free_mop(), ws_make_mop(), and ws_Mop_table_size.
Referenced by boot_initialize_client(), and boot_restart_client().
void ws_init_repl_objs | ( | void | ) |
Definition at line 5323 of file work_space.c.
References ws_repl_list::head, NULL, ws_repl_list::num_items, and ws_repl_list::tail.
Referenced by la_init().
|
static |
Definition at line 415 of file work_space.c.
References db_object::hash_link, ws_mop_table_entry::head, NULL, oid_compare(), p, remove_class_object(), ws_mop_table_entry::tail, ws_decache(), WS_ISVID, and WS_OID.
Referenced by ws_new_mop(), ws_rehash_vmop(), ws_update_oid(), and ws_vmop().
Definition at line 517 of file work_space.c.
References db_object::hash_link, ws_mop_table_entry::head, NULL, and ws_mop_table_entry::tail.
Referenced by ws_mop().
void ws_intern_instances | ( | MOP | class_mop | ) |
Definition at line 1548 of file work_space.c.
References DECACHE, locator_flush_all_instances(), NO_ERROR, ws_cull_mops(), and ws_filter_dirty().
Referenced by ldr_flush().
int ws_is_deleted | ( | MOP | mop | ) |
Definition at line 5037 of file work_space.c.
References db_object::deleted.
int ws_is_dirty | ( | MOP | mop | ) |
Definition at line 5025 of file work_space.c.
References db_object::dirty.
Definition at line 5000 of file work_space.c.
References db_object::mvcc_snapshot_version, and ws_MVCC_snapshot_version.
Referenced by locator_can_skip_fetch_from_server().
Definition at line 5065 of file work_space.c.
Referenced by add_class_grant(), au_add_member_method(), au_check_serial_authorization(), au_drop_member_method(), au_drop_user(), au_export_users(), au_find_user_cache_index(), au_grant(), au_is_dba_group_member(), au_revoke(), au_set_password_internal(), au_set_user(), au_set_user_comment(), check_authorization(), drop_stored_procedure(), find_grant_entry(), find_or_add_user(), get_grants(), get_set_value(), help_class_names(), locator_mflush(), make_class_user(), ml_add(), ml_append(), ml_ext_add(), ml_find(), ml_remove(), mq_virtual_queries(), pt_check_user_owns_class(), remove_user_cache_references(), set_change_owner(), tr_drop_deferred_activities(), and update_cache().
Definition at line 726 of file work_space.c.
References vid_info::flags, db_object::is_vid, vid_info::keys, NULL, and WS_VID_INFO.
Referenced by ws_free_mop().
Definition at line 3869 of file work_space.c.
References db_list::next, and NULL.
Definition at line 3985 of file work_space.c.
References db_list::next, NULL, and ws_list_free().
Referenced by classobj_copy_method_signature(), and classobj_init_method().
Definition at line 3945 of file work_space.c.
References tr_schema_cache::next, db_list::next, and NULL.
Referenced by classobj_clear_method(), classobj_free_method_signature(), classobj_free_representation(), classobj_free_template(), classobj_install_template(), sm_destroy_representations(), and ws_list_copy().
int ws_list_length | ( | DB_LIST * | list | ) |
Definition at line 3925 of file work_space.c.
References db_list::next, and NULL.
Referenced by classobj_install_template(), db_list_length(), do_alter_clause_change_attribute(), help_class_names(), help_trigger_names(), class_description::init(), ml_size(), sm_dynamic_link_class(), and sm_prelink_methods().
Definition at line 4028 of file work_space.c.
References db_list::next, and NULL.
Definition at line 3891 of file work_space.c.
References db_list::next, and NULL.
Definition at line 3964 of file work_space.c.
References db_list::next, and NULL.
Referenced by classobj_attribute_size(), classobj_class_size(), classobj_domain_size(), classobj_method_arg_size(), classobj_method_signature_size(), and classobj_method_size().
Definition at line 234 of file work_space.c.
References ARG_FILE_LINE, db_object::class_link, db_object::class_mop, db_object::commit_link, COPY_OID, DB_NOT_PARTITIONED_CLASS, db_object::decached, db_object::deleted, db_object::dirty, db_object::dirty_link, ER_ERROR_SEVERITY, ER_OUT_OF_VIRTUAL_MEMORY, er_set(), db_object::hash_link, db_object::is_temp, db_object::is_vid, db_object::label_value_list, db_object::lock, ws_statistics::mops_allocated, db_object::mvcc_snapshot_version, db_object::no_objects, NULL, NULL_LOCK, db_object::object, vid_oid::oid, db_object::oid_info, OID_SET_NULL, db_identifier::pageid, db_object::pinned, db_object::pruning_type, db_object::released, db_identifier::slotid, db_identifier::volid, ws_abort_transaction(), ws_get_mvcc_snapshot_version(), and WS_REAL_OID.
Referenced by ws_init(), ws_make_temp_mop(), ws_mop(), ws_new_mop(), and ws_vmop().
MOP ws_make_temp_mop | ( | void | ) |
Definition at line 336 of file work_space.c.
References db_object::is_temp, NULL, ws_statistics::temp_mops_allocated, and ws_make_mop().
Referenced by make_temp_object().
Definition at line 2118 of file work_space.c.
References db_object::class_link, db_object::class_mop, db_objlist::next, NULL, db_objlist::op, sm_Root_class_mop, WS_MAP_CONTINUE, WS_MAP_FAIL, and WS_MAP_SUCCESS.
Referenced by locator_decache_all_lock_instances(), locator_flush_all_instances(), locator_remove_class(), sm_decache_instances_after_query_executed_with_commit(), vid_flush_all_instances(), and ws_mark_instances_deleted().
Definition at line 2018 of file work_space.c.
References db_object::class_mop, db_object::dirty, db_object::dirty_link, tr_schema_cache::next, db_objlist::next, NULL, Null_object, db_objlist::op, sm_Root_class_mop, WS_MAP_CONTINUE, WS_MAP_FAIL, and WS_MAP_SUCCESS.
Referenced by locator_flush_all_instances(), and locator_flush_for_multi_update().
int ws_map_dirty | ( | MAPFUNC | function, |
void * | args | ||
) |
Definition at line 1849 of file work_space.c.
References ws_map_dirty_internal().
Referenced by locator_all_flush(), locator_assign_all_permanent_oids(), locator_flush_class(), and locator_internal_flush_instance().
Definition at line 1717 of file work_space.c.
References db_object::class_mop, db_object::dirty, db_object::dirty_link, tr_schema_cache::next, db_objlist::next, NULL, Null_object, db_objlist::op, sm_Root_class_mop, Ws_dirty, WS_MAP_CONTINUE, WS_MAP_FAIL, WS_MAP_SUCCESS, and ws_Num_dirty_mop.
Referenced by ws_filter_dirty(), and ws_map_dirty().
void ws_mark_deleted | ( | MOP | mop | ) |
Definition at line 3081 of file work_space.c.
References db_object::pinned, ws_dirty(), and WS_SET_DELETED.
Referenced by locator_remove_class(), locator_remove_instance(), and vid_rem_instance().
void ws_mark_instances_deleted | ( | MOP | class_op | ) |
Definition at line 2192 of file work_space.c.
References mark_instance_deleted(), NULL, and ws_map_class().
Referenced by sm_delete_class_mop().
Definition at line 614 of file work_space.c.
References add_class_object(), ARG_FILE_LINE, assert, db_object::class_mop, ER_ERROR_SEVERITY, er_set(), ER_WS_CANT_INSTALL_NULL_OID, db_object::hash_link, NO_ERROR, NULL, oid_compare(), OID_ISNULL, OID_PSEUDO_KEY, remove_class_object(), sm_Root_class_mop, ws_mop_table_entry::tail, ws_check_hash_link(), ws_free_mop(), ws_insert_mop_on_hash_link_with_position(), ws_make_mop(), ws_Mop_table_size, and WS_OID.
Referenced by allocate_foreign_key(), btree_load_index(), classobj_copy_constraint_like(), cursor_fetch_oids(), db_get_foreign_key_ref_class(), db_object(), object_printer::describe_constraint(), disk_to_domain2(), do_on_duplicate_key_update(), do_replace_into(), drop_foreign_key_ref_internal(), emit_foreign_key(), find_unique(), is_class(), jsp_unpack_object_value(), la_flush_repl_items(), ldr_oid_elem(), ldr_reset_context(), locator_add_root(), locator_cache_have_object(), locator_cache_lock_lockhint_classes(), locator_cache_not_have_object(), locator_demote_class_lock(), locator_find_class_by_oid(), locator_lock_class_of_instance(), locator_lock_nested(), locator_lock_set(), locator_lockhint_classes(), locator_mflush_force(), locator_save_nested_mops(), locator_set_chn_classes_objects(), mr_data_readval_object(), mr_getmem_object(), obj_find_object_by_cons_and_key(), obj_find_object_by_pkey(), orp_oid_get_classname(), pt_make_regu_constant(), sch_exported_keys_or_cross_reference(), setof_mop_to_setof_vobj(), sm_drop_cascade_foreign_key(), sm_init(), sm_save_constraint_info(), smt_rename_any(), swizzle_value(), tp_domain_select(), tp_swizzle_oid(), unpack_domain(), unpack_domain_2(), vid_decode_object(), vid_oid_to_object(), ws_cache_with_oid(), ws_update_oid_and_class(), and ws_vmop().
Definition at line 3144 of file work_space.c.
References oid_compare(), and WS_OID.
Referenced by locator_is_root(), sm_find_subclass_in_hierarchy(), tr_validate_schema_cache(), update_object_tuple(), and ws_print_oid().
Definition at line 548 of file work_space.c.
References db_object::hash_link, NULL, oid_compare(), OID_ISNULL, OID_PSEUDO_KEY, ws_mop_table_entry::tail, ws_Mop_table_size, and WS_OID.
Definition at line 5138 of file work_space.c.
References db_value::data, DB_TYPE_OBJECT, DB_VALUE_TYPE, db_object::label_value_list, ws_value_list::next, NULL, db_data::op, and ws_value_list::val.
bool ws_need_flush | ( | void | ) |
Definition at line 3813 of file work_space.c.
References ws_Num_dirty_mop.
Referenced by do_execute_insert(), do_execute_merge(), do_execute_select(), tran_flush_to_commit(), and tran_savepoint_internal().
Definition at line 1038 of file work_space.c.
References add_class_object(), ARG_FILE_LINE, assert, ER_ERROR_SEVERITY, er_set(), ER_WS_CANT_INSTALL_NULL_OID, NO_ERROR, NULL, OID_ISNULL, OID_PSEUDO_KEY, ws_check_hash_link(), ws_free_mop(), ws_insert_mop_on_hash_link(), ws_make_mop(), and ws_Mop_table_size.
Definition at line 2884 of file work_space.c.
References NULL, vid_base_instance(), WS_ISVID, and WS_OID.
Referenced by acquire_locks_for_multiple_rename(), allocate_disk_structures(), allocate_foreign_key(), check_fk_validity(), chksum_start(), classobj_is_pk_referred(), collect_hier_class_info(), compactdb_start(), do_check_for_empty_classes_in_delete(), do_find_unique_constraint_violations(), extract_objects(), find_unique(), la_repl_add_object(), locator_add_root(), locator_add_to_oidset_when_temp_oid(), locator_assign_permanent_oid(), locator_cache_lock(), locator_cache_lock_set(), locator_can_skip_fetch_from_server(), locator_check_object_and_get_class(), locator_create_heap_if_needed(), locator_fetch_class(), locator_fetch_instance(), locator_fetch_nested(), locator_fun_get_all_mops(), locator_lock(), locator_lock_and_doesexist(), locator_lock_class_of_instance(), locator_lock_nested(), locator_lock_set(), locator_lockhint_classes(), locator_mflush(), locator_mflush_force(), locator_prepare_rename_class(), locator_save_nested_mops(), method_receive_results_for_stand_alone(), obj_find_object_by_cons_and_key(), obj_find_object_by_pkey(), process_class(), process_object(), set_referenced_subclasses(), sm_init(), sm_truncate_using_delete(), smt_check_foreign_key(), util_get_class_oids_and_index_btid(), vid_get_keys(), vid_object_to_vobj(), ws_cache(), ws_clear_hints(), ws_decache(), ws_identifier_with_check(), and ws_set_lock().
int ws_pin | ( | MOP | mop, |
int | pin | ||
) |
Definition at line 2989 of file work_space.c.
References db_object::class_mop, db_on_server, NULL, db_object::pinned, and sm_Root_class_mop.
Referenced by fetch_instance(), object_description::init(), mr_data_lengthval_set(), mr_data_writeval_set(), obj_delete(), obt_apply_assignments(), set_add_element(), set_cardinality(), set_change_owner(), set_check_domain(), set_coerce(), set_compare(), set_compare_order(), set_convert_oids_to_objects(), set_copy(), set_drop_element(), set_drop_seq_element(), set_filter(), set_find_seq_element(), set_fprint(), set_get_domain(), set_get_element(), set_get_type(), set_has_null(), set_insert_element(), set_isempty(), set_ismember(), set_issome(), set_new_element(), set_op(), set_optimize(), set_put_element(), set_seq_compare(), set_size(), sm_object_size_quick(), sm_virtual_queries(), and vobj_compare().
void ws_pin_instance_and_class | ( | MOP | obj, |
int * | opin, | ||
int * | cpin | ||
) |
Definition at line 3020 of file work_space.c.
References db_object::class_mop, NULL, db_object::pinned, and sm_Root_class_mop.
Referenced by construct_instance(), ldr_reset_context(), obj_get_att(), and obj_set_att().
|
static |
Definition at line 3501 of file work_space.c.
References db_object::class_mop, db_object::dirty, db_object::no_objects, NULL, db_object::object, db_identifier::pageid, db_object::pinned, db_identifier::slotid, sm_get_ch_name(), sm_Root_class_mop, db_identifier::volid, WS_IS_DELETED, WS_MAP_CONTINUE, ws_mop_compare(), and WS_OID.
Definition at line 899 of file work_space.c.
References assert, sm_class::attributes, classobj_get_prop(), DB_FETCH_READ, db_get_int(), db_get_set(), db_get_string(), db_make_null(), db_make_sequence(), DB_TYPE_STRING, db_value_domain_init(), DB_VALUE_TYPE, sm_attribute::domain, sm_attribute::flags, pr_type::getmem(), db_object::hash_link, ws_mop_table_entry::head, sm_attribute::header, pr_type::id, db_object::is_vid, vid_info::keys, mht_valhash(), sm_component::next, NO_ERROR, NULL, sm_attribute::offset, pr_clear_value(), pr_clone_value(), tp_domain::precision, sm_attribute::properties, tp_domain::scale, set_create_sequence(), set_put_element(), SM_ATTFLAG_VID, SM_PROPERTY_VID_KEY, ws_mop_table_entry::tail, TM_TRAN_READ_FETCH_VERSION, sm_attribute::type, vid_fetch_instance(), ws_check_hash_link(), ws_find(), ws_insert_mop_on_hash_link(), ws_Mop_table_size, and WS_VID_INFO.
Referenced by vid_att_in_obj_id(), and vid_flush_and_rehash().
void ws_release_instance | ( | MOP | mop | ) |
Definition at line 1565 of file work_space.c.
References NULL, and db_object::released.
Referenced by insert_meth_instance(), ldr_reset_context(), and ws_release_user_instance().
void ws_release_user_instance | ( | MOP | mop | ) |
Definition at line 1579 of file work_space.c.
References db_object::class_mop, db_is_system_class(), and ws_release_instance().
Referenced by la_apply_insert_log(), la_apply_update_log(), and la_create_repl_filter().
Definition at line 5182 of file work_space.c.
References db_ws_free(), db_object::label_value_list, ws_value_list::next, NULL, and ws_value_list::val.
Referenced by pt_associate_label_with_value(), and pt_free_label().
void ws_remove_resident_class | ( | MOP | classop | ) |
Definition at line 1277 of file work_space.c.
References ml_remove(), sm_Root_class_mop, and ws_disconnect_deleted_instances().
Referenced by sm_delete_class_mop(), and ws_cull_mops().
void ws_restore_pin | ( | MOP | obj, |
int | opin, | ||
int | cpin | ||
) |
Definition at line 3052 of file work_space.c.
References db_object::class_mop, NULL, and db_object::pinned.
Referenced by ldr_restore_pin_and_drop_obj(), obj_get_att(), and obj_set_att().
Definition at line 1997 of file work_space.c.
References add_class_object(), and db_object::class_mop.
Referenced by locator_lock_class_of_instance().
void ws_set_deleted | ( | MOP | mop | ) |
Definition at line 5051 of file work_space.c.
References db_object::deleted, and WS_PUT_COMMIT_MOP.
int ws_set_ignore_error_list_for_mflush | ( | int | error_count, |
int * | error_list | ||
) |
Definition at line 4927 of file work_space.c.
References NO_ERROR, ws_Error_ignore_count, and ws_Error_ignore_list.
Referenced by er_filter_fileset().
Definition at line 2954 of file work_space.c.
References ARG_FILE_LINE, db_object::class_mop, er_print_callstack(), db_object::lock, NULL, db_object::object, prm_get_bool_value(), PRM_ID_CLIENT_CLASS_CACHE_DEBUG, sm_ch_name(), sm_Root_class_mop, ws_oid(), and WS_SET_LOCK.
Referenced by btree_load_index(), locator_add_class(), locator_add_instance(), locator_add_root(), locator_cache(), locator_cache_lock(), locator_cache_lock_lockhint_classes(), locator_cache_lock_set(), locator_cache_not_have_object(), locator_cache_object_class(), locator_cache_object_instance(), locator_decache_lock(), locator_demote_class_lock(), locator_keep_mops(), locator_lock_and_doesexist(), locator_lock_class_of_instance(), locator_lock_set(), vid_build_non_upd_object(), vid_build_virtual_mop(), and vid_decache_instance().
void ws_set_mop_fetched_with_current_snapshot | ( | MOP | mop | ) |
Definition at line 5013 of file work_space.c.
References db_object::mvcc_snapshot_version, and ws_MVCC_snapshot_version.
Referenced by locator_cache_have_object(), locator_cache_lock(), and locator_cache_lock_set().
void ws_set_repl_error_into_error_link | ( | LC_COPYAREA_ONEOBJ * | obj, |
char * | content_ptr | ||
) |
Definition at line 4944 of file work_space.c.
References ARG_FILE_LINE, ws_repl_flush_err::class_oid, lc_copyarea_oneobj::class_oid, ER_ERROR_SEVERITY, ER_OUT_OF_VIRTUAL_MEMORY, er_set(), ws_repl_flush_err::error_code, ws_repl_flush_err::error_link, ws_repl_flush_err::error_msg, NULL, ws_repl_flush_err::operation, lc_copyarea_oneobj::operation, or_unpack_int(), or_unpack_mem_value(), or_unpack_string_alloc(), ws_repl_flush_err::pkey_value, and ws_Repl_error_link.
Referenced by locator_repl_mflush_check_error().
void ws_unhide_new_old_trigger_obj | ( | MOP | op | ) |
Definition at line 3800 of file work_space.c.
References db_object::is_temp, db_object::is_vid, db_object::pinned, and WS_SET_DIRTY.
Referenced by pt_exec_trigger_stmt().
|
static |
Definition at line 1342 of file work_space.c.
References assert, db_object::commit_link, tr_schema_cache::next, NULL, and ws_Commit_mops.
Referenced by ws_cull_mops(), and ws_free_mop().
Definition at line 1154 of file work_space.c.
References ARG_FILE_LINE, assert, COPY_OID, ER_ERROR_SEVERITY, er_set(), ER_WS_MOP_NOT_FOUND, db_object::hash_link, ws_mop_table_entry::head, NO_ERROR, NULL, OID_PSEUDO_KEY, ws_mop_table_entry::tail, ws_check_hash_link(), ws_insert_mop_on_hash_link(), ws_Mop_table_size, WS_OID, and WS_REAL_OID.
Referenced by locator_assign_oidset(), locator_assign_permanent_oid(), and ws_update_oid_and_class().
Definition at line 1096 of file work_space.c.
References add_class_object(), assert, au_fetch_class_force(), AU_FETCH_READ, db_object::class_mop, ER_FAILED, error(), NO_ERROR, NULL, db_object::object, OID_EQ, remove_class_object(), ws_class_mop(), ws_mop(), WS_OID, and ws_update_oid().
Referenced by locator_mflush_force().
Definition at line 754 of file work_space.c.
References add_class_object(), ARG_FILE_LINE, assert, db_object::class_mop, db_value::data, db_get_object(), db_is_vclass(), db_make_null(), db_make_object(), db_real_instance(), DB_TYPE_OBJECT, DB_TYPE_OID, DB_VALUE_DOMAIN_TYPE, ER_ERROR_SEVERITY, ER_OUT_OF_VIRTUAL_MEMORY, er_set(), vid_info::flags, db_object::hash_link, db_object::is_vid, vid_info::keys, mht_valhash(), mq_fetch_one_real_class(), NO_ERROR, NULL, db_data::oid, pr_clone_value(), tp_value_equal(), VID_NEW, ws_check_hash_link(), ws_free_mop(), ws_insert_mop_on_hash_link(), ws_make_mop(), ws_mop(), ws_Mop_table_size, and WS_VID_INFO.
Referenced by vid_build_virtual_mop(), vid_fetch_instance(), and vid_vobj_to_object().
Definition at line 137 of file work_space.c.
unsigned int db_on_server |
Definition at line 91 of file network_interface_cl.c.
Referenced by ws_pin().
|
static |
Definition at line 128 of file work_space.c.
Referenced by add_class_object(), ws_disconnect_deleted_instances(), ws_has_dirty_objects(), ws_map_class_dirty(), and ws_map_dirty_internal().
Definition at line 144 of file work_space.c.
Definition at line 70 of file work_space.c.
Referenced by ws_abort_mops(), ws_clear_all_hints(), and ws_unlink_from_commit_mops_list().
|
static |
Definition at line 116 of file work_space.c.
Referenced by ws_final(), ws_has_updated(), ws_init(), and ws_map_dirty_internal().
int ws_Error_ignore_count = 0 |
Definition at line 161 of file work_space.c.
Referenced by locator_mflush_force(), and ws_set_ignore_error_list_for_mflush().
int ws_Error_ignore_list[-ER_LAST_ERROR] |
Definition at line 160 of file work_space.c.
Referenced by locator_mflush_force(), and ws_set_ignore_error_list_for_mflush().
WS_MOP_TABLE_ENTRY* ws_Mop_table = NULL |
Definition at line 79 of file work_space.c.
unsigned int ws_Mop_table_size = 0 |
Definition at line 86 of file work_space.c.
Referenced by ws_class_has_cached_objects(), ws_clear_internal(), ws_cull_mops(), ws_decache_allxlockmops_but_norealclasses(), ws_dump(), ws_examine_no_mop_has_cached_lock(), ws_final(), ws_init(), ws_mop(), ws_mop_if_exists(), ws_new_mop(), ws_rehash_vmop(), ws_update_oid(), and ws_vmop().
|
static |
Definition at line 152 of file work_space.c.
Referenced by ws_get_mvcc_snapshot_version(), ws_increment_mvcc_snapshot_version(), ws_is_mop_fetched_with_current_snapshot(), and ws_set_mop_fetched_with_current_snapshot().
int ws_Num_dirty_mop = 0 |
Definition at line 107 of file work_space.c.
Referenced by ws_abort_mops(), ws_clear_all_hints(), ws_map_dirty_internal(), and ws_need_flush().
|
static |
Definition at line 165 of file work_space.c.
Referenced by ws_get_repl_error_from_error_link(), and ws_set_repl_error_into_error_link().
|
static |
Definition at line 167 of file work_space.c.
DB_OBJLIST* ws_Resident_classes = NULL |
Definition at line 97 of file work_space.c.
Referenced by sm_free_resident_classes_virtual_query_cache(), sm_update_all_statistics(), and vid_allflush().
WS_STATISTICS ws_Stats = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } |
Definition at line 105 of file work_space.c.