geode-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Wes Williams (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (GEODE-3949) gfsh> put fails immediately after server startup
Date Fri, 03 Nov 2017 16:14:00 GMT

     [ https://issues.apache.org/jira/browse/GEODE-3949?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Wes Williams updated GEODE-3949:
--------------------------------
    Description: 
A bug was introduced since GemFire 8.2 where regions are not available immediately after server
startup. 
*GIVEN* a server that just started with a region that is defined in cache.xml, 
*THEN* following "put"  fails when run from a linux bash script:

gfsh <<!

start locator --name=locator --properties-file=config/locator.properties --port=10334 --J=-Xms256m
--J=-Xmx256m

start server --name=server1 --locators=localhost[10334] --J=-Xms512m --J=-Xmx512m --cache-xml-file=config/cache.xml
--properties-file=config/gemfire.properties

put --key='1' --value='A' --region=departments;  *{color:red}<==  FAIL {color}*
Result      : false
Message     : Region <departments> not found in any of the members *{color:red}<==
 NOT FOUND?? {color}*

gfsh>list regions;
List of regions
---------------
departments   *{color:red}<==  BUT IT IS FOUND {color}*

exit;
!

However, inserting a 1-second pause after server startup, the put succeeds:

{{gfsh <<!

start locator --name=locator --properties-file=config/locator.properties --port=$LOCATOR_PORT
--J=-Xms256m --J=-Xmx256m

configure pdx --portable-auto-serializable-classes=".*"

start server --name=server1 --locators=localhost[10334] --J=-Xms512m --J=-Xmx512m --cache-xml-file=config/cache.xml
--properties-file=config/gemfire.properties 

exit;
!

sleep 1

gfsh <<!

connect

put --key='1' --value='A' --region=departments;

}}

*TO REPRODUCE:*
*Run this with GemFire 9.1.x:*
{{#!/bin/bash

rm locator/*.dat

gfsh <<!

start locator --name=locator --J=-Xms256m --J=-Xmx256m

start server --name=server1 --locators=localhost[10334] --J=-Xms512m --J=-Xmx512m --cache-xml-file=cache.xml

put --key='1' --value='A' --region=departments;
list regions

exit;
!}}



*Here's a basic cache.xml:*
{{<?xml version="1.0"?>
<!DOCTYPE cache PUBLIC
    "-//GemStone Systems, Inc.//GemFire Declarative Caching 8.0//EN"
    "http://www.gemstone.com/dtd/cache8_0.dtd">

<cache>
   <region name="departments">
        <region-attributes data-policy="replicate">
         </region-attributes>
    </region>

</cache>}}


  was:
A bug was introduced since GemFire 8.2 where regions are not available immediately after server
startup. 
*GIVEN* a server that just started with a region that is defined in cache.xml, 
*THEN* following "put"  fails when run from a linux bash script:

gfsh <<!

start locator --name=locator --properties-file=config/locator.properties --port=10334 --J=-Xms256m
--J=-Xmx256m

start server --name=server1 --locators=localhost[10334] --J=-Xms512m --J=-Xmx512m --cache-xml-file=config/cache.xml
--properties-file=config/gemfire.properties

put --key='1' --value='A' --region=departments;  *{color:red}<==  FAIL {color}*
Result      : false
Message     : Region <departments> not found in any of the members *{color:red}<==
 NOT FOUND?? {color}*

gfsh>list regions;
List of regions
---------------
departments   *{color:red}<==  BUT IT IS FOUND {color}*

exit;
!

However, inserting a 1-second pause after server startup, the put succeeds:

{{gfsh <<!

start locator --name=locator --properties-file=config/locator.properties --port=$LOCATOR_PORT
--J=-Xms256m --J=-Xmx256m

configure pdx --portable-auto-serializable-classes=".*"

start server --name=server1 --locators=localhost[10334] --J=-Xms512m --J=-Xmx512m --cache-xml-file=config/cache.xml
--properties-file=config/gemfire.properties 

exit;
!

sleep 1

gfsh <<!

connect

put --key='1' --value='A' --region=departments;

}}

*TO REPRODUCE:*
Run this with GemFire 9.1.x:
{{#!/bin/bash

rm locator/*.dat

gfsh <<!

start locator --name=locator --J=-Xms256m --J=-Xmx256m

start server --name=server1 --locators=localhost[10334] --J=-Xms512m --J=-Xmx512m --cache-xml-file=cache.xml

put --key='1' --value='A' --region=departments;
list regions

exit;
!}}



Here's a basic cache.xml:
{{<?xml version="1.0"?>
<!DOCTYPE cache PUBLIC
    "-//GemStone Systems, Inc.//GemFire Declarative Caching 8.0//EN"
    "http://www.gemstone.com/dtd/cache8_0.dtd">

<cache>
   <region name="departments">
        <region-attributes data-policy="replicate">
         </region-attributes>
    </region>

</cache>}}



> gfsh> put fails immediately after server startup
> ------------------------------------------------
>
>                 Key: GEODE-3949
>                 URL: https://issues.apache.org/jira/browse/GEODE-3949
>             Project: Geode
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 1.3.0
>            Reporter: Wes Williams
>            Priority: Major
>             Fix For: 1.4.0
>
>
> A bug was introduced since GemFire 8.2 where regions are not available immediately after
server startup. 
> *GIVEN* a server that just started with a region that is defined in cache.xml, 
> *THEN* following "put"  fails when run from a linux bash script:
> gfsh <<!
> start locator --name=locator --properties-file=config/locator.properties --port=10334
--J=-Xms256m --J=-Xmx256m
> start server --name=server1 --locators=localhost[10334] --J=-Xms512m --J=-Xmx512m --cache-xml-file=config/cache.xml
--properties-file=config/gemfire.properties
> put --key='1' --value='A' --region=departments;  *{color:red}<==  FAIL {color}*
> Result      : false
> Message     : Region <departments> not found in any of the members *{color:red}<==
 NOT FOUND?? {color}*
> gfsh>list regions;
> List of regions
> ---------------
> departments   *{color:red}<==  BUT IT IS FOUND {color}*
> exit;
> !
> However, inserting a 1-second pause after server startup, the put succeeds:
> {{gfsh <<!
> start locator --name=locator --properties-file=config/locator.properties --port=$LOCATOR_PORT
--J=-Xms256m --J=-Xmx256m
> configure pdx --portable-auto-serializable-classes=".*"
> start server --name=server1 --locators=localhost[10334] --J=-Xms512m --J=-Xmx512m --cache-xml-file=config/cache.xml
--properties-file=config/gemfire.properties 
> exit;
> !
> sleep 1
> gfsh <<!
> connect
> put --key='1' --value='A' --region=departments;
> }}
> *TO REPRODUCE:*
> *Run this with GemFire 9.1.x:*
> {{#!/bin/bash
> rm locator/*.dat
> gfsh <<!
> start locator --name=locator --J=-Xms256m --J=-Xmx256m
> start server --name=server1 --locators=localhost[10334] --J=-Xms512m --J=-Xmx512m --cache-xml-file=cache.xml
> put --key='1' --value='A' --region=departments;
> list regions
> exit;
> !}}
> *Here's a basic cache.xml:*
> {{<?xml version="1.0"?>
> <!DOCTYPE cache PUBLIC
>     "-//GemStone Systems, Inc.//GemFire Declarative Caching 8.0//EN"
>     "http://www.gemstone.com/dtd/cache8_0.dtd">
> <cache>
>    <region name="departments">
>         <region-attributes data-policy="replicate">
>          </region-attributes>
>     </region>
> </cache>}}



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

Mime
View raw message