小编Alt*_*tug的帖子

没有互联网连接时,Spring schemaLocation失败

我使用的是Spring,application-context.xml我有以下定义:

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
   xmlns:util="http://www.springframework.org/schema/util"
   xmlns:context="http://www.springframework.org/schema/context"
   xmlns:aop="http://www.springframework.org/schema/aop"
   xmlns:tx="http://www.springframework.org/schema/tx"
   xmlns:p="http://www.springframework.org/schema/p"
   xmlns:security="http://www.springframework.org/schema/security"
   xsi:schemaLocation="
   http://www.springframework.org/schema/beans 
   http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
   http://www.springframework.org/schema/util 
   http://www.springframework.org/schema/util/spring-util-2.0.xsd
   http://www.springframework.org/schema/context
   http://www.springframework.org/schema/context/spring-context-2.1.xsd
   http://www.springframework.org/schema/tx
   http://www.springframework.org/schema/tx/spring-tx.xsd
   http://www.springframework.org/schema/aop
   http://www.springframework.org/schema/aop/spring-aop-2.0.xsd
   http://www.springframework.org/schema/security
   http://www.springframework.org/schema/security/spring-security-2.0.xsd"
   >
Run Code Online (Sandbox Code Playgroud)

.....

当我的互联网连接丢失时,我无法通过tomcat或jetty运行我的应用程序.

它给:

[main] WARN  org.springframework.beans.factory.xml.XmlBeanDefinitionReader - Ignored XML validation warning
org.xml.sax.SAXParseException: schema_reference.4: Failed to read schema document '/spring-beans-2.0.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.
    at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:195)
    at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.warning(ErrorHandlerWrapper.java:96)
    at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:380)
    at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:318) …
Run Code Online (Sandbox Code Playgroud)

java xml spring xsd

101
推荐指数
5
解决办法
16万
查看次数

“无法从 scm 存储库获取修订信息”

我收到 Maven 错误:

Cannot get the revision information from the scm repository
Run Code Online (Sandbox Code Playgroud)

知道如何解决这个问题吗?

java maven-2 pom.xml

5
推荐指数
2
解决办法
3万
查看次数

同时在Selenium中运行多个测试用例

我用Selenium IDE创建了2个测试套件,我想同时运行这些测试套件.就像同时触发线程一样.没有进入编程就可以吗?

PS:我无法在Firefox中打开2个selenium IDE.

谢谢.

Altug.

java testing selenium

4
推荐指数
1
解决办法
4532
查看次数

Spring @Transactional 并发


class MyService {

public void a() { synchronized(somekey) { b(); } }

@Transactional(propagation = Propagation.REQUIRES_NEW) public void b() { ...do DB works... } }

Run Code Online (Sandbox Code Playgroud)

我的目标是

    1 - 拿到钥匙
    2 - 开始交易
    3 - 提交事务
    4 - 松开钥匙

当我从外部调用 a() 方法时,事务不起作用。

有什么建议 ?

谢谢。

java concurrency spring synchronization transactions

2
推荐指数
1
解决办法
2728
查看次数