dxa 1.4 java code компиляция вопрос


1

Мы пытаемся скомпилировать java-код DXA 1.4 через maven, но сталкиваемся с некоторыми проблемами в компиляции.

Возможно ли получить весь требуемый код в одном проекте?

 

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-bom и dxa-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.

Обратите внимание, что ветвь master на GitHub в настоящее время действительно представляет предварительный выпуск DXA 1.5 (DXA 1.5 Sprint 2). Чтобы получить код DXA 1.4, вы должны использовать ветвь release/1.4.

  0

Я загрузил версию 1.4x для исправления dxa, но во время компиляции некоторых пользовательских классов я получаю эту ошибку: http://tridion.stackexchange.com/questions/14726/dxa-1-4-1 -compilation-и-CD-brokerjar8-1-1-1007-mising 26 май. 162016-05-26 06:48:10