mirror of
https://github.com/apache/zeppelin
synced 2026-05-24 09:38:26 +00:00
Merge branch 'master' into notebook-search
This commit is contained in:
commit
b13d5fbc4d
8 changed files with 44 additions and 29 deletions
|
|
@ -65,6 +65,7 @@ import com.google.common.base.Function;
|
|||
public class ZeppelinIT {
|
||||
private static final Logger LOG = LoggerFactory.getLogger(ZeppelinIT.class);
|
||||
private static final long MAX_BROWSER_TIMEOUT_SEC = 30;
|
||||
private static final long MAX_PARAGRAPH_TIMEOUT_SEC = 60;
|
||||
private WebDriver driver;
|
||||
|
||||
private void setWebDriver() {
|
||||
|
|
@ -112,7 +113,7 @@ public class ZeppelinIT {
|
|||
|
||||
while (System.currentTimeMillis() - start < 60 * 1000) {
|
||||
try { // wait for page load
|
||||
WebElement element = pollingWait(By.partialLinkText("Create new note"));
|
||||
WebElement element = pollingWait(By.partialLinkText("Create new note"), MAX_BROWSER_TIMEOUT_SEC);
|
||||
loaded = element.isDisplayed();
|
||||
break;
|
||||
} catch (TimeoutException e) {
|
||||
|
|
@ -149,22 +150,22 @@ public class ZeppelinIT {
|
|||
boolean waitForParagraph(final int paragraphNo, final String state) {
|
||||
By locator = By.xpath(getParagraphXPath(paragraphNo)
|
||||
+ "//div[contains(@class, 'control')]//span[1][contains(.,'" + state + "')]");
|
||||
WebElement element = pollingWait(locator);
|
||||
WebElement element = pollingWait(locator, MAX_PARAGRAPH_TIMEOUT_SEC);
|
||||
return element.isDisplayed();
|
||||
}
|
||||
|
||||
boolean waitForText(final String txt, final By locator) {
|
||||
try {
|
||||
WebElement element = pollingWait(locator);
|
||||
WebElement element = pollingWait(locator, MAX_BROWSER_TIMEOUT_SEC);
|
||||
return txt.equals(element.getText());
|
||||
} catch (TimeoutException e) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
public WebElement pollingWait(final By locator) {
|
||||
public WebElement pollingWait(final By locator, final long timeWait) {
|
||||
Wait<WebDriver> wait = new FluentWait<WebDriver>(driver)
|
||||
.withTimeout(MAX_BROWSER_TIMEOUT_SEC, TimeUnit.SECONDS)
|
||||
.withTimeout(timeWait, TimeUnit.SECONDS)
|
||||
.pollingEvery(1, TimeUnit.SECONDS)
|
||||
.ignoring(NoSuchElementException.class);
|
||||
|
||||
|
|
|
|||
|
|
@ -275,10 +275,6 @@ kbd {
|
|||
border-radius: 2px;
|
||||
}
|
||||
|
||||
.home {
|
||||
min-height: 400px;
|
||||
}
|
||||
|
||||
/*
|
||||
ngToast Style
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -20,6 +20,7 @@ angular.module('zeppelinWebApp').controller('InterpreterCtrl', function($scope,
|
|||
$scope.interpreterSettings = [];
|
||||
$scope.availableInterpreters = {};
|
||||
$scope.showAddNewSetting = false;
|
||||
$scope._ = _;
|
||||
|
||||
var getInterpreterSettings = function() {
|
||||
$http.get(baseUrlSrv.getRestApiBase()+'/interpreter/setting').
|
||||
|
|
@ -216,6 +217,9 @@ angular.module('zeppelinWebApp').controller('InterpreterCtrl', function($scope,
|
|||
var index = _.findIndex($scope.interpreterSettings, { 'id': settingId });
|
||||
var setting = $scope.interpreterSettings[index];
|
||||
|
||||
if (!setting.propertyKey || setting.propertyKey === '') {
|
||||
return;
|
||||
}
|
||||
setting.properties[setting.propertyKey] = setting.propertyValue;
|
||||
emptyNewProperty(setting);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -62,10 +62,6 @@
|
|||
overflow-y: auto;
|
||||
}
|
||||
|
||||
.interpreter table tr {
|
||||
height : 45px;
|
||||
}
|
||||
|
||||
.interpreterSettingAdd {
|
||||
margin : 5px 5px 5px 5px;
|
||||
padding : 10px 10px 10px 10px;
|
||||
|
|
@ -74,3 +70,17 @@
|
|||
.editable-wrap {
|
||||
width : 100%;
|
||||
}
|
||||
|
||||
.interpreter h5 {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.new_h3 {
|
||||
margin-top: 1px;
|
||||
padding-top: 7px;
|
||||
float: left;
|
||||
}
|
||||
|
||||
.empty-properties-message {
|
||||
color: #666;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ limitations under the License.
|
|||
<div class="header">
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<h3 class="new_h3" style="float:left">
|
||||
<h3 class="new_h3">
|
||||
Interpreters
|
||||
</h3>
|
||||
<span class="btn btn-default fa fa-plus"
|
||||
|
|
@ -65,17 +65,21 @@ limitations under the License.
|
|||
</span>
|
||||
</div>
|
||||
</div>
|
||||
<br />
|
||||
<div class="row interpreter">
|
||||
<div class="col-md-12">
|
||||
<b>Properties</b>
|
||||
<div ng-show="_.isEmpty(setting.properties) || valueform.$hidden" class="col-md-12 empty-properties-message">
|
||||
<em>Currently there are no properties set for this interpreter</em>
|
||||
</div>
|
||||
<div class="col-md-12" ng-show="!_.isEmpty(setting.properties) || valueform.$visible">
|
||||
<h5>Properties</h5>
|
||||
<table class="table table-striped">
|
||||
<tr>
|
||||
<th style="width:30%">name</th>
|
||||
<th>value</th>
|
||||
<th ng-if="valueform.$visible">action</th>
|
||||
</tr>
|
||||
<tr ng-repeat="(key, value) in setting.properties">
|
||||
<thead>
|
||||
<tr>
|
||||
<th style="width:30%">name</th>
|
||||
<th>value</th>
|
||||
<th ng-if="valueform.$visible">action</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tr ng-repeat="(key, value) in setting.properties" >
|
||||
<td>{{key}}</td>
|
||||
<td>
|
||||
<span editable-textarea="setting.properties[key]" e-form="valueform" e-msd-elastic>
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ limitations under the License.
|
|||
class="btn btn-default btn-xs"
|
||||
ng-click="runNote()"
|
||||
ng-class="{'disabled':isNoteRunning()}"
|
||||
tooltip-placement="bottom" tooltip="Run all the notes">
|
||||
tooltip-placement="bottom" tooltip="Run all paragraphs">
|
||||
<i class="icon-control-play"></i>
|
||||
</button>
|
||||
<button type="button"
|
||||
|
|
|
|||
|
|
@ -104,11 +104,6 @@
|
|||
color: #333333;
|
||||
}
|
||||
|
||||
.new_h3 {
|
||||
margin-top: 1px;
|
||||
padding-top: 7px;
|
||||
}
|
||||
|
||||
.form-control2 {
|
||||
width: 100%;
|
||||
height: 40px;
|
||||
|
|
|
|||
|
|
@ -404,3 +404,8 @@
|
|||
.dropdown-menu > li:first-child > a:hover {
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
table.table-striped {
|
||||
border-top: 1px solid #ddd;
|
||||
margin-top: 20px;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue