- URLConnection urlconn = url.openConnection();
- InputStream istr = urlconn.getInputStream();
- List<Entry> entries = getUniprotEntries(istr);
- if (entries != null)
+ HttpURLConnection urlconn = (HttpURLConnection)url.openConnection();
+ // anything other than 200 means we don't have data
+ // TODO: JAL-3882 reuse the EnsemblRestClient's fair
+ // use/backoff logic to retry when the server tells us to go away
+ if (urlconn.getResponseCode() == 200)