1 2 Previous Next 25 Replies Latest reply on Sep 30, 2016 9:12 AM by Matt Coles

    Error when refreshing a workbook with Tableau 10.0.1

    Damien Lesage

      Hello,

       

      I published a workbook to Tableau Server 10.0.1 and try to execute a refresh afterwards.

       

      I have the following errors:

       

      com.tableausoftware.nativeapi.dll.FederatedDataSourceException: No Tableau Server user found. class DataSourceException Unable to connect to the server "localhost". 
      Check that the server is running and that you have access privileges to the requested database.
      

       

      My workbook has 2 connections to a database with an extract and 1 connection to a Tableau Server data source.

       

      Is there anyone who knows what this error means?

       

      Damien.

       

      EDIT: root cause identified (see below) but issue is not solved.

        • 1. Re: Error when refreshing a workbook with Tableau 10.0.1
          Matt Coles

          Hi Damien. Tableau Server, when it tries to refresh your extract, will be looking for the data on the server "localhost"--which at that point, is itself, rather than the host you were creating your content on with Tableau Desktop. You'll want to use the actual hostname or IP address for the server your data lives on. Note also that if you're using a laptop or another machine that frequently powers down, your extract refreshes will fail if the Tableau Server schedule runs when it is not available. Generally speaking, you'll want your data living on an always-on machine somewhere, to do scheduled extract refreshes on Server.

          • 2. Re: Error when refreshing a workbook with Tableau 10.0.1
            Damien Lesage

            I'm not sure I understand. I have configured my data connections for using the hostname for the server where my data is (and I can't actually find any reference to 'localhost' in the workbook).

             

            Actually, a workbook with no Tableau Server data source can refresh normally. So I assume this happen when trying to refresh a workbook having also a Tableau Server data source.

             

            I have to say that I published this workbook that is in Desktop version 8.1 using the REST API. That might explain why I have an unexpected behavior too.

            • 3. Re: Error when refreshing a workbook with Tableau 10.0.1
              Matt Coles

              Ah, thanks--should have read that more closely. Yes, the old Desktop version is undoubtedly the main issue. You'll want to use a newer version of Desktop to connect to your 10.0 datasource.

              • 4. Re: Error when refreshing a workbook with Tableau 10.0.1
                Damien Lesage

                Well, I have a thousand of such workbooks to publish to a new server so if I can find a solution, that would be nice.

                • 5. Re: Error when refreshing a workbook with Tableau 10.0.1
                  Toby Erkson

                  Upgrade the workbook to the same version as Server if you can or at least to a more recent version if at all possible.

                   

                  Exactly how are you executing the refresh?

                  • 6. Re: Error when refreshing a workbook with Tableau 10.0.1
                    Damien Lesage

                    I am running the schedule on the UI.

                     

                    I will try to update the workbook manually with Tableau 10 and see if the error still occurs. If it does, i'll open a case since that means it's not linked to my exceptional context.

                    • 7. Re: Error when refreshing a workbook with Tableau 10.0.1
                      Matt Coles

                      So first, with respect to published datasource compatibility, there's this helpful snippet from Desktop and Server Compatibility:

                       

                      Workbooks that are saved in an earlier version of Desktop can connect to Server data sources published to later versions of Server.

                      ...

                      However, if you connect to a data source that uses features not available in earlier versions of Tableau Desktop, then those fields might become invalid. For example, suppose you have an 8.2 workbook that connects to a 9.0 Tableau Server data source that contains LOD calculations. Because LOD calculations are available in 9.0 and later, the LOD calculated fields are invalid in an 8.2 workbook.

                       

                      So hopefully that clarifies that. Note that basing the published datasource on an extract seemed to make my 8.2 workbook like the 10.0 federated published datasource again, so that's a possible workaround if it seems worth it to you to pursue.

                       

                       

                      The bigger issue is that I don't think we understand your use case very well. So you have 1,000 v8.1 workbooks that you need to automate publishing to a 10.0.1 Server for, which happens to be the same Server that they are already connected to for their published data source? Are you doing a test of 10.0.1 to prepare for a big upgrade? What's the deal?

                      • 8. Re: Error when refreshing a workbook with Tableau 10.0.1
                        Toby Erkson

                        Matt Coles wrote:

                         

                        ...

                        The bigger issue is that I don't think we understand your use case very well. So you have 1,000 v8.1 workbooks that you need to automate publishing to a 10.0.1 Server for, which happens to be the same Server that they are already connected to for their published data source? Are you doing a test of 10.0.1 to prepare for a big upgrade? What's the deal?

                        Agreed, it's confusing.  Please take your time to explain it.

                        • 9. Re: Error when refreshing a workbook with Tableau 10.0.1
                          Damien Lesage

                          Hello,

                           

                          As Matt guessed, I am testing an upgrade to Tableau Server 10.0.1 from a Tableau Server 8.1 (ouch!).

                           

                          We are going to upgrade our Tableau Server 8.1 to 10.0.1 the normal way, but we also want to put all our workbooks in source control (Git). For that, we need to be able to download all data sources and workbooks, then publish then again from Git to make sure we are actually capable of publishing them from our source control if a big issue arise.

                           

                          Note that I am well aware of the version control in Tableau 10.0 but it does not address our use case.

                           

                          That being said:

                          • The published data source is a Tableau Desktop 8.1 data source and has been successful published with this process
                          • It has been refreshed successfully (it runs on an extract too).
                          • The server is actually different (it has a different hostname). When I restore the backup, all the workbooks seems to work though they should target the previous hostname. I am trying to update this hostname in the workbook before publishing again and that might be one of the things that can break something.

                           

                          I'll work on that issue gain today and will update. First things being:

                          • Open the transform 8.1 workbook with Tableau Desktop 10 to see if it can linked to the server data source [EDIT: Tableau Desktop has no trouble to detect which server to connect to and can show data of the published data source 8.1]
                          • Save the workbook as a Tableau 10 workbook and try the process again to see whether the issue is still there [EDIT: Publishing the workbook version 10 connecting to this data source 8.1 leads to the same refresh error despite it works on Tableau Desktop. Moreover, in the UI, the workbook shows that it targets the right published data source.]

                           

                          Thanks for your help.

                          • 10. Re: Error when refreshing a workbook with Tableau 10.0.1
                            Toby Erkson

                            I would be guessing if I said it was the host name change that is contributing to the issue.  I don't know, I would contact Tableau Support.

                            • 11. Re: Error when refreshing a workbook with Tableau 10.0.1
                              Damien Lesage

                              Actually, I found out what is the cause and that's unfortunately bad news for us.

                               

                              I have reproduced the issue using only data sources and workbooks produced with Tableau 10. It has nothing to do with having Tableau 8.1 workbooks and data sources.

                               

                              The issue is in our publishing workflow with the REST API, which is basically the following:

                              1. Publish the workbook (with embedded credentials)
                              2. Change the owner (we don't want to keep the technical account as the owner... but the analyst who published the workbooks)
                                • At this stage, Tableau considers that it should get rid of the embedded credentials for ALL data connections
                              3. Update all connections in the workbook (yeah... we have to get them back...)
                                1. For a database, it's an easy update.
                                2. For a published data source, it just cannot be done (see error below)
                              com.tableausoftware.api.rest.exceptions.BadRequestRestException: com.tableausoftware.domain.exceptions.InvalidParameterException: dbclass: sqlproxy is not editable (errorCode=60004)
                                at com.tableausoftware.api.rest.impl.RestApiAppService.updateWorkbookConnection(RestApiAppService.java:2346)
                                at com.tableausoftware.api.rest.RestApiController.updateWorkbookConnection_aroundBody122(RestApiController.java:1183)
                                at com.tableausoftware.api.rest.RestApiController$AjcClosure123.run(RestApiController.java:1)
                                at org.aspectj.runtime.reflect.JoinPointImpl.proceed(JoinPointImpl.java:149)
                              ....
                              Caused by: com.tableausoftware.domain.exceptions.InvalidParameterException: dbclass: sqlproxy is not editable (errorCode=60004)
                                at com.tableausoftware.domain.content.DataConnectionService$UpdateConnectionsExternal.updateKeychainAndDataConnection(DataConnectionService.java:568)
                                at com.tableausoftware.domain.content.DataConnectionService.updateConnectionsImpl_aroundBody8(DataConnectionService.java:785)
                                at com.tableausoftware.domain.content.DataConnectionService$AjcClosure9.run(DataConnectionService.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.content.DataConnectionService.updateConnectionsImpl_aroundBody10(DataConnectionService.java:753)
                                at com.tableausoftware.domain.content.DataConnectionService$AjcClosure11.run(DataConnectionService.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.content.DataConnectionService.updateConnectionsImpl(DataConnectionService.java:753)
                                at com.tableausoftware.domain.content.DataConnectionService.updateConnections(DataConnectionService.java:723)
                                at com.tableausoftware.api.rest.impl.RestApiAppService.updateWorkbookConnection(RestApiAppService.java:2332)
                                ... 49 more
                              

                               

                              The error occurs because we get rid of the username to connect to the published data source when we update the owner. I have no solution. It seems to me this is a big limitation of the REST API (big as it doesn't allow us to implement our publishing process...).

                               

                              The funny things is that it's actually going to connect to the published data source when you visualize the workbook. It just doesn't when you try to refresh the embedded extracts.*

                               

                              EDIT: The possible solutions for Tableau (pick one or more):

                              • Stop deleting credentials when we update the owner of a workbook (or data source in that matter)
                              • Stop deleting credentials for a published data source when we update the owner of a workbook
                              • Stop trying to connect/refresh a published data source when we are trying to refresh only embedded extract
                              1 of 1 people found this helpful
                              • 12. Re: Error when refreshing a workbook with Tableau 10.0.1
                                Matt Coles

                                Okay, thanks for posting that info, it's good to know what the root cause was! I still don't think I understand why a big emergency would require re-publishing all content from Git rather than simply doing a restore operation from your backup.

                                 

                                Follow up question--rather than publishing under the administrator account, then changing workbook ownership, could you instead sign in and impersonate the user who owns the workbook, then publish as them? The REST API docs seem to support the idea that you could do that, though I haven't tried it myself... If you could do that, you could avoid the ownership change altogether, I'd think.

                                1 of 1 people found this helpful
                                • 13. Re: Error when refreshing a workbook with Tableau 10.0.1
                                  Toby Erkson

                                  Ah, you didn't tell us earlier that you were changing the ownership!  Yes, that does break things!!! This is why we ask for details

                                   

                                  I agree, as administrators we need the ability to change ownership without breaking the credentialing process.

                                  • 14. Re: Error when refreshing a workbook with Tableau 10.0.1
                                    Damien Lesage

                                    The main reason we didn't do that is that we are going to remove the publishing rights to the users. We took the assumption that the impersonation will have the rights of the impersonated user but I might be wrong. This is actually worth a try and would indeed solve this issue.

                                    1 2 Previous Next