You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@juneau.apache.org by steveblackmon <gi...@git.apache.org> on 2017/06/15 15:36:36 UTC

[GitHub] incubator-juneau pull request #3: resolves JUNEAU-55

GitHub user steveblackmon opened a pull request:

    https://github.com/apache/incubator-juneau/pull/3

    resolves JUNEAU-55

    i confirmed that interfaces with method annotated with PUT and DELETE no longer throw errors on instantiation and do indeed call the remote service as expected. 

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

    $ git pull https://github.com/steveblackmon/incubator-juneau JUNEAU-55

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

    https://github.com/apache/incubator-juneau/pull/3.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 #3
    
----
commit 3e9acb5fc4c279441a4bff0d8cd556a2336268e0
Author: Steve Blackmon @steveblackmon <sb...@apache.org>
Date:   2017-06-15T15:33:14Z

    resolves JUNEAU-55

----


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-juneau pull request #3: resolves JUNEAU-55

Posted by johnament <gi...@git.apache.org>.
Github user johnament commented on a diff in the pull request:

    https://github.com/apache/incubator-juneau/pull/3#discussion_r122239394
  
    --- Diff: juneau-core/src/main/java/org/apache/juneau/remoteable/RemoteableMethodMeta.java ---
    @@ -74,8 +74,8 @@ private Builder(String restUrl, Method m) {
     			RemoteMethod rm = m.getAnnotation(RemoteMethod.class);
     
     			httpMethod = rm == null ? "POST" : rm.httpMethod();
    -			if (! isOneOf(httpMethod, "GET", "POST"))
    -				throw new RemoteableMetadataException(m, "Invalid value specified for @RemoteMethod.httpMethod() annotation.  Valid values are [GET,POST].");
    +			if (! isOneOf(httpMethod, "DELETE", "GET", "POST", "PUT"))
    --- End diff --
    
    Should we perhaps use an enum?


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-juneau pull request #3: resolves JUNEAU-55

Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:

    https://github.com/apache/incubator-juneau/pull/3


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-juneau pull request #3: resolves JUNEAU-55

Posted by jamesbognar <gi...@git.apache.org>.
Github user jamesbognar commented on a diff in the pull request:

    https://github.com/apache/incubator-juneau/pull/3#discussion_r122241005
  
    --- Diff: juneau-core/src/main/java/org/apache/juneau/remoteable/RemoteableMethodMeta.java ---
    @@ -74,8 +74,8 @@ private Builder(String restUrl, Method m) {
     			RemoteMethod rm = m.getAnnotation(RemoteMethod.class);
     
     			httpMethod = rm == null ? "POST" : rm.httpMethod();
    -			if (! isOneOf(httpMethod, "GET", "POST"))
    -				throw new RemoteableMetadataException(m, "Invalid value specified for @RemoteMethod.httpMethod() annotation.  Valid values are [GET,POST].");
    +			if (! isOneOf(httpMethod, "DELETE", "GET", "POST", "PUT"))
    +				throw new RemoteableMetadataException(m, "Invalid value specified for @RemoteMethod.httpMethod() annotation.  Valid values are [DELTE,GET,POST,PUT].");
    --- End diff --
    
    Agreed.  But we should open a separate ticket for 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 infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-juneau pull request #3: resolves JUNEAU-55

Posted by johnament <gi...@git.apache.org>.
Github user johnament commented on a diff in the pull request:

    https://github.com/apache/incubator-juneau/pull/3#discussion_r122239466
  
    --- Diff: juneau-core/src/main/java/org/apache/juneau/remoteable/RemoteableMethodMeta.java ---
    @@ -74,8 +74,8 @@ private Builder(String restUrl, Method m) {
     			RemoteMethod rm = m.getAnnotation(RemoteMethod.class);
     
     			httpMethod = rm == null ? "POST" : rm.httpMethod();
    -			if (! isOneOf(httpMethod, "GET", "POST"))
    -				throw new RemoteableMetadataException(m, "Invalid value specified for @RemoteMethod.httpMethod() annotation.  Valid values are [GET,POST].");
    +			if (! isOneOf(httpMethod, "DELETE", "GET", "POST", "PUT"))
    +				throw new RemoteableMetadataException(m, "Invalid value specified for @RemoteMethod.httpMethod() annotation.  Valid values are [DELTE,GET,POST,PUT].");
    --- End diff --
    
    again, an enum would just mean we have to do `HttpMethods.values()`


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---