当筵意气临九霄,星离雨散不终朝。这篇文章主要讲述Jenkins 使用Tfs 插件出现 MappingConflictException 错误问题解决相关的知识,希望能为你提供帮助。
FATAL: com.microsoft.tfs.core.clients.versioncontrol.exceptions.MappingConflictException: The path C:\\JenkinsAgent\\workspace\\TestSystem is already mapped in workspace Hudson-TestSystem-XA-AT-SYSDEV; abcd. Also:hudson.remoting.Channel$CallSiteStackTrace: Remote call to JNLP4-connect connection from XA-AT-SYSDEV/10.32.2.184:2013 at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1741) at hudson.remoting.UserRequest$ExceptionResponse.retrieve(UserRequest.java:357) at hudson.remoting.Channel.call(Channel.java:955) at hudson.plugins.tfs.model.Server.execute(Server.java:233) at hudson.plugins.tfs.model.Workspaces.newWorkspace(Workspaces.java:109) at hudson.plugins.tfs.actions.CheckoutAction.getProject(CheckoutAction.java:144) at hudson.plugins.tfs.actions.CheckoutAction.checkout(CheckoutAction.java:59) at hudson.plugins.tfs.TeamFoundationServerScm.checkout(TeamFoundationServerScm.java:352) at hudson.scm.SCM.checkout(SCM.java:504) at hudson.model.AbstractProject.checkout(AbstractProject.java:1208) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:574) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:499) at hudson.model.Run.execute(Run.java:1810) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:97) at hudson.model.Executor.run(Executor.java:429) com.microsoft.tfs.core.clients.versioncontrol.exceptions.MappingConflictException: The path C:\\JenkinsAgent\\workspace\\TestSystem is already mapped in workspace Hudson-TestSystem-XA-AT-SYSDEV; GRAPECITY\\Component Test. at com.microsoft.tfs.core.clients.versioncontrol.workspacecache.internal.InternalCache.checkForMappingConflicts(InternalCache.java:212) at com.microsoft.tfs.core.clients.versioncontrol.workspacecache.internal.InternalCache.checkForMappingConflicts(InternalCache.java:176) at com.microsoft.tfs.core.clients.versioncontrol.VersionControlClient.createWorkspace(VersionControlClient.java:1014) at com.microsoft.tfs.core.clients.versioncontrol.VersionControlClient.createWorkspace(VersionControlClient.java:950) at hudson.plugins.tfs.model.MockableVersionControlClient.createWorkspace(MockableVersionControlClient.java:114) at hudson.plugins.tfs.commands.NewWorkspaceCommand.call(NewWorkspaceCommand.java:81) at hudson.plugins.tfs.commands.NewWorkspaceCommand.call(NewWorkspaceCommand.java:24) at hudson.remoting.UserRequest.perform(UserRequest.java:212) at hudson.remoting.UserRequest.perform(UserRequest.java:54) at hudson.remoting.Request$2.run(Request.java:369) at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at hudson.remoting.Engine$1.lambda$newThread$0(Engine.java:93) at java.lang.Thread.run(Unknown Source) Caused: java.lang.RuntimeException at hudson.plugins.tfs.model.Server.execute(Server.java:237) at hudson.plugins.tfs.model.Workspaces.newWorkspace(Workspaces.java:109) at hudson.plugins.tfs.actions.CheckoutAction.getProject(CheckoutAction.java:144) at hudson.plugins.tfs.actions.CheckoutAction.checkout(CheckoutAction.java:59) at hudson.plugins.tfs.TeamFoundationServerScm.checkout(TeamFoundationServerScm.java:352) at hudson.scm.SCM.checkout(SCM.java:504) at hudson.model.AbstractProject.checkout(AbstractProject.java:1208) at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:574) at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:499) at hudson.model.Run.execute(Run.java:1810) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43) at hudson.model.ResourceController.execute(ResourceController.java:97) at hudson.model.Executor.run(Executor.java:429)
出现这个问题的原因是 TFS 的配置文件中保存的信息和现在Jenkins 服务器上配置的信息不匹配导致的。
方案1: 修改Agent 中 Remote root directory 目录位置,修改后就可以回避错误了。
文章图片
方案2:使用 vs--> Source Control Explorer--> Workspace 的下拉框中选择 Workspace 打开 Manager Workspaces.
将有问题的workspace 删除就可以了。
文章图片
【Jenkins 使用Tfs 插件出现 MappingConflictException 错误问题解决】
推荐阅读
- Android File文件存储功能
- elestaticsearch原生写法创建mapping
- 安卓移动端line-height垂直居中出现偏移的解决方法
- 按键精灵对APP自动化测试(上)
- Appium 基础API
- Appium定位
- Android ADB 5037端口被占用问题解决办法(改端口号)
- mui app组件化选择器选择多种语言
- WinXP升级到SP2后网卡取得不到IP怎样办?