tableau / TabMigrate

A lightweight tool for moving Tableau content between multiple Tableau Server environments
MIT License
119 stars 59 forks source link

Tableau 10.1.3 - (400) Bad Request - There was a problem publishing the file - Error code 400011 #11

Open mcleane opened 7 years ago

mcleane commented 7 years ago

Trying to Upload a workbook from file system to site using TabMigrate 1.08, but get a 400 bad request with error code 400011. And tableau server vizportal log reports an Invalid Username & Password.

It's unclear what the Invalid Username & Password is referring to. The workbook being uploaded contains 4 embedded extracts. Publishing of workbooks via Tableau Desktop works as expected. Any assistance would be much appreciated.

TabMigrate displays the following error:

000,  2/1/2017 1:56:55 PM, finalize workbook publish (http://tableau/api/2.0/sites/XXX/workbooks?uploadSessionId=XXXX:XXXX-2:1&workbookType=twbx&overwrite=true) : The remote server returned an error: (400) Bad Request.
<?xml version='1.0' encoding='UTF-8'?><tsResponse xmlns="http://tableausoftware.com/api" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://tableausoftware.com/api http://tableausoftware.com/api/ts-api-2.0.3.xsd"><error code="400011"><summary>Bad Request</summary><detail>There was a problem publishing the file 'XXXX:XXXX-2:1'.</detail></error></tsResponse>

001,  2/1/2017 1:56:55 PM, Unexpected error finalizing publish of file C:\Users\Administrator\AppData\Roaming\TabMigrate\tableau\siteExport2017-02-01-1111-23\_remapTempspace\unzipped\output\test.twbx, The remote server returned an error: (400) Bad Request.
002,  2/1/2017 1:56:55 PM, Error uploading workbook C:\Users\Administrator\AppData\Roaming\TabMigrate\tableau\siteExport2017-02-01-1111-23\workbooks\Default\test.twbx. The remote server returned an error: (400) Bad Request.

On the tableau server the vizportal log shows an Invalid Username or password error:

2017-02-01 13:56:20.144 +1100 (-,-,-,XXX) catalina-exec-1 : ERROR com.tableausoftware.api.rest.util.RestApiControllerAdvice - com.tableausoftware.api.rest.exceptions.UnauthorizedRestException: com.tableausoftware.domain.exceptions.LoginFailedException: Invalid username or password. (errorCode=16)
com.tableausoftware.api.rest.exceptions.UnauthorizedRestException: com.tableausoftware.domain.exceptions.LoginFailedException: Invalid username or password. (errorCode=16)
    at com.tableausoftware.api.rest.impl.RestApiAuthenticationAppService.signIn(RestApiAuthenticationAppService.java:114)
    at com.tableausoftware.api.rest.RestApiController.signIn_aroundBody154(RestApiController.java:1543)
    at com.tableausoftware.api.rest.RestApiController$AjcClosure155.run(RestApiController.java:1)
    at org.aspectj.runtime.reflect.JoinPointImpl.proceed(JoinPointImpl.java:149)
    at com.tableausoftware.instrumentation.InstrumentedMethod.instrumentInvocation(InstrumentedMethod.java:67)
    at com.tableausoftware.instrumentation.InstrumentationAspect.aroundAnnotatedMethod(InstrumentationAspect.java:57)
    at com.tableausoftware.api.rest.RestApiController.signIn(RestApiController.java:1534)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:222)
    at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:137)
    at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:110)
    at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:814)
    at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:737)
    at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:85)
    at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:959)
    at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:893)
    at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:970)
    at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:872)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:650)
    at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:846)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:731)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at com.tableausoftware.core.controller.RelativeRedirectFilter.doFilter(RelativeRedirectFilter.java:60)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:121)
    at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:220)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:122)
    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:505)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:169)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:436)
    at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1078)
    at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:625)
    at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.doRun(AprEndpoint.java:2517)
    at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.run(AprEndpoint.java:2506)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
    at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
    at java.lang.Thread.run(Thread.java:745)
