1
스 캐라의 Http에 Dispatch Databinder 라이브러리를 사용하고 있습니다.스칼라 디스패치 데이터 바인딩 라이브러리가 java.nio.BufferUnderflowException을 throw합니다.
이 방법이 있습니다. 특정 URL을
def testCheckPage(url:String):String = {
try {
var http = new Http
var request = new Request(url)
val req_with_agent = request <:< Map("User-Agent" -> "Mozilla/4.0")
val responseBody = Http (req_with_agent as_str)
responseBody.length.toString
} catch {
case ex: Exception if ex.getMessage == null => "Message: " + ex.toString
case ex: Exception => "Message: " + ex.getMessage
}
}
같은 http://bae.cf.huffingtonpost.com
, 나는 java.nio.BufferUnderflowException
을 얻고있다. 어떤 생각 이요?