geode-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (GEODE-1897) Users should be able to configure eviction through gfsh
Date Wed, 29 Nov 2017 17:52:00 GMT

    [ https://issues.apache.org/jira/browse/GEODE-1897?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16271218#comment-16271218
] 

ASF GitHub Bot commented on GEODE-1897:
---------------------------------------

karensmolermiller commented on a change in pull request #1098: GEODE-1897 Docs:  configure
eviction through gfsh
URL: https://github.com/apache/geode/pull/1098#discussion_r153864555
 
 

 ##########
 File path: geode-docs/developing/eviction/configuring_data_eviction.html.md.erb
 ##########
 @@ -38,51 +38,26 @@ Configure data eviction as follows. You do not need to perform these
steps in th
 3.  Decide the maximum amount of data to allow in the member for the eviction measurement
indicated. This is the maximum for all storage for the region in the member. For partitioned
regions, this is the total for all buckets stored in the member for the region - including
any secondary buckets used for redundancy.
 4.  Decide whether to program a custom sizer for your region. If you are able to provide
such a class, it might be faster than the standard sizing done by <%=vars.product_name%>.
Your custom class must follow the guidelines for defining custom classes and, additionally,
must implement `org.apache.geode.cache.util.ObjectSizer`. See [Requirements for Using Custom
Classes in Data Caching](../../basic_config/data_entries_custom_classes/using_custom_classes.html).
 
-**Note:**
-You can also configure Regions using the gfsh command-line interface, however, you cannot
configure `eviction-attributes` using gfsh. See [Region Commands](../../tools_modules/gfsh/quick_ref_commands_by_area.html#topic_EF03119A40EE492984F3B6248596E1DD)
and [Disk Store Commands](../../tools_modules/gfsh/quick_ref_commands_by_area.html#topic_1ACC91B493EE446E89EC7DBFBBAE00EA).
-
-Examples:
-
-``` pre
-// Create an LRU memory eviction controller with max bytes of 1000 MB
-// Use a custom class for measuring the size of each object in the region 
-<region-attributes refid="REPLICATE"> 
-  <eviction-attributes> 
-    <lru-memory-size maximum="1000" action="overflow-to-disk"> 
-      <class-name>com.myLib.MySizer</class-name> 
-      <parameter name="name"> 
-        <string>Super Sizer</string> 
-      </parameter> 
-    </lru-memory-size> 
-  </eviction-attributes> 
-  </region-attributes>
-```
+**Examples:**
 
-``` pre
-// Create a memory eviction controller on a partitioned region with max bytes of 512 MB
-<region name="demoPR">
-  <region-attributes refid="PARTITION">
-    <partition-attributes local-max-memory="512" total-num-buckets="13"/>
-    <eviction-attributes>
-       <lru-memory-size action="local-destroy"/>
-       <class-name>org.apache.geode.cache.util.ObjectSizer
-       </class-name>
-    </eviction-attributes>
-  </region-attributes>
-</region>
-            
-```
+Create an LRU memory eviction controller with a maximum limit of 1000 MB. Use a custom class
for measuring the size of each object in the region:
 
-``` pre
-// Configure a partitioned region for heap LRU eviction. The resource manager controls the
limits. 
-<region-attributes refid="PARTITION_HEAP_LRU"> 
-</region-attributes>
 ```
+gfsh>create region --type=REPLICATE --eviction-max-memory=1000 \
 
 Review comment:
   The region name must be specified for the create region command.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


> Users should be able to configure eviction through gfsh
> -------------------------------------------------------
>
>                 Key: GEODE-1897
>                 URL: https://issues.apache.org/jira/browse/GEODE-1897
>             Project: Geode
>          Issue Type: Sub-task
>          Components: docs, gfsh
>            Reporter: Swapnil Bawaskar
>            Assignee: Dave Barnes
>             Fix For: 1.4.0
>
>
> While creating a region in gfsh, users should be able to configure eviction for that
region.
> All three modes of eviction should be supported:
> 1. Eviction driven by the resource manager:
> {noformat}
> gfsh>create region --name=myRegion --type=REPLICATE --eviction-enabled
> {noformat}
> 2. eviction driven by entry count in the region:
> {noformat}
> gfsh>create region --name=myRegion --type=REPLICATE --eviction-entry-count=1000
> {noformat}
> 3. eviction driven by bytes used:
> {noformat}
> gfsh>create region --name=myRegion --type=REPLICATE --eviction-max-memory=100
> (value in megabytes)
> {noformat}
> And also specify the eviction action as
> {noformat}
> --eviction-action=overflow-to-disk or
> --eviction-action=local-destroy
> {noformat}
> and an object sizer, so that users can plug-in custom object sizes as
> {noformat}
> --eviction-object-sizer=my.company.geode.MySizer
> {noformat}
> the sizer should only apply to heap and memory based eviction.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message