Home Home
  login

Gemini Community Support Site

This Gemini community support site can be used to find solutions to product issues. You can log in using Open Id, Google Profile and even Facebook. Feel free to ask a question or browse FAQs and documentation. Product tour videos are also available along with how-to videos demonstrating key Gemini capabilities.




Request timeout

api

When I call the GetFilteredIssues method on ServiceManager I got a "Timeout operation message" after 21:30 (mm:ss).

I'll try to setup a big time, setting the ServiceManager.IssuesService.HttpTimeout property to -1, int.MaxValue, etc, but nothing seems to work.

The filter condition should return around 3500 items (issues)

Any advice?

Gemini_log.txt ]
atorres
· 50
atorres
Replies (7)
helpful
0
not helpful

Do not use GetFilteredIssues use Get Paged Filtered Issues instead. This will be fixed for Gemini 5.


Simran
· 1762
Simran
helpful
0
not helpful

After many tests and waiting 10 minutes for each method call, the GetPagedFilteredIssues method always returns 0 items. It's very very frustrating slowness and API results.

IssuesFilterEN issuesFilter = new IssuesFilterEN() { ProjectID = "30|22|23|21|45|31|27|24|25", ExcludeClosed = true };

IEnumerable listIssues = this.serviceManager .IssuesService .GetPagedFilteredIssues(issuesFilter, 1, 100, false).Issues;

// listIssues has always 0 items


atorres
· 50
atorres
helpful
0
not helpful

Any comments?


atorres
· 50
atorres
helpful
0
not helpful

The start page should be 0. Replace the 1 with a 0. Do you have more than 100 issues?


Simran
· 1762
Simran
helpful
0
not helpful

Are you sure? If I use 0 instead of 1 for the startPage pararameter then throws this exception:

Root element is missing.

at System.Xml.XmlTextReaderImpl.Throw(Exception e) at System.Xml.XmlTextReaderImpl.ParseDocumentContent() at System.Xml.XmlTextReaderImpl.Read() at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace) at System.Xml.XmlDocument.Load(XmlReader reader) at System.Xml.XmlDocument.Load(Stream inStream) at CounterSoft.Gemini.Commons.Rest.Serializer.ConvertToObject[T](Stream stream) at CounterSoft.Gemini.WebServices.BaseService.GetObjectFromResponse[T](Stream stream, Int64 length) at CounterSoft.Gemini.WebServices.BaseService.ProcessResponse[T](String url,Object obj, RequestType requestType) at CounterSoft.Gemini.WebServices.IssuesService.GetPagedFilteredIssues(IssuesFilterEN filter, Int32 startpage, Int32 pageSize, Boolean includeAttachments)


atorres
· 50
atorres
helpful
0
not helpful

Please use page 1, but add the userid to the IssuesFilterEN. That should solve it.


Mark Wing
· 9108
Mark Wing
helpful
0
not helpful
ANSWER

Finally works. This is the solution:

private IEnumerable<IssueEN> GetPaggedIssues(IssuesFilterEN issuesFilter)

{ issuesFilter.UserID = this.serviceManager.UsersService.WhoAmI().UserID;

List<IssueEN> allIssues = new List<IssueEN>();

decimal pageCount = 1;
int pageSize = 100;

for (int pageIndex = 1; pageIndex <= pageCount; pageIndex++)
{
    PagedIssuesResultBag resultBag = this.serviceManager
        .IssuesService
        .GetPagedFilteredIssues(issuesFilter, pageIndex, pageSize, false);

    pageCount = resultBag.TotalIssues;
    pageCount = Math.Ceiling((decimal)pageCount / (decimal)pageSize);
    allIssues.AddRange(resultBag.Issues);
}

return allIssues;

}


atorres
· 50
atorres