Build failed in Jenkins: Geode-nightly-flaky #105

2017-08-28 Thread Apache Jenkins Server
See 


Changes:

[upthewaterspout] GEODE-3513: Removing the use of native sessions session 
caching

[klund] GEODE-3527: increase timeouts for file deletion

[klund] GEODE-3527: use consistent value for all timeouts

[klund] GEODE-3508: Remove three unused internal deprecated classes.

[bschuchardt] GEODE-3447 Implement client authorization for the new protocol

[khowe] GEODE-3277: Fix error path constructors of Launcher inner State classess

[khowe] GEODE-3277: Fix test failure caused by ServerState changes

[dschneider] GEODE-3448: Implement and expose parallel snapshot import

[khowe] GEODE-3277: Fix test failure caused by ServerState changes

[jdeppe] [#150615582] limit .gitattributes to only java files

--
[...truncated 110.43 KB...]
Download 
https://repo1.maven.org/maven2/io/springfox/springfox-spi/2.6.1/springfox-spi-2.6.1.pom
Download 
https://repo1.maven.org/maven2/io/springfox/springfox-schema/2.6.1/springfox-schema-2.6.1.pom
Download 
https://repo1.maven.org/maven2/io/springfox/springfox-swagger-common/2.6.1/springfox-swagger-common-2.6.1.pom
Download 
https://repo1.maven.org/maven2/io/springfox/springfox-spring-web/2.6.1/springfox-spring-web-2.6.1.pom
Download 
https://repo1.maven.org/maven2/com/fasterxml/classmate/1.3.1/classmate-1.3.1.pom
Download 
https://repo1.maven.org/maven2/org/springframework/plugin/spring-plugin-core/1.2.0.RELEASE/spring-plugin-core-1.2.0.RELEASE.pom
Download 
https://repo1.maven.org/maven2/org/springframework/plugin/spring-plugin/1.2.0.RELEASE/spring-plugin-1.2.0.RELEASE.pom
Download 
https://repo1.maven.org/maven2/org/springframework/plugin/spring-plugin-metadata/1.2.0.RELEASE/spring-plugin-metadata-1.2.0.RELEASE.pom
Download 
https://repo1.maven.org/maven2/org/mapstruct/mapstruct/1.0.0.Final/mapstruct-1.0.0.Final.pom
Download 
https://repo1.maven.org/maven2/org/mapstruct/mapstruct-parent/1.0.0.Final/mapstruct-parent-1.0.0.Final.pom
Download 
https://repo1.maven.org/maven2/org/springframework/spring-expression/4.3.5.RELEASE/spring-expression-4.3.5.RELEASE.pom
Download 
https://repo1.maven.org/maven2/com/thoughtworks/paranamer/paranamer/2.8/paranamer-2.8.pom
Download 
https://repo1.maven.org/maven2/com/thoughtworks/paranamer/paranamer-parent/2.8/paranamer-parent-2.8.pom
Download 
https://repo1.maven.org/maven2/io/springfox/springfox-core/2.6.1/springfox-core-2.6.1.pom
Download 
https://repo1.maven.org/maven2/com/fasterxml/jackson/module/jackson-module-scala_2.10/2.8.6/jackson-module-scala_2.10-2.8.6.jar
Download 
https://repo1.maven.org/maven2/io/springfox/springfox-swagger2/2.6.1/springfox-swagger2-2.6.1.jar
Download 
https://repo1.maven.org/maven2/io/springfox/springfox-swagger-ui/2.6.1/springfox-swagger-ui-2.6.1.jar
Download 
https://repo1.maven.org/maven2/org/springframework/hateoas/spring-hateoas/0.23.0.RELEASE/spring-hateoas-0.23.0.RELEASE.jar
Download 
https://repo1.maven.org/maven2/org/scala-lang/scala-library/2.10.6/scala-library-2.10.6.jar
Download 
https://repo1.maven.org/maven2/org/scala-lang/scala-reflect/2.10.6/scala-reflect-2.10.6.jar
Download 
https://repo1.maven.org/maven2/com/fasterxml/jackson/module/jackson-module-paranamer/2.8.6/jackson-module-paranamer-2.8.6.jar
Download 
https://repo1.maven.org/maven2/io/swagger/swagger-annotations/1.5.10/swagger-annotations-1.5.10.jar
Download 
https://repo1.maven.org/maven2/io/swagger/swagger-models/1.5.10/swagger-models-1.5.10.jar
Download 
https://repo1.maven.org/maven2/io/springfox/springfox-spi/2.6.1/springfox-spi-2.6.1.jar
Download 
https://repo1.maven.org/maven2/io/springfox/springfox-schema/2.6.1/springfox-schema-2.6.1.jar
Download 
https://repo1.maven.org/maven2/io/springfox/springfox-swagger-common/2.6.1/springfox-swagger-common-2.6.1.jar
Download 
https://repo1.maven.org/maven2/io/springfox/springfox-spring-web/2.6.1/springfox-spring-web-2.6.1.jar
Download 
https://repo1.maven.org/maven2/com/fasterxml/classmate/1.3.1/classmate-1.3.1.jar
Download 
https://repo1.maven.org/maven2/org/springframework/plugin/spring-plugin-core/1.2.0.RELEASE/spring-plugin-core-1.2.0.RELEASE.jar
Download 
https://repo1.maven.org/maven2/org/springframework/plugin/spring-plugin-metadata/1.2.0.RELEASE/spring-plugin-metadata-1.2.0.RELEASE.jar
Download 
https://repo1.maven.org/maven2/org/mapstruct/mapstruct/1.0.0.Final/mapstruct-1.0.0.Final.jar
Download 
https://repo1.maven.org/maven2/com/thoughtworks/paranamer/paranamer/2.8/paranamer-2.8.jar
Download 
https://repo1.maven.org/maven2/io/springfox/springfox-core/2.6.1/springfox-core-2.6.1.jar
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
:geode-web-api:processResources
:geode-web-api:classes
:geode-assembly:docs
:geode-assembly:gfshDepsJar
:geode-common:javadocJar
:geode-common:sourcesJar
:geode-common:signArchives SKIPPED
:geode-core:javadocJar
:geode-core:raJar
:geode-core:jcaJar

Build failed in Jenkins: Geode-nightly #937

2017-08-28 Thread Apache Jenkins Server
See 

--
[...truncated 79.27 KB...]
at 
org.apache.geode.test.dunit.rules.gfsh.GfshScript.awaitLoudly(GfshScript.java:133)
at 
org.apache.geode.test.dunit.rules.gfsh.GfshScript.awaitIfNecessary(GfshScript.java:112)
at 
org.apache.geode.test.dunit.rules.gfsh.GfshRule.execute(GfshRule.java:64)
at 
org.apache.geode.test.dunit.rules.gfsh.GfshScript.execute(GfshScript.java:105)
at 
org.apache.geode.management.internal.cli.shell.GfshExitCodeStatusCommandsTest$TestConfiguration.startNecessaryMembers(GfshExitCodeStatusCommandsTest.java:384)
at 
org.apache.geode.management.internal.cli.shell.GfshExitCodeStatusCommandsTest.offlineStatusCommandShouldSucceedWhenConnected_server_dir(GfshExitCodeStatusCommandsTest.java:199)

org.apache.geode.management.internal.cli.shell.GfshExitCodeStatusCommandsTest > 
offlineStatusCommandShouldSucceedWhenConnected_server_pid FAILED
org.junit.ComparisonFailure: expected:<[tru]e> but was:<[fals]e>
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at 
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at 
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at 
org.apache.geode.test.dunit.rules.gfsh.GfshScript.awaitLoudly(GfshScript.java:133)
at 
org.apache.geode.test.dunit.rules.gfsh.GfshScript.awaitIfNecessary(GfshScript.java:112)
at 
org.apache.geode.test.dunit.rules.gfsh.GfshRule.execute(GfshRule.java:64)
at 
org.apache.geode.test.dunit.rules.gfsh.GfshScript.execute(GfshScript.java:105)
at 
org.apache.geode.management.internal.cli.shell.GfshExitCodeStatusCommandsTest$TestConfiguration.startNecessaryMembers(GfshExitCodeStatusCommandsTest.java:384)
at 
org.apache.geode.management.internal.cli.shell.GfshExitCodeStatusCommandsTest.offlineStatusCommandShouldSucceedWhenConnected_server_pid(GfshExitCodeStatusCommandsTest.java:219)

org.apache.geode.management.internal.cli.shell.GfshExitCodeStatusCommandsTest > 
onlineStatusCommandShouldSucceedWhenConnected_locator_host_and_port FAILED
org.junit.ComparisonFailure: expected:<[0]> but was:<[1]>
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at 
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at 
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at 
org.apache.geode.test.dunit.rules.gfsh.GfshScript.awaitIfNecessary(GfshScript.java:115)
at 
org.apache.geode.test.dunit.rules.gfsh.GfshRule.execute(GfshRule.java:64)
at 
org.apache.geode.test.dunit.rules.gfsh.GfshScript.execute(GfshScript.java:105)
at 
org.apache.geode.management.internal.cli.shell.GfshExitCodeStatusCommandsTest.executeScriptWithExpectedExitCode(GfshExitCodeStatusCommandsTest.java:355)
at 
org.apache.geode.management.internal.cli.shell.GfshExitCodeStatusCommandsTest.onlineStatusCommandShouldSucceedWhenConnected_locator_host_and_port(GfshExitCodeStatusCommandsTest.java:182)

org.apache.geode.management.internal.cli.shell.GfshExitCodeStatusCommandsTest > 
offlineStatusCommandShouldSucceedEvenWhenNotConnected_server_dir FAILED
org.junit.ComparisonFailure: expected:<[tru]e> but was:<[fals]e>
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at 
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at 
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at 
org.apache.geode.test.dunit.rules.gfsh.GfshScript.awaitLoudly(GfshScript.java:133)
at 
org.apache.geode.test.dunit.rules.gfsh.GfshScript.awaitIfNecessary(GfshScript.java:112)
at 
org.apache.geode.test.dunit.rules.gfsh.GfshRule.execute(GfshRule.java:64)
at 
org.apache.geode.test.dunit.rules.gfsh.GfshScript.execute(GfshScript.java:105)
at 
org.apache.geode.management.internal.cli.shell.GfshExitCodeStatusCommandsTest$TestConfiguration.startNecessaryMembers(GfshExitCodeStatusCommandsTest.java:384)
at 
org.apache.geode.management.internal.cli.shell.GfshExitCodeStatusCommandsTest.offlineStatusCommandShouldSucceedEvenWhenNotConnected_server_dir(GfshExitCodeStatusCommandsTest.java:239)

org.apache.geode.management.internal.cli.shell.GfshExitCodeStatusCommandsTest > 
offlineStatusCommandShouldSucceedEvenWhenNotConnected_server_pid FAILED
org.junit.ComparisonFailure: expected:<[tru]e> but was:<[fals]e>
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at 
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at 

[GitHub] geode-examples pull request #14: GEODE-3440: Add example for function execut...

2017-08-28 Thread PivotalSarge
GitHub user PivotalSarge opened a pull request:

https://github.com/apache/geode-examples/pull/14

GEODE-3440: Add example for function execution.



You can merge this pull request into a Git repository by running:

$ git pull https://github.com/PivotalSarge/geode-examples feature/GEODE-3440

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/geode-examples/pull/14.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #14


commit a809fc829879b3df3d87ffa9ae99ed883267ef53
Author: Sarge 
Date:   2017-08-14T23:40:27Z

GEODE-3440: Add example for function execution.




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #747: GEODE-3514: Clean up locator and protobuf related c...

2017-08-28 Thread pivotal-amurmann
GitHub user pivotal-amurmann opened a pull request:

https://github.com/apache/geode/pull/747

GEODE-3514: Clean up locator and protobuf related code

* Check for feature flag only once
* Simplify TcpServerFactory
* Indicate RoundTripLocatorConnection test properly as DUnit test
* Move InvalidExecutionContextException to exception package.

Signed-off-by: Alexander Murmann 
Signed-off-by: Brian Rowe 

Thank you for submitting a contribution to Apache Geode.

In order to streamline the review of the contribution we ask you
to ensure the following steps have been taken:

### For all changes:
- [x] Is there a JIRA ticket associated with this PR? Is it referenced in 
the commit message?

- [x] Has your PR been rebased against the latest commit within the target 
branch (typically `develop`)?

- [ ] Is your initial contribution a single, squashed commit?

- [ ] Does `gradlew build` run cleanly?
It does not b/c develop is red. I will rebase again once that's fixed

- [ ] Have you written or updated unit tests to verify your changes?

- [ ] If adding new dependencies to the code, are these dependencies 
licensed in a way that is compatible for inclusion under [ASF 
2.0](http://www.apache.org/legal/resolved.html#category-a)?

### Note:
Please ensure that once the PR is submitted, you check travis-ci for build 
issues and
submit an update to your PR as soon as possible. If you need help, please 
send an
email to dev@geode.apache.org.


You can merge this pull request into a Git repository by running:

$ git pull https://github.com/pivotal-amurmann/geode 
chore/GEODE-3514/locator_cleanup

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/geode/pull/747.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #747


commit 68bc6dd7853245e49bfee874af41a80eb68af159
Author: Brian Rowe 
Date:   2017-08-24T19:09:05Z

GEODE-3514: Clean up locator and protobuf related code

* Check for feature flag only once
* Simplify TcpServerFactory
* Indicate RoundTripLocatorConnection test properly as DUnit test
* Move InvalidExecutionContextException to exception package.

Signed-off-by: Alexander Murmann 
Signed-off-by: Brian Rowe 




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #745: GEODE-3436: Restore reverted GFSH command refactori...

2017-08-28 Thread PurelyApplied
Github user PurelyApplied closed the pull request at:

https://github.com/apache/geode/pull/745


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #745: GEODE-3436: Restore reverted GFSH command refactori...

2017-08-28 Thread PurelyApplied
GitHub user PurelyApplied reopened a pull request:

https://github.com/apache/geode/pull/745

GEODE-3436: Restore reverted GFSH command refactoring

Given that this would restore multiple tickets worth of commits, it was 
unclear if this PR should squash all commits or if the history would be clearer 
without one enormous commit.

Precheckin returned green excepting spotless and some other minor 
adjustments (import ordering correction, etc).  Running another precheckin for 
due course.

-

Thank you for submitting a contribution to Apache Geode.

In order to streamline the review of the contribution we ask you
to ensure the following steps have been taken:

### For all changes:
- [x] Is there a JIRA ticket associated with this PR? Is it referenced in 
the commit message?

- [x] Has your PR been rebased against the latest commit within the target 
branch (typically `develop`)?

- [ ] Is your initial contribution a single, squashed commit?

- [x] Does `gradlew build` run cleanly?

- [n/a] Have you written or updated unit tests to verify your changes? 
[Existing tests provide coverage for refactored code.]

- [n/a] If adding new dependencies to the code, are these dependencies 
licensed in a way that is compatible for inclusion under [ASF 
2.0](http://www.apache.org/legal/resolved.html#category-a)?

### Note:
Please ensure that once the PR is submitted, you check travis-ci for build 
issues and
submit an update to your PR as soon as possible. If you need help, please 
send an
email to dev@geode.apache.org.


You can merge this pull request into a Git repository by running:

$ git pull https://github.com/PurelyApplied/geode geode-3436

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/geode/pull/745.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #745


commit caeb8375db68d68ec0ddbca6b81fd6ca6c91a73f
Author: YehEmily 
Date:   2017-08-22T17:57:05Z

GEODE-3436: Restore refactoring of MemberCommands

* See initial commit GEODE-3264 (d27f8b956de7d9c5d95ebdc68dfc67ee8b2d7b51)

commit 44cc0e8bb7927e61bb3e7613612703518fc87db6
Author: YehEmily 
Date:   2017-08-07T18:52:14Z

GEODE-3436: Restore refactoring of DurableClientCommands

* See initial commit GEODE-3259 (440c87f81fab96f9ce38a2d53ded75e5fe8390d7)

commit 1e9eea1f1b2d2c620679283aaf6e6c5ac12e1728
Author: YehEmily 
Date:   2017-08-04T17:47:48Z

GEODE-3436: Restore refactoring of PDXCommands

* See initial commit GEODE-3266 (67185abcdd68b908dea6888cb94286b8aa9ea49f)

commit 691700c2e51aef5b18ba5feec711bddf5ae9a05e
Author: YehEmily 
Date:   2017-08-07T20:58:08Z

GEODE-3436: Restore refactoring of RegionCommands

* See initial commits GEODE-3268 
(64de3b69c2aecb4930bcfd0a1161569b1d5fda89), GEODE-3255 
(756efe77c86bb03ac9984655e7bd040659e85890)

commit 0acf8be27f5ab5f6d9d5009bb7ec6740c1f7ae1b
Author: YehEmily 
Date:   2017-08-07T21:47:15Z

GEODE-3436: Restore refactoring of QueueCommands

* See initial commit GEODE-3267 (fd47ed660168864a6f81b2a4cd7dbceebc99a282)

commit 7594ebdd5e593179f0b33a94c30c7d5949fabf96
Author: YehEmily 
Date:   2017-08-24T22:42:12Z

GEODE-3436: Restore refactoring of GfshHelpCommands

* See initial commit GEODE-3261 (cf91426692349d0c81ce77394935576d9cc336e8)

commit 5daeb011cbeebfa2a71c225ed3dc3abc2047e3dd
Author: YehEmily 
Date:   2017-08-24T23:11:13Z

GEODE-3436: Restore refactoring of CreateAlterDestroyRegionCommands

* See initial commit GEODE-3255 (756efe77c86bb03ac9984655e7bd040659e85890)

commit a1823d323c26adebacf7536448e2cadf054d9528
Author: YehEmily 
Date:   2017-07-26T18:07:09Z

GEODE-3436: Restore refactoring of ConfigCommands

* See initial commit GEODE-3254 (97c4e9a59f17c7bc914e39dd048b0a4cd96293c4)

commit 78ec3cb687313799a911ed3d1ca6e560cb358de8
Author: YehEmily 
Date:   2017-08-03T16:00:08Z

GEODE-3436: Restore refactoring of DiskStoreCommands

* See initial commit GEODE-3258 (5d6cad7755ec3c4fe931e3d0f8e89fb181038543)

commit 1ecbd6fa08343a8de50bf30839c9ef47c02e73aa
Author: YehEmily 
Date:   2017-08-07T19:35:14Z

GEODE-3436: Restore refactoring of IndexCommands

* See initial commit GEODE-3262 (ed293e817e547fb5ecd399bf4ba10d694af51e0a)

commit b562bdafc46045bd2679c233cf591549fb016d8b
Author: YehEmily 
Date:   2017-08-07T19:56:17Z

GEODE-3436: Restore refactoring of Refactoring FunctionCommands

* See initial commit GEODE-3260 

[GitHub] geode pull request #730: GEODE-3472: Remove a great deal of commented-out co...

2017-08-28 Thread PurelyApplied
Github user PurelyApplied closed the pull request at:

https://github.com/apache/geode/pull/730


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #730: GEODE-3472: Remove a great deal of commented-out co...

2017-08-28 Thread PurelyApplied
GitHub user PurelyApplied reopened a pull request:

https://github.com/apache/geode/pull/730

GEODE-3472: Remove a great deal of commented-out code.

* Correct imports in touched files
* Correct several misspellings
* Removed redundant modifier and specifiers
* Corrected modifier orderings to adhere to style standard
* Removed several //TODO comments
* Removed "throws CheckedException" from methods that no longer throw the 
checked exception.
* Minor refactorings: iterator loops to for-each, simplified conditionals, 
etc.

Thank you for submitting a contribution to Apache Geode.

In order to streamline the review of the contribution we ask you
to ensure the following steps have been taken:

### For all changes:
- [x] Is there a JIRA ticket associated with this PR? Is it referenced in 
the commit message?

- [x] Has your PR been rebased against the latest commit within the target 
branch (typically `develop`)?

- [x] Is your initial contribution a single, squashed commit?

- [x] Does `gradlew build` run cleanly?

- [n/a] Have you written or updated unit tests to verify your changes? 
[n/a: Non-functional changes.]

- [n/a] If adding new dependencies to the code, are these dependencies 
licensed in a way that is compatible for inclusion under [ASF 
2.0](http://www.apache.org/legal/resolved.html#category-a)?

### Note:
Please ensure that once the PR is submitted, you check travis-ci for build 
issues and
submit an update to your PR as soon as possible. If you need help, please 
send an
email to dev@geode.apache.org.


You can merge this pull request into a Git repository by running:

$ git pull https://github.com/PurelyApplied/geode geode-3472

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/geode/pull/730.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #730


commit 80f44577b8f1431c14934a935f6d426f28ed0dea
Author: Patrick Rhomberg 
Date:   2017-08-18T20:59:44Z

GEODE-3472: Remove a great deal of commented-out code.

* Correct imports in touched files
* Correct several misspellings
* Removed redundant modifier and specifiers
* Corrected modifier orderings to adhere to style standard
* Removed several //TODO comments
* Removed "throws CheckedException" from methods that no longer throw the 
checked exception.
* Minor refactorings: iterator loops to for-each, simplified conditionals, 
etc.

commit 7a0db737bc7327adea58a5c972ad04856850c8b7
Author: Patrick Rhomberg 
Date:   2017-08-28T20:41:19Z

GEODE-3472: Suggested changes in pull request.

* Corrected incorrect correction of a typo in Gfsh.java
* Removed dead, trivial method
* Moved constant field from MBeanJMXAdapter to its use in VMStatsMonitor

commit 1324ed15533dbf5fe95a81e214d81d2355f239fd
Author: Patrick Rhomberg 
Date:   2017-08-28T22:10:51Z

empty commit to trigger Travis.




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #730: GEODE-3472: Remove a great deal of commented-out co...

2017-08-28 Thread PurelyApplied
Github user PurelyApplied closed the pull request at:

https://github.com/apache/geode/pull/730


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #730: GEODE-3472: Remove a great deal of commented-out co...

2017-08-28 Thread PurelyApplied
GitHub user PurelyApplied reopened a pull request:

https://github.com/apache/geode/pull/730

GEODE-3472: Remove a great deal of commented-out code.

* Correct imports in touched files
* Correct several misspellings
* Removed redundant modifier and specifiers
* Corrected modifier orderings to adhere to style standard
* Removed several //TODO comments
* Removed "throws CheckedException" from methods that no longer throw the 
checked exception.
* Minor refactorings: iterator loops to for-each, simplified conditionals, 
etc.

Thank you for submitting a contribution to Apache Geode.

In order to streamline the review of the contribution we ask you
to ensure the following steps have been taken:

### For all changes:
- [x] Is there a JIRA ticket associated with this PR? Is it referenced in 
the commit message?

- [x] Has your PR been rebased against the latest commit within the target 
branch (typically `develop`)?

- [x] Is your initial contribution a single, squashed commit?

- [x] Does `gradlew build` run cleanly?

- [n/a] Have you written or updated unit tests to verify your changes? 
[n/a: Non-functional changes.]

- [n/a] If adding new dependencies to the code, are these dependencies 
licensed in a way that is compatible for inclusion under [ASF 
2.0](http://www.apache.org/legal/resolved.html#category-a)?

### Note:
Please ensure that once the PR is submitted, you check travis-ci for build 
issues and
submit an update to your PR as soon as possible. If you need help, please 
send an
email to dev@geode.apache.org.


You can merge this pull request into a Git repository by running:

$ git pull https://github.com/PurelyApplied/geode geode-3472

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/geode/pull/730.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #730


commit 80f44577b8f1431c14934a935f6d426f28ed0dea
Author: Patrick Rhomberg 
Date:   2017-08-18T20:59:44Z

GEODE-3472: Remove a great deal of commented-out code.

* Correct imports in touched files
* Correct several misspellings
* Removed redundant modifier and specifiers
* Corrected modifier orderings to adhere to style standard
* Removed several //TODO comments
* Removed "throws CheckedException" from methods that no longer throw the 
checked exception.
* Minor refactorings: iterator loops to for-each, simplified conditionals, 
etc.

commit 7a0db737bc7327adea58a5c972ad04856850c8b7
Author: Patrick Rhomberg 
Date:   2017-08-28T20:41:19Z

GEODE-3472: Suggested changes in pull request.

* Corrected incorrect correction of a typo in Gfsh.java
* Removed dead, trivial method
* Moved constant field from MBeanJMXAdapter to its use in VMStatsMonitor

commit 1324ed15533dbf5fe95a81e214d81d2355f239fd
Author: Patrick Rhomberg 
Date:   2017-08-28T22:10:51Z

empty commit to trigger Travis.




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode issue #730: GEODE-3472: Remove a great deal of commented-out code.

2017-08-28 Thread PurelyApplied
Github user PurelyApplied commented on the issue:

https://github.com/apache/geode/pull/730
  
Precheckin returned green.

Open/Close PR to trigger Travis again.  Hopefully they've pulled `develop` 
recently...


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[Spring CI] Spring Data GemFire > Nightly-ApacheGeode > #661 was SUCCESSFUL (with 2027 tests)

2017-08-28 Thread Spring CI

---
Spring Data GemFire > Nightly-ApacheGeode > #661 was successful.
---
Scheduled
2029 tests in total.

https://build.spring.io/browse/SGF-NAG-661/





--
This message is automatically generated by Atlassian Bamboo

[GitHub] geode pull request #721: GEODE-3448: Implement and expose parallel snapshot ...

2017-08-28 Thread asfgit
Github user asfgit closed the pull request at:

https://github.com/apache/geode/pull/721


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode issue #730: GEODE-3472: Remove a great deal of commented-out code.

2017-08-28 Thread PurelyApplied
Github user PurelyApplied commented on the issue:

https://github.com/apache/geode/pull/730
  
Travis failures appear related to 
`f41ca9d7d2fa7c045ec439df9478335233f1d95e`.  Is there a way to force Travis to 
rerun without applying a new commit?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode issue #746: GEODE-3529 move new client/server security classes to a di...

2017-08-28 Thread bschuchardt
Github user bschuchardt commented on the issue:

https://github.com/apache/geode/pull/746
  
Travis check failed in an unrelated unit test.  This test passes on my 
branch when I run it individually or as part of the "build" task.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #746: GEODE-3529 move new client/server security classes ...

2017-08-28 Thread bschuchardt
GitHub user bschuchardt opened a pull request:

https://github.com/apache/geode/pull/746

GEODE-3529 move new client/server security classes to a different pac…

@kohlmu-pivotal @hiteshk25 @galen-pivotal @pivotal-amurmann @metatype 

The new classes/interfaces have been moved to 
org.apache.geode.security.server.

A package.html is now provided that describes the purpose of the package.

The word "Stream" has been removed from the names of these classes.  Those
names make sense in the context of the Protobuf support classes in
org.apache.geode.internal.cache.tier.sockets classes but not when taken
as a separate group of classes.

The method Authenticator.receiveMessage() has been renamed to
Authenticator.authenticate().

Thank you for submitting a contribution to Apache Geode.




In order to streamline the review of the contribution we ask you
to ensure the following steps have been taken:

### For all changes:
- [ x] Is there a JIRA ticket associated with this PR? Is it referenced in 
the commit message?

- [x] Has your PR been rebased against the latest commit within the target 
branch (typically `develop`)?

- [x] Is your initial contribution a single, squashed commit?

- [x] Does `gradlew build` run cleanly?

- [x] Have you written or updated unit tests to verify your changes?

- [n/a] If adding new dependencies to the code, are these dependencies 
licensed in a way that is compatible for inclusion under [ASF 
2.0](http://www.apache.org/legal/resolved.html#category-a)?

### Note:
Please ensure that once the PR is submitted, you check travis-ci for build 
issues and
submit an update to your PR as soon as possible. If you need help, please 
send an
email to dev@geode.apache.org.


You can merge this pull request into a Git repository by running:

$ git pull https://github.com/apache/geode feature/GEODE-3529

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/geode/pull/746.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #746


commit ed3ac98cec1610bde2c1cbcad5a0ff542296ea2a
Author: Bruce Schuchardt 
Date:   2017-08-28T21:43:45Z

GEODE-3529 move new client/server security classes to a different package

The new classes/interfaces have been moved to 
org.apache.geode.security.server.

A package.html is now provided that describes the purpose of the package.

The word "Stream" has been removed from the names of these classes.  Those
names make sense in the context of the Protobuf support classes in
org.apache.geode.internal.cache.tier.sockets classes but not when taken
as a separate group of classes.

The method Authenticator.receiveMessage() has been renamed to
Authenticator.authenticate().




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #745: GEODE-3436: Restore reverted GFSH command refactori...

2017-08-28 Thread PurelyApplied
Github user PurelyApplied commented on a diff in the pull request:

https://github.com/apache/geode/pull/745#discussion_r135641458
  
--- Diff: 
geode-core/src/test/java/org/apache/geode/management/internal/security/TestCommand.java
 ---
@@ -171,28 +171,37 @@ private static void init() {
 createTestCommand("alter disk-store --name=foo --region=xyz 
--disk-dirs=bar");
 createTestCommand("destroy disk-store --name=foo", clusterManageDisk);
 
-// DurableClientCommands
+// CloseDurableClientCommand, CloseDurableCQsCommand, 
CountDurableCQEventsCommand,
+// ListDurableClientCQsCommand
 createTestCommand("close durable-client --durable-client-id=client1", 
clusterManageQuery);
 createTestCommand("close durable-cq --durable-client-id=client1 
--durable-cq-name=cq1",
 clusterManageQuery);
 createTestCommand("show subscription-queue-size 
--durable-client-id=client1", clusterRead);
 createTestCommand("list durable-cqs --durable-client-id=client1", 
clusterRead);
 
-// ExportIMportSharedConfigurationCommands
+// ExportImportSharedConfigurationCommands
 createTestCommand("export cluster-configuration 
--zip-file-name=mySharedConfig.zip",
 clusterRead);
 createTestCommand("import cluster-configuration 
--zip-file-name=value.zip", clusterManage);
 
-// FunctionCommands
+// DestroyFunctionCommand, ExecuteFunctionCommand, ListFunctionCommand
+// TODO PSR: the `destroy function` command is interactive (in its 
interceptor) when both
--- End diff --

Killed the TODO, left the function commented out since it'll throw an error 
before authentication in that test.

I think that and the associated classes need a refactor in any case.  I'll 
address the commented-out-ness of the several functions then.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #745: GEODE-3436: Restore reverted GFSH command refactori...

2017-08-28 Thread pdxrunner
Github user pdxrunner commented on a diff in the pull request:

https://github.com/apache/geode/pull/745#discussion_r135639047
  
--- Diff: 
geode-core/src/test/java/org/apache/geode/management/internal/security/TestCommand.java
 ---
@@ -171,28 +171,37 @@ private static void init() {
 createTestCommand("alter disk-store --name=foo --region=xyz 
--disk-dirs=bar");
 createTestCommand("destroy disk-store --name=foo", clusterManageDisk);
 
-// DurableClientCommands
+// CloseDurableClientCommand, CloseDurableCQsCommand, 
CountDurableCQEventsCommand,
+// ListDurableClientCQsCommand
 createTestCommand("close durable-client --durable-client-id=client1", 
clusterManageQuery);
 createTestCommand("close durable-cq --durable-client-id=client1 
--durable-cq-name=cq1",
 clusterManageQuery);
 createTestCommand("show subscription-queue-size 
--durable-client-id=client1", clusterRead);
 createTestCommand("list durable-cqs --durable-client-id=client1", 
clusterRead);
 
-// ExportIMportSharedConfigurationCommands
+// ExportImportSharedConfigurationCommands
 createTestCommand("export cluster-configuration 
--zip-file-name=mySharedConfig.zip",
 clusterRead);
 createTestCommand("import cluster-configuration 
--zip-file-name=value.zip", clusterManage);
 
-// FunctionCommands
+// DestroyFunctionCommand, ExecuteFunctionCommand, ListFunctionCommand
+// TODO PSR: the `destroy function` command is interactive (in its 
interceptor) when both
--- End diff --

Have got a resolution on these TODO's?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #745: GEODE-3436: Restore reverted GFSH command refactori...

2017-08-28 Thread jinmeiliao
Github user jinmeiliao commented on a diff in the pull request:

https://github.com/apache/geode/pull/745#discussion_r135635795
  
--- Diff: 
geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/ShowMetricsCommand.java
 ---
@@ -794,7 +84,7 @@ public Result showMetrics(
   }
   if (regionName != null && !regionName.isEmpty()) {
 
-if 
(!org.apache.geode.internal.lang.StringUtils.isBlank(cacheServerPortString)) {
+if (!StringUtils.isBlank(cacheServerPortString)) {
--- End diff --

Let's leave these things for other cleanup tasks. The focus of this change 
set is to break these command into separate classes. I know we all can't resist 
the urge of making everything perfect from time to time, but one thing at a 
time.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #745: GEODE-3436: Restore reverted GFSH command refactori...

2017-08-28 Thread PurelyApplied
Github user PurelyApplied commented on a diff in the pull request:

https://github.com/apache/geode/pull/745#discussion_r135635781
  
--- Diff: 
geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/ShowMetricsCommand.java
 ---
@@ -794,7 +84,7 @@ public Result showMetrics(
   }
   if (regionName != null && !regionName.isEmpty()) {
 
-if 
(!org.apache.geode.internal.lang.StringUtils.isBlank(cacheServerPortString)) {
+if (!StringUtils.isBlank(cacheServerPortString)) {
--- End diff --

One step closer to purging that class altogether!


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #745: GEODE-3436: Restore reverted GFSH command refactori...

2017-08-28 Thread pdxrunner
Github user pdxrunner commented on a diff in the pull request:

https://github.com/apache/geode/pull/745#discussion_r135633281
  
--- Diff: 
geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/ExecuteFunctionCommand.java
 ---
@@ -156,7 +132,7 @@ public Result executeFunction(
 // if user wish to execute on locator then he can choose --member 
or --group option
 Set dsMembers = 
CliUtil.getAllNormalMembers(cache);
 if (dsMembers.size() > 0) {
-  function = new UserFunctionExecution();
+  new UserFunctionExecution();
--- End diff --

Where is this object used?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #745: GEODE-3436: Restore reverted GFSH command refactori...

2017-08-28 Thread PurelyApplied
Github user PurelyApplied commented on a diff in the pull request:

https://github.com/apache/geode/pull/745#discussion_r135632737
  
--- Diff: 
geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/CreateRegionCommand.java
 ---
@@ -247,7 +207,7 @@ public Result createRegion(
   new Object[] {CliStrings.CREATE_REGION__USEATTRIBUTESFROM, 
useAttributesFrom}));
--- End diff --

If there is one person to whom you need not apologize for nit-picking, it's 
this guy.

Inspections find six cases across `RegionCreateFunction` and 
`CreateRegionCommand`.  Done and done.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #745: GEODE-3436: Restore reverted GFSH command refactori...

2017-08-28 Thread pdxrunner
Github user pdxrunner commented on a diff in the pull request:

https://github.com/apache/geode/pull/745#discussion_r135629055
  
--- Diff: 
geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/CreateRegionCommand.java
 ---
@@ -247,7 +207,7 @@ public Result createRegion(
   new Object[] {CliStrings.CREATE_REGION__USEATTRIBUTESFROM, 
useAttributesFrom}));
--- End diff --

Bit of a nit-pick, but we have been trying to clean up these cases where we 
unnecessarily create new object arrays to pass to varargs methods. This occurs 
several places in the class


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #730: GEODE-3472: Remove a great deal of commented-out co...

2017-08-28 Thread PurelyApplied
Github user PurelyApplied commented on a diff in the pull request:

https://github.com/apache/geode/pull/730#discussion_r135626288
  
--- Diff: 
geode-core/src/main/java/org/apache/geode/management/internal/cli/CliUtil.java 
---
@@ -212,8 +211,7 @@ public static void bytesToFiles(byte[][] fileData, 
String parentDirPath, boolean
   }
 
   public static boolean isValidFileName(String filePath, String extension) 
{
-boolean isValid = true;
-return isValid;
+return true;
--- End diff --

Looks unused.  Must've just condensed the return from IntelliJ's inspection 
window and not looked too closely at this silly method.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #730: GEODE-3472: Remove a great deal of commented-out co...

2017-08-28 Thread PurelyApplied
Github user PurelyApplied commented on a diff in the pull request:

https://github.com/apache/geode/pull/730#discussion_r135625955
  
--- Diff: 
geode-core/src/main/java/org/apache/geode/management/internal/cli/shell/Gfsh.java
 ---
@@ -158,7 +156,7 @@
   private Thread runner;
   private boolean debugON;
   private Terminal terminal;
-  private boolean supressScriptCmdOutput;
+  private boolean suppressScriptCadOutput;
--- End diff --

IntelliJ Autocorrect strikes again!  Good catch.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #730: GEODE-3472: Remove a great deal of commented-out co...

2017-08-28 Thread PurelyApplied
Github user PurelyApplied commented on a diff in the pull request:

https://github.com/apache/geode/pull/730#discussion_r135625773
  
--- Diff: 
geode-core/src/main/java/org/apache/geode/management/internal/cli/domain/DataCommandResult.java
 ---
@@ -415,9 +413,8 @@ public Result toCommandResult() {
   toCommandResult_isPut(section, table);
 } else if (isRemove()) {
   toCommandResult_isRemove(section, table);
-} else if (isSelect()) {
-  // its moved to its separate method
 }
+// isSelect() moved to a separate method
--- End diff --

It was a little intentional to leave it.  In the context, I couldn't tell 
if it was actually helpful to explicitly comment that "No, we didn't forget 
about `isSelect()`", but I also didn't investigate too closely to see why 
`toCommandResult()` necessarily won't git on a select command.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #734: GEODE-3508: Remove unused internal deprecated class...

2017-08-28 Thread PurelyApplied
Github user PurelyApplied closed the pull request at:

https://github.com/apache/geode/pull/734


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode issue #739: GEODE-3385: Change GetAllRequest to return list of errors.

2017-08-28 Thread galen-pivotal
Github user galen-pivotal commented on the issue:

https://github.com/apache/geode/pull/739
  
Rebased on develop.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode issue #734: GEODE-3508: Remove unused internal deprecated classes.

2017-08-28 Thread kirklund
Github user kirklund commented on the issue:

https://github.com/apache/geode/pull/734
  
I'll pull this in.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #734: GEODE-3508: Remove unused internal deprecated class...

2017-08-28 Thread kirklund
Github user kirklund commented on a diff in the pull request:

https://github.com/apache/geode/pull/734#discussion_r135605423
  
--- Diff: 
geode-core/src/main/java/org/apache/geode/internal/process/ClusterConfigurationNotAvailableException.java
 ---
@@ -1,33 +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.internal.process;
-
-/**
- * Exception thrown during server startup when it requests the locators 
for shared configuration and
- * does not receive it.
- *
- * @since GemFire 8.0
- * @deprecated Please use
--- End diff --

Just delete it. It's fine.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #745: GEODE-3436: Restore reverted GFSH command refactori...

2017-08-28 Thread kirklund
Github user kirklund commented on a diff in the pull request:

https://github.com/apache/geode/pull/745#discussion_r135605262
  
--- Diff: 
geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/CreateDefinedIndexesCommand.java
 ---
@@ -0,0 +1,155 @@
+/*
+ * 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.management.internal.cli.commands;
+
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+import java.util.TreeSet;
+import java.util.concurrent.atomic.AtomicReference;
+
+import org.springframework.shell.core.annotation.CliCommand;
+import org.springframework.shell.core.annotation.CliOption;
+
+import org.apache.geode.cache.CacheFactory;
+import org.apache.geode.cache.execute.ResultCollector;
+import org.apache.geode.distributed.DistributedMember;
+import org.apache.geode.management.cli.CliMetaData;
+import org.apache.geode.management.cli.ConverterHint;
+import org.apache.geode.management.cli.Result;
+import org.apache.geode.management.internal.cli.CliUtil;
+import 
org.apache.geode.management.internal.cli.functions.CliFunctionResult;
+import 
org.apache.geode.management.internal.cli.functions.CreateDefinedIndexesFunction;
+import org.apache.geode.management.internal.cli.i18n.CliStrings;
+import org.apache.geode.management.internal.cli.result.ErrorResultData;
+import org.apache.geode.management.internal.cli.result.InfoResultData;
+import org.apache.geode.management.internal.cli.result.ResultBuilder;
+import org.apache.geode.management.internal.configuration.domain.XmlEntity;
+import org.apache.geode.management.internal.security.ResourceOperation;
+import org.apache.geode.security.ResourcePermission;
+
+public class CreateDefinedIndexesCommand implements GfshCommand {
+  private static final CreateDefinedIndexesFunction 
createDefinedIndexesFunction =
+  new CreateDefinedIndexesFunction();
+
+  @CliCommand(value = CliStrings.CREATE_DEFINED_INDEXES, help = 
CliStrings.CREATE_DEFINED__HELP)
+  @CliMetaData(relatedTopic = {CliStrings.TOPIC_GEODE_REGION, 
CliStrings.TOPIC_GEODE_DATA})
+  @ResourceOperation(resource = ResourcePermission.Resource.CLUSTER,
+  operation = ResourcePermission.Operation.MANAGE, target = 
ResourcePermission.Target.QUERY)
+  // TODO : Add optionContext for indexName
+  public Result createDefinedIndexes(
+
+  @CliOption(key = {CliStrings.MEMBER, CliStrings.MEMBERS},
+  optionContext = ConverterHint.MEMBERIDNAME,
+  help = CliStrings.CREATE_DEFINED_INDEXES__MEMBER__HELP) final 
String[] memberNameOrID,
+
+  @CliOption(key = {CliStrings.GROUP, CliStrings.GROUPS},
+  optionContext = ConverterHint.MEMBERGROUP,
+  help = CliStrings.CREATE_DEFINED_INDEXES__GROUP__HELP) final 
String[] group) {
+
+Result result;
+AtomicReference xmlEntity = new AtomicReference<>();
+
+if (IndexDefinition.indexDefinitions.isEmpty()) {
+  final InfoResultData infoResult = 
ResultBuilder.createInfoResultData();
+  infoResult.addLine(CliStrings.DEFINE_INDEX__FAILURE__MSG);
+  return ResultBuilder.buildResult(infoResult);
+}
+
+try {
+  final Set targetMembers = 
CliUtil.findMembers(group, memberNameOrID);
+
+  if (targetMembers.isEmpty()) {
+return 
ResultBuilder.createUserErrorResult(CliStrings.NO_MEMBERS_FOUND_MESSAGE);
+  }
+
+  // TODO PSR: is this safe to remove?
+  CacheFactory.getAnyInstance();
--- End diff --

I favor removal of all CacheFactory.getAnyInstance() calls anywhere in 
which the return is not used.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.

[GitHub] geode pull request #745: GEODE-3436: Restore reverted GFSH command refactori...

2017-08-28 Thread PurelyApplied
Github user PurelyApplied commented on a diff in the pull request:

https://github.com/apache/geode/pull/745#discussion_r135599224
  
--- Diff: 
geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/CreateDefinedIndexesCommand.java
 ---
@@ -0,0 +1,155 @@
+/*
+ * 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.management.internal.cli.commands;
+
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+import java.util.TreeSet;
+import java.util.concurrent.atomic.AtomicReference;
+
+import org.springframework.shell.core.annotation.CliCommand;
+import org.springframework.shell.core.annotation.CliOption;
+
+import org.apache.geode.cache.CacheFactory;
+import org.apache.geode.cache.execute.ResultCollector;
+import org.apache.geode.distributed.DistributedMember;
+import org.apache.geode.management.cli.CliMetaData;
+import org.apache.geode.management.cli.ConverterHint;
+import org.apache.geode.management.cli.Result;
+import org.apache.geode.management.internal.cli.CliUtil;
+import 
org.apache.geode.management.internal.cli.functions.CliFunctionResult;
+import 
org.apache.geode.management.internal.cli.functions.CreateDefinedIndexesFunction;
+import org.apache.geode.management.internal.cli.i18n.CliStrings;
+import org.apache.geode.management.internal.cli.result.ErrorResultData;
+import org.apache.geode.management.internal.cli.result.InfoResultData;
+import org.apache.geode.management.internal.cli.result.ResultBuilder;
+import org.apache.geode.management.internal.configuration.domain.XmlEntity;
+import org.apache.geode.management.internal.security.ResourceOperation;
+import org.apache.geode.security.ResourcePermission;
+
+public class CreateDefinedIndexesCommand implements GfshCommand {
+  private static final CreateDefinedIndexesFunction 
createDefinedIndexesFunction =
+  new CreateDefinedIndexesFunction();
+
+  @CliCommand(value = CliStrings.CREATE_DEFINED_INDEXES, help = 
CliStrings.CREATE_DEFINED__HELP)
+  @CliMetaData(relatedTopic = {CliStrings.TOPIC_GEODE_REGION, 
CliStrings.TOPIC_GEODE_DATA})
+  @ResourceOperation(resource = ResourcePermission.Resource.CLUSTER,
+  operation = ResourcePermission.Operation.MANAGE, target = 
ResourcePermission.Target.QUERY)
+  // TODO : Add optionContext for indexName
+  public Result createDefinedIndexes(
+
+  @CliOption(key = {CliStrings.MEMBER, CliStrings.MEMBERS},
+  optionContext = ConverterHint.MEMBERIDNAME,
+  help = CliStrings.CREATE_DEFINED_INDEXES__MEMBER__HELP) final 
String[] memberNameOrID,
+
+  @CliOption(key = {CliStrings.GROUP, CliStrings.GROUPS},
+  optionContext = ConverterHint.MEMBERGROUP,
+  help = CliStrings.CREATE_DEFINED_INDEXES__GROUP__HELP) final 
String[] group) {
+
+Result result;
+AtomicReference xmlEntity = new AtomicReference<>();
+
+if (IndexDefinition.indexDefinitions.isEmpty()) {
+  final InfoResultData infoResult = 
ResultBuilder.createInfoResultData();
+  infoResult.addLine(CliStrings.DEFINE_INDEX__FAILURE__MSG);
+  return ResultBuilder.buildResult(infoResult);
+}
+
+try {
+  final Set targetMembers = 
CliUtil.findMembers(group, memberNameOrID);
+
+  if (targetMembers.isEmpty()) {
+return 
ResultBuilder.createUserErrorResult(CliStrings.NO_MEMBERS_FOUND_MESSAGE);
+  }
+
+  // TODO PSR: is this safe to remove?
+  CacheFactory.getAnyInstance();
--- End diff --

Oh no I forgot to address all my TODOs!

That was there to remind me to spike that command out and see the right way 
to get rid of it.  Thanks for catching that.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact 

[GitHub] geode pull request #745: GEODE-3436: Restore reverted GFSH command refactori...

2017-08-28 Thread pdxrunner
Github user pdxrunner commented on a diff in the pull request:

https://github.com/apache/geode/pull/745#discussion_r135597926
  
--- Diff: 
geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/CreateDefinedIndexesCommand.java
 ---
@@ -0,0 +1,155 @@
+/*
+ * 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.management.internal.cli.commands;
+
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+import java.util.TreeSet;
+import java.util.concurrent.atomic.AtomicReference;
+
+import org.springframework.shell.core.annotation.CliCommand;
+import org.springframework.shell.core.annotation.CliOption;
+
+import org.apache.geode.cache.CacheFactory;
+import org.apache.geode.cache.execute.ResultCollector;
+import org.apache.geode.distributed.DistributedMember;
+import org.apache.geode.management.cli.CliMetaData;
+import org.apache.geode.management.cli.ConverterHint;
+import org.apache.geode.management.cli.Result;
+import org.apache.geode.management.internal.cli.CliUtil;
+import 
org.apache.geode.management.internal.cli.functions.CliFunctionResult;
+import 
org.apache.geode.management.internal.cli.functions.CreateDefinedIndexesFunction;
+import org.apache.geode.management.internal.cli.i18n.CliStrings;
+import org.apache.geode.management.internal.cli.result.ErrorResultData;
+import org.apache.geode.management.internal.cli.result.InfoResultData;
+import org.apache.geode.management.internal.cli.result.ResultBuilder;
+import org.apache.geode.management.internal.configuration.domain.XmlEntity;
+import org.apache.geode.management.internal.security.ResourceOperation;
+import org.apache.geode.security.ResourcePermission;
+
+public class CreateDefinedIndexesCommand implements GfshCommand {
+  private static final CreateDefinedIndexesFunction 
createDefinedIndexesFunction =
+  new CreateDefinedIndexesFunction();
+
+  @CliCommand(value = CliStrings.CREATE_DEFINED_INDEXES, help = 
CliStrings.CREATE_DEFINED__HELP)
+  @CliMetaData(relatedTopic = {CliStrings.TOPIC_GEODE_REGION, 
CliStrings.TOPIC_GEODE_DATA})
+  @ResourceOperation(resource = ResourcePermission.Resource.CLUSTER,
+  operation = ResourcePermission.Operation.MANAGE, target = 
ResourcePermission.Target.QUERY)
+  // TODO : Add optionContext for indexName
+  public Result createDefinedIndexes(
+
+  @CliOption(key = {CliStrings.MEMBER, CliStrings.MEMBERS},
+  optionContext = ConverterHint.MEMBERIDNAME,
+  help = CliStrings.CREATE_DEFINED_INDEXES__MEMBER__HELP) final 
String[] memberNameOrID,
+
+  @CliOption(key = {CliStrings.GROUP, CliStrings.GROUPS},
+  optionContext = ConverterHint.MEMBERGROUP,
+  help = CliStrings.CREATE_DEFINED_INDEXES__GROUP__HELP) final 
String[] group) {
+
+Result result;
+AtomicReference xmlEntity = new AtomicReference<>();
+
+if (IndexDefinition.indexDefinitions.isEmpty()) {
+  final InfoResultData infoResult = 
ResultBuilder.createInfoResultData();
+  infoResult.addLine(CliStrings.DEFINE_INDEX__FAILURE__MSG);
+  return ResultBuilder.buildResult(infoResult);
+}
+
+try {
+  final Set targetMembers = 
CliUtil.findMembers(group, memberNameOrID);
+
+  if (targetMembers.isEmpty()) {
+return 
ResultBuilder.createUserErrorResult(CliStrings.NO_MEMBERS_FOUND_MESSAGE);
+  }
+
+  // TODO PSR: is this safe to remove?
+  CacheFactory.getAnyInstance();
--- End diff --

I think this should be replaced by calling the GfshCommand interface's 
getCache() to limit the places where this potentially deadlock prone call is 
made. . Most (or at least many) other gfsh commands call the interface's method.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the 

[GitHub] geode issue #719: GEODE-3447 Implement client authorization for the new prot...

2017-08-28 Thread bschuchardt
Github user bschuchardt commented on the issue:

https://github.com/apache/geode/pull/719
  
@metatype After reviewing StreamAuthenticator I get your point.  I think 
these new interfaces and classes need to be in a different package.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #745: GEODE-3436: Restore reverted GFSH command refactori...

2017-08-28 Thread PurelyApplied
GitHub user PurelyApplied opened a pull request:

https://github.com/apache/geode/pull/745

GEODE-3436: Restore reverted GFSH command refactoring

Given that this would restore multiple tickets worth of commits, it was 
unclear if this PR should squash all commits or if the history would be clearer 
without one enormous commit.

Precheckin returned green excepting spotless and some other minor 
adjustments (import ordering correction, etc).  Running another precheckin for 
due course.

-

Thank you for submitting a contribution to Apache Geode.

In order to streamline the review of the contribution we ask you
to ensure the following steps have been taken:

### For all changes:
- [x] Is there a JIRA ticket associated with this PR? Is it referenced in 
the commit message?

- [x] Has your PR been rebased against the latest commit within the target 
branch (typically `develop`)?

- [ ] Is your initial contribution a single, squashed commit?

- [x] Does `gradlew build` run cleanly?

- [n/a] Have you written or updated unit tests to verify your changes? 
[Existing tests provide coverage for refactored code.]

- [n/a] If adding new dependencies to the code, are these dependencies 
licensed in a way that is compatible for inclusion under [ASF 
2.0](http://www.apache.org/legal/resolved.html#category-a)?

### Note:
Please ensure that once the PR is submitted, you check travis-ci for build 
issues and
submit an update to your PR as soon as possible. If you need help, please 
send an
email to dev@geode.apache.org.


You can merge this pull request into a Git repository by running:

$ git pull https://github.com/PurelyApplied/geode geode-3436

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/geode/pull/745.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #745


commit caeb8375db68d68ec0ddbca6b81fd6ca6c91a73f
Author: YehEmily 
Date:   2017-08-22T17:57:05Z

GEODE-3436: Restore refactoring of MemberCommands

* See initial commit GEODE-3264 (d27f8b956de7d9c5d95ebdc68dfc67ee8b2d7b51)

commit 44cc0e8bb7927e61bb3e7613612703518fc87db6
Author: YehEmily 
Date:   2017-08-07T18:52:14Z

GEODE-3436: Restore refactoring of DurableClientCommands

* See initial commit GEODE-3259 (440c87f81fab96f9ce38a2d53ded75e5fe8390d7)

commit 1e9eea1f1b2d2c620679283aaf6e6c5ac12e1728
Author: YehEmily 
Date:   2017-08-04T17:47:48Z

GEODE-3436: Restore refactoring of PDXCommands

* See initial commit GEODE-3266 (67185abcdd68b908dea6888cb94286b8aa9ea49f)

commit 691700c2e51aef5b18ba5feec711bddf5ae9a05e
Author: YehEmily 
Date:   2017-08-07T20:58:08Z

GEODE-3436: Restore refactoring of RegionCommands

* See initial commits GEODE-3268 
(64de3b69c2aecb4930bcfd0a1161569b1d5fda89), GEODE-3255 
(756efe77c86bb03ac9984655e7bd040659e85890)

commit 0acf8be27f5ab5f6d9d5009bb7ec6740c1f7ae1b
Author: YehEmily 
Date:   2017-08-07T21:47:15Z

GEODE-3436: Restore refactoring of QueueCommands

* See initial commit GEODE-3267 (fd47ed660168864a6f81b2a4cd7dbceebc99a282)

commit 7594ebdd5e593179f0b33a94c30c7d5949fabf96
Author: YehEmily 
Date:   2017-08-24T22:42:12Z

GEODE-3436: Restore refactoring of GfshHelpCommands

* See initial commit GEODE-3261 (cf91426692349d0c81ce77394935576d9cc336e8)

commit 5daeb011cbeebfa2a71c225ed3dc3abc2047e3dd
Author: YehEmily 
Date:   2017-08-24T23:11:13Z

GEODE-3436: Restore refactoring of CreateAlterDestroyRegionCommands

* See initial commit GEODE-3255 (756efe77c86bb03ac9984655e7bd040659e85890)

commit a1823d323c26adebacf7536448e2cadf054d9528
Author: YehEmily 
Date:   2017-07-26T18:07:09Z

GEODE-3436: Restore refactoring of ConfigCommands

* See initial commit GEODE-3254 (97c4e9a59f17c7bc914e39dd048b0a4cd96293c4)

commit 78ec3cb687313799a911ed3d1ca6e560cb358de8
Author: YehEmily 
Date:   2017-08-03T16:00:08Z

GEODE-3436: Restore refactoring of DiskStoreCommands

* See initial commit GEODE-3258 (5d6cad7755ec3c4fe931e3d0f8e89fb181038543)

commit 1ecbd6fa08343a8de50bf30839c9ef47c02e73aa
Author: YehEmily 
Date:   2017-08-07T19:35:14Z

GEODE-3436: Restore refactoring of IndexCommands

* See initial commit GEODE-3262 (ed293e817e547fb5ecd399bf4ba10d694af51e0a)

commit b562bdafc46045bd2679c233cf591549fb016d8b
Author: YehEmily 
Date:   2017-08-07T19:56:17Z

GEODE-3436: Restore refactoring of Refactoring FunctionCommands

* See initial commit GEODE-3260 

Re: Query mechanism

2017-08-28 Thread Jason Huynh
DefaultQuery is where the processing starts for a query.

CompiledSelect will most likely be the first node in processing the query.

The IndexManager class will contain the list of indexes for a region as
well as the methods that help find indexes to use with a query.

Specific index classes:
CompactRangeIndex
RangeIndex
HashIndex
PrimaryKeyIndex
MapRangeIndex
CompactMapRangeIndex



On Mon, Aug 28, 2017 at 6:04 AM Roi Apelker  wrote:

>
> Hi,
>
> I am looking into the internals of how the query process works, and how
> indexes/hints affect it,
>
> Can anyone point me to the most important classes, the main mechanism
> "wheels" etc.?
>
> Thanks,
>
> Roi
>
>
> -Original Message-
> From: Roi Apelker
> Sent: Sunday, August 27, 2017 12:55 PM
> To: dev@geode.apache.org
> Subject: Indxes and hints
>
> Hi,
>
> I have a few questions regarding indexes and hints, if someone could
> confirm the below it would be great:
>
> - I have a situation where I use 3 field values in a select (something
> like select where A>1, B>1, C=true)
> - A and B are fields on the key, and C is a field on the value.
> - A and B are indexes
> - I am looking for the most efficient way to execute the query above, in
> the situation where there is overflow to eviction files, meaning some of
> the data has already been evicted to a file, which slows down the select
> considerably (this is not persistence, but overflow).
>
>
> 1. Is it true to say, that the query as it is will load all the data
> values from the file, since the field C is part of the value, which is
> already persisted to file?
> 2. If I add a hint on A and B, will it mean that there will be a "2 phase
> search", first the select on A and B, and then, only on the results, on the
> field C? (this way, not all records will be loaded from file, only those
> that suit the A and B condition) 3. Is it possible to define an index on a
> value field? (i.e. not from the key) - will it work exactly like defining
> one form the key or are three any limitations? (again, I am looking to
> overcome the situation, where as it seems, the records are loaded
> unnecessarily from disk)
>
> Thank you,
>
> Roi
>
>
> -Original Message-
> From: Roi Apelker
> Sent: Thursday, August 24, 2017 7:03 PM
> To: dev@geode.apache.org
> Subject: eviction files
>
> Hi,
>
> I am looking into the internals of the eviction process,
>
> Can anyone point me to the most important classes, the main mechanism
> "wheels" etc.?
>
> Thanks,
>
> Roi
>
> -Original Message-
> From: Roi Apelker
> Sent: Wednesday, August 16, 2017 8:38 PM
> To: dev@geode.apache.org
> Subject: RE: continuous query internal mechanism questions
>
> It seems like the code in the native client (in the version I have, which
> may be old) send the message to all servers:
>
> CqResultsPtr CqQueryImpl::executeWithInitialResults(uint32_t timeout) {
>   ...
>
>   TcrMessage msg(TcrMessage::EXECUTECQ_WITH_IR_MSG_TYPE, m_cqName,
> m_queryString, CqState::RUNNING, isDurable(), m_tccdm);
>   TcrMessage reply(true, m_tccdm);
>   ChunkedQueryResponse* resultCollector = (new
> ChunkedQueryResponse(reply));
>   reply.setChunkedResultHandler(static_cast *>(resultCollector));
>   reply.setTimeout(timeout);
>
>   GfErrType err = GF_NOERR;
>   err = m_tccdm->sendSyncRequest(msg, reply); ..
>
> And sendSyncRequest:
> ...
>
> for (std::vector::iterator ep = m_endpoints.begin(); ep !=
> m_endpoints.end(); ++ep) {
> if ((*ep)->connected()) {
>   (*ep)->setDM(this);
>   opErr = sendRequestToEP(request, reply, *ep);//this will go to
> ThinClientDistributionManager
>
> ...
>
>
> Can this be causing the issue?
>
>
>
> -Roi
>
>
>
>
>
> -Original Message-
> From: Jason Huynh [mailto:jasonhu...@apache.org]
> Sent: Tuesday, August 15, 2017 9:25 PM
> To: dev@geode.apache.org
> Subject: Re: continuous query internal mechanism questions
>
> I am not quite sure how native client registers cqs. From my understanding:
> with the java api, I believe there is only one message (ExecuteCQ message)
> that is executed on the server side and then replicated to the other nodes
> through the profile (OperationMessage).
>
> It seems the extra ExecuteCQ message failing and then closing the cq might
> be putting the system in a weird state...
>
> On Tue, Aug 15, 2017 at 7:56 AM Roi Apelker 
> wrote:
>
> > Hi,
> >
> > I have been examining the continuous query registration mechanism for
> > quite some time This is related to an issue that I have, where
> > sometimes a node crashes (1 node out of 2), and the other one does not
> > send CQ events. The CQ is registered on a partitioned region which
> > resides on these 2 nodes.
> >
> > I noticed the following behavior, and I wonder if anyone can comment
> > regarding it, if it is justified or not and what is the reason:
> >
> > 1. When the software using the client (native client) registers for
> > the CQ, a CQ command (ExecuteCQ61) 

[GitHub] geode pull request #740: GEODE-3513: Removing the use of native sessions ses...

2017-08-28 Thread asfgit
Github user asfgit closed the pull request at:

https://github.com/apache/geode/pull/740


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #719: GEODE-3447 Implement client authorization for the n...

2017-08-28 Thread bschuchardt
Github user bschuchardt commented on a diff in the pull request:

https://github.com/apache/geode/pull/719#discussion_r135575597
  
--- Diff: 
geode-core/src/main/java/org/apache/geode/security/StreamAuthenticator.java ---
@@ -46,6 +44,14 @@ void receiveMessage(InputStream inputStream, 
OutputStream outputStream,
   boolean isAuthenticated();
 
   /**
+   * Return an authorization object which can be used to determine which 
permissions this stream has
+   * according to the provided securityManager.
+   *
+   * Calling this before authentication has succeeded may result in a null 
return object.
--- End diff --

We'll change this to throw AuthenticationRequiredException if 
authentication has not yet been performed.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


Re: Review Request 61895: GEDOE-3516: TXManagerImpl.tryResume call may add itself again into the waiting thread queue

2017-08-28 Thread Nick Reich

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/61895/#review183945
---




geode-core/src/test/java/org/apache/geode/internal/cache/TXManagerImplJUnitTest.java
Lines 380 (patched)


What does this Thread.sleep() do, if the next line is awaiting a latch?



geode-core/src/test/java/org/apache/geode/internal/cache/TXManagerImplJUnitTest.java
Lines 384 (patched)


Is spyMgr.suspend() here being attempted to occur between when the two 
threads start and before they complete? If so, is that guaranteed to occur?


- Nick Reich


On Aug. 25, 2017, 4:53 p.m., Eric Shu wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/61895/
> ---
> 
> (Updated Aug. 25, 2017, 4:53 p.m.)
> 
> 
> Review request for geode, anilkumar gingade, Darrel Schneider, Lynn Gallinat, 
> and Nick Reich.
> 
> 
> Bugs: GEODE-3516
> https://issues.apache.org/jira/browse/GEODE-3516
> 
> 
> Repository: geode
> 
> 
> Description
> ---
> 
> Remove the thread from waiting thread queue after successfully resumed the 
> transaction
> 
> 
> Diffs
> -
> 
>   geode-core/src/main/java/org/apache/geode/internal/cache/TXManagerImpl.java 
> a0a4d7c 
>   
> geode-core/src/test/java/org/apache/geode/internal/cache/TXManagerImplJUnitTest.java
>  a2c1e70 
> 
> 
> Diff: https://reviews.apache.org/r/61895/diff/2/
> 
> 
> Testing
> ---
> 
> precheckin.
> 
> 
> Thanks,
> 
> Eric Shu
> 
>



[GitHub] geode pull request #719: GEODE-3447 Implement client authorization for the n...

2017-08-28 Thread metatype
Github user metatype commented on a diff in the pull request:

https://github.com/apache/geode/pull/719#discussion_r135573704
  
--- Diff: 
geode-core/src/main/java/org/apache/geode/security/StreamAuthenticator.java ---
@@ -46,6 +44,14 @@ void receiveMessage(InputStream inputStream, 
OutputStream outputStream,
   boolean isAuthenticated();
 
   /**
+   * Return an authorization object which can be used to determine which 
permissions this stream has
+   * according to the provided securityManager.
+   *
+   * Calling this before authentication has succeeded may result in a null 
return object.
--- End diff --

`Optional` doesn't really fix the problem, just introduces more GC pressure 
:-)

Wouldn't it be better to throw `IllegalStateException` when the 
precondition is not met?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #719: GEODE-3447 Implement client authorization for the n...

2017-08-28 Thread bschuchardt
GitHub user bschuchardt reopened a pull request:

https://github.com/apache/geode/pull/719

GEODE-3447 Implement client authorization for the new protocol

Implementation of authorization checks for the new protocol.  This will 
have to be merged with the Locator Protobuf communications work that is in 
progress on another branch before we check it in.

@kohlmu-pivotal @hiteshk25 @galen-pivotal @pivotal-amurmann @WireBaron 

Thank you for submitting a contribution to Apache Geode.

In order to streamline the review of the contribution we ask you
to ensure the following steps have been taken:

### For all changes:
- [ x] Is there a JIRA ticket associated with this PR? Is it referenced in 
the commit message?

- [ x] Has your PR been rebased against the latest commit within the target 
branch (typically `develop`)?

- [x ] Is your initial contribution a single, squashed commit?

- [x] Does `gradlew build` run cleanly?
rat failed on a new StreamAuthorizer interface file.  This will be 
corrected.

- [ x] Have you written or updated unit tests to verify your changes?

- [ ] If adding new dependencies to the code, are these dependencies 
licensed in a way that is compatible for inclusion under [ASF 
2.0](http://www.apache.org/legal/resolved.html#category-a)?

### Note:
Please ensure that once the PR is submitted, you check travis-ci for build 
issues and
submit an update to your PR as soon as possible. If you need help, please 
send an
email to dev@geode.apache.org.


You can merge this pull request into a Git repository by running:

$ git pull https://github.com/apache/geode feature/GEODE-3447

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/geode/pull/719.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #719


commit a2b678aa06af73d218da6e9ae8d95f2942d23a7b
Author: Bruce Schuchardt 
Date:   2017-08-17T22:22:57Z

GEODE-3447 Implement client authorization for the new protocol

Implementation of authorization checks for the new protocol.

commit 495d788abd1935dea27b00ccc16e822eaf690b38
Author: Bruce Schuchardt 
Date:   2017-08-22T21:34:36Z

addressing review comments

commit ea1d8c1f9540d86751a8ce22732bd6b42c0ae4ae
Author: Bruce Schuchardt 
Date:   2017-08-22T22:34:21Z

rebase to origin/develop




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] geode pull request #719: GEODE-3447 Implement client authorization for the n...

2017-08-28 Thread bschuchardt
Github user bschuchardt closed the pull request at:

https://github.com/apache/geode/pull/719


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


Re: Review Request 61950: GEODE-3519 servers are not locking on remove or invalidate ops initiated by clients

2017-08-28 Thread Hitesh Khamesra

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/61950/#review183950
---


Ship it!




Ship It!

- Hitesh Khamesra


On Aug. 28, 2017, 4:09 p.m., Bruce Schuchardt wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/61950/
> ---
> 
> (Updated Aug. 28, 2017, 4:09 p.m.)
> 
> 
> Review request for geode, Alexander Murmann, Galen O'Sullivan, Hitesh 
> Khamesra, and Udo Kohlmeyer.
> 
> 
> Bugs: geode-3519
> https://issues.apache.org/jira/browse/geode-3519
> 
> 
> Repository: geode
> 
> 
> Description
> ---
> 
> While investigating dlocktoken cleanup I discovered that a number of 
> operations coming from a client were not locking entries for Scope.GLOBAL 
> regions on servers.  Only put, putIfAbsent and variants of replace were 
> obtaining locks.
> 
> 
> Diffs
> -
> 
>   
> geode-core/src/main/java/org/apache/geode/internal/cache/DistributedRegion.java
>  d9ed4edeff629b87d0fce2463fa9b22723b57d9a 
>   
> geode-core/src/test/java/org/apache/geode/cache30/ClientServerCCEDUnitTest.java
>  b4224e0dcba91ee75cf1abf185f6fc9fbe22390f 
> 
> 
> Diff: https://reviews.apache.org/r/61950/diff/1/
> 
> 
> Testing
> ---
> 
> precheckin, new integration test
> 
> 
> Thanks,
> 
> Bruce Schuchardt
> 
>



Re: [GitHub] geode issue #719: GEODE-3447 Implement client authorization for the new prot...

2017-08-28 Thread Michael Stolz
A hash is not guaranteed unique so is not suitable as a security token.

--
Mike Stolz
Principal Engineer, GemFire Product Manager
Mobile: +1-631-835-4771

On Fri, Aug 25, 2017 at 4:49 PM, galen-pivotal  wrote:

> Github user galen-pivotal commented on the issue:
>
> https://github.com/apache/geode/pull/719
>
> @metatype We need the `StreamAuthenticator` to receive and send
> (Protobuf-encoded) messages containing the credentials that get passed to
> the `SecurityManager`. I would think that ideally it's nothing more than
> this.
>
> I wonder if it would be better to send a hash that gets put into the
> Properties that SecurityManager uses, rather than having a message that
> explicitly contains username and password.
>
>
> ---
> If your project is set up for it, you can reply to this email and have your
> reply appear on GitHub as well. If your project does not have this feature
> enabled and wishes so, or if the feature is enabled but not working, please
> contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
> with INFRA.
> ---
>


Re: [Discuss] Enable region set operations to start JTA transactions

2017-08-28 Thread Michael Stolz
+1 for revising set ops to bootstrap by default. Document the behavior
change in release notes along with property to revert to old behavior.

--
Mike Stolz
Principal Engineer, GemFire Product Manager
Mobile: +1-631-835-4771

On Fri, Aug 25, 2017 at 6:41 PM, Anilkumar Gingade 
wrote:

> +1 Having a consistent behavior for set operation within the transaction
> (wherever its invoked). And having a gemfire property to allow old way.
>
> On Fri, Aug 25, 2017 at 2:49 PM, Eric Shu  wrote:
>
> > Hi Team,
> >
> > Currently in GEODE JTA implementation, if GEODE transaction is not yet
> > bootstrapped (there is no TXState created yet for the transaction),
> region
> > set operations will not bootstrap the JTA transaction. In other word, if
> > the first operation of the JTA transaction is region set operation, the
> set
> > is not in a transactional view (TXState). However, if the JTA
> > UserTransaction has been bootstrapped (first operation is a get or put
> > operation, etc), the following region set operation is transactional (in
> > TXState). To some users, this seems to be a bug. Please see the GEODE
> > ticket (https://issues.apache.org/jira/browse/GEODE-3521).
> >
> > Although we intentionally implemented this way to alleviate the memory
> > requirements for users (each transaction will have a new copy of region
> > data put into TXState but not if the set op is the first op), we think
> the
> > new user has a valid point as well. We propose to allow region set op to
> > bootstrap the transaction. To allow backward compatibility, we will
> > introduce a new GemFire property to allow the old behavior.
> >
> > The question is what should be a default behavior. Do we allow region set
> > op to bootstrap transaction as default? If so, existing customers need to
> > set the new property to get the old behavior. Or we maintain the old
> > behavior, and require the new users to set the property.
> >
> > Please comment if you have any suggestions.
> >
> > Thanks,
> > Eric
> >
>


Re: Indxes and hints

2017-08-28 Thread Jason Huynh
Hi Roi,

Answers are below the questions...

Question 1. Is it true to say, that the query as it is will load all the
data values from the file, since the field C is part of the value, which is
already persisted to file?

Depending on if an index is used or not, if an index is used, the values
that are part of the results will need to be loaded to actually return a
result.  If an index is not used, then the all the values would need to be
loaded to actually have something to evaluate the filter criteria on.

Question 2. If I add a hint on A and B, will it mean that there will be a
"2 phase search", first the select on A and B, and then, only on the
results, on the field C? (this way, not all records will be loaded from
file, only those that suit the A and B condition)

Depending on the  query, it could use one, or more.  If it's a query with
only AND clauses, it should just choose one and then evaluate the other
filters on the subset that is returned from the index.

Question 3. Is it possible to define an index on a value field? (i.e. not
from the key) - will it work exactly like defining one form the key or are
three any limitations? (again, I am looking to overcome the situation,
where as it seems, the records are loaded unnecessarily from disk)

Yes, indexes can be defined on fields in the value.  It will work the same.


If you are sure you are already using an index in the query and still
loading every value for every execution of that query, there may be
something weird going on...

On Sun, Aug 27, 2017 at 2:55 AM Roi Apelker  wrote:

> Hi,
>
> I have a few questions regarding indexes and hints, if someone could
> confirm the below it would be great:
>
> - I have a situation where I use 3 field values in a select (something
> like select where A>1, B>1, C=true)
> - A and B are fields on the key, and C is a field on the value.
> - A and B are indexes
> - I am looking for the most efficient way to execute the query above, in
> the situation where there is overflow to eviction files, meaning some of
> the data has already been evicted to a file, which slows down the select
> considerably (this is not persistence, but overflow).
>
>
> 1. Is it true to say, that the query as it is will load all the data
> values from the file, since the field C is part of the value, which is
> already persisted to file?
> 2. If I add a hint on A and B, will it mean that there will be a "2 phase
> search", first the select on A and B, and then, only on the results, on the
> field C? (this way, not all records will be loaded from file, only those
> that suit the A and B condition)
> 3. Is it possible to define an index on a value field? (i.e. not from the
> key) - will it work exactly like defining one form the key or are three any
> limitations? (again, I am looking to overcome the situation, where as it
> seems, the records are loaded unnecessarily from disk)
>
> Thank you,
>
> Roi
>
>
> -Original Message-
> From: Roi Apelker
> Sent: Thursday, August 24, 2017 7:03 PM
> To: dev@geode.apache.org
> Subject: eviction files
>
> Hi,
>
> I am looking into the internals of the eviction process,
>
> Can anyone point me to the most important classes, the main mechanism
> "wheels" etc.?
>
> Thanks,
>
> Roi
>
> -Original Message-
> From: Roi Apelker
> Sent: Wednesday, August 16, 2017 8:38 PM
> To: dev@geode.apache.org
> Subject: RE: continuous query internal mechanism questions
>
> It seems like the code in the native client (in the version I have, which
> may be old) send the message to all servers:
>
> CqResultsPtr CqQueryImpl::executeWithInitialResults(uint32_t timeout) {
>   ...
>
>   TcrMessage msg(TcrMessage::EXECUTECQ_WITH_IR_MSG_TYPE, m_cqName,
> m_queryString, CqState::RUNNING, isDurable(), m_tccdm);
>   TcrMessage reply(true, m_tccdm);
>   ChunkedQueryResponse* resultCollector = (new
> ChunkedQueryResponse(reply));
>   reply.setChunkedResultHandler(static_cast *>(resultCollector));
>   reply.setTimeout(timeout);
>
>   GfErrType err = GF_NOERR;
>   err = m_tccdm->sendSyncRequest(msg, reply); ..
>
> And sendSyncRequest:
> ...
>
> for (std::vector::iterator ep = m_endpoints.begin(); ep !=
> m_endpoints.end(); ++ep) {
> if ((*ep)->connected()) {
>   (*ep)->setDM(this);
>   opErr = sendRequestToEP(request, reply, *ep);//this will go to
> ThinClientDistributionManager
>
> ...
>
>
> Can this be causing the issue?
>
>
>
> -Roi
>
>
>
>
>
> -Original Message-
> From: Jason Huynh [mailto:jasonhu...@apache.org]
> Sent: Tuesday, August 15, 2017 9:25 PM
> To: dev@geode.apache.org
> Subject: Re: continuous query internal mechanism questions
>
> I am not quite sure how native client registers cqs. From my understanding:
> with the java api, I believe there is only one message (ExecuteCQ message)
> that is executed on the server side and then replicated to the other nodes
> through the profile (OperationMessage).
>
> It seems the extra ExecuteCQ message 

Review Request 61950: GEODE-3519 servers are not locking on remove or invalidate ops initiated by clients

2017-08-28 Thread Bruce Schuchardt

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/61950/
---

Review request for geode, Alexander Murmann, Galen O'Sullivan, Hitesh Khamesra, 
and Udo Kohlmeyer.


Bugs: geode-3519
https://issues.apache.org/jira/browse/geode-3519


Repository: geode


Description
---

While investigating dlocktoken cleanup I discovered that a number of operations 
coming from a client were not locking entries for Scope.GLOBAL regions on 
servers.  Only put, putIfAbsent and variants of replace were obtaining locks.


Diffs
-

  
geode-core/src/main/java/org/apache/geode/internal/cache/DistributedRegion.java 
d9ed4edeff629b87d0fce2463fa9b22723b57d9a 
  
geode-core/src/test/java/org/apache/geode/cache30/ClientServerCCEDUnitTest.java 
b4224e0dcba91ee75cf1abf185f6fc9fbe22390f 


Diff: https://reviews.apache.org/r/61950/diff/1/


Testing
---

precheckin, new integration test


Thanks,

Bruce Schuchardt



[GitHub] geode pull request #719: GEODE-3447 Implement client authorization for the n...

2017-08-28 Thread pivotal-amurmann
Github user pivotal-amurmann commented on a diff in the pull request:

https://github.com/apache/geode/pull/719#discussion_r135550580
  
--- Diff: 
geode-core/src/main/java/org/apache/geode/security/StreamAuthenticator.java ---
@@ -46,6 +44,14 @@ void receiveMessage(InputStream inputStream, 
OutputStream outputStream,
   boolean isAuthenticated();
 
   /**
+   * Return an authorization object which can be used to determine which 
permissions this stream has
+   * according to the provided securityManager.
+   *
+   * Calling this before authentication has succeeded may result in a null 
return object.
--- End diff --

How am I gonna see the comment as a user of this? I think it's unreasonable 
to assume that every consumer of the class is gonna look at its code.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


Query mechanism

2017-08-28 Thread Roi Apelker

Hi,

I am looking into the internals of how the query process works, and how 
indexes/hints affect it,

Can anyone point me to the most important classes, the main mechanism "wheels" 
etc.?

Thanks,

Roi


-Original Message-
From: Roi Apelker 
Sent: Sunday, August 27, 2017 12:55 PM
To: dev@geode.apache.org
Subject: Indxes and hints

Hi,

I have a few questions regarding indexes and hints, if someone could confirm 
the below it would be great:

- I have a situation where I use 3 field values in a select (something like 
select where A>1, B>1, C=true)
- A and B are fields on the key, and C is a field on the value.
- A and B are indexes
- I am looking for the most efficient way to execute the query above, in the 
situation where there is overflow to eviction files, meaning some of the data 
has already been evicted to a file, which slows down the select considerably 
(this is not persistence, but overflow).


1. Is it true to say, that the query as it is will load all the data values 
from the file, since the field C is part of the value, which is already 
persisted to file?
2. If I add a hint on A and B, will it mean that there will be a "2 phase 
search", first the select on A and B, and then, only on the results, on the 
field C? (this way, not all records will be loaded from file, only those that 
suit the A and B condition) 3. Is it possible to define an index on a value 
field? (i.e. not from the key) - will it work exactly like defining one form 
the key or are three any limitations? (again, I am looking to overcome the 
situation, where as it seems, the records are loaded unnecessarily from disk)

Thank you,

Roi


-Original Message-
From: Roi Apelker
Sent: Thursday, August 24, 2017 7:03 PM
To: dev@geode.apache.org
Subject: eviction files

Hi,

I am looking into the internals of the eviction process,

Can anyone point me to the most important classes, the main mechanism "wheels" 
etc.?

Thanks,

Roi

-Original Message-
From: Roi Apelker
Sent: Wednesday, August 16, 2017 8:38 PM
To: dev@geode.apache.org
Subject: RE: continuous query internal mechanism questions

It seems like the code in the native client (in the version I have, which may 
be old) send the message to all servers:

CqResultsPtr CqQueryImpl::executeWithInitialResults(uint32_t timeout) {
  ...

  TcrMessage msg(TcrMessage::EXECUTECQ_WITH_IR_MSG_TYPE, m_cqName, 
m_queryString, CqState::RUNNING, isDurable(), m_tccdm);
  TcrMessage reply(true, m_tccdm);
  ChunkedQueryResponse* resultCollector = (new ChunkedQueryResponse(reply));
  reply.setChunkedResultHandler(static_cast(resultCollector));
  reply.setTimeout(timeout);

  GfErrType err = GF_NOERR;
  err = m_tccdm->sendSyncRequest(msg, reply); ..

And sendSyncRequest:
...

for (std::vector::iterator ep = m_endpoints.begin(); ep != 
m_endpoints.end(); ++ep) {
if ((*ep)->connected()) {
  (*ep)->setDM(this);
  opErr = sendRequestToEP(request, reply, *ep);//this will go to 
ThinClientDistributionManager

...


Can this be causing the issue?



-Roi





-Original Message-
From: Jason Huynh [mailto:jasonhu...@apache.org]
Sent: Tuesday, August 15, 2017 9:25 PM
To: dev@geode.apache.org
Subject: Re: continuous query internal mechanism questions

I am not quite sure how native client registers cqs. From my understanding:
with the java api, I believe there is only one message (ExecuteCQ message) that 
is executed on the server side and then replicated to the other nodes through 
the profile (OperationMessage).

It seems the extra ExecuteCQ message failing and then closing the cq might be 
putting the system in a weird state...

On Tue, Aug 15, 2017 at 7:56 AM Roi Apelker  wrote:

> Hi,
>
> I have been examining the continuous query registration mechanism for 
> quite some time This is related to an issue that I have, where 
> sometimes a node crashes (1 node out of 2), and the other one does not 
> send CQ events. The CQ is registered on a partitioned region which 
> resides on these 2 nodes.
>
> I noticed the following behavior, and I wonder if anyone can comment 
> regarding it, if it is justified or not and what is the reason:
>
> 1. When the software using the client (native client) registers for 
> the CQ, a CQ command (ExecuteCQ61) is received on both servers.
>  -- is this normal behaviour? Does the client actually send this 
> command to both servers?
>
> 2. When this command is received by a server, and the CQ is 
> registered, another registration message is sent to the other node via 
> an OperationMessage (REGISTER_CQ)
>  -- it seems that regularly, the server can handle this situation as 
> the second registration identifies the previous one and does not 
> affect it. but the question, why do we need this 2nd registration, if 
> there is a command sent to each server?
>
> 3. For some reason, sometimes there is a failure to complete the first 
> registration (executed by ExecuteCQ61) and then this 

Bug while parsing the JSON "key which having short data type" in locate command

2017-08-28 Thread Dinesh Akhand
Hi Team,

I have found one bug in geode 1.2 .

If in the key we having the short data type

Example:

public class EmpData  implements Serializable{
private short empid;

public short getEmpid() {
   return empid;
}

public void setEmpid(short empid) {
   this.empid = empid;
}


EmpData d1 = new EmpData();
D1. setEmpid((short)1);

Region.put(d1,"value1");

Now try locate command on this .


Problem in code: file JSONTokener.java. it always return short to int value

try {
long longValue = Long.parseLong(number, base);
if(longValue <= Short.MAX_VALUE && longValue >= Short.MIN_VALUE)
{
 return (short) longValue;
}
else if (longValue <= Integer.MAX_VALUE && longValue >= 
Integer.MIN_VALUE) {
  return (int) longValue;
} else {
  return longValue;
}

Later it cause the problem of java.lang.IllegalArgumentException: argument type 
mismatch.
locate entry --key=--key=('empid ':1) --region=CUSTOMER_1

alternate way :  changes the  DataCommandFunctionJUnitTest.java changes the 
testLocateKeyIsObject method

due to same problem, we are facing problem with all commands where we usage the 
key.

Thanks,
Dinesh Akhand


This message and the information contained herein is proprietary and 
confidential and subject to the Amdocs policy statement,

you may review at https://www.amdocs.com/about/email-disclaimer 



DISCUSS : Monitor the neighbour JVM using neihbour's member-timeout (GEODE-3411)

2017-08-28 Thread Aravind Musigumpula
Hi Team,

We have a requirement to configure  different member timeout for different 
members as we need some members to survive in the view for longer time than the 
other the members before being kicked out of the view in case they aren't 
responding.


1.   Now with the current monitoring system it is not possible to determine 
when the member will be kicked out of the view if we configure different 
member-timeout's for some required members.

2.   Because if a member is not responding to any heartbeat requests, the 
member who is monitoring the non-responding member will initiate check member 
request.

3.   In this check member request monitoring member pings the 
non-responding member and waits for member-timeout of monitoring member for a 
response.

4.   If still there is no response, it will initiate a final suspect 
request to coordinator where the coordinator does the final check waiting for 
coordinators member-timeout.

5.   If coordinator did not get any response, it will remove the 
non-responding member from the view and publishes it.

6.   So, Here the time period for removing a member depends on its 
monitoring member's and coordinator's timeout. But the monitoring member 
depends on the view but it may change from time to time.

So, now when a monitoring-member doing the check on a member, if we wait for 
the non-responding member's timeout instead of the monitoring member-timeout, 
then the time when the non-responding member will be removed from the view 
depends on its own member-timeout and the coordinators member-timeout.
Hence we can configure different member-timeout for the required members.

I created a pull request based on the above scenario: 
https://github.com/apache/geode/pull/717

Is the above approach correct? Do we have any concerns around this area?
Please give your insights on this issue.

Thanks,
Aravind Musigumpula

This message and the information contained herein is proprietary and 
confidential and subject to the Amdocs policy statement,

you may review at https://www.amdocs.com/about/email-disclaimer 



[GitHub] geode issue #717: Feature/geode 3411 Monitor the neighbour JVM using neihbou...

2017-08-28 Thread aravindmusigumpula
Github user aravindmusigumpula commented on the issue:

https://github.com/apache/geode/pull/717
  
thanks @upthewaterspout for pointing out these issues ,
I have added this new parameter in two methods toDataPre_GFE_7_1_0_0, 
toDataPre_GFE_9_0_0_0.
And I understand that adding a field to toDataPre_GFE_7_1_0_0 breaks 
compatibility with client/peers, so should I remove it from this method?
I don't see any method toDataPre_GEODE_1_3_0_0, should I create one?
I am new here, please help me understand how to make this correct without 
breaking compatibility issues.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---