twitter/finagle

Support for uploading files in HTTP client

Open

#501 geöffnet am 26. Apr. 2016

Auf GitHub ansehen
 (3 Kommentare) (0 Reaktionen) (0 zugewiesene Personen)Scala (1.435 Forks)batch import
help wanted

Repository-Metriken

Stars
 (8.864 Stars)
PR-Merge-Metriken
 (Keine gemergten PRs in 30 T)

Beschreibung

I am abandoning scalaj-http in favour of Finagle. The only feature that I am missing is support for file uploads. From what I have found, there is no direct equivalent to this scalaj-http code:

val response = scalaj.http.Http(url)
  .postMulti(scalaj.http.MultiPart(
    "file",
    file.getName,
    Files.probeContentType(file.toPath),
    new FileInputStream(file),
    file.length(),
    onWrite))

Contributor Guide