[JBoss JIRA] (JBIDE-15581) openshift-java-client: support PATCH http method
by Andre Dietisheim (JIRA)
[ https://issues.jboss.org/browse/JBIDE-15581?page=com.atlassian.jira.plugi... ]
Andre Dietisheim edited comment on JBIDE-15581 at 9/30/13 3:38 AM:
-------------------------------------------------------------------
Http PATCH is defined in http://tools.ietf.org/html/rfc5789. Its semantic meaning in REST is to mutate an existing resource. PATCH allows a user to change an existing resource (like PUT) by only by passing a fragment, not replacing the whole resource (patching an existing resource):
* http://www.mnot.net/blog/2012/09/05/patch
* https://restful-api-design.readthedocs.org/en/latest/methods.html#patch-v...
The HttpUrlConnection we're using the client wont support any method that's not GET; POST; PUT, DELETE, OPTIONS, HEAD, TRACE. It'll throw a ProtocolException:
http://book.javanb.com/java-network-programming-3rd/javanp3-CHP-15-SECT-1...
Jersey (Jax-RS implementation) came across the very same problem and found a partial fix. They're changing the connection via reflection:
* https://java.net/jira/browse/JERSEY-639
* https://blogs.oracle.com/PavelBucek/entry/jersey_client_making_requests_with
But the solution wont work for non-supported methods that require a paylod being sent with the method:
* https://java.net/jira/browse/JERSEY-1367
JDK 8 will provide an additional http client which will support what's not provided by the HttpUrlConnection. Jersey 2.0 will use the apache http client internally in order to support the lacking features:
* https://java.net/jira/browse/JERSEY-639
A valid workaround is an approach called "verb" tunnelling", where you'd use *POST* and set a special header key *X-Http-Method-Override*:
* http://fandry.blogspot.fr/2012/03/x-http-header-method-override-and-rest....
* http://msdn.microsoft.com/en-us/library/dd541471.aspx
* https://tools.oasis-open.org/issues/browse/ODATA-462
That's what Claytons patch is implementing.
was (Author: adietish):
Http PATCH is defined in http://tools.ietf.org/html/rfc5789. Its semantic meaning in REST is to mutate an existing resource. PATCH allows a user to change an existing resource (like PUT) by only by passing a fragment, not replacing the whole resource (patching an existing resource):
* http://www.mnot.net/blog/2012/09/05/patch
* https://restful-api-design.readthedocs.org/en/latest/methods.html#patch-v...
The HttpUrlConnection we're using the client wont support any method that's not GET; POST; PUT, DELETE, OPTIONS, HEAD, TRACE. It'll throw a ProtocolException:
http://book.javanb.com/java-network-programming-3rd/javanp3-CHP-15-SECT-1...
Jersey (Jax-RS implementation) came across the very same problem and found a partial fix. They're changing the connection via reflection:
* https://java.net/jira/browse/JERSEY-639
* https://blogs.oracle.com/PavelBucek/entry/jersey_client_making_requests_with
But the solution wont work for non-supported methods that require a paylod being sent with the method:
* https://java.net/jira/browse/JERSEY-1367
JDK 8 will provide an additional http client which will support what's not provided by the HttpUrlConnection. Jersey 2.0 will use the apache http client internally in order to support the lacking features:
* https://java.net/jira/browse/JERSEY-639
A valid workaround is an approach called "verb" tunnelling, where you'd use *POST* and set a special header key *X-Http-Method-Override*:
* http://fandry.blogspot.fr/2012/03/x-http-header-method-override-and-rest....
* http://msdn.microsoft.com/en-us/library/dd541471.aspx
* https://tools.oasis-open.org/issues/browse/ODATA-462
That's what Claytons patch is implementing.
> openshift-java-client: support PATCH http method
> ------------------------------------------------
>
> Key: JBIDE-15581
> URL: https://issues.jboss.org/browse/JBIDE-15581
> Project: Tools (JBoss Tools)
> Issue Type: Feature Request
> Components: openshift
> Affects Versions: 4.2.0.Alpha1
> Reporter: Andre Dietisheim
> Assignee: Andre Dietisheim
> Labels: openshift-java-client
> Fix For: 4.2.x
>
>
> OpenShift's using the PATCH http method in links for protocol 1.6 (will those links get backported?).
> The OpenShift java client does not support any method that differs from GET, POST, PUT, DELETE and should support links that use the PATCH http method.
> {quote}
> (06:35:55 PM) clayton: we're adding PATCH methods and I'm ensuring that the client tools will be future compatible when that happens
> (06:36:06 PM) clayton: they'll only be in API 1.6 but want to fix it now
> {quote}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 6 months
[JBoss JIRA] (JBIDE-15575) Creation of foundation.ui to hold TaskWizard framework
by Rob Stryker (JIRA)
[ https://issues.jboss.org/browse/JBIDE-15575?page=com.atlassian.jira.plugi... ]
Rob Stryker commented on JBIDE-15575:
-------------------------------------
The two methods in the page which catch the exception and return false are: isPageComplete(), and canFlipToNextPage()
For both of these methods, the method it's calling is fragment.isComplete(). In a WizardFragment, isComplete() should be a very very simple method which only returns true or false. No complicated logic should ever be done in fragment.isComplete(). If the fragment wishes to update its fragment completion status, it should use protected void setComplete(boolean complete) {}.
So, in 99.9% of the cases, isComplete() should never throw an exception. The exception catching is there only in case an extender decided to do complicated logic in the isComplete() method, which they shouldn't be doing. You'll note that WizardFragment.isComplete() does not throw any exceptions at all.
In either event, I added tracing to the two methods so that if a developer is wishing to debug their wizard fragment, they can enable tracing on the foundation.ui plugin.
I do not think its appropriate for the framework to throw an exception here or to log an error in the error log, and I believe tracing is the appropriate solution. For that reason, I am marking the JIRA as resolved again.
> Creation of foundation.ui to hold TaskWizard framework
> ------------------------------------------------------
>
> Key: JBIDE-15575
> URL: https://issues.jboss.org/browse/JBIDE-15575
> Project: Tools (JBoss Tools)
> Issue Type: Feature Request
> Components: common/jst/core
> Affects Versions: 4.2.0.Alpha1
> Reporter: Rob Stryker
> Assignee: Rob Stryker
> Fix For: 4.2.0.Alpha1
>
>
> Creation of a foundation.ui is required for a few reasons:
> 1) runtimes should not depend on common. A foundation.ui is needed for that
> 2) Hold taskwizard, a framework from wtp internals which is very very useful and many have expressed interest in using. Runtimes will be using this framework very soon and others will convert in the future.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 6 months
[JBoss JIRA] (JBIDE-15581) openshift-java-client: support PATCH http method
by Andre Dietisheim (JIRA)
[ https://issues.jboss.org/browse/JBIDE-15581?page=com.atlassian.jira.plugi... ]
Andre Dietisheim updated JBIDE-15581:
-------------------------------------
Labels: openshift-java-client (was: )
> openshift-java-client: support PATCH http method
> ------------------------------------------------
>
> Key: JBIDE-15581
> URL: https://issues.jboss.org/browse/JBIDE-15581
> Project: Tools (JBoss Tools)
> Issue Type: Feature Request
> Components: openshift
> Affects Versions: 4.2.0.Alpha1
> Reporter: Andre Dietisheim
> Assignee: Andre Dietisheim
> Labels: openshift-java-client
> Fix For: 4.2.x
>
>
> OpenShift's using the PATCH http method in links for protocol 1.6 (will those links get backported?).
> The OpenShift java client does not support any method that differs from GET, POST, PUT, DELETE and should support links that use the PATCH http method.
> {quote}
> (06:35:55 PM) clayton: we're adding PATCH methods and I'm ensuring that the client tools will be future compatible when that happens
> (06:36:06 PM) clayton: they'll only be in API 1.6 but want to fix it now
> {quote}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 6 months
[JBoss JIRA] (JBIDE-15581) openshift-java-client: support PATCH http method
by Andre Dietisheim (JIRA)
[ https://issues.jboss.org/browse/JBIDE-15581?page=com.atlassian.jira.plugi... ]
Andre Dietisheim edited comment on JBIDE-15581 at 9/28/13 11:35 AM:
--------------------------------------------------------------------
Http PATCH is defined in http://tools.ietf.org/html/rfc5789. Its semantic meaning in REST is to mutate an existing resource. PATCH allows a user to change an existing resource (like PUT) by only by passing a fragment, not replacing the whole resource (patching an existing resource):
* http://www.mnot.net/blog/2012/09/05/patch
* https://restful-api-design.readthedocs.org/en/latest/methods.html#patch-v...
The HttpUrlConnection we're using the client wont support any method that's not GET; POST; PUT, DELETE, OPTIONS, HEAD, TRACE. It'll throw a ProtocolException:
http://book.javanb.com/java-network-programming-3rd/javanp3-CHP-15-SECT-1...
Jersey (Jax-RS implementation) came across the very same problem and found a partial fix. They're changing the connection via reflection:
* https://java.net/jira/browse/JERSEY-639
* https://blogs.oracle.com/PavelBucek/entry/jersey_client_making_requests_with
But the solution wont work for non-supported methods that require a paylod being sent with the method:
* https://java.net/jira/browse/JERSEY-1367
JDK 8 will provide an additional http client which will support what's not provided by the HttpUrlConnection. Jersey 2.0 will use the apache http client internally in order to support the lacking features:
* https://java.net/jira/browse/JERSEY-639
A valid workaround is an approach called "verb" tunnelling, where you'd use *POST* and set a special header key *X-Http-Method-Override*:
* http://fandry.blogspot.fr/2012/03/x-http-header-method-override-and-rest....
* http://msdn.microsoft.com/en-us/library/dd541471.aspx
* https://tools.oasis-open.org/issues/browse/ODATA-462
That's what Claytons patch is implementing.
was (Author: adietish):
Http PATCH is defined in http://tools.ietf.org/html/rfc5789. Its semantic meaning in REST is to mutate an existing resource. PATCH allows a user to change an existing resource (like PUT) by only by passing a fragment, not replacing the whole resource (patching an existing resource):
* http://www.mnot.net/blog/2012/09/05/patch
* https://restful-api-design.readthedocs.org/en/latest/methods.html#patch-v...
The HttpUrlConnection we're using the client wont support any method that's not GET; POST; PUT, DELETE, OPTIONS, HEAD, TRACE. It'll throw a ProtocolException:
http://book.javanb.com/java-network-programming-3rd/javanp3-CHP-15-SECT-1...
Jersey (Jax-RS implementation) came across the very same problem and found a partial fix. They're changing the connection via reflection:
* https://java.net/jira/browse/JERSEY-639
* https://blogs.oracle.com/PavelBucek/entry/jersey_client_making_requests_with
But the solution wont work for non-supported methods that require a paylod being sent with the method:
* https://java.net/jira/browse/JERSEY-1367
JDK 8 will provide an additional http client which will support what's not provided by the HttpUrlConnection. Jersey 2.0 will use the apache http client internally in order to support the lacking features:
* https://java.net/jira/browse/JERSEY-639
A valid workaround is an approach called "verb" tunnelling, where you'd use *POST* and set a special header key *X-Http-Method-Override*:
* http://fandry.blogspot.fr/2012/03/x-http-header-method-override-and-rest....
* https://tools.oasis-open.org/issues/browse/ODATA-462
That's what Claytons patch is implementing.
> openshift-java-client: support PATCH http method
> ------------------------------------------------
>
> Key: JBIDE-15581
> URL: https://issues.jboss.org/browse/JBIDE-15581
> Project: Tools (JBoss Tools)
> Issue Type: Feature Request
> Components: openshift
> Affects Versions: 4.2.0.Alpha1
> Reporter: Andre Dietisheim
> Assignee: Andre Dietisheim
> Fix For: 4.2.x
>
>
> OpenShift's using the PATCH http method in links for protocol 1.6 (will those links get backported?).
> The OpenShift java client does not support any method that differs from GET, POST, PUT, DELETE and should support links that use the PATCH http method.
> {quote}
> (06:35:55 PM) clayton: we're adding PATCH methods and I'm ensuring that the client tools will be future compatible when that happens
> (06:36:06 PM) clayton: they'll only be in API 1.6 but want to fix it now
> {quote}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 6 months
[JBoss JIRA] (JBIDE-15581) openshift-java-client: support PATCH http method
by Andre Dietisheim (JIRA)
[ https://issues.jboss.org/browse/JBIDE-15581?page=com.atlassian.jira.plugi... ]
Andre Dietisheim commented on JBIDE-15581:
------------------------------------------
Http PATCH is defined in http://tools.ietf.org/html/rfc5789. Its semantic meaning in REST is to mutate an existing resource. PATCH allows a user to change an existing resource (like PUT) by only by passing a fragment, not replacing the whole resource (patching an existing resource):
http://www.mnot.net/blog/2012/09/05/patch
https://restful-api-design.readthedocs.org/en/latest/methods.html#patch-v...
The HttpUrlConnection we're using the client wont support any method that's not GET; POST; PUT, DELETE, OPTIONS, HEAD, TRACE. It'll throw a ProtocolException:
http://book.javanb.com/java-network-programming-3rd/javanp3-CHP-15-SECT-1...
Jersey (Jax-RS implementation) came across the very same problem and found a partial fix. They're changing the connection via reflection:
* https://java.net/jira/browse/JERSEY-639
* https://blogs.oracle.com/PavelBucek/entry/jersey_client_making_requests_with
But the solution wont work for non-supported methods that require a paylod being sent with the method:
* https://java.net/jira/browse/JERSEY-1367
JDK 8 will provide an additional http client which will support what's not provided by the HttpUrlConnection. Jersey 2.0 will use the apache http client internally in order to support the lacking features:
https://java.net/jira/browse/JERSEY-639
A valid workaround is an approach called "verb" tunnelling, where you'd use *POST* and set a special header key *X-Http-Method-Override*:
http://fandry.blogspot.fr/2012/03/x-http-header-method-override-and-rest....
That's what Claytons patch is implementing.
> openshift-java-client: support PATCH http method
> ------------------------------------------------
>
> Key: JBIDE-15581
> URL: https://issues.jboss.org/browse/JBIDE-15581
> Project: Tools (JBoss Tools)
> Issue Type: Feature Request
> Components: openshift
> Affects Versions: 4.2.0.Alpha1
> Reporter: Andre Dietisheim
> Assignee: Andre Dietisheim
> Fix For: 4.2.x
>
>
> OpenShift's using the PATCH http method in links for protocol 1.6 (will those links get backported?).
> The OpenShift java client does not support any method that differs from GET, POST, PUT, DELETE and should support links that use the PATCH http method.
> {quote}
> (06:35:55 PM) clayton: we're adding PATCH methods and I'm ensuring that the client tools will be future compatible when that happens
> (06:36:06 PM) clayton: they'll only be in API 1.6 but want to fix it now
> {quote}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 6 months