【问题标题】:apache geode 9.0.3 off heap region, xml configurationapache geode 9.0.3 off heap region,xml配置
【发布时间】:2017-09-26 17:16:54
【问题描述】:

如何通过 xml 配置将区域声明为堆外 使用 apache geode 9.0.3

我的 xml 配置在 server-cache.xml 中。

<!DOCTYPE cache PUBLIC
 "-//GemStone Systems, Inc.//GemFire Declarative Caching 8.0//EN"
 "http://www.gemstone.com/dtd/cache8_0.dtd">
  <cache>

   <region name="regionA">
      <region-attributes off-heap="true"/>
      <region-attributes data-policy="partition"/>
   </region>

 </cache>

我收到此错误

org.apache.geode.cache.CacheXmlException: While reading Cache XML file:/server-cache.xml. Error while parsing XML, caused by org.xml.sax.SAXParseException; lineNumber: 14; columnNumber: 43; Attribute "off-heap" must be declared for element type "region-attributes".

我读过这个

通过将堆外区域属性设置为 true 来标记其条目值应在堆外存储的区域 为托管同一区域的所有数据的所有成员统一配置其他区域属性。

来自 http://gemfire.docs.pivotal.io/geode/managing/heap_use/off_heap_management.html

【问题讨论】:

    标签: xml in-memory-database geode off-heap


    【解决方案1】:

    您需要为这个新属性更新您的 xml 架构

    <?xml version="1.0" encoding="UTF-8"?>
      <cache
        xmlns="http://geode.apache.org/schema/cache"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://geode.apache.org/schema/cache 
        http://geode.apache.org/schema/cache/cache-1.0.xsd"
        version="1.0">
    
      <region name="regionA">
        <region-attributes off-heap="true"/>
        <region-attributes data-policy="partition"/>
      </region>
    </xml>
    

    尽管如此,堆外属性仍然没有被拾取。我为此提交了 Geode JIRA:https://issues.apache.org/jira/browse/GEODE-2841

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2019-02-01
      • 1970-01-01
      • 2018-07-11
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多