Skip to content

Commit

Permalink
Release 3.2.2
Browse files Browse the repository at this point in the history
Release notes are available at:
https://docs.dremio.com/release-notes/32-release-notes.html

Change-Id: I6543f7a01bb598d70e7fb9fedae1eef5fd6ae06b
  • Loading branch information
yongyanw committed May 23, 2019
1 parent a3ac4b5 commit 9648971
Show file tree
Hide file tree
Showing 104 changed files with 1,267 additions and 331 deletions.
2 changes: 1 addition & 1 deletion client/jdbc/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
<parent>
<groupId>com.dremio.client</groupId>
<artifactId>dremio-client-parent</artifactId>
<version>3.2.1-201905191350330803-1a33f83</version>
<version>3.2.2-201905231753430810-ccf9a4e</version>
</parent>
<artifactId>dremio-client-jdbc</artifactId>
<name>Client - JDBC Driver</name>
Expand Down
2 changes: 1 addition & 1 deletion client/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
<parent>
<groupId>com.dremio</groupId>
<artifactId>dremio-parent</artifactId>
<version>3.2.1-201905191350330803-1a33f83</version>
<version>3.2.2-201905231753430810-ccf9a4e</version>
</parent>

<groupId>com.dremio.client</groupId>
Expand Down
2 changes: 1 addition & 1 deletion common/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<parent>
<groupId>com.dremio</groupId>
<artifactId>dremio-parent</artifactId>
<version>3.2.1-201905191350330803-1a33f83</version>
<version>3.2.2-201905231753430810-ccf9a4e</version>
</parent>

<artifactId>dremio-common</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion connector/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<parent>
<groupId>com.dremio</groupId>
<artifactId>dremio-parent</artifactId>
<version>3.2.1-201905191350330803-1a33f83</version>
<version>3.2.2-201905231753430810-ccf9a4e</version>
</parent>

<artifactId>dremio-connector</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion contrib/hive-exec-shade/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
<parent>
<groupId>com.dremio.contrib</groupId>
<artifactId>dremio-contrib-parent</artifactId>
<version>3.2.1-201905191350330803-1a33f83</version>
<version>3.2.2-201905231753430810-ccf9a4e</version>
</parent>

<artifactId>dremio-hive-exec-shaded</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion contrib/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
<parent>
<groupId>com.dremio</groupId>
<artifactId>dremio-parent</artifactId>
<version>3.2.1-201905191350330803-1a33f83</version>
<version>3.2.2-201905231753430810-ccf9a4e</version>
</parent>

<groupId>com.dremio.contrib</groupId>
Expand Down
2 changes: 1 addition & 1 deletion contrib/slim-shade/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
<parent>
<groupId>com.dremio.contrib</groupId>
<artifactId>dremio-contrib-parent</artifactId>
<version>3.2.1-201905191350330803-1a33f83</version>
<version>3.2.2-201905231753430810-ccf9a4e</version>
</parent>

<artifactId>dremio-slim-shade</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion contrib/tpch-sample-data/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
<parent>
<artifactId>dremio-contrib-parent</artifactId>
<groupId>com.dremio.contrib</groupId>
<version>3.2.1-201905191350330803-1a33f83</version>
<version>3.2.2-201905231753430810-ccf9a4e</version>
</parent>

<artifactId>dremio-tpch-sample-data</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion dac/backend/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
<parent>
<groupId>com.dremio</groupId>
<artifactId>dremio-dac-parent</artifactId>
<version>3.2.1-201905191350330803-1a33f83</version>
<version>3.2.2-201905231753430810-ccf9a4e</version>
</parent>

<artifactId>dremio-dac-backend</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,11 @@ private FileDatasetHandle getDataset(
// no files in the found directory, not a table.
return null;
}
return formatPlugin.getDatasetAccessor(DatasetType.PHYSICAL_DATASET_HOME_FILE, oldConfig, fs, fileSelectionWithoutDir, this, datasetPath, updateKey.build(), maxLeafColumns);

