Comments (10)
@getActivity 轮子哥,这应该不算是bug,不过还是感觉首次是初始化了什么东西? 有时候甚至是达到700毫秒
from easyhttp.
from easyhttp.
小伙子,我测试了,确实存在这个问题,但是需要一些时间排查,目前我手头工作比较繁忙,我会尽量在这两天去处理这个问题。
from easyhttp.
好的,轮子哥修复后,艾特一下。我来替换新版本
from easyhttp.
recordTime = SystemClock.uptimeMillis();
OkHttpClient client = new OkHttpClient();
//创建表单请求参数
FormBody.Builder builder = new FormBody.Builder();
builder.add("name", "zhangsan");
builder.add("age", "18");
FormBody formBody = builder.build();
Request request = new Request.Builder()
.url("https://www.wanandroid.com/article/query/0/json")
.post(formBody)
.build();
client.newCall(request).enqueue(new Callback() {
@Override
public void onFailure(Call call, IOException e) {
}
@Override
public void onResponse(Call call, Response response) throws IOException {
System.out.println("EasyHttp Response 本次请求耗时:" + (response.receivedResponseAtMillis() - response.sentRequestAtMillis()));
System.out.println("EasyHttp Start RequestConsuming 本次请求耗时:" + (SystemClock.uptimeMillis() - recordTime));
}
});
from easyhttp.
from easyhttp.
小伙子,我用原生的 OkHttp 测试也有这个问题,那这个不是框架的问题了,你可能就要反馈给 OkHttp 官方了
from easyhttp.
那我借用轮子哥的截图,去okhttp那里贴一个issues
from easyhttp.
from easyhttp.
小伙子,我看到你在 OkHttp Github 上面提的 issue,建议小伙子你可以做进一步的排查,看看 OkHttp 是在哪些方法耗时比较长的,有详细的结果了再提交给 OkHttp 官方人员,还有要注意使用英文提问。
from easyhttp.
Related Issues (20)
- Android9和Android10 使用app专有目录下载文件,下载方法没有任何反应 HOT 3
- 返回错误返回了ok HOT 1
- 框架返回内容不对 返回ok HOT 1
- 请求结果返回ok HOT 4
- [疑惑]:轮子哥你好 在特定情况下 EasyConfig.getInstance().addParam 添加的全局参数会消失 HOT 1
- [Bug]:轮子哥你好 在特定情况下 EasyConfig.getInstance().addParam 添加的全局参数会消失 HOT 5
- [Bug]:java.lang.ClassCastException: java.lang.Class cannot be cast to java.lang.reflect.ParameterizedType HOT 1
- [疑惑]:如何post二进制的请求和处理返回的二进制数据 HOT 6
- [疑惑]:如何动态host,我需求的host主机地址会变动。 HOT 2
- [疑惑]: HOT 1
- [疑惑]:安全扫描提示HTTPS未校验服务器证书、主机名漏洞 HOT 4
- [Bug]:文件下载超时,文件大小7M,浏览器可以下载,但是使用 EasyHttp 下载超时 HOT 4
- [疑惑]:IRequestCache的缓存配置里getCacheTime是怎么用的 HOT 5
- [疑惑]:You haven't initialized the configuration yet HOT 1
- [建议]:建议可以每个请求单独设置header HOT 2
- [Bug]:USE_CACHE_FIRST模式下,无法更新缓存
- [疑惑]:如何获取当前请求的接口地址 HOT 6
- [建议]:框架可以支持到 protobuf 吗 HOT 3
- [疑惑]: HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from easyhttp.