You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@geode.apache.org by db...@apache.org on 2019/01/25 22:13:21 UTC

[geode] branch develop updated: GEODE-6319: User Guide - Clarify that partitioned regions can be crea… (#3119)

This is an automated email from the ASF dual-hosted git repository.

dbarnes pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/geode.git


The following commit(s) were added to refs/heads/develop by this push:
     new 9ae352c  GEODE-6319: User Guide - Clarify that partitioned regions can be crea… (#3119)
9ae352c is described below

commit 9ae352c34226080a6983a107298bdb2bf8e33c26
Author: Dave Barnes <db...@pivotal.io>
AuthorDate: Fri Jan 25 14:12:38 2019 -0800

    GEODE-6319: User Guide - Clarify that partitioned regions can be crea… (#3119)
    
    * GEODE-6319: User Guide - Clarify that partitioned regions can be created dynamically, Note that DynamicRegionFactory is deprecated
---
 .../region_options/dynamic_region_creation.html.md.erb    | 15 +++++++++------
 geode-docs/reference/topics/cache_xml.html.md.erb         |  6 ++++--
 2 files changed, 13 insertions(+), 8 deletions(-)

diff --git a/geode-docs/developing/region_options/dynamic_region_creation.html.md.erb b/geode-docs/developing/region_options/dynamic_region_creation.html.md.erb
index 8f3f467..fd88b72 100644
--- a/geode-docs/developing/region_options/dynamic_region_creation.html.md.erb
+++ b/geode-docs/developing/region_options/dynamic_region_creation.html.md.erb
@@ -21,15 +21,18 @@ limitations under the License.
 
 You can dynamically create regions in your application code and automatically instantiate them on members of a cluster.
 
-If your application does not require partitioned regions, you can use the <span class="keyword apiname">org.apache.geode.cache.DynamicRegionFactory</span> class to dynamically create regions, or you can create them using the `<dynamic-region-factory>` element in the cache.xml file that defines the region. See [&lt;dynamic-region-factory&gt;](../../reference/topics/cache_xml.html#dynamic-region-factory).
-
 Due to the number of options involved, most developers use functions to create regions dynamically in their applications, as described in this topic. Dynamic regions can also be created from the `gfsh` command line.
 
-For a complete discussion of using <%=vars.product_name%> functions, see [Function Execution](../function_exec/chapter_overview.html). Functions use the <span class="keyword apiname">org.apache.geode.cache.execute.FunctionService</span> class.
+For a complete discussion of using <%=vars.product_name%> functions, see [Function Execution](../function_exec/chapter_overview.html). Functions use the `org.apache.geode.cache.execute.FunctionService` class.
+
+If your application does not require partitioned regions, you can use the `org.apache.geode.cache.DynamicRegionFactory` class to dynamically create regions, or
+you can create them using the `<dynamic-region-factory>` element in the cache.xml file that defines the region.
+(You can create partitioned regions dynamically, but you cannot use the `DynamicRegionFactory` class or the
+`<dynamic-region-factory>` element to do it.)
 
-For example, the following Java classes define and use a function for dynamic region creation:
+**Note:** Use of the `DynamicRegionFactory` class (and the `<dynamic-region-factory>` element) are deprecated in favor of the `FunctionService` approach described here.
 
-The <span class="keyword apiname">CreateRegionFunction</span> class defines a function invoked on a server by a client using the <span class="keyword apiname">onServer()</span> method of the <span class="keyword apiname">FunctionService</span> class. This function call initiates region creation by putting an entry into the region attributes metadata region. The entry key is the region name and the value is the set of region attributes used to create the region.
+In the following example, the `CreateRegionFunction` class defines a function invoked on a server by a client using the `onServer()` method of the `FunctionService` class. This function call initiates region creation by putting an entry into the region attributes metadata region. The entry key is the region name and the value is the set of region attributes used to create the region.
 
 ``` pre
 #CreateRegionFunction.java
@@ -132,7 +135,7 @@ public class CreateRegionFunction implements Function, Declarable {
 }
 ```
 
-The <span class="keyword apiname">CreateRegionCacheListener</span> class is a cache listener that implements two methods, <span class="keyword apiname">afterCreate()</span> and <span class="keyword apiname">afterRegionCreate()</span>. The <span class="keyword apiname">afterCreate()</span> method creates the region. The <span class="keyword apiname">afterRegionCreate()</span> method causes each new server to create all the regions defined in the metadata region.
+The `CreateRegionCacheListener` class is a cache listener that implements two methods, `afterCreate()` and `afterRegionCreate()`. The `afterCreate()` method creates the region. The `afterRegionCreate()` method causes each new server to create all the regions defined in the metadata region.
 
 ``` pre
 #CreateRegionCacheListener.java
diff --git a/geode-docs/reference/topics/cache_xml.html.md.erb b/geode-docs/reference/topics/cache_xml.html.md.erb
index a1e3f6c..eb2e1b7 100644
--- a/geode-docs/reference/topics/cache_xml.html.md.erb
+++ b/geode-docs/reference/topics/cache_xml.html.md.erb
@@ -138,10 +138,12 @@ Specify the Java class and its initialization parameters with the `<class-name>`
 
 ## <a id="dynamic-region-factory" class="no-quick-link"></a>&lt;dynamic-region-factory&gt;
 
-The `<dynamic-region-factory>` element configures a dynamic region factory for this cache. You can use this element to dynamically create regions in your application code. Use the <span class="keyword apiname">createDynamicRegion()</span> method of the <span class="keyword apiname">org.apache.geode.cache.DynamicRegionFactory</span> class in your Java code to dynamically create regions.
+The `<dynamic-region-factory>` element configures a dynamic region factory for this cache. You can use this element to dynamically create regions in your application code. Use the `createDynamicRegion()` method of the `org.apache.geode.cache.DynamicRegionFactory` class in your Java code to dynamically create regions.
 
 **Note:**
-You can not use this element to dynamically create *partitioned* regions.
+You cannot use this element to dynamically create *partitioned* regions.
+
+**Note:** Use of the `DynamicRegionFactory` class and the `<dynamic-region-factory>` element are deprecated in favor of the `org.apache.geode.cache.execute.FunctionService` class and the [`<function-service>`](#function-service) element.
 
 We recommend that you use functions to dynamically create regions. See [Creating Regions Dynamically](../../developing/region_options/dynamic_region_creation.html).