Uploaded image for project: 'CDAP'
  1. CDAP
  2. CDAP-2530

Custom RecordScannable<StructuredRecord> datasets cannot be explored

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.1.0
    • Component/s: Datasets, Explore
    • Labels:
      None
    • Rank:
      1|hzytjr:

      Description

      The error message in the logs is:

      co.cask.cdap.explore.service.ExploreException: Cannot enable explore on dataset contacts. Reason: Response code: 400, message:'Bad Request', body: 'No record field provided for java.lang.Object'
      

      This error message is cryptic and does not tell us anything about the true reason. Which is that for StructuredRecord, the schema must be read from one of the dataset properties, and the Explore service has logic to do that. But it only calls that logic for ObjectMappedTable. (ExploreTableManager.java:160):

          if (ObjectMappedTableModule.FULL_NAME.equals(datasetType) ||
            ObjectMappedTableModule.SHORT_NAME.equals(datasetType)) {
            return createFromSchemaProperty(spec, datasetID, serdeProperties);
          }
      

      This is not sufficient. Perhaps we can say, anytime that the type is StructuredRecord, it must call this method. Not sure what is right.

        Attachments

          Activity

            People

            • Assignee:
              ashau Albert Shau
              Reporter:
              andreas Andreas Neumann
            • Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: