{"action":"created","issue":{"url":"https://api.github.com/repos/warelab/gramoogle/issues/21","labels_url":"https://api.github.com/repos/warelab/gramoogle/issues/21/labels{/name}","comments_url":"https://api.github.com/repos/warelab/gramoogle/issues/21/comments","events_url":"https://api.github.com/repos/warelab/gramoogle/issues/21/events","html_url":"https://github.com/warelab/gramoogle/issues/21","id":60123376,"number":21,"title":"Figure out client-server request timeline","user":{"login":"mycrobe","id":40182,"avatar_url":"https://avatars.githubusercontent.com/u/40182?v=3","gravatar_id":"","url":"https://api.github.com/users/mycrobe","html_url":"https://github.com/mycrobe","followers_url":"https://api.github.com/users/mycrobe/followers","following_url":"https://api.github.com/users/mycrobe/following{/other_user}","gists_url":"https://api.github.com/users/mycrobe/gists{/gist_id}","starred_url":"https://api.github.com/users/mycrobe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mycrobe/subscriptions","organizations_url":"https://api.github.com/users/mycrobe/orgs","repos_url":"https://api.github.com/users/mycrobe/repos","events_url":"https://api.github.com/users/mycrobe/events{/privacy}","received_events_url":"https://api.github.com/users/mycrobe/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-03-06T16:22:17Z","updated_at":"2015-03-06T22:38:43Z","closed_at":null,"body":"gramoogle requires search results in a number of different forms:\r\n* Summary statistics for filter summary\r\n* List of genes for list view (may not be visible)\r\n* Results faceted by genomic location bin.\r\n  * Genes are in multiple bins for different resolution (e.g. 1Mb, 2Mb, 10Mb).\r\n  * Only one of these would be used at a time.\r\n* Results faceted to provide counts for the filter UI (interpro domain, go term etc)\r\n\r\nShould these all be requested separately? By components when required? Bundled into one SOLR request with a large body?"},"comment":{"url":"https://api.github.com/repos/warelab/gramoogle/issues/comments/77649565","html_url":"https://github.com/warelab/gramoogle/issues/21#issuecomment-77649565","issue_url":"https://api.github.com/repos/warelab/gramoogle/issues/21","id":77649565,"user":{"login":"ajo2995","id":1328413,"avatar_url":"https://avatars.githubusercontent.com/u/1328413?v=3","gravatar_id":"","url":"https://api.github.com/users/ajo2995","html_url":"https://github.com/ajo2995","followers_url":"https://api.github.com/users/ajo2995/followers","following_url":"https://api.github.com/users/ajo2995/following{/other_user}","gists_url":"https://api.github.com/users/ajo2995/gists{/gist_id}","starred_url":"https://api.github.com/users/ajo2995/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ajo2995/subscriptions","organizations_url":"https://api.github.com/users/ajo2995/orgs","repos_url":"https://api.github.com/users/ajo2995/repos","events_url":"https://api.github.com/users/ajo2995/events{/privacy}","received_events_url":"https://api.github.com/users/ajo2995/received_events","type":"User","site_admin":false},"created_at":"2015-03-06T22:38:43Z","updated_at":"2015-03-06T22:38:43Z","body":"I imagine there will be a mix of requests for data that fire under different circumstances.\r\n\r\n1. Typeahead requests\r\n2. list of genes for list view\r\n3. Taxonomic and genomic location distributions\r\n4. Other filters\r\n\r\n1. Typeahead should be as lean as possible. If we don't care about suggestions being compatible with active filters, the suggest requestHandler in solr can do the job. Otherwise, we need to use the select requestHandler with a minimal response document and no facet counting. If we want to query across multiple cores, and keep the suggestions relevant to the current result set it gets more complicated and requires an intermediate service to integrate the responses from multiple cores. I'm leaning toward setting up an intermediate service anyway in case it becomes necessary to do complex things without complicating gramoogle.\r\n\r\n2. The list of genes contains more information than the typeahead responses and is definitely subject to any filters that have been defined. The nrows query parameter can be set to something small in the request that provides the taxonomic and genomic location distributions. Subsequent requests triggered by scrolling can happen without facet counting.\r\n\r\n3. The taxonomic and genomic location distributions differ from other filters in that they need to be requested with facet.limit=-1 (default is to limit to 100).\r\n\r\n4. Other filters are not shown until the Filters tab is opened. Therefore, if it is not open, the solr request with those facet fields should happen separately from the request that provides the gene list and tax&gen distributions (2 & 3). The filter summary view shows each filter field with the exact number of terms in the result set or \">100\". The term counts need to be calculated from the solr response for each facet.field because solr doesn't do it for you. The same solr response contains the necessary info to populate each filter. A filter may need to request useful info from an associated solr core such as domain name and description given a list of interpro ids. When a specific filter is being displayed, additional facet terms beyond the top 100 most popular w.r.t. the gene result set may be retrieved for just this facet with facet.offset=100.\r\n"}}