Skip to content

Commit

Permalink
Web console: better schema discovery copy (#14601)
Browse files Browse the repository at this point in the history
* better-schema-discovery-copy

* Update web-console/src/views/load-data-view/load-data-view.tsx

Co-authored-by: Charles Smith <techdocsmith@gmail.com>

* Update web-console/src/views/load-data-view/load-data-view.tsx

Co-authored-by: Charles Smith <techdocsmith@gmail.com>

* auto-format

---------

Co-authored-by: Charles Smith <techdocsmith@gmail.com>
  • Loading branch information
vogievetsky and techdocsmith authored Jul 18, 2023
1 parent 6425ef4 commit 6becd81
Showing 1 changed file with 22 additions and 15 deletions.
37 changes: 22 additions & 15 deletions web-console/src/views/load-data-view/load-data-view.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2376,7 +2376,7 @@ export class LoadDataView extends React.PureComponent<LoadDataViewProps, LoadDat
checked={schemaMode === 'fixed'}
onChange={() =>
this.setState({
newSchemaMode: schemaMode === 'fixed' ? 'string-only-discovery' : 'fixed',
newSchemaMode: schemaMode === 'fixed' ? 'type-aware-discovery' : 'fixed',
})
}
label="Explicitly specify schema"
Expand Down Expand Up @@ -2645,8 +2645,9 @@ export class LoadDataView extends React.PureComponent<LoadDataViewProps, LoadDat
</p>
<p>Making this change will reset all schema configuration done so far.</p>
{autoDetect && (
<Switch
checked={newSchemaMode === 'type-aware-discovery'}
<RadioGroup
label="Schemaless mode"
selectedValue={newSchemaMode}
onChange={() => {
this.setState({
newSchemaMode:
Expand All @@ -2656,18 +2657,24 @@ export class LoadDataView extends React.PureComponent<LoadDataViewProps, LoadDat
});
}}
>
Use the new type-aware schema discovery capability. Avoid this if you are appending to a
datasource created with string-only schema discovery of Druid and want to preserve
schema compatibility. For more information see the{' '}
<ExternalLink
href={`${getLink(
'DOCS',
)}/ingestion/schema-design.html#schema-auto-discovery-for-dimensions`}
>
documentation
</ExternalLink>
.
</Switch>
<Radio value="type-aware-discovery">
Use the new type-aware schema discovery capability to discover columns according to
data type. Columns with multiple values will be ingested as ARRAY types. For more
information see the{' '}
<ExternalLink
href={`${getLink(
'DOCS',
)}/ingestion/schema-design.html#schema-auto-discovery-for-dimensions`}
>
documentation
</ExternalLink>
.
</Radio>
<Radio value="string-only-discovery">
Use classic string-only schema discovery to discover all new columns as strings.
Columns with multiple values will be ingested as multi-value-strings.
</Radio>
</RadioGroup>
)}
</AsyncActionDialog>
);
Expand Down

0 comments on commit 6becd81

Please sign in to comment.