[to #53220315] add debug info for opaque memory used

This commit is contained in:
obdev 2024-02-08 04:15:17 +00:00 committed by ob-robot
parent 98ff4df9b3
commit 35d5e90049
2 changed files with 10 additions and 1 deletions

View File

@ -4500,6 +4500,15 @@ int64_t ObPLAssocArray::get_last()
return last_;
}
ObIAllocator& ObPLOpaque::get_allocator()
{
int ret = OB_SUCCESS;
if (allocator_.used() > 1024 * 1024 * 512) {
LOG_ERROR("opaque allocator hold too much memory", K(allocator_.used()));
}
return allocator_;
}
int ObPLOpaque::deep_copy(ObPLOpaque *dst)
{
int ret = OB_SUCCESS;

View File

@ -1206,7 +1206,7 @@ public:
inline bool is_xmltype() const { return ObPLOpaqueType::PL_XML_TYPE == type_; }
inline bool is_json_type() const { return ObPLOpaqueType::PL_JSON_TYPE == type_; }
inline ObIAllocator& get_allocator() { return allocator_; }
ObIAllocator& get_allocator(); // { return allocator_; }
virtual int deep_copy(ObPLOpaque *dst);