dxa 1.4 java代码编译问题


1

我们试图通过maven编译DXA 1.4 java代码,但是在编译时遇到一些问题。

是否有可能在一个项目中获得所有必需的代码?

 

D:\SDL-DXA-java\sh_dxa_git_1_4\dxa-web-application-java\dxa-framework>mvn clean package 
[INFO] Scanning for projects... 
[ERROR] [ERROR] Some problems were encountered while processing the POMs: 
[ERROR] Non-resolvable import POM: Failure to find com.sdl.dxa:dxa-bom:pom:1.5.0-SNAPSHOT in file:///D:\SDL-DXA-java\sh_dxa_git_1_4\dxa-web-application-java\dxa-framework/../../local-project-repo was cached in the local repository, resolution will not be reattempted until the update interval of local-project-repo has elapsed or updates are forced @ line 71, column 25 
[ERROR] 'dependencies.dependency.version' for ch.qos.logback:logback-core:jar is missing. @ line 83, column 21[ERROR] 'dependencies.dependency.version' for org.slf4j:slf4j-api:jar is missing. @ line 87, column 21 
[ERROR] 'dependencies.dependency.version' for org.slf4j:jcl-over-slf4j:jar is missing. @ line 91, column 21 
[ERROR] 'dependencies.dependency.version' for ch.qos.logback:logback-classic:jar is missing. @ line 95, column 21 
[ERROR] 'dependencies.dependency.version' for cglib:cglib:jar is missing. @ line 116, column 21 
[ERROR] 'dependencies.dependency.version' for junit:junit:jar is missing. @ line 122, column 21 
[ERROR] 'dependencies.dependency.version' for org.hamcrest:hamcrest-core:jar is missing. @ line 126, column 21 
[ERROR] 'dependencies.dependency.version' for org.hamcrest:hamcrest-library:jar is missing. @ line 130, column 21 
[ERROR] 'dependencies.dependency.version' for org.mockito:mockito-all:jar is missing. @ line 134, column 21 
[ERROR] 'dependencies.dependency.version' for org.springframework:spring-test:jar is missing. @ line 138, column 21 
[ERROR] 'dependencies.dependency.version' for net.sf.ehcache:ehcache:jar is missing. @ line 143, column 21 
[ERROR] 'dependencies.dependency.version' for org.ehcache:jcache:jar is missing. @ line 147, column 21 
[ERROR] 'dependencies.dependency.version' for javax.cache:cache-api:jar is missing. @ line 151, column 21 
[ERROR] 'dependencies.dependency.version' for org.projectlombok:lombok:jar is missing. @ line 156, column 21 @ 
[ERROR] The build could not read 1 project -> [Help 1] 
[ERROR] 
[ERROR] The project com.sdl.dxa:dxa-framework:1.5.0-SNAPSHOT (D:\SDL-DXA-java\sh_dxa_git_1_4\dxa-web-application-java\dxa-framework\pom.xml) has 15 errors 
[ERROR]  Non-resolvable import POM: Failure to find com.sdl.dxa:dxa-bom:pom:1.5.0-SNAPSHOT in file:///D:\SDL-DXA-java\sh_dxa_git_1_4\dxa-web-application-java\dxa-framework/../../local-project-repo was cached in the local repository, resolution will not be reattempted until the update interval of local-project-repo has elapsed or updates are forced @ line 71, column 25 -> [Help 2] 
[ERROR]  'dependencies.dependency.version' for ch.qos.logback:logback-core:jar is missing. @ line 83, column 21 
[ERROR]  'dependencies.dependency.version' for org.slf4j:slf4j-api:jar is missing. @ line 87, column 21 
[ERROR]  'dependencies.dependency.version' for org.slf4j:jcl-over-slf4j:jar is missing. @ line 91, column 21 
[ERROR]  'dependencies.dependency.version' for ch.qos.logback:logback-classic:jar is missing. @ line 95, column 21 
[ERROR]  'dependencies.dependency.version' for cglib:cglib:jar is missing. @ line 116, column 21 
[ERROR]  'dependencies.dependency.version' for junit:junit:jar is missing. @ line 122, column 21 
[ERROR]  'dependencies.dependency.version' for org.hamcrest:hamcrest-core:jar is missing. @ line 126, column 21 
[ERROR]  'dependencies.dependency.version' for org.hamcrest:hamcrest-library:jar is missing. @ line 130, column 21 
[ERROR]  'dependencies.dependency.version' for org.mockito:mockito-all:jar is missing. @ line 134, column 21 
[ERROR]  'dependencies.dependency.version' for org.springframework:spring-test:jar is missing. @ line 138, column 21 
[ERROR]  'dependencies.dependency.version' for net.sf.ehcache:ehcache:jar is missing. @ line 143, column 21 
[ERROR]  'dependencies.dependency.version' for org.ehcache:jcache:jar is missing. @ line 147, column 21 
[ERROR]  'dependencies.dependency.version' for javax.cache:cache-api:jar is missing. @ line 151, column 21 
[ERROR]  'dependencies.dependency.version' for org.projectlombok:lombok:jar is missing. @ line 156, column 21 
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. 
[ERROR] Re-run Maven using the -X switch to enable full debug logging. 
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles: 
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/ProjectBuildingException 
[ERROR] [Help 2] http://cwiki.apache.org/confluence/display/MAVEN/UnresolvableModelException 

D:\SDL-DXA-java\sh_dxa_git_1_4\dxa-web-application-java\dxa-framework> 

3

在DXA全部依赖管理被转移到dxa-bomdxa-bom-2013sp1文物,现在的版本是在一个地方整个框架进行管理。这是在多个地方摆脱由DXA使用的相同工件的多个版本所需的。

您的情况com.sdl.dxa:dxa-bom:pom:1.5.0-SNAPSHOT无法解析,因此工件的版本不可用。有两个可能的解决方案:


2

您确定您正在编译DXA 1.4 Java源代码吗?对1.5.0-SNAPSHOT的引用意味着它是DXA 1.5预发布代码。

请注意,GitHub上的master分支目前确实代表DXA 1.5预发布(DXA 1.5 Sprint 2)。要获得DXA 1.4代码,您应该使用release/1.4分支。

  0

我已经下载了dxa修补程序1.4.1版本,但在编译某些自定义类时,出现此错误: http://tridion.stackexchange.com/questions/14726/dxa-1-4-1 -compilation和-CD-brokerjar8-1-1-1007-mising 26 5月. 162016-05-26 06:48:10