Caused by: com.tableausoftware.domain.exceptions.LoginFailedException: Invalid username or password. (errorCode=16)
    at com.tableausoftware.domain.user.LocalIdentityProvider.getIdentity(LocalIdentityProvider.java:88)
    at com.tableausoftware.domain.user.SecurityManager.getIdentity(SecurityManager.java:92)
    at com.tableausoftware.domain.user.service.AuthenticationService.getSystemUserOrFail(AuthenticationService.java:389)
    at com.tableausoftware.domain.user.service.AuthenticationService.loginWithImpersonation(AuthenticationService.java:338)
    at com.tableausoftware.domain.user.service.AuthenticationService.loginWithImpersonation_aroundBody12(AuthenticationService.java:326)
    at com.tableausoftware.domain.user.service.AuthenticationService$AjcClosure13.run(AuthenticationService.java:1)
    at org.aspectj.runtime.reflect.JoinPointImpl.proceed(JoinPointImpl.java:221)
    at com.tableausoftware.aspects.search.RequiresIndexUpdateAspect.setupTransactionTracking(RequiresIndexUpdateAspect.java:84)
    at com.tableausoftware.domain.user.service.AuthenticationService.loginWithImpersonation_aroundBody14(AuthenticationService.java:319)
    at com.tableausoftware.domain.user.service.AuthenticationService$AjcClosure15.run(AuthenticationService.java:1)
    at org.springframework.transaction.aspectj.AbstractTransactionAspect.ajc$around$org_springframework_transaction_aspectj_AbstractTransactionAspect$1$2a73e96cproceed(AbstractTransactionAspect.aj:66)
    at org.springframework.transaction.aspectj.AbstractTransactionAspect$AbstractTransactionAspect$1.proceedWithInvocation(AbstractTransactionAspect.aj:72)
    at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:281)
    at org.springframework.transaction.aspectj.AbstractTransactionAspect.ajc$around$org_springframework_transaction_aspectj_AbstractTransactionAspect$1$2a73e96c(AbstractTransactionAspect.aj:70)
    at com.tableausoftware.domain.user.service.AuthenticationService.loginWithImpersonation(AuthenticationService.java:319)
    at com.tableausoftware.api.rest.impl.RestApiAuthenticationAppService.signIn(RestApiAuthenticationAppService.java:102)
    ... 50 more
ghost commented 7 years ago

Hi Evan, I'd like to help figure out what is going on here. A few questions:

  1. Are you able to successfully upload other workbooks?
  2. Can you send me the detailed logs from TabMigrage (and or the workbook). -- Please feel free to contact me at isalmre@tableau.com. Happy to look at the details and work through this with you.
watsacha commented 7 years ago

Hi, I am getting this error when trying to append the data to an existing data source on the server. Please advise if there is any resolution. Thank you very much.

rferraton commented 7 years ago

Hello First thanks a lot fo your effort to build a migration tools.

I have the same error on some workbooks (not all). we can found theses lines into the vizportal log file :

2017-06-27 15:48:36.980 +0000 (dev,tadmin,-yA8DyHCRU-FcxLhTjoXFw,WVJ@VAoHTAEAAA4wzwEAAABh) catalina-exec-131 : DEBUG com.tableausoftware.domain.content.publishing.WorkbookPublishingService - Adding global credential to support kerberos for workbook BMX_CSTAT_T1 2017-06-27 15:48:37.236 +0000 (dev,tadmin,-yA8DyHCRU-FcxLhTjoXFw,WVJ@VAoHTAEAAA4wzwEAAABh) catalina-exec-131 : DEBUG com.tableausoftware.domain.content.publishing.WorkbookPublishingService - No transaction for upload extract. 2017-06-27 15:48:37.237 +0000 (dev,tadmin,-yA8DyHCRU-FcxLhTjoXFw,WVJ@VAoHTAEAAA4wzwEAAABh) catalina-exec-131 : INFO com.tableausoftware.domain.content.publishing.WorkbookPublishingService - Retrieving project: siteId=3, id=null, name=CSTAT 2017-06-27 15:48:37.503 +0000 (dev,tadmin,-yA8DyHCRU-FcxLhTjoXFw,WVJ@VAoHTAEAAA4wzwEAAABh) catalina-exec-131 : DEBUG com.tableausoftware.domain.content.publishing.PublishingHelperService - wgserver.publish.check_connections is disabled, skipping connection checks. 2017-06-27 15:48:37.505 +0000 (dev,tadmin,-yA8DyHCRU-FcxLhTjoXFw,WVJ@VAoHTAEAAA4wzwEAAABh) catalina-exec-131 : INFO com.tableausoftware.domain.content.publishing.WorkbookPublishingService - No workbook entity exists, creating a new one. ... 2017-06-27 15:48:38.206 +0000 (dev,tadmin,-yA8DyHCRU-FcxLhTjoXFw,WVJ@VAoHTAEAAA4wzwEAAABh) catalina-exec-131 : ERROR com.tableausoftware.api.rest.util.RestApiControllerAdvice - com.tableausoftware.api.rest.exceptions.BadRequestRestException: com.tableausoftware.domain.exception.NativeException: [SAP AG][LIBODBCHDB DLL][HDBODBC] Communication link failure;-10709 Connection failed (RTE:[-1] Kerberos error. Major: "Miscellaneous failure [851968]", minor: " []" (frox4122.mycompany.net:30215)) Unable to connect to the server "frox4122.mycompany.net". Check that the server is running and that you have access privileges to the requested database.

