我正在尝试为安全的https连接实现webclient.我导入了服务器证书并将其添加到java密钥库.但是当我尝试运行客户端时,我得到以下例外: -
Oct 18, 2013 3:25:25 PM org.apache.cxf.phase.PhaseInterceptorChain doDefaultLogging WARNING: Interceptor for
{http://tempuri.org/}Service#{http://tempuri.org/}GetUserInformation has thrown exception,
unwinding now org.apache.cxf.interceptor.Fault: Could not send Message.
at
org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingInterceptor.handleMessage(MessageSenderInterceptor.java:64)
at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:272)
at org.apache.cxf.endpoint.ClientImpl.doInvoke(ClientImpl.java:565)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:474)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:377)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:330)
at org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:96)
at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:135)
at $Proxy29.getUserInformation(Unknown Source)
at
org.tempuri.ServiceSoap_ServiceSoap_Client.main(ServiceSoap_ServiceSoap_Client.java:78)
Caused by: java.io.IOException: IOException invoking
myurl/**/**/asmx: The https URL hostname does not
match the Common Name (CN) on the server certificate in the client's truststore. Make sure
server certificate is correct, or to disable this check …Run Code Online (Sandbox Code Playgroud) 我做的事情是:
Propertyfile:URL = SAMPLEURL
Spring.xml:
<bean
class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
<property name="locations" value="classpath*:data.properties*"/>
</bean>
<bean id="dataSource" class="org.tempuri.DataBeanClass">
<property name="url" value="${url}"></property>
</bean>
Run Code Online (Sandbox Code Playgroud)
beanclass
public class DataBeanClass extends PropertyPlaceholderConfigurer{
private String url;
public String getUrl() {
return url;
}
public void setUrl(String url) {
this.url = url;
}
}
Run Code Online (Sandbox Code Playgroud)
web.xml中的条目
<context-param>
<param-name>contextConfigLocation</param-name>
<param-value>classpath*:Spring*.xml</param-value>
</context-param>
<listener>
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
</listener>
Run Code Online (Sandbox Code Playgroud)
现在我的问题是我不知道我应该覆盖什么方法的PropertyPlaceholderConfigurer,我该怎么做才能设置变量url的值,以便我可以使用getproperty()方法从其他类中调用它.
我正在使用 tinymce 编辑器,我的要求是在粘贴时剥离内容上应用的所有样式,而不会丢失项目符号和表格。这可能吗?我尝试初始化我的 tinymce 编辑器如下:
tinymce.init({
plugins: "paste,textcolor",
paste_as_text: true,
encoding: "xml",
mode: "exact",
selector: "textarea.className",
menubar: false,
statusbar: false,
height: 257,
browser_spellcheck: true,
toolbar: "forecolor backcolor,bold,italic,underline,separator,strikethrough,justifyleft,justifycenter,justifyright, justifyfull,bullist,numlist,undo,redo,link,unlink"
});
Run Code Online (Sandbox Code Playgroud)
我正在使用粘贴插件并将 paste_as_text 设置为 true。这将去除所有样式,以便我可以自己应用所需的样式。然而,连子弹和桌子也被剥光了,这并不好。有什么想法吗?提前致谢!!
我知道这个问题听起来像是重复。然而,尽管我发现了类似的问题,但我没有得到任何确切的信息。我不想删除从查询返回的任何重复值。我想要的是获得一个唯一标识符,例如从 sp 返回的结果的序列号。我尝试使用 Row_Number()。但是,即使这样也不起作用,因为它应该基于非重复列进行分区。我的结果不需要有非重复的列。等级和密集等级也不在考虑之列。那么,我应该怎么做才能获得唯一标识每一行的序列号类型的列。这些行也应该是 int 的。这是一个例子:
empName empSalary
Peter 10000
Schott 20000
Schott 10000
Run Code Online (Sandbox Code Playgroud)
表应该还有一列,如下所示:
Slno empName empSalary
1 Peter 10000
2 Schott 20000
3 Schott 10000
Run Code Online (Sandbox Code Playgroud) cxf ×1
html ×1
java ×1
javascript ×1
properties ×1
spring ×1
sql-server ×1
ssl ×1
tinymce ×1
web-services ×1