此内容没有您所选择的语言版本。

9.7. Large Objects (LOBs)


Large Objects (LOBs) consist of data. The three main large object runtime data types used by JBoss are:
  1. Binary (BLOB)
    • Contains multimedia objects such as images and audio.
  2. Character (CLOB)
    • Contains ASCII characters.
  3. Extensible Markup Language (XML)
    • Contains textual data.
LOBs and JBoss

The JBoss Data Services Connector API returns a reference to the LOB if allowed by the JBoss Data Services server. The JBoss Data Services server or JDBC driver can then access the data via a stream rather than retrieving the data all at once. This is useful for several reasons:

  • Reduces memory usage when returning the result set to the user.
  • Improves performance by passing less data in the result set.
  • Enables access to LOBs when required rather than assuming that users will always use the LOB data.
  • Enables handling of arbitrarily large data values within a fixed JBoss Data Services memory usage.
These benefits are achieved if the Connector itself does not materialize an entire LOB all at once. For example, the JDBC API supports a streaming interface for BLOB and CLOB data.
Source LOB values are typically accessed by reference, rather than having the value copied to a temporary location. Care must be taken to ensure that source LOBs are returned in a memory-safe manner.
LOBs are broken into pieces when being created and streamed. The size of each piece when fetched by the client can be configured.
Cached lobs will be copied rather than relying on the reference to the source lob.
Temporary lobs created by Teiid will be cleaned up when the result set or statement is closed. To rely on implicit garbage collection based cleanup instead of statement close, the Teiid session variable clean_lobs_onclose can be set to false (by issuing the query "SELECT teiid_session_set('clean_lobs_onclose', false)" - which can be done for example via the new connection sql in the datasource definition). This can be used for local client scenarios that relied on the implicit behavior, such as Designer generated REST VDBs.
返回顶部
Red Hat logoGithubredditYoutubeTwitter

学习

尝试、购买和销售

社区

关于红帽文档

通过我们的产品和服务,以及可以信赖的内容,帮助红帽用户创新并实现他们的目标。 了解我们当前的更新.

让开源更具包容性

红帽致力于替换我们的代码、文档和 Web 属性中存在问题的语言。欲了解更多详情,请参阅红帽博客.

關於紅帽

我们提供强化的解决方案,使企业能够更轻松地跨平台和环境(从核心数据中心到网络边缘)工作。

Theme

© 2025 Red Hat