的pom.xml
<!-- Spring -->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-context</artifactId>
<version>${org.springframework-version}</version>
<exclusions>
<!-- Exclude Commons Logging in favor of SLF4j -->
<exclusion>
<groupId>commons-logging</groupId>
<artifactId>commons-logging</artifactId>
</exclusion>
</exclusions>
</dependency>
我在eclipse中用spring,jsp,sevlet制作web项目。 但是春天的核心依赖会带来麻烦。
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
显示错误
错误信息很长......我不知道..
无法转移commons-logging:commons-logging:jar:1.1.1 from https://repo.maven.apache.org/maven2被缓存在当地 库, 在中心的更新间隔过去或强制更新之前,不会重新尝试解析。原始错误:不能 转移神器 commons-logging:commons-logging:jar:1.1.1 from / to central(https://repo.maven.apache.org/maven2):操作被取消。 org.eclipse.aether.transfer.ArtifactTransferException:无法从https://传输commons-logging:commons-logging:jar:1.1.1 repo.maven.apache.org/maven2缓存在本地存储库中,在更新之前不会重新尝试解析 间隔 中央有 已过去或更新被强制。原始错误:无法传输工件commons-logging:commons-logging:jar:1.1.1 from / to 中央 (https://开头 repo.maven.apache.org/maven2):操作被取消了。在
org.eclipse.aether.internal.impl.DefaultUpdateCheckManager.newException(DefaultUpdateCheckManager.java:238)
在 org.eclipse.aether.internal.impl.DefaultUpdateCheckManager.checkArtifact(DefaultUpdateCheckManager.java:206) 在 org.eclipse.aether.internal.impl.DefaultArtifactResolver.gatherDownloads(DefaultArtifactResolver.java:585) 在 org.eclipse.aether.internal.impl.DefaultArtifactResolver.performDownloads(DefaultArtifactResolver.java:503) 在 org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:421) 在 org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolveArtifacts(DefaultArtifactResolver.java:246) 在 org.eclipse.aether.internal.impl.DefaultRepositorySystem.resolveDependencies(DefaultRepositorySystem.java:367) 在 org.apache.maven.project.DefaultProjectDependenciesResolver.resolve(DefaultProjectDependenciesResolver.java:205) 在 org.apache.maven.project.DefaultProjectBuilder.resolveDependencies(DefaultProjectBuilder.java:215) 在 org.apache.maven.project.DefaultProjectBuilder.build(DefaultProjectBuilder.java:188) 在 org.apache.maven.project.DefaultProjectBuilder.build(DefaultProjectBuilder.java:119) 在 org.eclipse.m2e.core.internal.embedder.MavenImpl.readMavenProject(MavenImpl.java:636) 在 org.eclipse.m2e.core.internal.project.registry.DefaultMavenDependencyResolver.resolveProjectDependencies(DefaultMavenDependencyResolver.java: 63)at or.e.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refreshPhase2(ProjectRegistryManager.java:530) 在 org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager $ 3.call(ProjectRegistryManager.java:492) 在 org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager $ 3.call(ProjectRegistryManager.java:1) 在 org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:176) 在 org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:151) 在 org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:496) 在 org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:351) 在 org.eclipse.m2e.core.internal.project.registry.ProjectRegistryManager.refresh(ProjectRegistryManager.java:298) 在 org.eclipse.m2e.core.internal.builder.MavenBuilder $ BuildMethod.getProjectFacade(MavenBuilder.java:154) 在 org.eclipse.m2e.core.internal.builder.MavenBuilder $ BuildMethod $ 1.call(MavenBuilder.java:89) 在 org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:176) 在 org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:151) 在 org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:99) 在 org.eclipse.m2e.core.internal.builder.MavenBuilder $ BuildMethod.execute(MavenBuilder.java:86) 在 org.eclipse.m2e.core.internal.builder.MavenBuilder.build(MavenBuilder.java:200) 在org.eclipse.core.internal.events.BuildManager $ 2.run(BuildManager.java:735)在org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)at at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:206) 在 org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:246) 在org.eclipse.core.internal.events.BuildManager $ 1.run(BuildManager.java:301)在org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:304) 在 org.eclipse.core.internal.events.BuildManager.basicBuildLoop(BuildManager.java:360) 在 org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:383) 在 org.eclipse.core.internal.events.AutoBuildJob.doBuild(AutoBuildJob.java:144) 在 org.eclipse.core.internal.events.AutoBuildJob.run(AutoBuildJob.java: 235)在org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
感谢您帮助我..我是初学者
答案 0 :(得分:-1)
请删除位于/Users//.m2的本地.m2文件夹并尝试重新构建。