如何使用apache geode 9.0.3通过xml配置声明一个脱离堆的区域
我的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
发布于 2017-04-29 01:42:53
您需要为这个新属性更新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
https://stackoverflow.com/questions/43682707
复制相似问题