Giter Site home page Giter Site logo

Comments (3)

looly avatar looly commented on May 23, 2024

感谢你的issue,关于这几个问题我一一解答:
1、header(Header.ACCEPT_ENCODING, "gzip", true)加入是因为在HttpResponse中有Gzip解压的逻辑。具体看下:HttpResponse.readBody
2、header(Header.CONTENT_TYPE, "application/x-www-form-urlencoded", true) 这个Header确实应该是这几个方法用,但是貌似GET等发发并不影响,所以就没有去掉,默认了。之后我会测试,加个判断。
3、302跳转现在可以支持,在HttpRequest.setFollowRedirects方法设置为true时可跳转。

from hutool.

huo-feng-ding avatar huo-feng-ding commented on May 23, 2024

问题1,3 看到了,谢谢,由于没有相关的测试用例,我直接HttpConnection返回的inputstream抽取解压数据,原来有HttpResponse类可以处理,setFollowRedirects方法也见到了
谢谢

from hutool.

looly avatar looly commented on May 23, 2024

单元测试比较简单,HttpConnection只是一个内部使用类,因此没有做测试。后续欢迎提供更多issue~

from hutool.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.