[英]Unable to add couchdb4j dependency in gwt maven project
I have followed the following link to create a maven project Create Project . 我已按照以下链接创建了一个maven项目Create Project 。 Like creating a simple gwt project and then configure for maven.
就像创建一个简单的gwt项目然后配置为maven。 Till here it goes simple without any problem.Like we are couchdb as our database, I have been trying to add couchdb dependency.
到这里它很简单没有任何问题。就像我们的数据库,我一直在尝试添加couchdb依赖。
Problem 1: Tried out many ways but unable to add couchdb 4j dependency. 问题1:尝试了很多方法,但无法添加couchdb 4j依赖项。
Error: Missing artifact com.google.code:couchdb4j:jar:0.1.2
错误:缺少工件
com.google.code:couchdb4j:jar:0.1.2
Now, want the solution for this. 现在,想要解决方案。
Query: Is there any other way to work with maven with GWT. 查询:有没有其他方法可以与maven一起使用GWT。
EDIT 1 I got a pom.xml from a link where they have couchdb4j in it, but still my basics function of create document(), getDocument() are not been received. 编辑1我从一个链接中获得了一个pom.xml,其中有couchdb4j,但仍然没有收到创建document(),getDocument()的基本功能。 The couchdb4j is not added to maven dependencies as seen in build path.
如在构建路径中看到的,couchdb4j未添加到maven依赖项。
Is there some difference with client and server side use of maven dependencies? 客户端和服务器端使用maven依赖项有什么不同吗?
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>couchdb4j</groupId>
<artifactId>couchdb4j</artifactId>
<name>CouchDB4J</name>
<version>0.3.0-i386-1</version>
<url>http://code.google.com/p/couchdb4j/</url>
<build>
<sourceDirectory>src/java</sourceDirectory>
<testSourceDirectory>src/test</testSourceDirectory>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.5</source>
<target>1.5</target>
</configuration>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.5</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>commons-logging</groupId>
<artifactId>commons-logging</artifactId>
<version>1.1.1</version>
<scope>compile</scope>
<exclusions>
<exclusion>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
</exclusion>
<exclusion>
<groupId>logkit</groupId>
<artifactId>logkit</artifactId>
</exclusion>
<exclusion>
<groupId>avalon-framework</groupId>
<artifactId>avalon-framework</artifactId>
</exclusion>
<exclusion>
<groupId>javax.servlet</groupId>
<artifactId>servlet-api</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>net.sf.json-lib</groupId>
<artifactId>json-lib</artifactId>
<version>2.3</version>
<scope>compile</scope>
<classifier>jdk15</classifier>
<exclusions>
<exclusion>
<groupId>org.jruby</groupId>
<artifactId>jruby</artifactId>
</exclusion>
<exclusion>
<groupId>org.codehaus.groovy</groupId>
<artifactId>groovy-all</artifactId>
</exclusion>
<exclusion>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>net.sf.ezmorph</groupId>
<artifactId>ezmorph</artifactId>
<version>1.0.4</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
<version>4.0-beta2</version>
</dependency>
<dependency>
<groupId>com.google.gwt</groupId>
<artifactId>gwt-user</artifactId>
<version>2.7.0</version>
</dependency>
<dependency>
<groupId>com.google.gwt</groupId>
<artifactId>gwt-dev</artifactId>
<version>2.7.0</version>
</dependency>
<dependency>
<groupId>javax.validation</groupId>
<artifactId>validation-api</artifactId>
<version>1.0.0.GA</version>
</dependency>
</dependencies>
<pluginRepositories>
<pluginRepository>
<id>codehaus.snapshots</id>
<name>Codehaus Maven Snapshot Repository</name>
<url>http://snapshots.repository.codehaus.org</url>
<snapshots>
</snapshots>
</pluginRepository>
</pluginRepositories>
<distributionManagement>
<repository>
<id>nexus</id>
<name>My Nexus</name>
<url>http://localhost:8081/nexus/content/repositories/thirdparty/</url>
</repository>
</distributionManagement>
</project>
For the time being i added it as it is. 目前我按原样添加了它。
Still unaware with the problem that why its not adding the dependencies? 仍然没有意识到为什么它不添加依赖项的问题?
What exactly I have to do for adding couchdb4j jar from dependencies? 从依赖项添加couchdb4j jar到底我需要做什么?
<repositories> <repository> <id>repo-wso2</id> <url>http://maven.wso2.org/nexus/content/repositories/abdera.couchdb.temporary</url> </repository> </repositories>
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.