Skip to content

pay模块使用jodd-http方式,已支持证书方式#189

Merged
binarywang merged 3 commits intobinarywang:developfrom
crskyp:develop
Apr 19, 2017
Merged

pay模块使用jodd-http方式,已支持证书方式#189
binarywang merged 3 commits intobinarywang:developfrom
crskyp:develop

Conversation

@crskyp
Copy link
Copy Markdown

@crskyp crskyp commented Apr 18, 2017

1、pay模块使用jodd-http方式,已支持证书方式
2、使用证书的方式和httpclient一样,都是通过java.net.ssl.SSLContext获取机器中的证书

@@ -1,5 +1,7 @@
package com.github.binarywang.wxpay.service.impl;
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个文件没有做实际改动吧?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

没有实际变动,手误提交了

@@ -384,6 +376,7 @@ private String post(String url, String xmlParam) {

/**
* 由于暂时未找到使用jodd-http实现证书配置的办法,故而暂时使用httpclient
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

注释能否修正一下?既然已经使用jodd-http实现了,上面的注释就显得无用了吧

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

收到

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

无用注释已去掉

}
HttpRequest request =HttpRequest.post(url).withConnectionProvider(new SSLSocketHttpConnectionProvider(sslContext));
request.bodyText(requestStr);
HttpResponse response =request.send();
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

此行代码貌似没有格式化

} finally {
httpPost.releaseConnection();
}
HttpRequest request =HttpRequest.post(url).withConnectionProvider(new SSLSocketHttpConnectionProvider(sslContext));
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

此行代码貌似没有格式化

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

收到

@crskyp
Copy link
Copy Markdown
Author

crskyp commented Apr 19, 2017

已格式化代码,再看下

@crskyp
Copy link
Copy Markdown
Author

crskyp commented Apr 19, 2017

无用的注释已去掉

@binarywang binarywang merged commit a8d443e into binarywang:develop Apr 19, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants