From e0fbf362e7dbf82efaca7c082aec3babf92dbeb5 Mon Sep 17 00:00:00 2001 From: Cylance <11178036+cylance@user.noreply.gitee.com> Date: Thu, 22 May 2025 09:56:01 +0800 Subject: [PATCH] modify shared_dictionary_cache.cc --- sql/dd/impl/cache/shared_dictionary_cache.cc | 35 ++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/sql/dd/impl/cache/shared_dictionary_cache.cc b/sql/dd/impl/cache/shared_dictionary_cache.cc index ec58095d8..ad5a2f022 100644 --- a/sql/dd/impl/cache/shared_dictionary_cache.cc +++ b/sql/dd/impl/cache/shared_dictionary_cache.cc @@ -58,6 +58,9 @@ void Shared_dictionary_cache::init() { spatial_reference_system_capacity); instance()->m_map()->set_capacity(tablespace_def_size); instance()->m_map()->set_capacity(resource_group_capacity); +#ifdef HAVE_ZSQL_ORA_PROFILE + instance()->m_map()->set_capacity(ora_profile_info_capacity); +#endif //HAVE_ZSQL_ORA_PROFILE } void Shared_dictionary_cache::shutdown() { @@ -71,6 +74,9 @@ void Shared_dictionary_cache::shutdown() { instance()->m_map()->shutdown(); instance()->m_map()->shutdown(); instance()->m_map()->shutdown(); +#ifdef HAVE_ZSQL_ORA_PROFILE + instance()->m_map()->shutdown(); +#endif //HAVE_ZSQL_ORA_PROFILE } // Don't call this function anywhere except upgrade scenario. @@ -340,5 +346,34 @@ Shared_dictionary_cache::get_uncached( const Resource_group **) const; template void Shared_dictionary_cache::put( const Resource_group *, Cache_element **); + +#ifdef HAVE_ZSQL_ORA_PROFILE +template bool +Shared_dictionary_cache::get( + THD *thd, const Ora_profile_info::Id_key &, + Cache_element **); +template bool +Shared_dictionary_cache::get( + THD *thd, const Ora_profile_info::Name_key &, + Cache_element **); +template bool +Shared_dictionary_cache::get( + THD *thd, const Ora_profile_info::Aux_key &, + Cache_element **); +template bool Shared_dictionary_cache::get_uncached( + THD *thd, const Ora_profile_info::Id_key &, enum_tx_isolation, + const Ora_profile_info **) const; +template bool Shared_dictionary_cache::get_uncached( + THD *thd, const Ora_profile_info::Name_key &, enum_tx_isolation, + const Ora_profile_info **) const; +template bool Shared_dictionary_cache::get_uncached( + THD *thd, const Ora_profile_info::Aux_key &, enum_tx_isolation, + const Ora_profile_info **) const; +template void Shared_dictionary_cache::put( + const Ora_profile_info *, Cache_element **); +#endif // HAVE_ZSQL_ORA_PROFILE } // namespace cache } // namespace dd -- Gitee