[geode-examples] branch develop updated: Adds AuthInitialize example.
This is an automated email from the ASF dual-hosted git repository. jbarrett pushed a commit to branch develop in repository https://gitbox.apache.org/repos/asf/geode-examples.git The following commit(s) were added to refs/heads/develop by this push: new 2c69c57 Adds AuthInitialize example. 2c69c57 is described below commit 2c69c575e31f6216fa885b9052d90adce6d7e8ae Author: Jacob Barrett AuthorDate: Thu Oct 19 05:04:53 2017 + Adds AuthInitialize example. --- .../Apache.Geode.Examples.AuthInitialize.csproj| 62 ++ .../ExampleAuthInitialize.cs | 31 +++ .../Program.cs | 34 .../README.md | 14 - .../dotnet/Apache.Geode.Examples.Cache/Program.cs | 5 +- .../dotnet/Apache.Geode.Examples.Cache/README.md | 8 +++ native/dotnet/Apache.Geode.Examples.sln| 14 - native/dotnet/README.md| 3 +- 8 files changed, 166 insertions(+), 5 deletions(-) diff --git a/native/dotnet/Apache.Geode.Examples.AuthInitialize/Apache.Geode.Examples.AuthInitialize.csproj b/native/dotnet/Apache.Geode.Examples.AuthInitialize/Apache.Geode.Examples.AuthInitialize.csproj new file mode 100644 index 000..f95ca2c --- /dev/null +++ b/native/dotnet/Apache.Geode.Examples.AuthInitialize/Apache.Geode.Examples.AuthInitialize.csproj @@ -0,0 +1,62 @@ + +http://schemas.microsoft.com/developer/msbuild/2003";> + + +Debug +AnyCPU +{047FC72E-F06D-4F3A-9EF3-B66FAE4B6C36} +Exe +Properties +Apache.Geode.Examples.AuthInitialize +Apache.Geode.Examples.AuthInitialize +v4.5.2 +512 +true + + +true +bin\x64\Debug\ +DEBUG;TRACE +full +x64 +prompt +MinimumRecommendedRules.ruleset +true + + +bin\x64\Release\ +TRACE +true +pdbonly +x64 +prompt +MinimumRecommendedRules.ruleset +true + + + + Y:\build64\clicache\src\Debug\Apache.Geode.dll + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/native/dotnet/Apache.Geode.Examples.AuthInitialize/ExampleAuthInitialize.cs b/native/dotnet/Apache.Geode.Examples.AuthInitialize/ExampleAuthInitialize.cs new file mode 100644 index 000..583ac23 --- /dev/null +++ b/native/dotnet/Apache.Geode.Examples.AuthInitialize/ExampleAuthInitialize.cs @@ -0,0 +1,31 @@ +using System; +using Apache.Geode.Client; + +namespace Apache.Geode.Examples.AuthInitialize +{ + class ExampleAuthInitialize : IAuthInitialize + { +public ExampleAuthInitialize() +{ + // TODO initialize your resources here + Console.Out.WriteLine("ExampleAuthInitialize::ExampleAuthInitialize called"); +} + +public void Close() +{ + // TODO close your resources here + Console.Out.WriteLine("ExampleAuthInitialize::Close called"); +} + +public Properties GetCredentials(Properties props, string server) +{ + // TODO get your username and password + Console.Out.WriteLine("ExampleAuthInitialize::GetCredentials called"); + + var credentials = new Properties(); + credentials.Insert("username", "john"); + credentials.Insert("password", "secret"); + return credentials; +} + } +} diff --git a/native/dotnet/Apache.Geode.Examples.AuthInitialize/Program.cs b/native/dotnet/Apache.Geode.Examples.AuthInitialize/Program.cs new file mode 100644 index 000..76c8772 --- /dev/null +++ b/native/dotnet/Apache.Geode.Examples.AuthInitialize/Program.cs @@ -0,0 +1,34 @@ +using System; +using Apache.Geode.Client; + +namespace Apache.Geode.Examples.AuthInitialize +{ + class Program + { +static void Main(string[] args) +{ + var cacheFactory = CacheFactory.CreateCacheFactory() + .Set("log-level", "none") + .SetAuthInitialize(new ExampleAuthInitialize()); + + var cache = cacheFactory.Create(); + var poolFactory = cache.GetPoolFactory() + .AddLocator("localhost", 10334); + poolFactory.Create("pool", cache); + var regionFactory = cache.CreateRegionFactory(RegionShortcut.PROXY) + .SetPoolName("pool"); + var region = regionFactory.Create("region"); + + region["a"] = "1"; + region["b"] = "2"; + + var a = region["a"]; + var b = region["b"]; + + Console.Out.WriteLine("a = " + a); + Console.Out.WriteLine("b = " + b); + + cache.Close(); +} + } +} diff --git a/native/dotnet/Apache.Geode.Examples.Cache/README.md b/native/dotnet/Apache.Geode.Examples.AuthInitialize/README.md similarity index 51% copy from native/dotnet/Apache.Geode.Examples.Cache/README.md copy to native/dotnet/Apache.Geode.Examples.AuthInitialize/README.md index 167eaa4..c82ae7e 100644 --- a/native/dotnet/Apache.Geode.Examples.Cache/README.md +++ b/native/dotnet/Apache.Geode.Examples.AuthInitialize/README.md @@ -1,4 +1,6 @@ -# C
[geode-examples] branch develop updated: Adds initial example for Geode Native .NET client.
This is an automated email from the ASF dual-hosted git repository. jbarrett pushed a commit to branch develop in repository https://gitbox.apache.org/repos/asf/geode-examples.git The following commit(s) were added to refs/heads/develop by this push: new 6ae1e61 Adds initial example for Geode Native .NET client. 6ae1e61 is described below commit 6ae1e617b5ee11fb949e61ccf38f710809a035da Author: Jacob Barrett AuthorDate: Thu Oct 19 04:32:47 2017 + Adds initial example for Geode Native .NET client. --- .gitignore | 5 ++ README.md | 4 ++ .../Apache.Geode.Examples.Cache.csproj | 77 ++ .../dotnet/Apache.Geode.Examples.Cache/Program.cs | 48 ++ .../dotnet/Apache.Geode.Examples.Cache/README.md | 14 native/dotnet/Apache.Geode.Examples.sln| 21 ++ native/dotnet/README.md| 13 7 files changed, 182 insertions(+) diff --git a/.gitignore b/.gitignore index fa3d887..af1018c 100644 --- a/.gitignore +++ b/.gitignore @@ -28,3 +28,8 @@ server2 *.dat *.rej *.orig + +/native/dotnet/*/bin +/native/dotnet/*/obj +/native/dotnet/.vs + diff --git a/README.md b/README.md index 46bf24e..15b4a56 100644 --- a/README.md +++ b/README.md @@ -89,6 +89,10 @@ tutorial. * Resource manager * PDX Advanced +### Native +* C++ +* [.NET](native/dotnet/README.md) + ### Use cases, integrations and external examples This section has self-contained little projects that illustrate a use case or diff --git a/native/dotnet/Apache.Geode.Examples.Cache/Apache.Geode.Examples.Cache.csproj b/native/dotnet/Apache.Geode.Examples.Cache/Apache.Geode.Examples.Cache.csproj new file mode 100644 index 000..b108c40 --- /dev/null +++ b/native/dotnet/Apache.Geode.Examples.Cache/Apache.Geode.Examples.Cache.csproj @@ -0,0 +1,77 @@ + + +http://schemas.microsoft.com/developer/msbuild/2003";> + + +Debug +AnyCPU +{15ACFB5B-0D2C-4C38-9236-7AF01874A84F} +Exe +Properties +Apache.Geode.Examples.Cache +Apache.Geode.Examples.Cache +v4.5.2 +512 +true + + +true +bin\x64\Debug\ +DEBUG;TRACE +full +x64 +prompt +MinimumRecommendedRules.ruleset +true + + +bin\x64\Release\ +TRACE +true +pdbonly +x64 +prompt +MinimumRecommendedRules.ruleset +true + + + + Y:\build64\clicache\src\Debug\Apache.Geode.dll + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/native/dotnet/Apache.Geode.Examples.Cache/Program.cs b/native/dotnet/Apache.Geode.Examples.Cache/Program.cs new file mode 100644 index 000..52aa3a8 --- /dev/null +++ b/native/dotnet/Apache.Geode.Examples.Cache/Program.cs @@ -0,0 +1,48 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +using System; +using Apache.Geode.Client; + +namespace Apache.Geode.Examples.Cache +{ + class Program + { +static void Main(string[] args) +{ + var cacheFactory = CacheFactory.CreateCacheFactory(); + var cache = cacheFactory.Create(); + + var poolFactory = cache.GetPoolFactory() + .AddLocator("localhost", 10334); + poolFactory.Create("pool", cache); + + var regionFactory = cache.CreateRegionFactory(RegionShortcut.PROXY) + .SetPoolName("pool"); + var region = regionFactory.Create("region"); + + region["a"] = "1"; + region["b"] = "2"; + + var a = region["a"]; + var b = region["b"]; + + Console.Out.WriteLine("a = " + a); + Console.Out.WriteLine("b = " + b); +} + } +} diff --git a/native/dotnet/Apache.Geode.Examples.Cache/README.md b/native/dotnet/Apache.Geode.Examples.Cache/README.md new file mode 100644 index 000..167eaa4 --- /dev/null +++ b/native/dotnet/Apache.Geode.Examples.Cache/README.md @@ -0,0 +1,14 @@ +# Cache Example + +## Prerequisits +* Install [Apache Geode](https://geode.apache.org) +* Build and install [Apache Geode Native](https://github.com/apache/geode-native) + +## Running +* Start Geode Server and create region. + ``` + gfsh>start locator --name=locator + gf
[geode-examples] branch master updated: Adds initial example for Geode Native .NET client.
This is an automated email from the ASF dual-hosted git repository. jbarrett pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/geode-examples.git The following commit(s) were added to refs/heads/master by this push: new 821a2fd Adds initial example for Geode Native .NET client. 821a2fd is described below commit 821a2fd3886eb20c8a74bef30b88715d48f69f44 Author: Jacob Barrett AuthorDate: Thu Oct 19 04:32:47 2017 + Adds initial example for Geode Native .NET client. --- .gitignore | 5 ++ README.md | 4 ++ .../Apache.Geode.Examples.Cache.csproj | 77 ++ .../dotnet/Apache.Geode.Examples.Cache/Program.cs | 48 ++ .../dotnet/Apache.Geode.Examples.Cache/README.md | 14 native/dotnet/Apache.Geode.Examples.sln| 21 ++ native/dotnet/README.md| 13 7 files changed, 182 insertions(+) diff --git a/.gitignore b/.gitignore index bc00815..b4d66f3 100644 --- a/.gitignore +++ b/.gitignore @@ -27,3 +27,8 @@ server2 *.dat *.rej *.orig + +/native/dotnet/*/bin +/native/dotnet/*/obj +/native/dotnet/.vs + diff --git a/README.md b/README.md index 1894591..77d492f 100644 --- a/README.md +++ b/README.md @@ -106,6 +106,10 @@ tutorial. * Resource manager * PDX Advanced +### Native +* C++ +* [.NET](native/dotnet/README.md) + ### Use cases, integrations and external examples This section has self-contained little projects that illustrate a use case or diff --git a/native/dotnet/Apache.Geode.Examples.Cache/Apache.Geode.Examples.Cache.csproj b/native/dotnet/Apache.Geode.Examples.Cache/Apache.Geode.Examples.Cache.csproj new file mode 100644 index 000..b108c40 --- /dev/null +++ b/native/dotnet/Apache.Geode.Examples.Cache/Apache.Geode.Examples.Cache.csproj @@ -0,0 +1,77 @@ + + +http://schemas.microsoft.com/developer/msbuild/2003";> + + +Debug +AnyCPU +{15ACFB5B-0D2C-4C38-9236-7AF01874A84F} +Exe +Properties +Apache.Geode.Examples.Cache +Apache.Geode.Examples.Cache +v4.5.2 +512 +true + + +true +bin\x64\Debug\ +DEBUG;TRACE +full +x64 +prompt +MinimumRecommendedRules.ruleset +true + + +bin\x64\Release\ +TRACE +true +pdbonly +x64 +prompt +MinimumRecommendedRules.ruleset +true + + + + Y:\build64\clicache\src\Debug\Apache.Geode.dll + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/native/dotnet/Apache.Geode.Examples.Cache/Program.cs b/native/dotnet/Apache.Geode.Examples.Cache/Program.cs new file mode 100644 index 000..52aa3a8 --- /dev/null +++ b/native/dotnet/Apache.Geode.Examples.Cache/Program.cs @@ -0,0 +1,48 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +using System; +using Apache.Geode.Client; + +namespace Apache.Geode.Examples.Cache +{ + class Program + { +static void Main(string[] args) +{ + var cacheFactory = CacheFactory.CreateCacheFactory(); + var cache = cacheFactory.Create(); + + var poolFactory = cache.GetPoolFactory() + .AddLocator("localhost", 10334); + poolFactory.Create("pool", cache); + + var regionFactory = cache.CreateRegionFactory(RegionShortcut.PROXY) + .SetPoolName("pool"); + var region = regionFactory.Create("region"); + + region["a"] = "1"; + region["b"] = "2"; + + var a = region["a"]; + var b = region["b"]; + + Console.Out.WriteLine("a = " + a); + Console.Out.WriteLine("b = " + b); +} + } +} diff --git a/native/dotnet/Apache.Geode.Examples.Cache/README.md b/native/dotnet/Apache.Geode.Examples.Cache/README.md new file mode 100644 index 000..167eaa4 --- /dev/null +++ b/native/dotnet/Apache.Geode.Examples.Cache/README.md @@ -0,0 +1,14 @@ +# Cache Example + +## Prerequisits +* Install [Apache Geode](https://geode.apache.org) +* Build and install [Apache Geode Native](https://github.com/apache/geode-native) + +## Running +* Start Geode Server and create region. + ``` + gfsh>start locator --name=locator + gf
[geode] branch develop updated: GEODE-3026: Removed the AsyncEventQueue for the Lucene index if the region isn't created
This is an automated email from the ASF dual-hosted git repository. boglesby 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 b0e0070 GEODE-3026: Removed the AsyncEventQueue for the Lucene index if the region isn't created b0e0070 is described below commit b0e0070763f42eb1744643def8af913ae41055bc Author: Barry Oglesby AuthorDate: Wed Oct 18 17:51:27 2017 -0700 GEODE-3026: Removed the AsyncEventQueue for the Lucene index if the region isn't created * GEODE-3026: Removed the AsyncEventQueue for the Lucene index if region fails to be created * GEODE-3026: Renamed RegionService to RegionCacheService * GEODE-3026: Moved RegionCacheService API to RegionListener * GEODE-3026: Updated dunit test --- .../asyncqueue/internal/AsyncEventQueueImpl.java | 6 ++ .../geode/internal/cache/GemFireCacheImpl.java | 21 +++- .../apache/geode/internal/cache/InternalCache.java | 6 ++ .../apache/geode/internal/cache/LocalRegion.java | 11 +-- .../geode/internal/cache/PartitionedRegion.java| 2 +- .../geode/internal/cache/RegionListener.java | 23 - .../apache/geode/internal/cache/RegionService.java | 30 -- .../internal/cache/xmlcache/CacheCreation.java | 15 +++ .../internal/cache/RegionListenerDUnitTest.java| 110 + .../internal/cache/RegionListenerJUnitTest.java| 8 ++ .../lucene/internal/InternalLuceneService.java | 4 +- .../cache/lucene/internal/LuceneIndexImpl.java | 21 .../lucene/internal/LuceneRegionListener.java | 30 +- .../cache/lucene/internal/LuceneServiceImpl.java | 55 --- .../apache/geode/cache/lucene/LuceneDUnitTest.java | 37 --- .../cache/lucene/LuceneIndexCreationDUnitTest.java | 45 - 16 files changed, 346 insertions(+), 78 deletions(-) diff --git a/geode-core/src/main/java/org/apache/geode/cache/asyncqueue/internal/AsyncEventQueueImpl.java b/geode-core/src/main/java/org/apache/geode/cache/asyncqueue/internal/AsyncEventQueueImpl.java index bf7e874..d011e28 100644 --- a/geode-core/src/main/java/org/apache/geode/cache/asyncqueue/internal/AsyncEventQueueImpl.java +++ b/geode-core/src/main/java/org/apache/geode/cache/asyncqueue/internal/AsyncEventQueueImpl.java @@ -220,4 +220,10 @@ public class AsyncEventQueueImpl implements AsyncEventQueue { public boolean waitUntilFlushed(long timeout, TimeUnit unit) throws InterruptedException { return ((AbstractGatewaySender) this.sender).waitUntilFlushed(timeout, unit); } + + @Override + public String toString() { +return new StringBuffer().append(getClass().getSimpleName()).append("{").append("id=" + getId()) +.append(",isRunning=" + this.sender.isRunning()).append("}").toString(); + } } diff --git a/geode-core/src/main/java/org/apache/geode/internal/cache/GemFireCacheImpl.java b/geode-core/src/main/java/org/apache/geode/internal/cache/GemFireCacheImpl.java index e2975ea..a399a7a 100755 --- a/geode-core/src/main/java/org/apache/geode/internal/cache/GemFireCacheImpl.java +++ b/geode-core/src/main/java/org/apache/geode/internal/cache/GemFireCacheImpl.java @@ -3175,6 +3175,20 @@ public class GemFireCacheImpl implements InternalCache, InternalClientCache, Has } @Override + public void invokeBeforeDestroyed(LocalRegion region) { +for (RegionListener listener : this.regionListeners) { + listener.beforeDestroyed(region); +} + } + + @Override + public void invokeCleanupFailedInitialization(LocalRegion region) { +for (RegionListener listener : this.regionListeners) { + listener.cleanupFailedInitialization(region); +} + } + + @Override public Region getRegion(String path) { return getRegion(path, false); } @@ -3950,7 +3964,12 @@ public class GemFireCacheImpl implements InternalCache, InternalClientCache, Has @Override public Set getAsyncEventQueues() { -return this.allVisibleAsyncEventQueues; +return getAsyncEventQueues(true); + } + + @Override + public Set getAsyncEventQueues(boolean visibleOnly) { +return visibleOnly ? this.allVisibleAsyncEventQueues : this.allAsyncEventQueues; } @Override diff --git a/geode-core/src/main/java/org/apache/geode/internal/cache/InternalCache.java b/geode-core/src/main/java/org/apache/geode/internal/cache/InternalCache.java index 5ef8fcd..58ab77d 100644 --- a/geode-core/src/main/java/org/apache/geode/internal/cache/InternalCache.java +++ b/geode-core/src/main/java/org/apache/geode/internal/cache/InternalCache.java @@ -131,6 +131,10 @@ public interface InternalCache extends Cache, Extensible, CacheTime { void invokeRegionAfter(LocalRegion region); + void invokeBeforeDestroyed(LocalRegion region); + + void invokeCleanupFailedInitialization(LocalRegion region); + TXManagerImpl getTXMgr(); boolean forcedDisconnec
[geode] branch feature/GEODE-3810 created (now 442c745)
This is an automated email from the ASF dual-hosted git repository. boglesby pushed a change to branch feature/GEODE-3810 in repository https://gitbox.apache.org/repos/asf/geode.git. at 442c745 GEODE-3810: Incremented test timestamp by 1 in case it is the same as the previous event This branch includes the following new commits: new 442c745 GEODE-3810: Incremented test timestamp by 1 in case it is the same as the previous event The 1 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "add" were already present in the repository and have only been added to this reference. -- To stop receiving notification emails like this one, please contact ['"commits@geode.apache.org" '].
[geode] 01/01: GEODE-3810: Incremented test timestamp by 1 in case it is the same as the previous event
This is an automated email from the ASF dual-hosted git repository. boglesby pushed a commit to branch feature/GEODE-3810 in repository https://gitbox.apache.org/repos/asf/geode.git commit 442c74586ec882089acfac5e661cb6211c043b93 Author: Barry Oglesby AuthorDate: Wed Oct 18 17:47:38 2017 -0700 GEODE-3810: Incremented test timestamp by 1 in case it is the same as the previous event --- .../internal/cache/UpdateVersionDUnitTest.java | 24 ++ 1 file changed, 20 insertions(+), 4 deletions(-) diff --git a/geode-wan/src/test/java/org/apache/geode/internal/cache/UpdateVersionDUnitTest.java b/geode-wan/src/test/java/org/apache/geode/internal/cache/UpdateVersionDUnitTest.java index 60fda06..8bd445c 100644 --- a/geode-wan/src/test/java/org/apache/geode/internal/cache/UpdateVersionDUnitTest.java +++ b/geode-wan/src/test/java/org/apache/geode/internal/cache/UpdateVersionDUnitTest.java @@ -135,7 +135,11 @@ public class UpdateVersionDUnitTest extends JUnit4DistributedTestCase { int entryVersion = stamp.getEntryVersion() - 1; int dsid = stamp.getDistributedSystemId(); - long time = System.currentTimeMillis(); + + // Increment the time by 1 in case the time is the same as the previous event. + // The entry's version timestamp can be incremented by 1 in certain circumstances. + // See AbstractRegionEntry.generateVersionTag. + long time = System.currentTimeMillis() + 1; versionTag.setEntryVersion(entryVersion); versionTag.setDistributedSystemId(dsid); @@ -266,7 +270,11 @@ public class UpdateVersionDUnitTest extends JUnit4DistributedTestCase { int entryVersion = stamp.getEntryVersion() - 1; int dsid = stamp.getDistributedSystemId(); - long time = System.currentTimeMillis(); + + // Increment the time by 1 in case the time is the same as the previous event. + // The entry's version timestamp can be incremented by 1 in certain circumstances. + // See AbstractRegionEntry.generateVersionTag. + long time = System.currentTimeMillis() + 1; versionTag.setEntryVersion(entryVersion); versionTag.setDistributedSystemId(dsid); @@ -386,7 +394,11 @@ public class UpdateVersionDUnitTest extends JUnit4DistributedTestCase { int entryVersion = stamp.getEntryVersion() - 1; int dsid = stamp.getDistributedSystemId(); - long time = System.currentTimeMillis(); + + // Increment the time by 1 in case the time is the same as the previous event. + // The entry's version timestamp can be incremented by 1 in certain circumstances. + // See AbstractRegionEntry.generateVersionTag. + long time = System.currentTimeMillis() + 1; versionTag.setEntryVersion(entryVersion); versionTag.setDistributedSystemId(dsid); @@ -519,7 +531,11 @@ public class UpdateVersionDUnitTest extends JUnit4DistributedTestCase { int entryVersion = stamp.getEntryVersion() - 1; int dsid = stamp.getDistributedSystemId(); - long time = System.currentTimeMillis(); + + // Increment the time by 1 in case the time is the same as the previous event. + // The entry's version timestamp can be incremented by 1 in certain circumstances. + // See AbstractRegionEntry.generateVersionTag. + long time = System.currentTimeMillis() + 1; versionTag.setEntryVersion(entryVersion); versionTag.setDistributedSystemId(dsid); -- To stop receiving notification emails like this one, please contact "commits@geode.apache.org" .
[geode] branch feature/GEODE-3810 deleted (was af7d819)
This is an automated email from the ASF dual-hosted git repository. boglesby pushed a change to branch feature/GEODE-3810 in repository https://gitbox.apache.org/repos/asf/geode.git. was af7d819 GEODE-3810: Incremented test timestamp by 1 in case it is the same as the previous event This change permanently discards the following revisions: discard af7d819 GEODE-3810: Incremented test timestamp by 1 in case it is the same as the previous event -- To stop receiving notification emails like this one, please contact ['"commits@geode.apache.org" '].
[geode] branch feature/GEODE-3521 updated: Modify test to use public suspend resume when testSuspendResumeOnDifferentThread
This is an automated email from the ASF dual-hosted git repository. eshu11 pushed a commit to branch feature/GEODE-3521 in repository https://gitbox.apache.org/repos/asf/geode.git The following commit(s) were added to refs/heads/feature/GEODE-3521 by this push: new 8783980 Modify test to use public suspend resume when testSuspendResumeOnDifferentThread 8783980 is described below commit 87839805fe8096936f79cfdca7682c66e5fc2ca2 Author: eshu AuthorDate: Wed Oct 18 17:12:36 2017 -0700 Modify test to use public suspend resume when testSuspendResumeOnDifferentThread --- .../geode/internal/cache/ClientServerTransactionDUnitTest.java | 10 ++ 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/geode-core/src/test/java/org/apache/geode/internal/cache/ClientServerTransactionDUnitTest.java b/geode-core/src/test/java/org/apache/geode/internal/cache/ClientServerTransactionDUnitTest.java index 29b4674..035eb06 100644 --- a/geode-core/src/test/java/org/apache/geode/internal/cache/ClientServerTransactionDUnitTest.java +++ b/geode-core/src/test/java/org/apache/geode/internal/cache/ClientServerTransactionDUnitTest.java @@ -2435,13 +2435,14 @@ public class ClientServerTransactionDUnitTest extends RemoteTransactionDUnitTest mgr.begin(); pr.put(custId, new Customer("name10", "address10")); r.put(10, "value10"); -final TXStateProxy txState = mgr.pauseTransaction(); + +final TransactionId txId = mgr.suspend(); assertNull(pr.get(custId)); assertNull(r.get(10)); final CountDownLatch latch = new CountDownLatch(1); Thread t = new Thread(new Runnable() { public void run() { -mgr.unpauseTransaction(txState); +mgr.resume(txId); mgr.commit(); latch.countDown(); } @@ -2916,7 +2917,8 @@ public class ClientServerTransactionDUnitTest extends RemoteTransactionDUnitTest Map m = new HashMap(); m.put(new CustId(2), new Customer("name2", "address2")); r.putAll(m); -TXStateProxyImpl tx = (TXStateProxyImpl) mgr.pauseTransaction(); +TXStateProxyImpl tx = (TXStateProxyImpl) mgr.getTXState(); +TransactionId txId = mgr.suspend(); ClientTXStateStub txStub = (ClientTXStateStub) tx.getRealDeal(null, null); txStub.setAfterLocalLocks(new Runnable() { public void run() { @@ -2928,7 +2930,7 @@ public class ClientServerTransactionDUnitTest extends RemoteTransactionDUnitTest } } }); -mgr.unpauseTransaction(tx); +mgr.resume(txId); mgr.commit(); } }); -- To stop receiving notification emails like this one, please contact ['"commits@geode.apache.org" '].
[geode] branch develop updated: GEODE-3701 Emphasize performance penalty of hash indexes in docs (#949)
This is an automated email from the ASF dual-hosted git repository. kmiller 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 cff010f GEODE-3701 Emphasize performance penalty of hash indexes in docs (#949) cff010f is described below commit cff010f4fd058079846ea0023e581a83e65a0fea Author: Karen Miller AuthorDate: Wed Oct 18 16:44:59 2017 -0700 GEODE-3701 Emphasize performance penalty of hash indexes in docs (#949) * GEODE-3701 Emphasize performance penalty of hash indexes in docs * GEODE-3701 Revise wording on hash indexes per review --- .../query_index/creating_hash_indexes.html.md.erb | 28 +- 1 file changed, 17 insertions(+), 11 deletions(-) diff --git a/geode-docs/developing/query_index/creating_hash_indexes.html.md.erb b/geode-docs/developing/query_index/creating_hash_indexes.html.md.erb index 49b9596..e785749 100644 --- a/geode-docs/developing/query_index/creating_hash_indexes.html.md.erb +++ b/geode-docs/developing/query_index/creating_hash_indexes.html.md.erb @@ -19,25 +19,31 @@ See the License for the specific language governing permissions and limitations under the License. --> -<%=vars.product_name%> supports the creation of hash indexes for the purposes of performing equality-based queries. +<%=vars.product_name%> supports the creation of hash indexes for the purpose of performing equality-based queries. -## Why Create a HashIndex - -By creating a hash index, you can improve the memory usage of your index. If you are doing equality-based queries, your indexing footprint is significantly reduced. As an example, previously when you created an index that contained string fields, copies of the strings were included in the index. By using hash indexes, indexed expressions are canonicalized and stored in the index as pointers to the objects lying in the region. Improvements in the 30% range are expected, depending on the k [...] - -**Note:** -Your performance results may vary depending on the keys and data being indexed. - -## Performance Considerations +## Hash Index Performance The performance of put operations and recovery time when using a hash index will be worse than a range index. Queries are expected to be slower due to the implementation -of hash index and the cost of recalculating the key on request, -which is the trade-off for the space savings that using a hash index provides. +of the hash index and the cost of recalculating the key on request. +A hash index can improve the memory usage of the index. +So, the trade-off of the hash index space savings must be weighed against the +performance penalty it imposes. If memory usage is not a concern, a range index is recommended. +Consider the memory usage when an index contains string fields. +Copies of the strings are included in the index. +With hash indexes, indexed expressions are canonicalized and stored in the index +as pointers to the objects residing in the region, +thereby using less memory. +Tests achieved as high as a 30% reduction in memory footprint, +but the savings depend on the keys and data being used. + +## Performance Considerations + + ## Limitations The following limitations must be considered when creating hash indexes: -- To stop receiving notification emails like this one, please contact ['"commits@geode.apache.org" '].
[geode] branch develop updated: GEODE-3538 Update doc section Running Geode Server Processes (#945)
This is an automated email from the ASF dual-hosted git repository. kmiller 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 d118ea6 GEODE-3538 Update doc section Running Geode Server Processes (#945) d118ea6 is described below commit d118ea68b85b904b150095f73c15e4da8ea4734f Author: Karen Miller AuthorDate: Wed Oct 18 16:22:20 2017 -0700 GEODE-3538 Update doc section Running Geode Server Processes (#945) * GEODE-3538 Update doc section Running Geode Server Processes Also corrected a typo and improved wording in the gfsh start server command reference page. * GEODE-3858 Spelling correction, requested in a review. --- .../running/running_the_cacheserver.html.md.erb| 121 + .../gfsh/command-pages/start.html.md.erb | 2 +- 2 files changed, 52 insertions(+), 71 deletions(-) diff --git a/geode-docs/configuring/running/running_the_cacheserver.html.md.erb b/geode-docs/configuring/running/running_the_cacheserver.html.md.erb index 37d864f..b97be1a 100644 --- a/geode-docs/configuring/running/running_the_cacheserver.html.md.erb +++ b/geode-docs/configuring/running/running_the_cacheserver.html.md.erb @@ -22,24 +22,22 @@ A <%=vars.product_name%> server is a process that runs as a long-lived, configur The <%=vars.product_name%> server is used primarily for hosting long-lived data regions and for running standard <%=vars.product_name%> processes such as the server in a client/server configuration. You can start and stop servers using the following methods: -- The `gfsh` tool allows you to manage <%=vars.product_name%> server processes from the command line. -- You can also start, stop and manage the <%=vars.product_name%> servers through the `org.apache.geode.distributed.ServerLauncher` API. The `ServerLauncher` API can only be used for <%=vars.product_name%> Servers that were started with `gfsh` or with the `ServerLauncher` class itself. See the JavaDocs for additional specifics on using the `ServerLauncher` API. +- The `gfsh` command-line tool. +- Programmatically, through the `org.apache.geode.distributed.ServerLauncher` API. The `ServerLauncher` API can only be used for <%=vars.product_name%> Servers that were started with `gfsh` or with the `ServerLauncher` class itself. ## Default Server Configuration and Log Files The `gfsh` utility uses a working directory for its configuration files and log files. These are the defaults and configuration options: - When you start a standalone server using `gfsh`, `gfsh` will automatically load the required JAR file `lib/geode-dependencies.jar` into the CLASSPATH of the JVM process. If you start a standalone server using the ServerLauncher API, you must specify this JAR file inside your command to launch the process. For more information on CLASSPATH settings in <%=vars.product_name%>, see [Setting Up the CLASSPATH](../../getting_started/setup_classpath.html). -- Servers are configured like any other <%=vars.product_name%> process, with `gemfire.properties` and shared cluster configuration files. It is not programmable except through application plug-ins. Typically, you provide the `gemfire.properties` file and the `gfsecurity.properties` file (if you are using a separate, restricted access security settings file). You can also specify a `cache.xml` file in the cache server’s working directory. -- By default, a new server started with `gfsh` receives its initial cache configuration from the cluster configuration service, assuming the locator is running the cluster configuration service. If you specify a group when starting the server, the server also receives configurations that apply to a group. The shared configuration consists of `cache.xml` files, `gemfire.properties` files, and deployed jar files. You can disable use of the cluster configuration service by specifying `--u [...] +- Servers are configured like any other <%=vars.product_name%> process, with `gemfire.properties` and shared cluster configuration files. It is not programmable except through application plug-ins. Typically, you provide the `gemfire.properties` file and the `gfsecurity.properties` file. You can also specify a `cache.xml` file in the cache server’s working directory. +- By default, a new server started with `gfsh` receives its initial cache configuration from the cluster configuration service, assuming the locator is running the cluster configuration service. If you specify a group when starting the server, the server also receives configurations that apply to a group. The shared configuration consists of `cache.xml` files, `gemfire.properties` files, and deployed jar files. You can disable use of the cluster configuration service by specifying `--u [...] -See [Overview of the Cluster Configuration Service](../cluster_con
[geode] branch develop updated: GEODE-3857: Pulse login fails after second login (#939)
This is an automated email from the ASF dual-hosted git repository. jensdeppe 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 bfdaeba GEODE-3857: Pulse login fails after second login (#939) bfdaeba is described below commit bfdaebafb63419efb4f71420bf36a3ef2ae68c34 Author: Jens Deppe AuthorDate: Wed Oct 18 15:28:49 2017 -0700 GEODE-3857: Pulse login fails after second login (#939) * GEODE-3857: Pulse login fails after second login * GEODE-3857: Consolidate actions for logging out - Close the JMX connection and remove the reference from the cluster map in one place. --- .../java/org/apache/geode/test/junit/rules/HttpClientRule.java | 4 .../java/org/apache/geode/tools/pulse/PulseSecurityTest.java | 7 +++ .../org/apache/geode/tools/pulse/internal/data/Repository.java | 10 ++ .../tools/pulse/internal/security/GemFireAuthentication.java | 4 .../pulse/internal/security/GemFireAuthenticationProvider.java | 3 +-- .../geode/tools/pulse/internal/security/LogoutHandler.java | 3 ++- 6 files changed, 24 insertions(+), 7 deletions(-) diff --git a/geode-assembly/src/test/java/org/apache/geode/test/junit/rules/HttpClientRule.java b/geode-assembly/src/test/java/org/apache/geode/test/junit/rules/HttpClientRule.java index cfff7c1..8434136 100644 --- a/geode-assembly/src/test/java/org/apache/geode/test/junit/rules/HttpClientRule.java +++ b/geode-assembly/src/test/java/org/apache/geode/test/junit/rules/HttpClientRule.java @@ -73,6 +73,10 @@ public class HttpClientRule extends ExternalResource { .contains("/pulse/clusterDetail.html"); } + public HttpResponse logoutFromPulse() throws Exception { +return get("/pulse/clusterLogout"); + } + public HttpResponse get(String uri, String... params) throws Exception { return httpClient.execute(host, buildHttpGet(uri, params)); } diff --git a/geode-assembly/src/test/java/org/apache/geode/tools/pulse/PulseSecurityTest.java b/geode-assembly/src/test/java/org/apache/geode/tools/pulse/PulseSecurityTest.java index a28ae59..42d8411 100644 --- a/geode-assembly/src/test/java/org/apache/geode/tools/pulse/PulseSecurityTest.java +++ b/geode-assembly/src/test/java/org/apache/geode/tools/pulse/PulseSecurityTest.java @@ -108,4 +108,11 @@ public class PulseSecurityTest { assertThat(result.toString()).contains("No Data Found"); } + @Test + public void loginAfterLogout() throws Exception { +client.loginToPulseAndVerify("data", "data"); +client.logoutFromPulse(); +client.loginToPulseAndVerify("data", "data"); +client.logoutFromPulse(); + } } diff --git a/geode-pulse/src/main/java/org/apache/geode/tools/pulse/internal/data/Repository.java b/geode-pulse/src/main/java/org/apache/geode/tools/pulse/internal/data/Repository.java index c3a33fd..9a03349 100644 --- a/geode-pulse/src/main/java/org/apache/geode/tools/pulse/internal/data/Repository.java +++ b/geode-pulse/src/main/java/org/apache/geode/tools/pulse/internal/data/Repository.java @@ -136,6 +136,16 @@ public class Repository { } } + public void logoutUser(String username) { +Cluster data = clusterMap.remove(username); +if (data != null) { + try { +data.getJMXConnector().close(); + } catch (Exception e) { +// We're logging out so this can be ignored + } +} + } // This method is used to remove all cluster threads public void removeAllClusters() { diff --git a/geode-pulse/src/main/java/org/apache/geode/tools/pulse/internal/security/GemFireAuthentication.java b/geode-pulse/src/main/java/org/apache/geode/tools/pulse/internal/security/GemFireAuthentication.java index dc75735..62de395 100644 --- a/geode-pulse/src/main/java/org/apache/geode/tools/pulse/internal/security/GemFireAuthentication.java +++ b/geode-pulse/src/main/java/org/apache/geode/tools/pulse/internal/security/GemFireAuthentication.java @@ -81,8 +81,4 @@ public class GemFireAuthentication extends UsernamePasswordAuthenticationToken { } - public JMXConnector getJmxc() { -return jmxc; - } - } diff --git a/geode-pulse/src/main/java/org/apache/geode/tools/pulse/internal/security/GemFireAuthenticationProvider.java b/geode-pulse/src/main/java/org/apache/geode/tools/pulse/internal/security/GemFireAuthenticationProvider.java index 2b110bc..2d3f0b1 100644 --- a/geode-pulse/src/main/java/org/apache/geode/tools/pulse/internal/security/GemFireAuthenticationProvider.java +++ b/geode-pulse/src/main/java/org/apache/geode/tools/pulse/internal/security/GemFireAuthenticationProvider.java @@ -44,8 +44,7 @@ public class GemFireAuthenticationProvider implements AuthenticationProvider { public Authentication authenticate(Authentication authentication) throws AuthenticationException { if (authentication instanceof GemFireAuthentication) {
[geode] branch feature/GEODE-3864 updated: GEODE-3864: Added protobuf message file archiving
This is an automated email from the ASF dual-hosted git repository. udo pushed a commit to branch feature/GEODE-3864 in repository https://gitbox.apache.org/repos/asf/geode.git The following commit(s) were added to refs/heads/feature/GEODE-3864 by this push: new 9ed6a78 GEODE-3864: Added protobuf message file archiving 9ed6a78 is described below commit 9ed6a789529f19b128d8f74ad0542d84dce4e804 Author: kohlmu-pivotal AuthorDate: Wed Oct 18 14:28:35 2017 -0700 GEODE-3864: Added protobuf message file archiving --- geode-assembly/build.gradle | 677 ++-- geode-protobuf/build.gradle | 1 - 2 files changed, 336 insertions(+), 342 deletions(-) diff --git a/geode-assembly/build.gradle b/geode-assembly/build.gradle index 80dc870..48a5cfa 100755 --- a/geode-assembly/build.gradle +++ b/geode-assembly/build.gradle @@ -21,227 +21,222 @@ apply plugin: 'distribution' // disable artifact generation for this project jar.enabled = false extraArchive { -sources = false -javadoc = false -tests = false + sources = false + javadoc = false + tests = false } // Gradle doesn't automatically remove the jar artifact even though we disabled it // this causes publishing to fail. So we nuke all the disabled artifacts from all configurations. configurations.all { -artifacts.removeAll artifacts.findAll { -it instanceof ArchivePublishArtifact && !it.archiveTask.enabled -} + artifacts.removeAll artifacts.findAll { it instanceof ArchivePublishArtifact && !it.archiveTask.enabled } } -gradle.taskGraph.whenReady({ graph -> -tasks.withType(Tar).each { tar -> -tar.compression = Compression.GZIP -tar.extension = 'tar.gz' -} -tasks.srcDistZip { -classifier 'src' -} -tasks.srcDistTar { -classifier 'src' -} +gradle.taskGraph.whenReady( { graph -> + tasks.withType(Tar).each { tar -> +tar.compression = Compression.GZIP +tar.extension = 'tar.gz' + } + tasks.srcDistZip { +classifier 'src' + } + tasks.srcDistTar { +classifier 'src' + } }) configurations { -bundled { -description 'A dependency that is shipped with geode, but is not required to compile' -} -gfshDependencies + bundled { +description 'A dependency that is shipped with geode, but is not required to compile' + } + gfshDependencies } dependencies { -provided project(':geode-core') - -archives project(':geode-common') -archives project(':geode-json') -archives project(':geode-core') -archives project(':geode-lucene') -archives project(':geode-old-client-support') -archives project(':geode-protobuf') -archives project(':geode-web') -archives project(':geode-web-api') -archives project(':geode-wan') -archives project(':geode-cq') -archives project(':geode-rebalancer') - -testCompile project(':geode-junit') -testCompile project(':geode-pulse') -testCompile files(project(':geode-core').sourceSets.test.output) -testCompile('org.springframework:spring-web:' + project.'springframework.version') { -exclude module: 'aopalliance' -exclude module: 'spring-aop' -} - -testCompile 'org.apache.httpcomponents:httpclient:' + project.'httpclient.version' -testCompile 'org.apache.httpcomponents:httpcore:' + project.'httpcore.version' -testCompile 'com.google.guava:guava:' + project.'guava.version' -testCompile 'org.apache.commons:commons-exec:' + project.'commons-exec.version' - -testCompile group: 'org.codehaus.cargo', name: 'cargo-core-uberjar', version: '1.6.3' - -testCompile(project(':extensions/geode-modules')) { -// Remove everything related to Tomcat -exclude group: 'org.apache.tomcat' -} -testCompile(project(':extensions/geode-modules-session-internal')) { -// Remove everything related to Tomcat -exclude group: 'org.apache.tomcat' -} - -testCompile project(':extensions/session-testing-war') - -testRuntime files("${System.getProperty('java.home')}/../lib/tools.jar") -testRuntime files("$buildDir/install/${distributions.main.baseName}/lib/geode-dependencies.jar") - - -gfshDependencies('org.springframework:spring-web:' + project.'springframework.version') { -exclude module: 'spring-core' -exclude module: 'commons-logging' -} - -testCompile project(':geode-old-versions') + provided project(':geode-core') + + archives project(':geode-common') + archives project(':geode-json') + archives project(':geode-core') + archives project(':geode-lucene') + archives project(':geode-old-client-support') + archives project(':geode-protobuf') + archives project(':geode-web') + archives project(':geode-web-api') + archives project(':geode-wan') + archives project(':geode-cq') + archives project(':geode-rebalancer') + + testCompile project(':geode-junit') + testCompile project(':geode-pulse') +
[geode] branch develop updated: GEODE-3708: Added a separate iterator for MemoryIndexStore which doesn't iterate over the values in the Map.
This is an automated email from the ASF dual-hosted git repository. nnag 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 2e710e5 GEODE-3708: Added a separate iterator for MemoryIndexStore which doesn't iterate over the values in the Map. 2e710e5 is described below commit 2e710e5d8ab11695c12f381f107398f2122f43ec Author: nabarun AuthorDate: Fri Oct 6 13:17:52 2017 -0700 GEODE-3708: Added a separate iterator for MemoryIndexStore which doesn't iterate over the values in the Map. * The new iterator MemoryIndexStoreKeyIterator will only iterate over the keys * This is different from the previous iterator which iterates over the values too and sending out IndexStoreEntry pairs of the key and iterated value entry * This resulted in duplicate results in join queries with OR clause as the same key was being repeatedly sent if the value associated with the key is a collection. --- .../query/internal/index/CompactRangeIndex.java| 14 ++--- .../query/internal/index/MemoryIndexStore.java | 64 ++ .../cache/query/JoinQueriesIntegrationTest.java| 13 +++-- 3 files changed, 78 insertions(+), 13 deletions(-) diff --git a/geode-core/src/main/java/org/apache/geode/cache/query/internal/index/CompactRangeIndex.java b/geode-core/src/main/java/org/apache/geode/cache/query/internal/index/CompactRangeIndex.java index 7031532..2c19d9d 100644 --- a/geode-core/src/main/java/org/apache/geode/cache/query/internal/index/CompactRangeIndex.java +++ b/geode-core/src/main/java/org/apache/geode/cache/query/internal/index/CompactRangeIndex.java @@ -181,14 +181,16 @@ public class CompactRangeIndex extends AbstractIndex { long start = updateIndexUseStats(); ((AbstractIndex) indx).updateIndexUseStats(); List data = new ArrayList(); -CloseableIterator outer = null; +Iterator outer = null; Iterator inner = null; try { // We will iterate over each of the index Map to obtain the keys - outer = indexStore.iterator(null); + outer = ((MemoryIndexStore) indexStore).getKeysIterator(); if (indx instanceof CompactRangeIndex) { -inner = ((CompactRangeIndex) indx).getIndexStorage().iterator(null); +IndexStore indexStore = ((CompactRangeIndex) indx).getIndexStorage(); +inner = ((MemoryIndexStore) indexStore).getKeysIterator(); + } else { inner = ((RangeIndex) indx).getValueToEntriesMap().entrySet().iterator(); } @@ -252,10 +254,8 @@ public class CompactRangeIndex extends AbstractIndex { } finally { ((AbstractIndex) indx).updateIndexUseEndStats(start); updateIndexUseEndStats(start); - if (outer != null) { -outer.close(); - } - if (inner != null && indx instanceof CompactRangeIndex) { + if (inner != null && indx instanceof CompactRangeIndex + && inner instanceof CloseableIterator) { ((CloseableIterator) inner).close(); } } diff --git a/geode-core/src/main/java/org/apache/geode/cache/query/internal/index/MemoryIndexStore.java b/geode-core/src/main/java/org/apache/geode/cache/query/internal/index/MemoryIndexStore.java index 8e298c9..91dbfc4 100644 --- a/geode-core/src/main/java/org/apache/geode/cache/query/internal/index/MemoryIndexStore.java +++ b/geode-core/src/main/java/org/apache/geode/cache/query/internal/index/MemoryIndexStore.java @@ -420,6 +420,10 @@ public class MemoryIndexStore implements IndexStore { keysToRemove); } + public Iterator getKeysIterator() { +return new MemoryIndexStoreKeyIterator(this.valueToEntriesMap); + } + @Override public CloseableIterator iterator(Collection keysToRemove) { return new MemoryIndexStoreIterator(this.valueToEntriesMap, null, keysToRemove); @@ -560,6 +564,38 @@ public class MemoryIndexStore implements IndexStore { return numIndexKeys.get(); } + private class MemoryIndexStoreKeyIterator implements Iterator { + +final private Map valuesToEntriesMap; +private Object currKey; +private Iterator mapIterator; + +public MemoryIndexStoreKeyIterator(Map valuesToEntriesMap) { + this.valuesToEntriesMap = valuesToEntriesMap; +} + +@Override +public boolean hasNext() { + if (mapIterator == null) { +mapIterator = this.valuesToEntriesMap.entrySet().iterator(); + } + if (mapIterator.hasNext()) { +Map.Entry currentEntry = mapIterator.next(); +currKey = currentEntry.getKey(); +if (currKey == IndexManager.NULL || currKey == QueryService.UNDEFINED) { + return hasNext(); +} +return currKey != null; + } + return false; +} + +@Override +public MemoryIndexStoreKey next() { + return new MemoryIndexStoreKey(currKey); +} + } + /** * A bi-directional iterator over the CS
[geode] branch develop updated: GEODE-3614 remove JUnit3CacheTestCase, cleanup JUnit4CacheTestCase
This is an automated email from the ASF dual-hosted git repository. gosullivan 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 6206fc1 GEODE-3614 remove JUnit3CacheTestCase, cleanup JUnit4CacheTestCase 6206fc1 is described below commit 6206fc1c2e07d6373cabc3b8dda6d24d6050fc5b Author: Galen O'Sullivan AuthorDate: Wed Sep 13 14:43:15 2017 -0700 GEODE-3614 remove JUnit3CacheTestCase, cleanup JUnit4CacheTestCase * Use LogService instead of LogWriter * get rid of an unused method or two * remove redundant error handling * remove TODOs. --- .../SharedConfigurationTestUtils.java | 4 +- .../dunit/cache/internal/JUnit3CacheTestCase.java | 236 .../dunit/cache/internal/JUnit4CacheTestCase.java | 96 ++--- .../dunit/internal/JUnit3DistributedTestCase.java | 240 - .../dunit/internal/JUnit4DistributedTestCase.java | 2 +- 5 files changed, 26 insertions(+), 552 deletions(-) diff --git a/geode-core/src/test/java/org/apache/geode/management/internal/configuration/SharedConfigurationTestUtils.java b/geode-core/src/test/java/org/apache/geode/management/internal/configuration/SharedConfigurationTestUtils.java index eddaad2..cd4f40a 100644 --- a/geode-core/src/test/java/org/apache/geode/management/internal/configuration/SharedConfigurationTestUtils.java +++ b/geode-core/src/test/java/org/apache/geode/management/internal/configuration/SharedConfigurationTestUtils.java @@ -17,7 +17,7 @@ package org.apache.geode.management.internal.configuration; import org.apache.geode.distributed.internal.ClusterConfigurationService; import org.apache.geode.distributed.internal.InternalLocator; import org.apache.geode.test.dunit.SerializableRunnable; -import org.apache.geode.test.dunit.internal.JUnit3DistributedTestCase; +import org.apache.geode.test.dunit.internal.JUnit4DistributedTestCase; public class SharedConfigurationTestUtils { @@ -32,7 +32,7 @@ public class SharedConfigurationTestUtils { } locator.stop(); } - JUnit3DistributedTestCase.disconnectAllFromDS(); + JUnit4DistributedTestCase.disconnectAllFromDS(); } }; } diff --git a/geode-core/src/test/java/org/apache/geode/test/dunit/cache/internal/JUnit3CacheTestCase.java b/geode-core/src/test/java/org/apache/geode/test/dunit/cache/internal/JUnit3CacheTestCase.java deleted file mode 100644 index 7c88cc3..000 --- a/geode-core/src/test/java/org/apache/geode/test/dunit/cache/internal/JUnit3CacheTestCase.java +++ /dev/null @@ -1,236 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more contributor license - * agreements. See the NOTICE file distributed with this work for additional information regarding - * copyright ownership. The ASF licenses this file to You under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance with the License. You may obtain a - * copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software distributed under the License - * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express - * or implied. See the License for the specific language governing permissions and limitations under - * the License. - */ -package org.apache.geode.test.dunit.cache.internal; - -import java.io.File; -import java.io.IOException; - -import org.apache.geode.cache.Cache; -import org.apache.geode.cache.CacheException; -import org.apache.geode.cache.CacheFactory; -import org.apache.geode.cache.Region; -import org.apache.geode.cache.RegionAttributes; -import org.apache.geode.cache.RegionExistsException; -import org.apache.geode.cache.TimeoutException; -import org.apache.geode.cache.client.ClientCache; -import org.apache.geode.cache.client.ClientCacheFactory; -import org.apache.geode.cache30.CacheSerializableRunnable; -import org.apache.geode.internal.cache.GemFireCacheImpl; -import org.apache.geode.internal.cache.InternalCache; -import org.apache.geode.test.dunit.IgnoredException; -import org.apache.geode.test.dunit.cache.CacheTestCase; -import org.apache.geode.test.dunit.internal.JUnit3DistributedTestCase; - -/** - * The abstract superclass of tests that require the creation of a {@link Cache}. - * - * @deprecated Please use {@link CacheTestCase} which extends {@link JUnit4CacheTestCase} when - * writing new tests. - */ -@Deprecated -public abstract class JUnit3CacheTestCase extends JUnit3DistributedTestCase -implements CacheTestFixture { - - private final JUnit4CacheTestCase delegate = new JUnit4CacheTestCase(this) {}; - - public JUnit3CacheTestCase(final String name) { -super(name); - } - - /** - * Creates the {@code Cache} for this test that is not connected to other
[geode-examples] branch develop updated: bump version
This is an automated email from the ASF dual-hosted git repository. sbawaskar pushed a commit to branch develop in repository https://gitbox.apache.org/repos/asf/geode-examples.git The following commit(s) were added to refs/heads/develop by this push: new bf9ab05 bump version bf9ab05 is described below commit bf9ab058379b18becfd7ce1fbb5e3c1bb6e6031d Author: Swapnil Bawaskar AuthorDate: Thu Oct 19 02:22:15 2017 +0530 bump version --- gradle.properties | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gradle.properties b/gradle.properties index 40ea7a6..317c923 100644 --- a/gradle.properties +++ b/gradle.properties @@ -14,8 +14,8 @@ # See the License for the specific language governing permissions and # limitations under the License. # -version = 1.3.0-SNAPSHOT -geodeVersion = 1.2.0 +version = 1.4.0-SNAPSHOT +geodeVersion = 1.3.0 # release properties, set these on the command line to validate against # a release candidate -- To stop receiving notification emails like this one, please contact ['"commits@geode.apache.org" '].
[geode] branch develop updated: Parameterizing LuceneSerializer with a type
This is an automated email from the ASF dual-hosted git repository. upthewaterspout 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 10c3111 Parameterizing LuceneSerializer with a type 10c3111 is described below commit 10c311157be1c093c5e4bfb29e1e66522c5a3b5c Author: Dan Smith AuthorDate: Tue Oct 17 10:59:46 2017 -0700 Parameterizing LuceneSerializer with a type User's may want to create LuceneSerializers that only support specific types, eg LuceneSerializer. Adding a parameterized type to the LuceneSerializer interface. --- .../java/org/apache/geode/cache/lucene/LuceneSerializer.java | 11 +-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/geode-lucene/src/main/java/org/apache/geode/cache/lucene/LuceneSerializer.java b/geode-lucene/src/main/java/org/apache/geode/cache/lucene/LuceneSerializer.java index ceebc65..2101b70 100644 --- a/geode-lucene/src/main/java/org/apache/geode/cache/lucene/LuceneSerializer.java +++ b/geode-lucene/src/main/java/org/apache/geode/cache/lucene/LuceneSerializer.java @@ -19,20 +19,27 @@ import java.util.Collection; import org.apache.geode.cache.Declarable; import org.apache.lucene.document.Document; +import org.apache.lucene.document.Field; import org.apache.geode.annotations.Experimental; /** * An interface for writing the fields of an object into a lucene document + * + * @param The type of object supported by this lucene serializer */ @Experimental -public interface LuceneSerializer extends Declarable { +public interface LuceneSerializer extends Declarable { /** * Add the fields of the given value to a set of documents + * + * Added fields should be marked with {@link Field.Store#NO}. These fields are only used for + * searches. When doing a query, geode will return the value from the region, not any fields that + * are stored on the returned Documents. * * @param index lucene index * @param value user object to be serialized into index */ - Collection toDocuments(LuceneIndex index, Object value); + Collection toDocuments(LuceneIndex index, T value); } -- To stop receiving notification emails like this one, please contact ['"commits@geode.apache.org" '].
[geode-examples] annotated tag rel/v1.3.0.RC3 updated (4ff8f8e -> 644b3ac)
This is an automated email from the ASF dual-hosted git repository. sbawaskar pushed a change to annotated tag rel/v1.3.0.RC3 in repository https://gitbox.apache.org/repos/asf/geode-examples.git. *** WARNING: tag rel/v1.3.0.RC3 was modified! *** from 4ff8f8e (commit) to 644b3ac (tag) tagging 4ff8f8eafd0927888e711ee45d283ab07d345000 (commit) replaces rel/v1.2.1 by Swapnil Bawaskar on Thu Oct 19 02:05:14 2017 +0530 - Log - Release candidate 3 for 1.3.0 -BEGIN PGP SIGNATURE- Comment: GPGTools - https://gpgtools.org iQIcBAABCgAGBQJZ57sJAAoJEI+PK8wY+QLbdDcQAKquFvzKC5XKoQ6X2y/8rzvx r8YSpzOcgnpxzghKRsgvm3Ko31ABlPrAZfWhzMvwFx5dRhpBU6BN/2CVu5qzuEyv JOqh9YuI/qE9zjNKADInlBHl9KD5ZerbhvHJ1e9pBKt9ywlCTth6n+QjvSjPaWFm NS09Nc9m1m5RXzDJuSKywhuj5JWesQHWqXFJlmbretaCItd8gWAcpArL/NVskgrS EufoWRY/3UJy9Nv8FkB0ZrhIyNmyAkeAOo78T6Z0jXex/dPWkn4BOUSAYmC+hZty IlXQHckSCb3Z9CIXUmHerkPjPZsoPmbmafHDB8bCHkGNhEhL78vK95QxgFBldLAG lh90fMXjltyJwaVQI2KzviI69UCXdQCOtewXDQWHMaEI3cXXkRjAazEOt84K47R4 OrU5Vhh5mmmG3ZwadAwgGbyKzcWUGbvgu7gU2VJfp0KeLt4q46p00lkli+xp8xmf Bs2EgL4h6flfJNWDSCZM6zVo+fdy9gxpX0MuYfK6HPlF6GsNncL7UF2Asg9RxNUZ TMe3FhM490fyRJXFgZVEKBI0e4cCXmOKyqPbvlM10pTW5R55TnQVvBrFsgfaTDdy XSTnN72XEOaRWUXBx1gPTj5iD0f/l/yLEoVVS79udY+F3yBhzw/7BspsgAvycsJe pOeVUAMTkA+qTrl0MI5x =ZLDV -END PGP SIGNATURE- --- No new revisions were added by this update. Summary of changes: -- To stop receiving notification emails like this one, please contact ['"commits@geode.apache.org" '].
[geode-examples] branch release/1.3.0 updated: - removing SNAPSHOT from release version - change geode distribution extenstion from tar.gz to tgz
This is an automated email from the ASF dual-hosted git repository. sbawaskar pushed a commit to branch release/1.3.0 in repository https://gitbox.apache.org/repos/asf/geode-examples.git The following commit(s) were added to refs/heads/release/1.3.0 by this push: new 4ff8f8e - removing SNAPSHOT from release version - change geode distribution extenstion from tar.gz to tgz 4ff8f8e is described below commit 4ff8f8eafd0927888e711ee45d283ab07d345000 Author: Swapnil Bawaskar AuthorDate: Thu Oct 19 01:59:22 2017 +0530 - removing SNAPSHOT from release version - change geode distribution extenstion from tar.gz to tgz --- build.gradle | 2 +- gradle.properties | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/build.gradle b/build.gradle index e79e20e..2fad0f4 100644 --- a/build.gradle +++ b/build.gradle @@ -26,7 +26,7 @@ def downloadUrl = (geodeReleaseUrl != "") ? geodeReleaseUrl : def verificationUrl = (geodeReleaseUrl != "") ? geodeReleaseUrl : "https://www.apache.org/dist/geode/$geodeVersion"; -def downloadFile = "apache-geode-${geodeVersion}.tar.gz" +def downloadFile = "apache-geode-${geodeVersion}.tgz" def installFile = "$buildDir/$downloadFile" def installDir = "$buildDir/apache-geode-${geodeVersion}" diff --git a/gradle.properties b/gradle.properties index 40ea7a6..ce453bc 100644 --- a/gradle.properties +++ b/gradle.properties @@ -14,8 +14,8 @@ # See the License for the specific language governing permissions and # limitations under the License. # -version = 1.3.0-SNAPSHOT -geodeVersion = 1.2.0 +version = 1.3.0 +geodeVersion = 1.3.0 # release properties, set these on the command line to validate against # a release candidate -- To stop receiving notification emails like this one, please contact ['"commits@geode.apache.org" '].
[geode-examples] branch release/1.3.0 created (now e55efcc)
This is an automated email from the ASF dual-hosted git repository. sbawaskar pushed a change to branch release/1.3.0 in repository https://gitbox.apache.org/repos/asf/geode-examples.git. at e55efcc Changes to Readmes No new revisions were added by this update. -- To stop receiving notification emails like this one, please contact ['"commits@geode.apache.org" '].
[geode-examples] branch release/1.3.0 deleted (was 98ae39b)
This is an automated email from the ASF dual-hosted git repository. sbawaskar pushed a change to branch release/1.3.0 in repository https://gitbox.apache.org/repos/asf/geode-examples.git. was 98ae39b Merge branch 'release/1.2.1' The revisions that were on this branch are still contained in other references; therefore, this change does not discard any commits from the repository. -- To stop receiving notification emails like this one, please contact ['"commits@geode.apache.org" '].
[geode-examples] branch release/1.3.0 created (now 98ae39b)
This is an automated email from the ASF dual-hosted git repository. sbawaskar pushed a change to branch release/1.3.0 in repository https://gitbox.apache.org/repos/asf/geode-examples.git. at 98ae39b Merge branch 'release/1.2.1' No new revisions were added by this update. -- To stop receiving notification emails like this one, please contact ['"commits@geode.apache.org" '].
[geode-examples] branch release/1.3.0 deleted (was 98ae39b)
This is an automated email from the ASF dual-hosted git repository. sbawaskar pushed a change to branch release/1.3.0 in repository https://gitbox.apache.org/repos/asf/geode-examples.git. was 98ae39b Merge branch 'release/1.2.1' The revisions that were on this branch are still contained in other references; therefore, this change does not discard any commits from the repository. -- To stop receiving notification emails like this one, please contact ['"commits@geode.apache.org" '].
svn commit: r22569 - /dev/geode/1.3.0.RC3/
Author: sbawaskar Date: Wed Oct 18 19:51:53 2017 New Revision: 22569 Log: Adding examples to Apache Geode 1.3.0.RC3 distribution Added: dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.tar.gz (with props) dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.tar.gz.asc dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.tar.gz.md5 dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.tar.gz.sha256 dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.zip (with props) dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.zip.asc dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.zip.md5 dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.zip.sha256 Added: dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.tar.gz == Binary file - no diff available. Propchange: dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.tar.gz -- svn:mime-type = application/octet-stream Added: dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.tar.gz.asc == --- dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.tar.gz.asc (added) +++ dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.tar.gz.asc Wed Oct 18 19:51:53 2017 @@ -0,0 +1,17 @@ +-BEGIN PGP SIGNATURE- +Version: BCPG v1.51 + +iQIcBAABAgAGBQJZ562cAAoJEI+PK8wY+QLbPG4QAJ6qz1VUI2T/Mg+XtUybTOut +wFeiag3SP/b4UEj3bHnboxrg6k91InblxWAsNNSJb5xallPRjzn5mkkm1rz+Larj +j/OpfY1RTkWL1Q+Mz5B8Yoz9Kti5kiQpPmLEogRnA9T3jUY643VIgBhGXV69NmCV +axEs17StlnF4cCPYJZyD4Kmvy7G1U3YHi8AQRyNIqRTyGuLIzBh4D1BHtV2UOJ/M +x1ZGjjXYLwvdq1OWu9qSYsn0+jLw8IsZqRSGHqnAVUy69y9W12vp5BSp+r6YwxnA +LW0yn1fgYqTgciCpXTmOuL2e6AFWRTPmFrhaLzamoSd2fRWbIdBlEkPwKkLL2L8S +Tnbo/f0K9mazs8X9JAfM67WbjoAqQNJKuZOUcBsp9LdHriEEfjmKWlv65m6qSr0I +9wWQDs0wdw4/goPLMBsT/9xfb8AxYzlMgRc35b458p9PJ7sHitamwxpJ/kU5qGir +8KlUvlAqBFciYFZIbUpWwI2i3faYjf4DdqMNDxHypjs1PUZ6BvBi8zHBsC9XPQXr +TfLCnJaJjg7n/njDOYGpclGImUnYrL5S5vtS5sYUQEFBpGeL97Thux2gB7bvyQiD +jHmUwLs/85DGZfYm4NQAjHvaoJQV8X9rV4ef0kojuprGEylIGukqgKkUBWgoc3Ls +qOGXI0ZH0yDd/ayzQtjz +=taiz +-END PGP SIGNATURE- Added: dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.tar.gz.md5 == --- dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.tar.gz.md5 (added) +++ dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.tar.gz.md5 Wed Oct 18 19:51:53 2017 @@ -0,0 +1 @@ +c7bb485c21f3afb4ecaee0ce5f5fea45 *apache-geode-examples-1.3.0.tar.gz Added: dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.tar.gz.sha256 == --- dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.tar.gz.sha256 (added) +++ dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.tar.gz.sha256 Wed Oct 18 19:51:53 2017 @@ -0,0 +1 @@ +fcc03640c5778d8c0be492e0b48b953ee49c778f741808f901299136ebccb10b *apache-geode-examples-1.3.0.tar.gz Added: dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.zip == Binary file - no diff available. Propchange: dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.zip -- svn:mime-type = application/octet-stream Added: dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.zip.asc == --- dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.zip.asc (added) +++ dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.zip.asc Wed Oct 18 19:51:53 2017 @@ -0,0 +1,17 @@ +-BEGIN PGP SIGNATURE- +Version: BCPG v1.51 + +iQIcBAABAgAGBQJZ562cAAoJEI+PK8wY+QLbBHEP/1mn60kbvqtjYhzhHP6v30zS +0b+TrEL+uIWXw7te7GipfaVswnGAbD+6QzFvsjS7HZqRkKhi6J247LGf3ZqAOyVr +Wsz8GpWIDr6P1F5zsv5km7geWEoGkfBA69zt+Vr3I95a7E+2COt6KruIl7cUgbbL +qCoi9hB/U+K9FNYKrDg9ZHeBH04hsqlU5/+RdedgrErN8wCzlJPrduEO7IjjMA+M +mtW0faI67xAivV19bCw1ONl4nkO+eCncjoPQCzUv9Mp9SR/0LpI+PDgWgO3tj3Ph +dMBNcSvqydc0y+Jz1+qm31Q+Lp6V9iXJDXcF3eq2BQdjyPpSeQRikgoJG8CJ+yqG +CvAEdoBgEn5lQxC3J+6NHerwnEdZWBmdr5nGsFzie+6x4ybnilzRjn3kVKmYn2r9 +b3v9ZiCSAiEpbN+nvE1P0Ty4ByqvCFXV2MNB5I2BzW4baP/lrIhmnHUt+w6NngHN +egcJak+vZjPJlE58za6GfvRFLEYMSmRnVPH/Q+eddU02+MpK/muNmm1VOdoWcguK +b0VfmWHMNJugsOOra+ngY9yOiTWiBV/uT/vl0t5yGyo8AM2g00xRgyjdNUc5O9ae +iTLAFlxzm/QVG/8yrRXEcWSpaq85zZb56eur1BVdU9M7MKX4F/0szunxEB3jA2oW +wnapcf+Z7OOPr/Vhti6O +=zZY4 +-END PGP SIGNATURE- Added: dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.zip.md5 == --- dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.zip.md5 (added) +++ dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.zip.md5 Wed Oct 18 19:51:53 2017 @@ -0,0 +1 @@ +82684b106f00341e0b668139ad4bdcc8 *apache-geode-examples-1.3.0.zip Added: dev/geode/1.3.0.RC3/apache-geode-examples-1.3.0.zip.sha256 =
[geode] branch develop updated: GEODE-3841 CI Failure : WanCommandListDUnitTest.testListGatewaySenderGatewayReceiver_group GEODE-3780 suspected member is never watched again after passing final check
This is an automated email from the ASF dual-hosted git repository. bschuchardt 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 2636bd8 GEODE-3841 CI Failure : WanCommandListDUnitTest.testListGatewaySenderGatewayReceiver_group GEODE-3780 suspected member is never watched again after passing final check 2636bd8 is described below commit 2636bd842d4b87992ffda45c5d2683060d20c05f Author: Bruce Schuchardt AuthorDate: Wed Oct 18 12:14:09 2017 -0700 GEODE-3841 CI Failure : WanCommandListDUnitTest.testListGatewaySenderGatewayReceiver_group GEODE-3780 suspected member is never watched again after passing final check Added FinalCheckPassedMessage to the DSFID registry and added a test to ensure that it's possible to serialize and deserialize one of these objects. --- .../gms/messages/FinalCheckPassedMessage.java | 2 ++ .../java/org/apache/geode/internal/DSFIDFactory.java| 2 ++ .../membership/gms/fd/GMSHealthMonitorJUnitTest.java| 17 + 3 files changed, 21 insertions(+) diff --git a/geode-core/src/main/java/org/apache/geode/distributed/internal/membership/gms/messages/FinalCheckPassedMessage.java b/geode-core/src/main/java/org/apache/geode/distributed/internal/membership/gms/messages/FinalCheckPassedMessage.java index 3f3b278..b64917d 100644 --- a/geode-core/src/main/java/org/apache/geode/distributed/internal/membership/gms/messages/FinalCheckPassedMessage.java +++ b/geode-core/src/main/java/org/apache/geode/distributed/internal/membership/gms/messages/FinalCheckPassedMessage.java @@ -28,6 +28,8 @@ public class FinalCheckPassedMessage extends HighPriorityDistributionMessage { private InternalDistributedMember suspect; + public FinalCheckPassedMessage() {} + public FinalCheckPassedMessage(InternalDistributedMember recipient, InternalDistributedMember suspect) { super(); diff --git a/geode-core/src/main/java/org/apache/geode/internal/DSFIDFactory.java b/geode-core/src/main/java/org/apache/geode/internal/DSFIDFactory.java index 31887ef..d60a913 100644 --- a/geode-core/src/main/java/org/apache/geode/internal/DSFIDFactory.java +++ b/geode-core/src/main/java/org/apache/geode/internal/DSFIDFactory.java @@ -96,6 +96,7 @@ import org.apache.geode.distributed.internal.membership.gms.locator.FindCoordina import org.apache.geode.distributed.internal.membership.gms.locator.FindCoordinatorResponse; import org.apache.geode.distributed.internal.membership.gms.locator.GetViewRequest; import org.apache.geode.distributed.internal.membership.gms.locator.GetViewResponse; +import org.apache.geode.distributed.internal.membership.gms.messages.FinalCheckPassedMessage; import org.apache.geode.distributed.internal.membership.gms.messages.HeartbeatMessage; import org.apache.geode.distributed.internal.membership.gms.messages.HeartbeatRequestMessage; import org.apache.geode.distributed.internal.membership.gms.messages.InstallViewMessage; @@ -475,6 +476,7 @@ public class DSFIDFactory implements DataSerializableFixedID { } private static void registerDSFIDTypes() { +registerDSFID(FINAL_CHECK_PASSED_MESSAGE, FinalCheckPassedMessage.class); registerDSFID(NETWORK_PARTITION_MESSAGE, NetworkPartitionMessage.class); registerDSFID(REMOVE_MEMBER_REQUEST, RemoveMemberMessage.class); registerDSFID(HEARTBEAT_REQUEST, HeartbeatRequestMessage.class); diff --git a/geode-core/src/test/java/org/apache/geode/distributed/internal/membership/gms/fd/GMSHealthMonitorJUnitTest.java b/geode-core/src/test/java/org/apache/geode/distributed/internal/membership/gms/fd/GMSHealthMonitorJUnitTest.java index 2d0d0cd..e7109ca 100644 --- a/geode-core/src/test/java/org/apache/geode/distributed/internal/membership/gms/fd/GMSHealthMonitorJUnitTest.java +++ b/geode-core/src/test/java/org/apache/geode/distributed/internal/membership/gms/fd/GMSHealthMonitorJUnitTest.java @@ -14,6 +14,7 @@ */ package org.apache.geode.distributed.internal.membership.gms.fd; +import org.apache.geode.DataSerializer; import org.apache.geode.distributed.internal.*; import org.apache.geode.distributed.internal.membership.InternalDistributedMember; import org.apache.geode.distributed.internal.membership.NetView; @@ -30,6 +31,7 @@ import org.apache.geode.distributed.internal.membership.gms.messages.HeartbeatMe import org.apache.geode.distributed.internal.membership.gms.messages.HeartbeatRequestMessage; import org.apache.geode.distributed.internal.membership.gms.messages.SuspectMembersMessage; import org.apache.geode.distributed.internal.membership.gms.messages.SuspectRequest; +import org.apache.geode.internal.HeapDataOutputStream; import org.apache.geode.internal.net.SocketCreator; import org.apache.geode.internal.Version; import org.apache.geode.internal.net.SocketCreatorFactory; @@ -529,6 +531,21 @@ public class GMSHea
[geode] branch develop updated: GEODE-2405 Update docs with changes to export cluster-configuration
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 8fdacaf GEODE-2405 Update docs with changes to export cluster-configuration 8fdacaf is described below commit 8fdacafa0c3fdc8020123da388995a9be2e435d3 Author: Dave Barnes AuthorDate: Tue Oct 17 11:55:12 2017 -0700 GEODE-2405 Update docs with changes to export cluster-configuration --- .../configuring/cluster_config/export-import.html.md.erb| 2 +- .../cluster_config/persisting_configurations.html.md.erb| 2 +- .../tools_modules/gfsh/command-pages/export.html.md.erb | 13 +++-- 3 files changed, 9 insertions(+), 8 deletions(-) diff --git a/geode-docs/configuring/cluster_config/export-import.html.md.erb b/geode-docs/configuring/cluster_config/export-import.html.md.erb index 833be90..54c1384 100644 --- a/geode-docs/configuring/cluster_config/export-import.html.md.erb +++ b/geode-docs/configuring/cluster_config/export-import.html.md.erb @@ -33,7 +33,7 @@ in [Cluster Configuration Files and Troubleshooting](gfsh_config_troubleshooting To export a cluster configuration, run the `gfsh` `export cluster-configuration` command while connected to a <%=vars.product_name%> cluster. For example: ``` pre -export cluster-configuration --zip-file-name=myClusterConfig.zip --dir=/home/username/configs +export cluster-configuration --zip-file-name=/home/username/configs/myClusterConfig.zip ``` See [export cluster-configuration](../../tools_modules/gfsh/command-pages/export.html#topic_mdv_jgz_ck). diff --git a/geode-docs/configuring/cluster_config/persisting_configurations.html.md.erb b/geode-docs/configuring/cluster_config/persisting_configurations.html.md.erb index 37f3478..6aa6aa7 100644 --- a/geode-docs/configuring/cluster_config/persisting_configurations.html.md.erb +++ b/geode-docs/configuring/cluster_config/persisting_configurations.html.md.erb @@ -171,7 +171,7 @@ This section provides a walk-through example of configuring a simple <%=vars.pro You can use the `gfsh export cluster-configuration` command to create a zip file that contains the cluster's persisted configuration. The zip file contains a copy of the contents of the `cluster_config` directory. For example: ``` pre -gfsh>export cluster-configuration --zip-file-name=myClConfig.zip --dir=/Users/username +gfsh>export cluster-configuration --zip-file-name=/Users/username/myClConfig.zip ``` <%=vars.product_name_long%> writes the cluster configuration to the specified zip file. diff --git a/geode-docs/tools_modules/gfsh/command-pages/export.html.md.erb b/geode-docs/tools_modules/gfsh/command-pages/export.html.md.erb index 203fdd8..9d4d58c 100644 --- a/geode-docs/tools_modules/gfsh/command-pages/export.html.md.erb +++ b/geode-docs/tools_modules/gfsh/command-pages/export.html.md.erb @@ -58,34 +58,35 @@ See [Overview of the Cluster Configuration Service](../../../configuring/cluster **Syntax:** ``` pre -export cluster-configuration --zip-file-name=value [--dir=value] +export cluster-configuration --zip-file-name=value ``` **Export Cluster-Configuration Parameters:** | Name | Description | Default Value | |---|--|---| -| \\-\\-zip-file-name | *Required.* File name of the zip file to contain the exported cluster configuration. | | -| \\-\\-dir | Directory where the cluster configuration zip files is saved.| Locator directory | +| \\-\\-zip-file-name | *Required.* Filename of the zip file to contain the exported cluster configuration. May also include an absolute or relative path. | | **Example Commands:** ``` pre -gfsh>export cluster-configuration --zip-file-name=/home/username/gemfire/myClusterConfig.zip +gfsh>export cluster-configuration --zip-file-name=/group/shared-configs/devClusterConfig.zip +gfsh>export cluster-configuration --zip-file-name=my-configs/myClusterConfig.zip +gfsh>export cluster-configuration --zip-file-name=myClusterConfig.zip ``` **Sample Output:** ``` pre gfsh>export cluster-configuration --zip-file-name=mySharedConfig.zip -Downloading cluster configuration : /home/username/gemfire/myClusterConfig.zip +Downloading cluster configuration : /home/username/gemfire/mySharedConfig.zip ``` ## export config Export configuration properties for a member or members. -If you do not specify any parameters, all member configuration will be exported. +If you do not specify any parameters, all member configurations will be exported. **
svn commit: r22568 - /dev/geode/1.3.0.RC3/
Author: sbawaskar Date: Wed Oct 18 19:04:49 2017 New Revision: 22568 Log: Releasing Apache Geode 1.3.0.RC3 distribution Added: dev/geode/1.3.0.RC3/ dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.tgz (with props) dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.tgz.asc dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.tgz.md5 dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.tgz.sha256 dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.zip (with props) dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.zip.asc dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.zip.md5 dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.zip.sha256 dev/geode/1.3.0.RC3/apache-geode-1.3.0.tgz (with props) dev/geode/1.3.0.RC3/apache-geode-1.3.0.tgz.asc dev/geode/1.3.0.RC3/apache-geode-1.3.0.tgz.md5 dev/geode/1.3.0.RC3/apache-geode-1.3.0.tgz.sha256 dev/geode/1.3.0.RC3/apache-geode-1.3.0.zip (with props) dev/geode/1.3.0.RC3/apache-geode-1.3.0.zip.asc dev/geode/1.3.0.RC3/apache-geode-1.3.0.zip.md5 dev/geode/1.3.0.RC3/apache-geode-1.3.0.zip.sha256 Added: dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.tgz == Binary file - no diff available. Propchange: dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.tgz -- svn:mime-type = application/octet-stream Added: dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.tgz.asc == --- dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.tgz.asc (added) +++ dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.tgz.asc Wed Oct 18 19:04:49 2017 @@ -0,0 +1,17 @@ +-BEGIN PGP SIGNATURE- +Version: BCPG v1.51 + +iQIcBAABAgAGBQJZ55w3AAoJEI+PK8wY+QLbu8IP/AiJN6FU06hE6mXcAlf7fmVm +46wNMX8uPp7mMzMx5u+b1ddQCcGkpiBR5AR9eHfwiVKICI6lR4IU7dMeSJLQ+7Cb +LAstYh9XTAvP5grhNt/9RY6GEvgxP90QRhzRFkiuqA+ItXowjTjj8py3zeu1C9aq +ZqinfMVa/svj1qhLCXVye8Bk81JYfpyEnVSo6Irh5BYVbzBClEfDZXuEGpi6HJ/p +iEhStHQs3zxli3j3TThOOh84Y8hGTeS4hCJRJANm0hFBIyCjBl6X3FO7XN1Lc+7j +NIS3HoZCWIMgCk4kW1V7Mz6G4soIMyuQq3yfPmQdQ0CVSVPl+FL/yqbMFMrIUHFe +CwJFPYzYzKnOsyyCgNcHaXQxhFgQG388efhtwElGUbc3kxsIxibbss7rj0msr7gP +Ca1n3LQeG3mdY/Q1nECteiBzX7qnb9aFBkyahiyn8Y85ictkv0Hay4V4WnZpNnQc +T4c360tE+tVcUS5PdJ9GPeXKDMtjoKNGLkOcDFvpc5Suo7uE1OgpgdHYh8eCdHIr +SOrTJQJJOWPtzNdJrYWTv2Ea3Eaes0xGOVaY5neXSUK3Ai0keI0BJtphMaYDEUrz +7limGa8rUmoUuewkFVF/lseMpEM4486v9JKMAdtek4t61yPiUvtATJ0zsdSSxnG0 +4BGMiZbU90uBRM3UrHXD +=8XFu +-END PGP SIGNATURE- Added: dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.tgz.md5 == --- dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.tgz.md5 (added) +++ dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.tgz.md5 Wed Oct 18 19:04:49 2017 @@ -0,0 +1 @@ +60bc775b90cefb85f3799df4afcdb673 *apache-geode-1.3.0-src.tgz Added: dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.tgz.sha256 == --- dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.tgz.sha256 (added) +++ dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.tgz.sha256 Wed Oct 18 19:04:49 2017 @@ -0,0 +1 @@ +88f945c05f3c37b63c455bfdb893e64bc90fed9d153683c6c80776e0a36a35b4 *apache-geode-1.3.0-src.tgz Added: dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.zip == Binary file - no diff available. Propchange: dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.zip -- svn:mime-type = application/octet-stream Added: dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.zip.asc == --- dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.zip.asc (added) +++ dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.zip.asc Wed Oct 18 19:04:49 2017 @@ -0,0 +1,17 @@ +-BEGIN PGP SIGNATURE- +Version: BCPG v1.51 + +iQIcBAABAgAGBQJZ55w3AAoJEI+PK8wY+QLb8fwP/i/NGM9dSKSUE9EnI+Cngaj7 +4TOVg6L+f0J00tjPxJS6mgXhRuH2oJ3QM+WyGmP+QCns6FnxTmUxoH7bvQsZgKMo +5BacRNpO3Xy8ywQaozNrhEfTx/hdDPgvg8MC8yXdFpmkARlRyFrFLwpd6htON6WR +7bvkPb6TWq+uAxc9grg1Gtmj9Bt6eJE+1dC1YAlfjYJmid3nBjZbodyqPXU5v6Dg +SVBOLDeKO/yTggxdDXaxrtZmtzg5mUBYREdrW0jzWpbGQ3BuAAmWmQsl9FIRmWv4 +nbeq/Nu2i/PO3hW+pM4PjdIxTF6uFZZT7nEeT/1BS3Fy43JKfjG+RuEDBqqiYFeB +0gOttjGwtp2qasZYicE1daJeFbx+KzSMKHTtFs/5FPUABBgEontZziw0uKTg318C +s8ZEmrlqRnx84rP9QnTBhvWJR3zZA/Lc5VtdVblvmczPS/yGj7TxtHKuJp24Oh5x +O4y9pDvp5mPCPT09W37TbZrPnBPNTNfWnZWXlFTax/DRC+Tbdn4pWvqcaU4v/Rd1 +xsQS15QH4Y88uK/1Ts5w6DnToibXfWomxxv9SIFFyeDBYNQ07V2VyKlWaliq3BHh +ckvEjIRLrIz/EVbo4M4NLp0NauRvB6wTRfWHRboA4rXvxtQMQWUC/Jiyjm+v6ieb +pFXR+pWD/uk4WInh22+Y +=IxWm +-END PGP SIGNATURE- Added: dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.zip.md5 == --- dev/geode/1.3.0.RC3/apache-geode-1.3.0-src.zip.md5 (added) +++ dev/g
[geode] branch feature/GEODE-3521 updated: Handle a situation that RegionEntry can be set in the KeyInfo when iterate through keys.
This is an automated email from the ASF dual-hosted git repository. eshu11 pushed a commit to branch feature/GEODE-3521 in repository https://gitbox.apache.org/repos/asf/geode.git The following commit(s) were added to refs/heads/feature/GEODE-3521 by this push: new 28efea1 Handle a situation that RegionEntry can be set in the KeyInfo when iterate through keys. 28efea1 is described below commit 28efea1d95d2332170da73bf3ea9db6653413def Author: eshu AuthorDate: Wed Oct 18 11:19:51 2017 -0700 Handle a situation that RegionEntry can be set in the KeyInfo when iterate through keys. --- .../main/java/org/apache/geode/internal/cache/TXManagerImpl.java | 2 +- .../src/main/java/org/apache/geode/internal/cache/TXStateStub.java | 7 ++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/geode-core/src/main/java/org/apache/geode/internal/cache/TXManagerImpl.java b/geode-core/src/main/java/org/apache/geode/internal/cache/TXManagerImpl.java index 06aac77..ebd37cc 100644 --- a/geode-core/src/main/java/org/apache/geode/internal/cache/TXManagerImpl.java +++ b/geode-core/src/main/java/org/apache/geode/internal/cache/TXManagerImpl.java @@ -320,7 +320,7 @@ public class TXManagerImpl implements CacheTransactionManager, MembershipListene TXStateProxy curProxy = txContext.get(); if (curProxy == PAUSED) { throw new java.lang.IllegalStateException( -"Currend thread is in a paused state, it can not start a new transaction"); +"Current thread has paused its transaction so it can not start a new transaction"); } } TXId id = new TXId(this.distributionMgrId, this.uniqId.incrementAndGet()); diff --git a/geode-core/src/main/java/org/apache/geode/internal/cache/TXStateStub.java b/geode-core/src/main/java/org/apache/geode/internal/cache/TXStateStub.java index 6055705..76dbca3 100644 --- a/geode-core/src/main/java/org/apache/geode/internal/cache/TXStateStub.java +++ b/geode-core/src/main/java/org/apache/geode/internal/cache/TXStateStub.java @@ -39,6 +39,7 @@ import org.apache.geode.internal.cache.tier.sockets.ClientProxyMembershipID; import org.apache.geode.internal.cache.tier.sockets.VersionedObjectList; import org.apache.geode.internal.cache.tx.TXRegionStub; import org.apache.geode.internal.i18n.LocalizedStrings; +import org.apache.geode.internal.logging.LogService; /** * TXStateStub lives on the accessor node when we are remoting a transaction. It is a stub for @@ -485,7 +486,11 @@ public abstract class TXStateStub implements TXStateInterface { */ public Object getKeyForIterator(KeyInfo keyInfo, LocalRegion currRgn, boolean rememberReads, boolean allowTombstones) { -return keyInfo.getKey(); +Object key = keyInfo.getKey(); +if (key instanceof RegionEntry) { + return ((RegionEntry) key).getKey(); +} +return key; } /* -- To stop receiving notification emails like this one, please contact ['"commits@geode.apache.org" '].
[geode] 02/02: GEODE-3299: Remove unneeded constructor
This is an automated email from the ASF dual-hosted git repository. khowe pushed a commit to branch develop in repository https://gitbox.apache.org/repos/asf/geode.git commit b5e3db5260026b3a9882c54e254397f6d3749cb8 Author: Ken Howe AuthorDate: Tue Oct 17 11:20:00 2017 -0700 GEODE-3299: Remove unneeded constructor --- .../apache/geode/management/internal/cli/result/CommandResultTest.java | 1 - 1 file changed, 1 deletion(-) diff --git a/geode-core/src/test/java/org/apache/geode/management/internal/cli/result/CommandResultTest.java b/geode-core/src/test/java/org/apache/geode/management/internal/cli/result/CommandResultTest.java index e320b7e..59fb1fb 100644 --- a/geode-core/src/test/java/org/apache/geode/management/internal/cli/result/CommandResultTest.java +++ b/geode-core/src/test/java/org/apache/geode/management/internal/cli/result/CommandResultTest.java @@ -26,7 +26,6 @@ import org.junit.experimental.categories.Category; @Category({UnitTest.class}) public class CommandResultTest { - public CommandResultTest() {} @Test public void emptyResultHasOneEmptyLine() { -- To stop receiving notification emails like this one, please contact "commits@geode.apache.org" .
[geode] 01/02: GEODE-3299: refactor functions to get Cache from FunctionContext
This is an automated email from the ASF dual-hosted git repository. khowe pushed a commit to branch develop in repository https://gitbox.apache.org/repos/asf/geode.git commit c855209c98852249caf1013dbcf2a801ea8768a1 Author: Ken Howe AuthorDate: Thu Oct 12 13:34:17 2017 -0700 GEODE-3299: refactor functions to get Cache from FunctionContext This is the 4th set of updates. --- .../internal/cli/commands/CreateRegionCommand.java | 2 +- .../internal/cli/commands/GetCommand.java | 3 +- .../internal/cli/commands/PutCommand.java | 2 +- .../internal/cli/commands/RemoveCommand.java | 2 +- .../cli/functions/DataCommandFunction.java | 62 -- .../functions/FetchRegionAttributesFunction.java | 7 +- .../cli/functions/ListDiskStoresFunction.java | 7 +- .../internal/cli/functions/ListIndexFunction.java | 7 +- .../functions/DataCommandFunctionJUnitTest.java| 8 ++- .../DataCommandFunctionWithPDXJUnitTest.java | 7 +- .../internal/cli/functions/Geode3544JUnitTest.java | 3 +- .../functions/ListDiskStoresFunctionJUnitTest.java | 75 +++--- .../cli/functions/ListIndexFunctionJUnitTest.java | 31 +++-- .../internal/cli/result/CommandResultTest.java | 18 ++ 14 files changed, 87 insertions(+), 147 deletions(-) diff --git a/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/CreateRegionCommand.java b/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/CreateRegionCommand.java index 708c3f1..99c5d0b 100644 --- a/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/CreateRegionCommand.java +++ b/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/CreateRegionCommand.java @@ -568,7 +568,7 @@ public class CreateRegionCommand implements GfshCommand { // First check whether the region exists on a this manager, if yes then no // need to use FetchRegionAttributesFunction to fetch RegionAttributes try { - attributes = FetchRegionAttributesFunction.getRegionAttributes(regionPath); + attributes = FetchRegionAttributesFunction.getRegionAttributes(cache, regionPath); } catch (IllegalArgumentException e) { /* region doesn't exist on the manager */ } diff --git a/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/GetCommand.java b/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/GetCommand.java index 0ccdfe0..ed7ab26 100644 --- a/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/GetCommand.java +++ b/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/GetCommand.java @@ -84,8 +84,7 @@ public class GetCommand implements GfshCommand { false); } } else { - dataResult = getfn.get(null, key, keyClass, valueClass, regionPath, loadOnCacheMiss, - cache.getSecurityService()); + dataResult = getfn.get(null, key, keyClass, valueClass, regionPath, loadOnCacheMiss, cache); } dataResult.setKeyClass(keyClass); if (valueClass != null) { diff --git a/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/PutCommand.java b/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/PutCommand.java index a2e1903..b20aeb1 100644 --- a/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/PutCommand.java +++ b/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/PutCommand.java @@ -81,7 +81,7 @@ public class PutCommand implements GfshCommand { false); } } else { - dataResult = putfn.put(key, value, putIfAbsent, keyClass, valueClass, regionPath); + dataResult = putfn.put(key, value, putIfAbsent, keyClass, valueClass, regionPath, cache); } dataResult.setKeyClass(keyClass); if (valueClass != null) { diff --git a/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/RemoveCommand.java b/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/RemoveCommand.java index fa5f4b9..1318cdf 100644 --- a/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/RemoveCommand.java +++ b/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/RemoveCommand.java @@ -84,7 +84,7 @@ public class RemoveCommand implements GfshCommand { request.setRegionName(regionPath); dataResult = callFunctionForRegion(request, removefn, memberList); } else { - dataResult = removefn.remove(key, keyClass, regionPath, removeAllKeys ? "ALL" : null); + dataResult = removefn.remove(key, keyClass, regionPath, removeAllKeys ? "ALL" : null, cache); } dataResult.setKeyClass(keyClass); diff --git a/geode-core/src/main/java/org/apache/geode/management/internal/cli/functions/DataCommandFunction.java b/geode-core/src/main/java/or
[geode] branch develop updated (b16a709 -> b5e3db5)
This is an automated email from the ASF dual-hosted git repository. khowe pushed a change to branch develop in repository https://gitbox.apache.org/repos/asf/geode.git. from b16a709 GEODE-3819: correctly set the result status code when building the re… (#935) new c855209 GEODE-3299: refactor functions to get Cache from FunctionContext new b5e3db5 GEODE-3299: Remove unneeded constructor The 2 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "add" were already present in the repository and have only been added to this reference. Summary of changes: .../internal/cli/commands/CreateRegionCommand.java | 2 +- .../internal/cli/commands/GetCommand.java | 3 +- .../internal/cli/commands/PutCommand.java | 2 +- .../internal/cli/commands/RemoveCommand.java | 2 +- .../cli/functions/DataCommandFunction.java | 62 -- .../functions/FetchRegionAttributesFunction.java | 7 +- .../cli/functions/ListDiskStoresFunction.java | 7 +- .../internal/cli/functions/ListIndexFunction.java | 7 +- .../functions/DataCommandFunctionJUnitTest.java| 8 ++- .../DataCommandFunctionWithPDXJUnitTest.java | 7 +- .../internal/cli/functions/Geode3544JUnitTest.java | 3 +- .../functions/ListDiskStoresFunctionJUnitTest.java | 75 +++--- .../cli/functions/ListIndexFunctionJUnitTest.java | 31 +++-- .../internal/cli/result/CommandResultTest.java | 17 ++--- 14 files changed, 86 insertions(+), 147 deletions(-) -- To stop receiving notification emails like this one, please contact ['"commits@geode.apache.org" '].
[geode] branch release/1.3.0 updated: GEODE-3859: Simplify API for reading output from a GfshScript
This is an automated email from the ASF dual-hosted git repository. jstewart pushed a commit to branch release/1.3.0 in repository https://gitbox.apache.org/repos/asf/geode.git The following commit(s) were added to refs/heads/release/1.3.0 by this push: new 59f2a73 GEODE-3859: Simplify API for reading output from a GfshScript 59f2a73 is described below commit 59f2a73d108101744ed7b2d88e8d1c948d19781c Author: Jared Stewart AuthorDate: Tue Oct 17 14:27:01 2017 -0700 GEODE-3859: Simplify API for reading output from a GfshScript (cherry picked from commit 4dd26da) --- .../StopServerWithSecurityAcceptanceTest.java | 8 ++-- .../geode/test/junit/rules/gfsh/GfshExecution.java | 17 ++-- .../test/junit/rules/gfsh/internal/OutputLine.java | 45 ++ .../rules/gfsh/{ => internal}/ProcessLogger.java | 40 +-- .../rules/gfsh/{ => internal}/StreamGobbler.java | 2 +- 5 files changed, 81 insertions(+), 31 deletions(-) diff --git a/geode-assembly/src/test/java/org/apache/geode/management/internal/cli/commands/StopServerWithSecurityAcceptanceTest.java b/geode-assembly/src/test/java/org/apache/geode/management/internal/cli/commands/StopServerWithSecurityAcceptanceTest.java index 4588ee6..7d5405a 100644 --- a/geode-assembly/src/test/java/org/apache/geode/management/internal/cli/commands/StopServerWithSecurityAcceptanceTest.java +++ b/geode-assembly/src/test/java/org/apache/geode/management/internal/cli/commands/StopServerWithSecurityAcceptanceTest.java @@ -60,7 +60,7 @@ public class StopServerWithSecurityAcceptanceTest { startCluster(); GfshExecution stopServer = dataReaderCannotStopServer(true); -assertThat(stopServer.getStdErrText()).contains("dataReader not authorized for CLUSTER:READ"); +assertThat(stopServer.getOutputText()).contains("dataReader not authorized for CLUSTER:READ"); } @Test @@ -75,7 +75,7 @@ public class StopServerWithSecurityAcceptanceTest { startCluster(); GfshExecution stopServer = dataReaderCannotStopServer(false); -assertThat(stopServer.getStdErrText()).contains("dataReader not authorized for CLUSTER:READ"); +assertThat(stopServer.getOutputText()).contains("dataReader not authorized for CLUSTER:READ"); } @Test @@ -90,7 +90,7 @@ public class StopServerWithSecurityAcceptanceTest { startCluster(); GfshExecution stopServer = clusterReaderCannotStopServer(false); -assertThat(stopServer.getStdErrText()) +assertThat(stopServer.getOutputText()) .contains("clusterRead not authorized for CLUSTER:MANAGE"); } @@ -99,7 +99,7 @@ public class StopServerWithSecurityAcceptanceTest { startCluster(); GfshExecution stopServer = clusterReaderCannotStopServer(true); -assertThat(stopServer.getStdErrText()) +assertThat(stopServer.getOutputText()) .contains("clusterRead not authorized for CLUSTER:MANAGE"); } diff --git a/geode-junit/src/main/java/org/apache/geode/test/junit/rules/gfsh/GfshExecution.java b/geode-junit/src/main/java/org/apache/geode/test/junit/rules/gfsh/GfshExecution.java index 23d83e6..3c1e130 100644 --- a/geode-junit/src/main/java/org/apache/geode/test/junit/rules/gfsh/GfshExecution.java +++ b/geode-junit/src/main/java/org/apache/geode/test/junit/rules/gfsh/GfshExecution.java @@ -14,12 +14,9 @@ */ package org.apache.geode.test.junit.rules.gfsh; -import static java.util.stream.Collectors.joining; - import java.io.File; -import java.util.List; -import org.apache.commons.lang.SystemUtils; +import org.apache.geode.test.junit.rules.gfsh.internal.ProcessLogger; public class GfshExecution { private final Process process; @@ -32,16 +29,8 @@ public class GfshExecution { this.processLogger = new ProcessLogger(process, workingDir.getName()); } - public List getStdOutLines() { -return processLogger.getStdOutLines(); - } - - public List getStdErrLines() { -return processLogger.getStdErrLines(); - } - - public String getStdErrText() { -return getStdErrLines().stream().collect(joining(SystemUtils.LINE_SEPARATOR)); + public String getOutputText() { +return processLogger.getOutputText(); } /** diff --git a/geode-junit/src/main/java/org/apache/geode/test/junit/rules/gfsh/internal/OutputLine.java b/geode-junit/src/main/java/org/apache/geode/test/junit/rules/gfsh/internal/OutputLine.java new file mode 100644 index 000..ecf7ca3 --- /dev/null +++ b/geode-junit/src/main/java/org/apache/geode/test/junit/rules/gfsh/internal/OutputLine.java @@ -0,0 +1,45 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more contributor license + * agreements. See the NOTICE file distributed with this work for additional information regarding + * copyright ownership. The ASF licenses this file to You under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance with the License. You may obtain a + * copy of t
[geode] branch develop updated: GEODE-3819: correctly set the result status code when building the re… (#935)
This is an automated email from the ASF dual-hosted git repository. jinmeiliao 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 b16a709 GEODE-3819: correctly set the result status code when building the re… (#935) b16a709 is described below commit b16a709bc72589446959740f88de8d25793c9e17 Author: jinmeiliao AuthorDate: Wed Oct 18 08:59:57 2017 -0700 GEODE-3819: correctly set the result status code when building the re… (#935) * GEODE-3819: correctly set the result status code when building the result from json string --- .../internal/cli/commands/CreateRegionCommand.java | 8 +--- .../management/internal/cli/result/ErrorResultData.java| 6 -- .../management/internal/cli/result/ResultBuilder.java | 7 +++ .../management/internal/cli/result/ResultBuilderTest.java | 9 + .../internal/security/GfshCommandsSecurityTest.java| 14 +- 5 files changed, 26 insertions(+), 18 deletions(-) diff --git a/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/CreateRegionCommand.java b/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/CreateRegionCommand.java index e5aced8..708c3f1 100644 --- a/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/CreateRegionCommand.java +++ b/geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/CreateRegionCommand.java @@ -29,7 +29,6 @@ import org.springframework.shell.core.annotation.CliCommand; import org.springframework.shell.core.annotation.CliOption; import org.apache.geode.cache.DataPolicy; -import org.apache.geode.cache.PartitionResolver; import org.apache.geode.cache.Region; import org.apache.geode.cache.RegionAttributes; import org.apache.geode.cache.RegionShortcut; @@ -159,7 +158,6 @@ public class CreateRegionCommand implements GfshCommand { ) { Result result; AtomicReference xmlEntity = new AtomicReference<>(); -String lastError = null; try { InternalCache cache = getCache(); @@ -297,7 +295,7 @@ public class CreateRegionCommand implements GfshCommand { if (success) { xmlEntity.set(regionCreateResult.getXmlEntity()); } else { - lastError = regionCreateResult.getMessage(); + tabularResultData.setStatus(Result.Status.ERROR); } } result = ResultBuilder.buildResult(tabularResultData); @@ -308,10 +306,6 @@ public class CreateRegionCommand implements GfshCommand { result = ResultBuilder.createUserErrorResult(e.getMessage()); } -if (lastError != null) { - result = ResultBuilder.createUserErrorResult(lastError); -} - if (xmlEntity.get() != null) { persistClusterConfiguration(result, () -> getSharedConfiguration().addXmlEntity(xmlEntity.get(), groups)); diff --git a/geode-core/src/main/java/org/apache/geode/management/internal/cli/result/ErrorResultData.java b/geode-core/src/main/java/org/apache/geode/management/internal/cli/result/ErrorResultData.java index 9edcdbf..9734bf2 100644 --- a/geode-core/src/main/java/org/apache/geode/management/internal/cli/result/ErrorResultData.java +++ b/geode-core/src/main/java/org/apache/geode/management/internal/cli/result/ErrorResultData.java @@ -98,8 +98,10 @@ public class ErrorResultData extends InfoResultData { @Override public void setStatus(final Status status) { -throw new UnsupportedOperationException( -"The status of an ErrorResultData result must always be ERROR"); +if (status != Status.ERROR) { + throw new UnsupportedOperationException( + "The status of an ErrorResultData result must always be ERROR"); +} } @Override diff --git a/geode-core/src/main/java/org/apache/geode/management/internal/cli/result/ResultBuilder.java b/geode-core/src/main/java/org/apache/geode/management/internal/cli/result/ResultBuilder.java index 460ade2..22db17c 100755 --- a/geode-core/src/main/java/org/apache/geode/management/internal/cli/result/ResultBuilder.java +++ b/geode-core/src/main/java/org/apache/geode/management/internal/cli/result/ResultBuilder.java @@ -230,6 +230,13 @@ public class ResultBuilder { resultData = errorResultData; } + Integer statusCode = (Integer) jsonObject.get("status"); + if (Result.Status.OK.getCode() == statusCode) { +resultData.setStatus(Result.Status.OK); + } else { +resultData.setStatus(Result.Status.ERROR); + } + result = buildResult(resultData); String fileToDownloadPath = jsonObject.getString("fileToDownload"); diff --git a/geode-core/src/test/java/org/apache/geode/management/internal/cli/result/ResultBuilderTest.java b/geode-core/src/test/java/org/apache/geode/management/internal/cli/result/ResultBuilderTest.java index 0ce89c1..3b4e371 100644 --
[geode] branch develop updated: GEODE-2563: fix flaky test (#942)
This is an automated email from the ASF dual-hosted git repository. jinmeiliao 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 7b866cc GEODE-2563: fix flaky test (#942) 7b866cc is described below commit 7b866ccfb2bf0970f5a30ca4bf2016d58761d5d2 Author: jinmeiliao AuthorDate: Wed Oct 18 08:59:16 2017 -0700 GEODE-2563: fix flaky test (#942) --- .../internal/cli/commands/DestroyRegionCommandDUnitTest.java | 12 +++- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/geode-core/src/test/java/org/apache/geode/management/internal/cli/commands/DestroyRegionCommandDUnitTest.java b/geode-core/src/test/java/org/apache/geode/management/internal/cli/commands/DestroyRegionCommandDUnitTest.java index 5a193d5..89bb3bd 100644 --- a/geode-core/src/test/java/org/apache/geode/management/internal/cli/commands/DestroyRegionCommandDUnitTest.java +++ b/geode-core/src/test/java/org/apache/geode/management/internal/cli/commands/DestroyRegionCommandDUnitTest.java @@ -125,7 +125,7 @@ public class DestroyRegionCommandDUnitTest { Cache cache = LocatorServerStartupRule.serverStarter.getCache(); RegionFactory factory = cache.createRegionFactory(RegionShortcut.PARTITION); factory.create("Customer"); - factory.create("Customer-2"); + factory.create("Customer_2"); factory.create("Customer_3"); }, server1, server2); @@ -134,20 +134,22 @@ public class DestroyRegionCommandDUnitTest { RegionFactory factory = cache.createRegionFactory(RegionShortcut.REPLICATE); factory.setScope(Scope.LOCAL); factory.create("Customer"); - factory.create("Customer-2"); + factory.create("Customer_2"); factory.create("Customer_3"); }); locator.invoke(() -> waitForRegionMBeanCreation("/Customer", 3)); +locator.invoke(() -> waitForRegionMBeanCreation("/Customer_2", 3)); +locator.invoke(() -> waitForRegionMBeanCreation("/Customer_3", 3)); gfsh.executeAndVerifyCommand("destroy region --name=Customer", "destroyed successfully"); -gfsh.executeAndVerifyCommand("destroy region --name=Customer-2", "destroyed successfully"); +gfsh.executeAndVerifyCommand("destroy region --name=Customer_2", "destroyed successfully"); gfsh.executeAndVerifyCommand("destroy region --name=Customer_3", "destroyed successfully"); MemberVM.invokeInEveryMember(() -> { Cache cache = LocatorServerStartupRule.serverStarter.getCache(); assertThat(cache.getRegion("Customer")).isNull(); - assertThat(cache.getRegion("Customer-2")).isNull(); + assertThat(cache.getRegion("Customer_2")).isNull(); assertThat(cache.getRegion("Customer_3")).isNull(); }, server1, server2, server3); } @@ -199,7 +201,7 @@ public class DestroyRegionCommandDUnitTest { String queryExp = MessageFormat.format(ManagementConstants.OBJECTNAME__REGION_MXBEAN, regionPath, "*"); ObjectName queryExpON = new ObjectName(queryExp); -return mbeanServer.queryNames(null, queryExpON).size() == mbeanCount; +return mbeanServer.queryNames(queryExpON, null).size() == mbeanCount; } catch (MalformedObjectNameException mone) { throw new RuntimeException(mone); } -- To stop receiving notification emails like this one, please contact ['"commits@geode.apache.org" '].