Merge branch 'madhusudancs/testframework-update'
diff --git a/asterix-app/src/main/resources/webui/querytemplate.html b/asterix-app/src/main/resources/webui/querytemplate.html
index 8cc8d29..40ce161 100644
--- a/asterix-app/src/main/resources/webui/querytemplate.html
+++ b/asterix-app/src/main/resources/webui/querytemplate.html
@@ -16,6 +16,9 @@
<script type="text/javascript">
$(document).ready(function() {
+ var optionButtonSize = $('#checkboxes-on').width();
+ $('#clear-query-button, #run-btn').width(optionButtonSize);
+
$('#checkboxes-on').click(function() {
/* Displays a checkmark to indicate selection/clearing */
if ($('#opts').is(":visible")) {
@@ -165,18 +168,19 @@
</div>
<div class="btn-group">
- <button id="checkboxes-on" class="btn"><i id="opts" class="icon-ok" ></i>Select Options</button>
+ <button id="checkboxes-on" class="btn">
+ <i id="opts" class="icon-ok" style="display:none;"></i>Select Options</button>
<button id="clear-query-button" class="btn">Clear Query</button>
<!-- <button id="checkboxes-off" class="btn">Clear All Options</button> -->
<button type="submit" id="run-btn" class="btn btn-custom-darken">Run</button>
</div>
<div>
- <label class="checkbox optlabel"><input type="checkbox" checked="checked" name="print-expr-tree" value="true" /> Print parsed expressions</label>
- <label class="checkbox optlabel"><input type="checkbox" checked="checked" name="print-rewritten-expr-tree" value="true" /> Print rewritten expressions</label>
- <label class="checkbox optlabel"><input type="checkbox" checked="checked" name="print-logical-plan" value="true" /> Print logical plan</label>
- <label class="checkbox optlabel"><input type="checkbox" checked="checked" name="print-optimized-logical-plan" value="true" /> Print optimized logical plan</label>
- <label class="checkbox optlabel"><input type="checkbox" checked="checked" name="print-job" value="true" /> Print Hyracks job</label>
+ <label class="checkbox optlabel"><input type="checkbox" name="print-expr-tree" value="true" /> Print parsed expressions</label>
+ <label class="checkbox optlabel"><input type="checkbox" name="print-rewritten-expr-tree" value="true" /> Print rewritten expressions</label>
+ <label class="checkbox optlabel"><input type="checkbox" name="print-logical-plan" value="true" /> Print logical plan</label>
+ <label class="checkbox optlabel"><input type="checkbox" name="print-optimized-logical-plan" value="true" /> Print optimized logical plan</label>
+ <label class="checkbox optlabel"><input type="checkbox" name="print-job" value="true" /> Print Hyracks job</label>
</div>
</form>
</div>
diff --git a/asterix-app/src/main/resources/webui/static/css/style.css b/asterix-app/src/main/resources/webui/static/css/style.css
index b84c5ef..a3e411c 100644
--- a/asterix-app/src/main/resources/webui/static/css/style.css
+++ b/asterix-app/src/main/resources/webui/static/css/style.css
@@ -73,7 +73,9 @@
}
pre {
+ overflow-x : auto;
overflow: auto;
+ overflow-wrap: normal;
white-space: pre;
}
diff --git a/asterix-doc/src/site/markdown/AdmAql101.md b/asterix-doc/src/site/markdown/AdmAql101.md
index ed4736e..994c464 100644
--- a/asterix-doc/src/site/markdown/AdmAql101.md
+++ b/asterix-doc/src/site/markdown/AdmAql101.md
@@ -211,8 +211,8 @@
This index will be a B+ tree index; its type is unspecified and _btree_ is the default type.
The other three illustrate how you can explicitly specify the desired type of index.
In addition to btree, _rtree_ and inverted _keyword_ indexes are supported by AsterixDB.
-Indexes can also have composite keys, and there are more advanced flavors of text indexing
-available as well (_fuzzy keyword_ and _ngram(k)_, where _k_ is the desired gram length).
+Indexes can also have composite keys, and more advanced text indexing is available as well
+(ngram(k), where k is the desired gram length).
### Querying the Metadata Dataverse ###
diff --git a/asterix-doc/src/site/markdown/AsterixAlphaRelease.md b/asterix-doc/src/site/markdown/AsterixAlphaRelease.md
deleted file mode 100644
index ff9efb2..0000000
--- a/asterix-doc/src/site/markdown/AsterixAlphaRelease.md
+++ /dev/null
@@ -1,57 +0,0 @@
-# AsterixDB: A Big Data Management System _(Alpha Release)_ #
-
-## What Is AsterixDB? ##
-
-Welcome to the new home of the AsterixDB Big Data Management System (BDMS).
-The AsterixDB BDMS is the result of about 3.5 years of R&D involving researchers at UC Irvine, UC Riverside, and UC San Diego.
-The AsterixDB code base now consists of roughly 250K lines of Java code that has been co-developed at UC Irvine and UC Riverside.
-
-Initiated in 2009, the NSF-sponsored ASTERIX project has been developing new technologies for ingesting, storing, managing, indexing, querying, and analyzing vast quantities of semi-structured information.
-The project has been combining ideas from three distinct areas---semi-structured data, parallel databases, and data-intensive computing (a.k.a. today's Big Data platforms)---in order to create a next-generation, open-source software platform that scales by running on large, shared-nothing commodity computing clusters.
-The ASTERIX effort has been targeting a wide range of semi-structured information, ranging from "data" use cases---where information is well-typed and highly regular---to "content" use cases---where data tends to be irregular, much of each datum may be textual, and the ultimate schema for the various data types involved may be hard to anticipate up front.
-The ASTERIX project has been addressing technical issues including highly scalable data storage and indexing, semi-structured query processing on very large clusters, and merging time-tested parallel database techniques with modern data-intensive computing techniques to support performant yet declarative solutions to the problem of storing and analyzing semi-structured information effectively.
-The first fruits of this labor have been captured in the AsterixDB system that is now being released in preliminary or "Alpha" release form.
-We are hoping that the arrival of AsterixDB will mark the beginning of the "BDMS era", and we hope that both the Big Data community and the database community will find the AsterixDB system to be interesting and useful for a much broader class of problems than can be addressed with any one of today's current Big Data platforms and related technologies (e.g., Hadoop, Pig, Hive, HBase, MongoDB, and so on). One of our project mottos has been "one size fits a bunch"---at least that has been our aim. For more information about the research effort that led to the birth of AsterixDB, please refer to our NSF project web site: [http://asterix.ics.uci.edu/](http://asterix.ics.uci.edu/).
-
-In a nutshell, AsterixDB is a full-function BDMS with a rich feature set that distinguishes it from pretty much any other Big Data platform that's out and available today. We believe that its feature set makes it well-suited to modern needs such as web data warehousing and social data storage and analysis. AsterixDB has:
-
- * A semistructured NoSQL style data model (ADM) resulting from extending JSON with object database ideas
- * An expressive and declarative query language (AQL) that supports a broad range of queries and analysis over semistructured data
- * A parallel runtime query execution engine, Hyracks, that has been scale-tested on up to 1000+ cores and 500+ disks
- * Partitioned LSM-based data storage and indexing to support efficient ingestion and management of semistructured data
- * Support for query access to externally stored data (e.g., data in HDFS) as well as to data stored natively by AsterixDB
- * A rich set of primitive data types, including spatial and temporal data in addition to integer, floating point, and textual data
- * Secondary indexing options that include B+ trees, R trees, and inverted keyword (exact and fuzzy) index types
- * Support for fuzzy and spatial queries as well as for more traditional parametric queries
- * Basic transactional (concurrency and recovery) capabilities akin to those of a NoSQL store
-
-## Getting and Using AsterixDB ##
-
-You are most likely here because you are interested in getting your hands on AsterixDB---so you would like to know how to get it, how to set it up, and how to use it.
-Someday our plan is to have comprehensive documentation for AsterixDB and its data model (ADM) and query language (AQL) here on this wiki.
-For the Alpha release, we've got a start; for the Beta release a month or so from now, we will hopefully have much more.
-The following is a list of the wiki pages and supporting documents that we have available today:
-
-1. [InstallingAsterixUsingManagix](InstallingAsterixUsingManagix.html) :
-This is our installation guide, and it is where you should start.
-This document will tell you how to obtain, install, and manage instances of [AsterixDB](https://asterixdb.googlecode.com/files/asterix-installer-0.0.4-binary-assembly.zip), including both single-machine setup (for developers) as well as cluster installations (for deployment in its intended form).
-
-2. [AdmAql101](AdmAql101.html) :
-This is a first-timers introduction to the user model of the AsterixDB BDMS, by which we mean the view of AsterixDB as seen from the perspective of an "average user" or Big Data application developer.
-The AsterixDB user model consists of its data modeling features (ADM) and its query capabilities (AQL).
-This document presents a tiny "social data warehousing" example and uses it as a backdrop for describing, by example, the key features of AsterixDB.
-By working through this document, you will learn how to define the artifacts needed to manage data in AsterixDB, how to load data into the system, how to use most of the basic features of its query language, and how to insert and delete data dynamically.
-
-3. [AsterixDataTypesAndFunctions](AsterixDataTypesAndFunctions.html) :
-This is a reference document that catalogs the primitive data types and built-in functions available for use in AsterixDB schemas (in ADM) and queries (in AQL).
-
-4. [AQL Reference](AsterixQueryLanguageReference.html) :
-This is the AQL language reference manual.
-
-5. [AsterixDBRestAPI](AsterixDBRestAPI.html) :
-Access to data in an AsterixDB instance is provided via a REST-based API.
-This is a short document that describes the REST API entry points and their URL syntax.
-
-To all who have now come this far: Thanks for your interest in AsterixDB, and for kicking its tires in its Alpha form
-In addition to getting the system and trying it out, please sign up as a member of the AsterixDB user mailing list (asterixdb-users (at) googlegroups.com) so that you can contact us easily with your questions, issues, and other feedback.
-We want AsterixDB to be a "big hit" some day, and we are anxious to see what users do with it and to learn from that feedback what we should be working on most urgently in the next phase of the project.
diff --git a/asterix-doc/src/site/markdown/AsterixQueryLanguage.md b/asterix-doc/src/site/markdown/AsterixQueryLanguage.md
deleted file mode 100644
index af25cda..0000000
--- a/asterix-doc/src/site/markdown/AsterixQueryLanguage.md
+++ /dev/null
@@ -1,195 +0,0 @@
-`<wiki:toc max_depth="2" />`
-
-# The Asterix Query Language, Version 1.0 #
-
-# Introduction #
-
-This wiki page provides an overview of the Asterix Query language and the Asterix Data model.
-
-*WARNING:* _THIS IS AN INCOMPLETE SUSPENDED WORK IN PROGRESS...
-_ It will hopefully be resumed shortly in order to produce a legit AQL spec to go out with the Beta Release of AsterixDB. What's here is very likely inconsistent with what's in the system as of today, as this was from an older snapshot of the world.
-
-# Asterix Data Model #
-
-Data in Asterix is represented using the Asterix Data Model (ADM). The ADM derives inspiration from prior standards such as JSON, XQuery, and the Object Data Model from ODMG.
-
-## Asterix Types ##
-
-### Primitive Types ##
-
-|| *Primitive Type* || *Description* ||
-|| int8 || Signed 8-bit integer. Valid range -128 thru 127 ||
-|| int16 || Signed 16-bit integer. Valid range -32768 thru 32767 ||
-|| int32 || Signed 32-bit integer. Valid range -2147483648 thru 2147483647 ||
-|| int64 || Signed 64-bit integer. Valid range -9223372036854775807 thru 9223372036854775808 ||
-|| uint8 || Unsigned 8-bit integer. Valid range 0 thru 255 ||
-|| uint16 || Unsigned 16-bit integer. Valid range 0 thru 65535 ||
-|| uint32 || Unsigned 32-bit integer. Valid range 0 thru 4294967295 ||
-|| uint64 || Unsigned 64-bit integer. Valid range 0 thru 18446744073709551615 ||
-|| string || String of characters ||
-|| null || null type (Type of the null value) ||
-|| date || Date ||
-|| time || Time of day ||
-|| boolean || Boolean ||
-|| datetime || Date and time ||
-|| point2d || A point in 2-D space ||
-|| point3d || A point in 3-D space ||
-|| binary || Binary data ||
-|| yminterval || Year-Month interval ||
-|| dtinterval || Day-Time interval ||
-|| interval || Year-Month and Day-Time interval ||
-
-### Collection Types ###
-
-|| *Collection Type* || *Description* ||
-|| Record || A record type describes the record data item. A record contains a set of fields which can have values of any ADM type. Fields of a record must be unique. ||
-|| Union || A union type is an abstract type (A value never has a union type) that describes a set of type choices. ||
-|| Ordered List || An orderedlist instance represents a sequence of values where the order of the instances is determined by creation/insertion ||
-|| UnorderedList || An unorderedlist instance represents a collection of values where the order of the instances where the order is irrelevant ||
-|| Enumeration || An enumeration type represents a choice of string values ||
-
-# AQL Expressions #
-
-## Primary Expressions ##
-
-Primary expressions are the basic expressions that form the core of AQL.
-
-### Literals ###
-
-A Literal is a syntactic representation of a constant value. The various literals allowed in AQL are described in the table below.
-
-|| *Literal type* || *Syntax* ||
-|| StringLiteral || ` STRING_LITERAL : ("\"" ("\\\"" | ~["\""])* "\"") | ("\'"("\\\'" | ~["\'"])* "\'") ` ||
-|| IntegerLiteral || ` INTEGER_LITERAL : (["0" - "9"])+ ` ||
-|| FloatLiteral || ` FLOAT_LITERAL: ((["0" - "9"])* "." (["0" - "9"])+ ("f" | "F")) ` ||
-|| DoubleLiteral || ` DOUBLE_LITERAL: ((["0" - "9"])* "." (["0" - "9"])+) ` ||
-|| NullLiteral || ` NULL_LITERAL: "null" ` ||
-|| BooleanLiteral || ` BOOLEAN_LITERAL: "true" | "false" ` ||
-
-### Function Call ###
-
-Function Calls in AQL can be used to invoke builtin functions as well as user defined functions.
-Function Calls have the following syntax.
-
-
- IDENTIFIER "(" ( Expression ( "," Expression )* )? ")"
-
-
-### Variable Reference ###
-
-Variables in AQL are used to bind to values. Variables can be bound to values by the For, Let, Group by clauses of the FLWOR expressions. Variables can also be bound by
-the Quantified Expressions.
-
-### Ordered List Constructor ###
-
-Constructs an ordered list. An ordered list represents a collection of values. The order of values is relevant. The collection may contain duplicate values.
-
-### Unordered List Constructor ###
-
-Constructs an unordered list. An unordered list represents a collection of values. The order of values is not relevant. The collection may contain duplicate values.
-
-### Record Constructor ###
-
-Constructs an AQL Record. A record contains fields. Each field has a name and a value. The name of the field is of type string. The value of a field may be any legal ADM data type. A record may not contain duplicate fields.
-
-## Arithmetic Expressions ##
-
-AQL allows all the standard arithmetic operators on numeric data types. The specific operators allowed are:
-
-|| *Operator* || *Description* ||
-|| + || Add ||
-|| - || Subtract ||
-|| * || Multiply ||
-|| / || Divide ||
-|| mod || Modulo ||
-
-## Comparison Expressions ##
-
-AQL provides the six standard comparison expressions listed below. In addition, AQL supports fuzzy comparisons.
-
-|| *Operator* || *Description* ||
-|| = || Equal ||
-|| = || Not Equal ||
-|| `< || Less Than ||
-|| `<= || Less Than or Equal ||
-|| >` || Greater Than ||
-|| >`= || Greater Than or Equal ||
-|| >`= || Greater Than or Equal ||
-|| ~= || Fuzzy Equals ||
-
-## Logical Expressions ##
-
-AQL provides two logical connectors:
-
-|| *Operator* || *Description* ||
-|| and || Logical AND ||
-|| or || Logical OR ||
-
-## Field Access Expressions ##
-
-The "." operator is used to access fields of a record. For example,
-
-
- $x.name
-
-
-accesses the name field of the record bound to $x.
-
-## Indexed Expressions ##
-
-Indexed expressions are used to access values in an ordered list. For example,
-
-
- $x[5]
-
-
-accesses the 6th item in the list bound to $x. Indexes start at 0.
-
-## FLWOR Expression ##
-
-The FLWOR expression is the most elaborate expression in AQL. It is made up of two parts -- Clauses and the Return Expression.
-
-The syntax of the FLWOR expression is:
-
-
-
- ( ForClause | LetClause )
- ( ForClause | LetClause | WhereClause | OrderClause | GroupClause | LimitClause | DistinctClause )*
- "return" ReturnExpression
-
-
-
-* For Clause
-
- "for" Variable "in" Expression
-
-* Let Clause
-
- "let" Variable ":=" Expression
-
-* Where Clause
-
- "where" Expression
-
-* Order Clause
-
- "order" "by" Expression ("asc" | "desc") ("," Expression ("asc" | "desc"))*
-
-* Group Clause
-
- "group" "by" ((Variable ":=")? Expression) ("," ((Variable ":=")? Expression))* "with" Variable
-
-* Limit Clause
-
- "limit" Expression ("," Expression)?
-
-
-* If Then Else Expressions *
-
- "if" "(" Expression ")" "then" Expression "else" Expression
-
-
-* Quantified Expressions *
-
- ("some" | "every") Variable "in" Expression "satisfies" Expression
-
diff --git a/asterix-doc/src/site/markdown/index.md b/asterix-doc/src/site/markdown/index.md
index cba2fdc..ff9efb2 100644
--- a/asterix-doc/src/site/markdown/index.md
+++ b/asterix-doc/src/site/markdown/index.md
@@ -1 +1,57 @@
-# AsterixDB
+# AsterixDB: A Big Data Management System _(Alpha Release)_ #
+
+## What Is AsterixDB? ##
+
+Welcome to the new home of the AsterixDB Big Data Management System (BDMS).
+The AsterixDB BDMS is the result of about 3.5 years of R&D involving researchers at UC Irvine, UC Riverside, and UC San Diego.
+The AsterixDB code base now consists of roughly 250K lines of Java code that has been co-developed at UC Irvine and UC Riverside.
+
+Initiated in 2009, the NSF-sponsored ASTERIX project has been developing new technologies for ingesting, storing, managing, indexing, querying, and analyzing vast quantities of semi-structured information.
+The project has been combining ideas from three distinct areas---semi-structured data, parallel databases, and data-intensive computing (a.k.a. today's Big Data platforms)---in order to create a next-generation, open-source software platform that scales by running on large, shared-nothing commodity computing clusters.
+The ASTERIX effort has been targeting a wide range of semi-structured information, ranging from "data" use cases---where information is well-typed and highly regular---to "content" use cases---where data tends to be irregular, much of each datum may be textual, and the ultimate schema for the various data types involved may be hard to anticipate up front.
+The ASTERIX project has been addressing technical issues including highly scalable data storage and indexing, semi-structured query processing on very large clusters, and merging time-tested parallel database techniques with modern data-intensive computing techniques to support performant yet declarative solutions to the problem of storing and analyzing semi-structured information effectively.
+The first fruits of this labor have been captured in the AsterixDB system that is now being released in preliminary or "Alpha" release form.
+We are hoping that the arrival of AsterixDB will mark the beginning of the "BDMS era", and we hope that both the Big Data community and the database community will find the AsterixDB system to be interesting and useful for a much broader class of problems than can be addressed with any one of today's current Big Data platforms and related technologies (e.g., Hadoop, Pig, Hive, HBase, MongoDB, and so on). One of our project mottos has been "one size fits a bunch"---at least that has been our aim. For more information about the research effort that led to the birth of AsterixDB, please refer to our NSF project web site: [http://asterix.ics.uci.edu/](http://asterix.ics.uci.edu/).
+
+In a nutshell, AsterixDB is a full-function BDMS with a rich feature set that distinguishes it from pretty much any other Big Data platform that's out and available today. We believe that its feature set makes it well-suited to modern needs such as web data warehousing and social data storage and analysis. AsterixDB has:
+
+ * A semistructured NoSQL style data model (ADM) resulting from extending JSON with object database ideas
+ * An expressive and declarative query language (AQL) that supports a broad range of queries and analysis over semistructured data
+ * A parallel runtime query execution engine, Hyracks, that has been scale-tested on up to 1000+ cores and 500+ disks
+ * Partitioned LSM-based data storage and indexing to support efficient ingestion and management of semistructured data
+ * Support for query access to externally stored data (e.g., data in HDFS) as well as to data stored natively by AsterixDB
+ * A rich set of primitive data types, including spatial and temporal data in addition to integer, floating point, and textual data
+ * Secondary indexing options that include B+ trees, R trees, and inverted keyword (exact and fuzzy) index types
+ * Support for fuzzy and spatial queries as well as for more traditional parametric queries
+ * Basic transactional (concurrency and recovery) capabilities akin to those of a NoSQL store
+
+## Getting and Using AsterixDB ##
+
+You are most likely here because you are interested in getting your hands on AsterixDB---so you would like to know how to get it, how to set it up, and how to use it.
+Someday our plan is to have comprehensive documentation for AsterixDB and its data model (ADM) and query language (AQL) here on this wiki.
+For the Alpha release, we've got a start; for the Beta release a month or so from now, we will hopefully have much more.
+The following is a list of the wiki pages and supporting documents that we have available today:
+
+1. [InstallingAsterixUsingManagix](InstallingAsterixUsingManagix.html) :
+This is our installation guide, and it is where you should start.
+This document will tell you how to obtain, install, and manage instances of [AsterixDB](https://asterixdb.googlecode.com/files/asterix-installer-0.0.4-binary-assembly.zip), including both single-machine setup (for developers) as well as cluster installations (for deployment in its intended form).
+
+2. [AdmAql101](AdmAql101.html) :
+This is a first-timers introduction to the user model of the AsterixDB BDMS, by which we mean the view of AsterixDB as seen from the perspective of an "average user" or Big Data application developer.
+The AsterixDB user model consists of its data modeling features (ADM) and its query capabilities (AQL).
+This document presents a tiny "social data warehousing" example and uses it as a backdrop for describing, by example, the key features of AsterixDB.
+By working through this document, you will learn how to define the artifacts needed to manage data in AsterixDB, how to load data into the system, how to use most of the basic features of its query language, and how to insert and delete data dynamically.
+
+3. [AsterixDataTypesAndFunctions](AsterixDataTypesAndFunctions.html) :
+This is a reference document that catalogs the primitive data types and built-in functions available for use in AsterixDB schemas (in ADM) and queries (in AQL).
+
+4. [AQL Reference](AsterixQueryLanguageReference.html) :
+This is the AQL language reference manual.
+
+5. [AsterixDBRestAPI](AsterixDBRestAPI.html) :
+Access to data in an AsterixDB instance is provided via a REST-based API.
+This is a short document that describes the REST API entry points and their URL syntax.
+
+To all who have now come this far: Thanks for your interest in AsterixDB, and for kicking its tires in its Alpha form
+In addition to getting the system and trying it out, please sign up as a member of the AsterixDB user mailing list (asterixdb-users (at) googlegroups.com) so that you can contact us easily with your questions, issues, and other feedback.
+We want AsterixDB to be a "big hit" some day, and we are anxious to see what users do with it and to learn from that feedback what we should be working on most urgently in the next phase of the project.
diff --git a/asterix-doc/src/site/site.xml b/asterix-doc/src/site/site.xml
index 6724153..4953eb4 100644
--- a/asterix-doc/src/site/site.xml
+++ b/asterix-doc/src/site/site.xml
@@ -29,7 +29,6 @@
</links>
<menu name="Documentation">
- <item name="AsterixDB: A Big Data Management System" href="AsterixAlphaRelease.html"/>
<item name="Installing Asterix using Managix" href="InstallingAsterixUsingManagix.html"/>
<item name="AsterixDB 101: An ADM and AQL Primer" href="AdmAql101.html"/>
<item name="Asterix Data Model (ADM)" href="AsterixDBDataModel.html"/>
@@ -38,7 +37,6 @@
<item name="AsterixDB Support of Similarity Queries" href="AsterixSimilarityQueries.html"/>
<item name="Accessing External Data in AsterixDB" href="AccessingExternalDataInAsterixDB.html"/>
<item name="REST API to AsterixDB" href="AsterixDBRestAPI.html"/>
- <item name="(old AQL doc)" href="AsterixQueryLanguage.html"/>
</menu>
<menu ref="reports"/>
diff --git a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/AlterCommand.java b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/AlterCommand.java
index 814f3c9..32918a7 100644
--- a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/AlterCommand.java
+++ b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/AlterCommand.java
@@ -30,7 +30,7 @@
@Override
protected void execCommand() throws Exception {
- InstallerDriver.initConfig();
+ InstallerDriver.initConfig(true);
String instanceName = ((AlterConfig) config).name;
InstallerUtil.validateAsterixInstanceExists(instanceName, State.INACTIVE);
ILookupService lookupService = ServiceProvider.INSTANCE.getLookupService();
diff --git a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/BackupCommand.java b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/BackupCommand.java
index 261de22..a0014f6 100644
--- a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/BackupCommand.java
+++ b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/BackupCommand.java
@@ -35,7 +35,7 @@
@Override
protected void execCommand() throws Exception {
- InstallerDriver.initConfig();
+ InstallerDriver.initConfig(true);
String asterixInstanceName = ((BackupConfig) config).name;
AsterixInstance instance = InstallerUtil.validateAsterixInstanceExists(asterixInstanceName, State.INACTIVE);
List<BackupInfo> backupInfo = instance.getBackupInfo();
diff --git a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/CreateCommand.java b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/CreateCommand.java
index 01a409e..a99b530 100644
--- a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/CreateCommand.java
+++ b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/CreateCommand.java
@@ -39,7 +39,7 @@
@Override
protected void execCommand() throws Exception {
- InstallerDriver.initConfig();
+ InstallerDriver.initConfig(true);
ValidateCommand validateCommand = new ValidateCommand();
boolean valid = validateCommand.validateCluster(((CreateConfig) config).clusterPath);
if (!valid) {
diff --git a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/DeleteCommand.java b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/DeleteCommand.java
index 2279d8f..4c2bb09 100644
--- a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/DeleteCommand.java
+++ b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/DeleteCommand.java
@@ -28,7 +28,7 @@
@Override
protected void execCommand() throws Exception {
- InstallerDriver.initConfig();
+ InstallerDriver.initConfig(true);
String asterixInstanceName = ((DeleteConfig) config).name;
AsterixInstance instance = InstallerUtil.validateAsterixInstanceExists(asterixInstanceName, State.INACTIVE);
PatternCreator pc = new PatternCreator();
diff --git a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/DescribeCommand.java b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/DescribeCommand.java
index 9306a56..66c6e77 100644
--- a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/DescribeCommand.java
+++ b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/DescribeCommand.java
@@ -31,7 +31,7 @@
@Override
protected void execCommand() throws Exception {
- InstallerDriver.initConfig();
+ InstallerDriver.initConfig(true);
String asterixInstanceName = ((DescribeConfig) config).name;
boolean adminView = ((DescribeConfig) config).admin;
if (asterixInstanceName != null) {
diff --git a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/RestoreCommand.java b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/RestoreCommand.java
index 9ef925a..d4d9de3 100644
--- a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/RestoreCommand.java
+++ b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/RestoreCommand.java
@@ -30,7 +30,7 @@
@Override
protected void execCommand() throws Exception {
- InstallerDriver.initConfig();
+ InstallerDriver.initConfig(true);
String asterixInstanceName = ((RestoreConfig) config).name;
AsterixInstance instance = InstallerUtil.validateAsterixInstanceExists(asterixInstanceName, State.INACTIVE);
int backupId = ((RestoreConfig) config).backupId;
diff --git a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/ShutdownCommand.java b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/ShutdownCommand.java
index b9dd23d..f38184d 100644
--- a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/ShutdownCommand.java
+++ b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/ShutdownCommand.java
@@ -22,7 +22,7 @@
@Override
protected void execCommand() throws Exception {
- InstallerDriver.initConfig();
+ InstallerDriver.initConfig(false);
ILookupService lookupService = ServiceProvider.INSTANCE.getLookupService();
lookupService.stopService(InstallerDriver.getConfiguration());
}
diff --git a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/StartCommand.java b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/StartCommand.java
index 1180a4e..9d3cb64 100644
--- a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/StartCommand.java
+++ b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/StartCommand.java
@@ -33,7 +33,7 @@
@Override
protected void execCommand() throws Exception {
- InstallerDriver.initConfig();
+ InstallerDriver.initConfig(true);
String asterixInstanceName = ((StartConfig) config).name;
AsterixInstance instance = InstallerUtil.validateAsterixInstanceExists(asterixInstanceName, State.INACTIVE);
InstallerUtil.createAsterixZip(instance);
diff --git a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/StopCommand.java b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/StopCommand.java
index dfd8c5e..f78cfbc 100644
--- a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/StopCommand.java
+++ b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/command/StopCommand.java
@@ -35,7 +35,7 @@
@Override
protected void execCommand() throws Exception {
- InstallerDriver.initConfig();
+ InstallerDriver.initConfig(true);
String asterixInstanceName = ((StopConfig) config).name;
AsterixInstance asterixInstance = InstallerUtil.validateAsterixInstanceExists(asterixInstanceName,
State.ACTIVE, State.UNUSABLE);
diff --git a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/driver/InstallerDriver.java b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/driver/InstallerDriver.java
index 08249ee..a9ab53b 100644
--- a/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/driver/InstallerDriver.java
+++ b/asterix-installer/src/main/java/edu/uci/ics/asterix/installer/driver/InstallerDriver.java
@@ -55,7 +55,7 @@
return conf;
}
- public static void initConfig() throws Exception {
+ public static void initConfig(boolean ensureLookupServiceIsRunning) throws Exception {
File configFile = new File(managixHome + File.separator + MANAGIX_CONF_XML);
JAXBContext configCtx = JAXBContext.newInstance(Configuration.class);
Unmarshaller unmarshaller = configCtx.createUnmarshaller();
@@ -63,7 +63,7 @@
asterixZip = initBinary("asterix-server");
ILookupService lookupService = ServiceProvider.INSTANCE.getLookupService();
- if (!lookupService.isRunning(conf)) {
+ if (ensureLookupServiceIsRunning && !lookupService.isRunning(conf)) {
lookupService.startService(conf);
}
}
diff --git a/asterix-installer/src/test/java/edu/uci/ics/asterix/installer/test/AsterixInstallerIntegrationUtil.java b/asterix-installer/src/test/java/edu/uci/ics/asterix/installer/test/AsterixInstallerIntegrationUtil.java
index dc6f643..c7beb28 100644
--- a/asterix-installer/src/test/java/edu/uci/ics/asterix/installer/test/AsterixInstallerIntegrationUtil.java
+++ b/asterix-installer/src/test/java/edu/uci/ics/asterix/installer/test/AsterixInstallerIntegrationUtil.java
@@ -87,7 +87,7 @@
cmdHandler.processCommand(command.split(" "));
startZookeeper();
- InstallerDriver.initConfig();
+ InstallerDriver.initConfig(true);
createInstance();
hcc = new HyracksConnection(CC_IP_ADDRESS, DEFAULT_HYRACKS_CC_CLIENT_PORT);
}