Revision 58484
Added by Andreas Czerniak about 4 years ago
modules/dnet-download-service/trunk/src/main/java/eu/dnetlib/data/download/worker/DownloadWorker.java | ||
---|---|---|
64 | 64 |
**/ |
65 | 65 |
private int sleepTimeMs; |
66 | 66 |
|
67 |
private String userAgent = "Mozilla/5.0 (compatible; OAI; +http://www.openaire.eu)"; |
|
67 |
private String userAgent = "Mozilla/5.0 (compatible; OAI; +http://www.openaire.eu)"; // "OpenAIRE aggregation system/2.2.5 ; (OpenAccess aggregator; mailto:helpdesk@openaire.eu)"
|
|
68 | 68 |
|
69 | 69 |
/** |
70 | 70 |
* Instantiates a new download worker. |
... | ... | |
169 | 169 |
connection.setRequestProperty("User-Agent", userAgent); |
170 | 170 |
connection.setConnectTimeout(getConnectTimeoutMs()); |
171 | 171 |
connection.setReadTimeout(getReadTimeoutMs()); |
172 |
connection.setRequestProperty("User-Agent", "OpenAIRE aggregation system/2.2.5 ; (OpenAccess aggregator; mailto:helpdesk@openaire.eu) "); |
|
172 |
//connection.setRequestProperty("User-Agent", "OpenAIRE aggregation system/2.2.5 ; (OpenAccess aggregator; mailto:helpdesk@openaire.eu) ");
|
|
173 | 173 |
|
174 | 174 |
log.debug(threadId + ": getting input stream from " + toDownload); |
175 | 175 |
record.setInputStream(connection.getInputStream()); |
Also available in: Unified diff
fix user-agent strings (doublett)