FileDatasetHandle.checkMaxFiles(datasetPath.getName(), fileSelectionWithoutDir.getStatuses().size(), getContext(),
getConfig().isInternal());
return formatPlugin.getDatasetAccessor(DatasetType.PHYSICAL_DATASET_HOME_FILE, oldConfig, fs,
fileSelectionWithoutDir, this, datasetPath, updateKey.build(), maxLeafColumns);
}

private static List<String> relativePath(List<String> tableSchemaPath, Path rootPath) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@
import com.dremio.exec.store.CatalogService;
import com.dremio.exec.store.RecordReader;
import com.dremio.exec.store.StoragePlugin;
import com.dremio.exec.store.dfs.FileCountTooLargeException;
import com.dremio.exec.store.dfs.FileDatasetHandle;
import com.dremio.exec.store.dfs.FileSelection;
import com.dremio.exec.store.dfs.FileSystemPlugin;
import com.dremio.exec.store.dfs.FileSystemWrapper;
Expand Down Expand Up @@ -209,8 +211,15 @@ private FileFormat detectFileFormat(NamespaceKey key) {
}
}

private static Iterator<FileStatus> getFilesForFormatting(FileSystemWrapper fs, Path path) throws IOException{
return fs.listRecursive(path, false).iterator();
private Iterator<FileStatus> getFilesForFormatting(FileSystemWrapper fs, Path path) throws IOException, FileCountTooLargeException {
final List<FileStatus> files = fs.listRecursive(path, false)
.stream()
.filter(f -> f.isFile())
.collect(Collectors.toList());

FileDatasetHandle.checkMaxFiles(path.getName(), files.size(), context,
false /* format previews are explicitly done by the user */);
return files.iterator();
}

private static FileFormat asFormat(NamespaceKey key, Path path, boolean isFolder) {
Expand Down Expand Up @@ -433,7 +442,7 @@ private interface Nextable<T> {
T next() throws IOException;
}

private class PredicateNextable<T> implements Nextable<T> {
private static class PredicateNextable<T> implements Nextable<T> {

private final Nextable<T> delegate;
private final Predicate<T> predicate;
Expand Down Expand Up @@ -461,7 +470,7 @@ public T next() throws IOException {

}

private class NextableSingleton<T> implements Nextable<T> {
private static class NextableSingleton<T> implements Nextable<T> {

public NextableSingleton(T singleValue) {
super();
Expand Down
2 changes: 1 addition & 1 deletion dac/common/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
<parent>
<groupId>com.dremio</groupId>
<artifactId>dremio-dac-parent</artifactId>
<version>3.2.1-201905191350330803-1a33f83</version>
<version>3.2.2-201905231753430810-ccf9a4e</version>
</parent>

<artifactId>dremio-dac-common</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion dac/daemon/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
<parent>
<groupId>com.dremio</groupId>
<artifactId>dremio-dac-parent</artifactId>
<version>3.2.1-201905191350330803-1a33f83</version>
<version>3.2.2-201905231753430810-ccf9a4e</version>
</parent>

<artifactId>dremio-dac-daemon</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion dac/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
<parent>
<groupId>com.dremio</groupId>
<artifactId>dremio-parent</artifactId>
<version>3.2.1-201905191350330803-1a33f83</version>
<version>3.2.2-201905231753430810-ccf9a4e</version>
</parent>

<artifactId>dremio-dac-parent</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion dac/ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
},
"scripts": {
"start": "node server.js",
"startprod": "NODE_ENV=production node server.js",
"startprod": "NODE_ENV=production DREMIO_MINIFY=true DREMIO_RELEASE=true node server.js",
"lint:path": "eslint --cache",
"lint": "eslint --cache ./ ${DREMIO_UI_SRC:-src}",
"postshrinkwrap": "shankwrap fsevents nan",
Expand Down
2 changes: 1 addition & 1 deletion dac/ui/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
<parent>
<groupId>com.dremio</groupId>
<artifactId>dremio-dac-parent</artifactId>
<version>3.2.1-201905191350330803-1a33f83</version>
<version>3.2.2-201905231753430810-ccf9a4e</version>
</parent>

<artifactId>dremio-dac-ui</artifactId>
Expand Down
3 changes: 3 additions & 0 deletions dac/ui/server.config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"apiOrigin": "http://localhost:9047"
}
13 changes: 11 additions & 2 deletions dac/ui/server.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@
*/
/*eslint no-console: 0*/

const fs = require('fs');
const path = require('path');
const webpack = require('webpack');
const webpackDevMiddleware = require('webpack-dev-middleware');
const proxy = require('http-proxy-middleware');
Expand All @@ -25,7 +27,6 @@ const app = express();

const config = require('./webpack.config');
const testConfig = require('./webpack.tests.config');
const userConfig = require('./webpackUtils/userConfig');
const isProductionBuild = process.env.NODE_ENV === 'production';

const ENABLE_TESTS = false; // not quite yet ready
Expand All @@ -52,10 +53,18 @@ if (ENABLE_TESTS && !isProductionBuild) {

let storedProxy;
let prevAPIOrigin;
const readServerSettings = () => {
return JSON.parse(fs.readFileSync( // eslint-disable-line no-sync
path.resolve(__dirname, 'server.config.json'),
'utf8'
));
};

// Job profiles load their css/js from /static/*, so redirect those calls as well
app.use(['/api*', '/static/*'], function() {
const newAPIOrigin = userConfig.live().apiOrigin;
// todo it would be nice to enforce server and web socket to use the same origin.
// See https://github.com/dremio/dremio/blob/64ada2028fb042e6b3a035b9ef64814218095e30/oss/dac/ui/src/constants/Api.js#L22
const newAPIOrigin = readServerSettings().apiOrigin;
if (newAPIOrigin !== prevAPIOrigin) {
storedProxy = proxy({
target: newAPIOrigin,
Expand Down
4 changes: 3 additions & 1 deletion dac/ui/src/actions/explore/view.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import Immutable from 'immutable';
import actionUtils from 'utils/actionUtils/actionUtils';

export const SET_CURRENT_SQL = 'SET_CURRENT_SQL';
Expand All @@ -24,8 +25,9 @@ export function setCurrentSql({ sql }) {
return { type: SET_CURRENT_SQL, sql };
}

const defaultContext = new Immutable.List();
export function setQueryContext({ context }) {
return { type: SET_QUERY_CONTEXT, context };
return { type: SET_QUERY_CONTEXT, context: context || defaultContext };
}

export function resetNewQuery(viewId) {
Expand Down
20 changes: 17 additions & 3 deletions dac/ui/src/actions/prodError.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,18 +13,32 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import invariant from 'invariant';
import sentryUtil from '@app/utils/sentryUtil';

export const SHOW_PROD_ERROR = 'SHOW_PROD_ERROR';
export const HIDE_PROD_ERROR = 'HIDE_PROD_ERROR';

const e2eTestErrorMessage = 'JS_ERROR_OCCURRED';

export function showAppError(error, errorId) {
const getError = (e) => {
invariant(e, 'error must be provided');
if (e instanceof Error) {
return e;
}
if (e.message) {
return new Error(e.message + '\n\n' + e.stack + '\n\n(non-Error instance)');
}
return new Error(e); // error components expect objects
};

export function showAppError(error) {
// a signal for e2e tests
console.error(e2eTestErrorMessage);
return {
type: SHOW_PROD_ERROR,
error,
errorId
error: getError(error),
errorId: sentryUtil.getEventId()
};
}

Expand Down
18 changes: 3 additions & 15 deletions dac/ui/src/components/ErrorBoundary.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
import { PureComponent } from 'react';
import { connect } from 'react-redux';
import PropTypes from 'prop-types';
import invariant from 'invariant';
import { showAppError } from 'actions/prodError';
import sentryUtil from '@app/utils/sentryUtil';

Expand All @@ -25,17 +24,6 @@ const mapDispatchToProps = ({
showAppError
});

export const getError = (e) => {
invariant(e, 'error must be provided');
if (e instanceof Error) {
return e;
}
if (e.message) {
return new Error(e.message + '\n\n' + e.stack + '\n\n(non-Error instance)');
}
return new Error(e); // error components expect objects
};

@connect(null, mapDispatchToProps)
export class ErrorBoundary extends PureComponent {
static propTypes = {
Expand All @@ -56,9 +44,9 @@ export class ErrorBoundary extends PureComponent {
if (!isProd) {
debugger; // eslint-disable-line no-debugger
}
const errorObject = getError(error);

this.props.showAppError(errorObject, sentryUtil.getEventId());
// This line must be here as in case DREMIO_RELEASE=true Raven does not not catch a error
sentryUtil.logException(error);
this.props.showAppError(error);
}

render() {
Expand Down
3 changes: 1 addition & 2 deletions dac/ui/src/components/Forms/General.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import { Component } from 'react';

import PropTypes from 'prop-types';

import { section, sectionTitle, formRow } from 'uiTheme/radium/forms';
import { section, formRow } from 'uiTheme/radium/forms';

import { FieldWithError, TextField } from 'components/Fields';
import AccelerationSection from 'components/Forms/AccelerationSection';
Expand Down Expand Up @@ -57,7 +57,6 @@ export default class General extends Component {
return (
<div>
<div className='general' style={section}>
<h2 style={sectionTitle}>{la('General')}</h2>
<div style={{...formRow, display: 'flex', marginBottom: 10}}>
<FieldWithError errorPlacement='top' label={la('Name')} {...name}
style={fieldWithErrorStyle}>
Expand Down
13 changes: 6 additions & 7 deletions dac/ui/src/containers/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import urlParse from 'url-parse';
import { showAppError } from 'actions/prodError';
import { boot } from 'actions/app';
import { DnDContextDecorator } from '@app/components/DragComponents/DnDContextDecorator';
import { ErrorBoundary, getError } from '@app/components/ErrorBoundary';
import { ErrorBoundary } from '@app/components/ErrorBoundary';

import socket from 'utils/socket';
import sentryUtil from 'utils/sentryUtil';
Expand Down Expand Up @@ -125,7 +125,7 @@ export class App extends Component {
if (!url || urlParse(url).origin !== this._getWindowOrigin()) return;

console.error('Uncaught Error', error || msg);
this.displayError(error || msg, sentryUtil.getEventId());
this.displayError(error || msg);
};

handleUnhandledRejection = (rejectionEvent) => {
Expand All @@ -135,15 +135,14 @@ export class App extends Component {
if (error.stack && this._shouldIgnoreExternalStack(error.stack)) return;

//By default, Raven.js does not capture unhandled promise rejections.
const eventId = sentryUtil.logException(error);
sentryUtil.logException(error);

console.error('UnhandledRejection', error);
this.displayError(error, eventId);
this.displayError(error);
};

displayError(error, eventId) {
const errorObject = getError(error);
this.props.dispatch(showAppError(errorObject, eventId));
displayError(error) {
this.props.dispatch(showAppError(error));
}

_getWindowOrigin() {
Expand Down
3 changes: 3 additions & 0 deletions dac/ui/src/customData/vlhfDetail.json
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,9 @@
{
"propName": "config.allowCreateDrop"
},
{
"propName": "config.compatibilityMode"
},
{
"propName": "config.rootPath"
}
Expand Down
2 changes: 1 addition & 1 deletion dac/ui/src/pages/HomePage/components/forms/SpaceForm.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ export class SpaceForm extends Component {
const description = intl.formatMessage({ id: 'Space.AddSpaceModalDescription' });
return (
<ModalForm {...modalFormProps(this.props)} onSubmit={handleSubmit(onFormSubmit)}>
<FormBody style={{padding: '20px 5px 20px 15px'}}>
<FormBody style={{padding: '20px 15px'}}>
<General
showAccelerationSection={false}
fields={fields}
Expand Down
Loading

0 comments on commit 9648971

Please sign in to comment.