I cannot find a reason of timeout exception when updating an issue using REST API and PUT method. The similar code in VB.NET, which successfully updates e.g. summary, cannot updates assigne or add new comment. After 1 minute the TWebException is raised.
Works:
"{ ""update"" : { ""summary"" : [{""set"" : """ & pstrSummary & """}] } }"
Works:
"{ ""update"" : { ""description"" : [{""set"" : """ & pstrDescription & """}] } }"
Doesn't work:
"{ ""update"" : { ""assignee"" : [{""set"" : {""name"" : """ & pstrAssigned & """}}] } }"
Doesn't work:
"{ ""update"" : { ""comment"" : [{""add"" : {""body"" : """ & pstrCommentText & """}}] } }"
The stack trace:
System
w System.Net.HttpWebRequest.GetRequestStream(TransportContext& context)
w System.Net.HttpWebRequest.GetRequestStream()
w JiraRestClient.Examples.JiraClient.Assign(String pstrIssueKey, String pstrAssigned) w <path>
System.IO.Stream GetRequestStream(System.Net.TransportContext ByRef)
You should set assignee like this
"fields": {"assignee": { "name": "homer" }}
and you should add comments using
POST /rest/api/2/issue/{issueIdOrKey}/comment
Thank you, Alexey. I will recognize my error: I was thinking of a new comment like as a result of an issue update - but my examples was updates of assignee and comment, not additions to issue. Hava a nice day!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
BTW, why the API responds with a timeout, not with an error? It's interesting.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.