com.tableausoftware.api.rest.exceptions.BadRequestRestException: com.tableausoftware.domain.exception.NativeException: [SAP AG][LIBODBCHDB DLL][HDBODBC] Communication link failure;-10709 Connection failed (RTE:[-1] Kerberos error. Major: "Miscellaneous failure [851968]", minor: " []" (frox4122.mycompany.net:30215)) Unable to connect to the server "frox4122.mycompany.net". Check that the server is running and that you have access privileges to the requested database. `

The "special" thing for this workbook is a SAP HANA connection and I have not provide database credentials mapping file during import.

I will try to see if it change something and come back.

rferraton commented 7 years ago

With a database mapping credentials file it works !

mli8888 commented 6 years ago

Hi IvoSalmreTableau and rferraton,

I am new for Tableau admin. I have got same issue with upload workbooks. So what is database mapping credential file? How do I created one or et one.

Thanks a lot. Mang

siripuramsneha commented 5 years ago

Hi,

I am getting the error below in my vizportal logs i need help with debugging this issue. I see InvalidPayloadException and BadRequestRestException exceptions in the logs below Tableau server -10.5

INFO com.tableausoftware.instrumentation.InstrumentationUtil - Instrumenting 'com.tableausoftware.api.rest.IRestApiResponse com.tableausoftware.api.rest.util.RestApiControllerAdvice.handleInvalidPayloadException(com.tableausoftware.api.rest.exceptions.BadRequestRestException, com.tableausoftware.core.localization.LanguageCode, com.tableausoftware.api.rest.util.RestApiVersion)' as 'com.tableausoftware.instrumentation:00=api,01=rest,02=exception,name=InvalidPayload,type=methods'. ERROR com.tableausoftware.api.rest.util.RestApiControllerAdvice - com.tableausoftware.api.rest.exceptions.BadRequestRestException: com.tableausoftware.domain.exception.NativeException: Version mismatch

com.tableausoftware.api.rest.exceptions.BadRequestRestException: com.tableausoftware.domain.exception.NativeException: Version mismatch

at com.tableausoftware.api.rest.impl.RestApiAppService.publishWorkbook(RestApiAppService.java:4084)
at com.tableausoftware.api.rest.RestApiController.publishWorkbook_aroundBody168(RestApiController.java:1684)
at com.tableausoftware.api.rest.RestApiController$AjcClosure169.run(RestApiController.java:1)
at org.aspectj.runtime.reflect.JoinPointImpl.proceed(JoinPointImpl.java:149)
at com.tableausoftware.instrumentation.InstrumentedMethod.instrumentInvocation(InstrumentedMethod.java:66)
at com.tableausoftware.instrumentation.InstrumentationAspect.aroundAnnotatedMethod(InstrumentationAspect.java:57)
at com.tableausoftware.api.rest.RestApiController.publishWorkbook(RestApiController.java:1675)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:221)
at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:136)
at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:114)
at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:827)
at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:738)
at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:85)
at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:963)
at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:897)
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:970)
at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:872)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:650)
at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:846)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:731)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
at com.tableausoftware.core.controller.RelativeRedirectFilter.doFilter(RelativeRedirectFilter.java:62)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:197)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:219)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:110)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:506)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:169)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:445)
at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1115)
at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:637)
at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.doRun(AprEndpoint.java:2555)
at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.run(AprEndpoint.java:2544)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
at java.lang.Thread.run(Thread.java:748)
rferraton commented 5 years ago

Hello @mli8888

What is your "action" to have this error ?

Did you switch to the 10.5-dev branch of my fork (because api url change for each version of Tableau Server, the file TabRESTMigrate/RESTHelpers/TableauServerUrls.cs need to be maintained to follow new urls) ?

The forked repo and 10.5 branch is here https://github.com/aetperf/TabMigrate/tree/10.5-dev The sources have been recompiled for the 10.5 version so you will find binaries in https://github.com/aetperf/TabMigrate/tree/10.5-dev/TabRESTMigrate/bin/Release Replace your binaries files (or compile sources your side) with files provide and try again.

Regards

siripuramsneha commented 5 years ago

I am trying to publish a workbook for .tde extracts

Tableau version :10.5.6 I have updated the ts-api _2.0.1.xsd to ts_api_2.8.xsd

I know that for tableau 10.5 the .tde extracts have been removed and replaced with .hyper i have update the extension also but it still gives me the same error i am not sure how to proceed with this. Tableau support did not help with this

Regards