From 20b835944ec814690d9330969e0ed3b0669bfd95 Mon Sep 17 00:00:00 2001 From: Jade McGough Date: Sun, 30 Oct 2016 23:23:32 -0700 Subject: [PATCH] Revert "Show flash error if can't connect in data explorer." This reverts commit b269e4a34d0bda99ac27d6de5218b739c43cefb4. --- ui/src/chronograf/api/index.js | 9 --------- ui/src/chronograf/containers/App.js | 21 ++++++--------------- 2 files changed, 6 insertions(+), 24 deletions(-) diff --git a/ui/src/chronograf/api/index.js b/ui/src/chronograf/api/index.js index 19078def6f..70018e9683 100644 --- a/ui/src/chronograf/api/index.js +++ b/ui/src/chronograf/api/index.js @@ -1,5 +1,4 @@ import AJAX from 'utils/ajax'; -import {proxy} from 'utils/queryUrlGenerator'; export function saveExplorer({name, panels, queryConfigs, explorerID}) { return AJAX({ @@ -14,11 +13,3 @@ export function saveExplorer({name, panels, queryConfigs, explorerID}) { }), }); } - -export function verifySource(proxyLink) { - return proxy({ - source: proxyLink, - query: "select * from cpu limit 1", - db: 'telegraf', - }); -} diff --git a/ui/src/chronograf/containers/App.js b/ui/src/chronograf/containers/App.js index 3433d97648..6314243629 100644 --- a/ui/src/chronograf/containers/App.js +++ b/ui/src/chronograf/containers/App.js @@ -3,7 +3,6 @@ import {connect} from 'react-redux'; import {withRouter} from 'react-router'; import {fetchExplorers} from '../actions/view'; import DataExplorer from './DataExplorer'; -import {verifySource} from '../api'; const App = React.createClass({ propTypes: { @@ -20,23 +19,15 @@ const App = React.createClass({ params: PropTypes.shape({ base64ExplorerID: PropTypes.string, }).isRequired, - addFlashMessage: PropTypes.func, }, componentDidMount() { - verifySource(this.props.source.links.proxy).then(() => { - const {base64ExplorerID} = this.props.params; - this.props.fetchExplorers({ - source: this.props.source, - userID: 1, // TODO: get the userID - explorerID: base64ExplorerID ? this.decodeID(base64ExplorerID) : null, - push: this.props.router.push, - }); - }).catch(() => { - this.props.addFlashMessage({ - type: 'error', - text: `Connection error. Check that your server is running.`, - }); + const {base64ExplorerID} = this.props.params; + this.props.fetchExplorers({ + source: this.props.source, + userID: 1, // TODO: get the userID + explorerID: base64ExplorerID ? this.decodeID(base64ExplorerID) : null, + push: this.props.router.push, }); },