asterixdb git commit: Remove some broken links to the old AsterixDB site.
Repository: asterixdb Updated Branches: refs/heads/master 99fed93d0 -> 337966976 Remove some broken links to the old AsterixDB site. Change-Id: I54e42c3ecca6e4b002dec1f4922b7255b5a49593 Reviewed-on: https://asterix-gerrit.ics.uci.edu/1499 Reviewed-by: Yingyi BuSonar-Qube: Jenkins Tested-by: Jenkins Project: http://git-wip-us.apache.org/repos/asf/asterixdb/repo Commit: http://git-wip-us.apache.org/repos/asf/asterixdb/commit/33796697 Tree: http://git-wip-us.apache.org/repos/asf/asterixdb/tree/33796697 Diff: http://git-wip-us.apache.org/repos/asf/asterixdb/diff/33796697 Branch: refs/heads/master Commit: 337966976e5859996be830976f4fc1c300730a26 Parents: 99fed93 Author: Cameron Samak Authored: Sat Feb 11 01:05:42 2017 + Committer: Cameron Samak Committed: Fri Feb 10 17:54:58 2017 -0800 -- asterixdb/asterix-doc/src/site/markdown/install.md | 4 ++-- asterixdb/asterix-doc/src/site/markdown/overview.md | 2 +- asterixdb/asterix-doc/src/site/markdown/yarn.md | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) -- http://git-wip-us.apache.org/repos/asf/asterixdb/blob/33796697/asterixdb/asterix-doc/src/site/markdown/install.md -- diff --git a/asterixdb/asterix-doc/src/site/markdown/install.md b/asterixdb/asterix-doc/src/site/markdown/install.md index 888d4d3..fd86023 100644 --- a/asterixdb/asterix-doc/src/site/markdown/install.md +++ b/asterixdb/asterix-doc/src/site/markdown/install.md @@ -195,7 +195,7 @@ Execute 'exit' to close the session. Connection to 127.0.0.1 closed. ### Configuring Managix ### -You will need the AsterixDB installer (a.k.a. Managix). Download Managix from [here](http://asterixdb.ics.uci.edu/download.html); this includes the bits for Managix as well as AsterixDB. +You will need the AsterixDB installer (a.k.a. Managix). Download the Standalone Cluster installer from [here](https://asterixdb.apache.org/download.html); this includes the bits for Managix as well as AsterixDB. To be able to create an AsterixDB instance and manage its lifecycle, the Managix requires you to configure a set of configuration files namely: @@ -445,7 +445,7 @@ Then run the following step again and type "yes" if prompted: ### Step (2): Define the AsterixDB cluster ### -We first log into the master machine as the user "joe". On this machine, download Managix from [here](http://asterixdb.ics.uci.edu/download.html) (save as above), then do the following steps similar to the single-machine case described above: +We first log into the master machine as the user "joe". On this machine, download the Standalone Cluster installer from [here](https://asterixdb.apache.org/download.html) (save as above), then do the following steps similar to the single-machine case described above: machineA> cd ~ machineA> mkdir asterix-mgmt http://git-wip-us.apache.org/repos/asf/asterixdb/blob/33796697/asterixdb/asterix-doc/src/site/markdown/overview.md -- diff --git a/asterixdb/asterix-doc/src/site/markdown/overview.md b/asterixdb/asterix-doc/src/site/markdown/overview.md index edf98bb..d0f2e73 100644 --- a/asterixdb/asterix-doc/src/site/markdown/overview.md +++ b/asterixdb/asterix-doc/src/site/markdown/overview.md @@ -44,7 +44,7 @@ The following is a list of the supporting documents that we have available today 1. [Installing AsterixDB using Managix](install.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](http://asterixdb.ics.uci.edu/download.html), including both single-machine setup (for developers) as well as cluster installations (for deployment in its intended form). +This document will tell you how to obtain, install, and manage instances of [AsterixDB](https://asterixdb.apache.org/download.html), including both single-machine setup (for developers) as well as cluster installations (for deployment in its intended form). 2. [AsterixDB 101: An ADM and AQL Primer](aql/primer.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. http://git-wip-us.apache.org/repos/asf/asterixdb/blob/33796697/asterixdb/asterix-doc/src/site/markdown/yarn.md -- diff --git a/asterixdb/asterix-doc/src/site/markdown/yarn.md b/asterixdb/asterix-doc/src/site/markdown/yarn.md index 84bea89..787a4c8 100644 ---
asterixdb git commit: Add necesasary plugins for simple release method
Repository: asterixdb Updated Branches: refs/heads/master c229da657 -> 99fed93d0 Add necesasary plugins for simple release method Change-Id: I8768ff760235f2f7f0c33d5af633bcdefa0b51e5 Reviewed-on: https://asterix-gerrit.ics.uci.edu/1493 Sonar-Qube: JenkinsTested-by: Jenkins BAD: Jenkins Integration-Tests: Jenkins Reviewed-by: Michael Blow Project: http://git-wip-us.apache.org/repos/asf/asterixdb/repo Commit: http://git-wip-us.apache.org/repos/asf/asterixdb/commit/99fed93d Tree: http://git-wip-us.apache.org/repos/asf/asterixdb/tree/99fed93d Diff: http://git-wip-us.apache.org/repos/asf/asterixdb/diff/99fed93d Branch: refs/heads/master Commit: 99fed93d0c64fe68c3e0fbd9555b1917696ee991 Parents: c229da6 Author: Ian Maxon Authored: Thu Feb 9 19:11:39 2017 -0800 Committer: Ian Maxon Committed: Fri Feb 10 11:24:00 2017 -0800 -- asterixdb/pom.xml | 31 +++ hyracks-fullstack/pom.xml | 37 - 2 files changed, 47 insertions(+), 21 deletions(-) -- http://git-wip-us.apache.org/repos/asf/asterixdb/blob/99fed93d/asterixdb/pom.xml -- diff --git a/asterixdb/pom.xml b/asterixdb/pom.xml index c684539..57488bc 100644 --- a/asterixdb/pom.xml +++ b/asterixdb/pom.xml @@ -406,6 +406,16 @@ + +org.codehaus.mojo +versions-maven-plugin +2.1 + + +org.apache.maven.plugins +maven-scm-plugin +1.9.5 + @@ -521,6 +531,27 @@ + release + + + +org.apache.maven.plugins +maven-gpg-plugin +1.6 + + +sign-artifacts +verify + + sign + + + + + + + + java8 1.8 http://git-wip-us.apache.org/repos/asf/asterixdb/blob/99fed93d/hyracks-fullstack/pom.xml -- diff --git a/hyracks-fullstack/pom.xml b/hyracks-fullstack/pom.xml index 2c078c4..5ddbf92 100644 --- a/hyracks-fullstack/pom.xml +++ b/hyracks-fullstack/pom.xml @@ -395,6 +395,16 @@ + +org.codehaus.mojo +versions-maven-plugin +2.1 + + +org.apache.maven.plugins +maven-scm-plugin +1.9.5 + @@ -407,35 +417,20 @@ - asterix-release - - - src/main/assembly/source.xml - - + release org.apache.maven.plugins -maven-assembly-plugin - +maven-gpg-plugin +1.6 - -source-release-assembly -package +sign-artifacts +verify - single + sign - - - -src/main/assembly/source.xml - -
asterixdb git commit: Debian Packaging for NCService
Repository: asterixdb Updated Branches: refs/heads/master 392bbbc00 -> c229da657 Debian Packaging for NCService Change-Id: I1b5d0895ed5a34700d4e2f666715b857ce275127 Reviewed-on: https://asterix-gerrit.ics.uci.edu/1492 Sonar-Qube: JenkinsTested-by: Jenkins BAD: Jenkins Integration-Tests: Jenkins Reviewed-by: Michael Blow Project: http://git-wip-us.apache.org/repos/asf/asterixdb/repo Commit: http://git-wip-us.apache.org/repos/asf/asterixdb/commit/c229da65 Tree: http://git-wip-us.apache.org/repos/asf/asterixdb/tree/c229da65 Diff: http://git-wip-us.apache.org/repos/asf/asterixdb/diff/c229da65 Branch: refs/heads/master Commit: c229da6576b1d280857cf64dab078842dad2 Parents: 392bbbc Author: Ian Maxon Authored: Thu Feb 9 09:52:25 2017 -0800 Committer: Ian Maxon Committed: Fri Feb 10 11:17:36 2017 -0800 -- asterixdb/asterix-server/pom.xml| 60 .../asterix-server/src/deb/control/control | 24 .../asterix-server/src/deb/control/postinst | 17 ++ asterixdb/asterix-server/src/deb/control/postrm | 15 + .../asterix-server/src/deb/control/preinst | 15 + asterixdb/asterix-server/src/deb/control/prerm | 15 + .../src/deb/systemd/asterix-cc.service | 26 + .../src/deb/systemd/asterix-nc.service | 26 + 8 files changed, 198 insertions(+) -- http://git-wip-us.apache.org/repos/asf/asterixdb/blob/c229da65/asterixdb/asterix-server/pom.xml -- diff --git a/asterixdb/asterix-server/pom.xml b/asterixdb/asterix-server/pom.xml index f91ed64..7d74903 100644 --- a/asterixdb/asterix-server/pom.xml +++ b/asterixdb/asterix-server/pom.xml @@ -343,6 +343,66 @@ +jdeb +org.vafer +1.5 + + +package + + jdeb + + + + + ${project.build.directory}/${project.build.finalName}-binary-assembly/ + bin/** + directory + +perm +/opt/apache-asterixdb/ +asterixdb +asterixdb +644 + + + + ${project.build.directory}/${project.build.finalName}-binary-assembly/bin + directory + +perm +/opt/apache-asterixdb/bin +asterixdb +asterixdb +754 + + + + file + src/deb/systemd/asterix-cc.service + + /lib/systemd/system + perm + root + root + + + + file + src/deb/systemd/asterix-nc.service + + /lib/systemd/system + perm + root + root + + + + + + + + org.apache.maven.plugins maven-dependency-plugin 2.10 http://git-wip-us.apache.org/repos/asf/asterixdb/blob/c229da65/asterixdb/asterix-server/src/deb/control/control -- diff --git a/asterixdb/asterix-server/src/deb/control/control b/asterixdb/asterix-server/src/deb/control/control new file mode 100644 index 000..1f6c213 --- /dev/null +++ b/asterixdb/asterix-server/src/deb/control/control @@ -0,0 +1,24 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +Package: apache-asterixdb-server +Version:
[2/4] asterixdb git commit: Fix async result delivery
http://git-wip-us.apache.org/repos/asf/asterixdb/blob/392bbbc0/asterixdb/asterix-common/src/test/java/org/apache/asterix/test/aql/TestExecutor.java -- diff --git a/asterixdb/asterix-common/src/test/java/org/apache/asterix/test/aql/TestExecutor.java b/asterixdb/asterix-common/src/test/java/org/apache/asterix/test/aql/TestExecutor.java index ff30df3..b5fbcf5 100644 --- a/asterixdb/asterix-common/src/test/java/org/apache/asterix/test/aql/TestExecutor.java +++ b/asterixdb/asterix-common/src/test/java/org/apache/asterix/test/aql/TestExecutor.java @@ -32,12 +32,15 @@ import java.io.StringWriter; import java.lang.reflect.InvocationTargetException; import java.lang.reflect.Method; import java.net.Inet4Address; +import java.net.URI; +import java.net.URISyntaxException; import java.nio.charset.StandardCharsets; import java.util.ArrayList; import java.util.Arrays; import java.util.HashMap; import java.util.HashSet; import java.util.List; +import java.util.Map; import java.util.Set; import java.util.concurrent.Executors; import java.util.concurrent.Future; @@ -72,6 +75,7 @@ import org.apache.http.impl.client.HttpClients; import org.apache.http.impl.client.StandardHttpRequestRetryHandler; import org.apache.http.util.EntityUtils; import org.apache.hyracks.util.StorageUtil; +import org.junit.Assert; import com.fasterxml.jackson.core.JsonProcessingException; import com.fasterxml.jackson.databind.DeserializationFeature; @@ -91,12 +95,21 @@ public class TestExecutor { private static final long MAX_URL_LENGTH = 2000l; private static final Pattern JAVA_BLOCK_COMMENT_PATTERN = Pattern.compile("/\\*.*\\*/", Pattern.MULTILINE | Pattern.DOTALL); +private static final Pattern JAVA_LINE_COMMENT_PATTERN = Pattern.compile("//.*$", Pattern.MULTILINE); +private static final Pattern SHELL_LINE_COMMENT_PATTERN = Pattern.compile("#.*$", Pattern.MULTILINE); private static final Pattern REGEX_LINES_PATTERN = Pattern.compile("^(-)?/(.*)/([im]*)$"); private static final Pattern POLL_TIMEOUT_PATTERN = Pattern.compile("polltimeoutsecs=(\\d+)(\\D|$)", Pattern.MULTILINE); private static final Pattern POLL_DELAY_PATTERN = Pattern.compile("polldelaysecs=(\\d+)(\\D|$)", Pattern.MULTILINE); +private static final Pattern HANDLE_VARIABLE_PATTERN = Pattern.compile("handlevariable=(\\w+)"); +private static final Pattern VARIABLE_REF_PATTERN = Pattern.compile("\\$(\\w+)"); + public static final int TRUNCATE_THRESHOLD = 16384; +public static final String DELIVERY_ASYNC = "async"; +public static final String DELIVERY_DEFERRED = "deferred"; +public static final String DELIVERY_IMMEDIATE = "immediate"; + private static Method managixExecuteMethod = null; private static final HashMaprunningTestServers = new HashMap<>(); @@ -376,8 +389,13 @@ public class TestExecutor { // For tests where you simply want the byte-for-byte output. private static void writeOutputToFile(File actualFile, InputStream resultStream) throws Exception { -if (!actualFile.getParentFile().mkdirs()) { -LOGGER.warning("Unable to create actual file parent dir: " + actualFile.getParentFile()); +final File parentDir = actualFile.getParentFile(); +if (!parentDir.isDirectory()) { +if (parentDir.exists()) { +LOGGER.warning("Actual file parent \"" + parentDir + "\" exists but is not a directory"); +} else if (!parentDir.mkdirs()) { +LOGGER.warning("Unable to create actual file parent dir: " + parentDir); +} } try (FileOutputStream out = new FileOutputStream(actualFile)) { IOUtils.copy(resultStream, out); @@ -424,38 +442,30 @@ public class TestExecutor { return httpResponse; } -public InputStream executeQuery(String str, OutputFormat fmt, String url, List params) +public InputStream executeQuery(String str, OutputFormat fmt, URI uri, List params) throws Exception { -HttpUriRequest method = constructHttpMethod(str, url, "query", false, params); +HttpUriRequest method = constructHttpMethod(str, uri, "query", false, params); // Set accepted output response type method.setHeader("Accept", fmt.mimeType()); HttpResponse response = executeAndCheckHttpRequest(method); return response.getEntity().getContent(); } -public InputStream executeQueryService(String str, String url) throws Exception { -return executeQueryService(str, OutputFormat.CLEAN_JSON, url, new ArrayList<>(), false); +public InputStream executeQueryService(String str, URI uri) throws Exception { +return executeQueryService(str, OutputFormat.CLEAN_JSON, uri, new ArrayList<>(), false); } -public InputStream executeQueryService(String str,
[1/4] asterixdb git commit: Fix async result delivery
Repository: asterixdb Updated Branches: refs/heads/master 19e0c22a8 -> 392bbbc00 http://git-wip-us.apache.org/repos/asf/asterixdb/blob/392bbbc0/hyracks-fullstack/hyracks/hyracks-control/hyracks-control-nc/src/main/java/org/apache/hyracks/control/nc/dataset/DatasetPartitionManager.java -- diff --git a/hyracks-fullstack/hyracks/hyracks-control/hyracks-control-nc/src/main/java/org/apache/hyracks/control/nc/dataset/DatasetPartitionManager.java b/hyracks-fullstack/hyracks/hyracks-control/hyracks-control-nc/src/main/java/org/apache/hyracks/control/nc/dataset/DatasetPartitionManager.java index a594f95..5fac823 100644 --- a/hyracks-fullstack/hyracks/hyracks-control/hyracks-control-nc/src/main/java/org/apache/hyracks/control/nc/dataset/DatasetPartitionManager.java +++ b/hyracks-fullstack/hyracks/hyracks-control/hyracks-control-nc/src/main/java/org/apache/hyracks/control/nc/dataset/DatasetPartitionManager.java @@ -18,10 +18,8 @@ */ package org.apache.hyracks.control.nc.dataset; -import java.util.HashMap; import java.util.LinkedHashMap; import java.util.Map; -import java.util.Map.Entry; import java.util.Set; import java.util.concurrent.Executor; import java.util.logging.Logger; @@ -66,29 +64,22 @@ public class DatasetPartitionManager implements IDatasetPartitionManager { datasetMemoryManager = null; } partitionResultStateMap = new LinkedHashMap<>(); -executor.execute(new ResultStateSweeper(this, resultTTL, resultSweepThreshold)); +executor.execute(new ResultStateSweeper(this, resultTTL, resultSweepThreshold, LOGGER)); } @Override public IFrameWriter createDatasetPartitionWriter(IHyracksTaskContext ctx, ResultSetId rsId, boolean orderedResult, boolean asyncMode, int partition, int nPartitions) throws HyracksException { -DatasetPartitionWriter dpw = null; +DatasetPartitionWriter dpw; JobId jobId = ctx.getJobletContext().getJobId(); synchronized (this) { dpw = new DatasetPartitionWriter(ctx, this, jobId, rsId, asyncMode, orderedResult, partition, nPartitions, datasetMemoryManager, fileFactory); -ResultSetMap rsIdMap = (ResultSetMap) partitionResultStateMap.get(jobId); -if (rsIdMap == null) { -rsIdMap = new ResultSetMap(); -partitionResultStateMap.put(jobId, rsIdMap); -} +ResultSetMap rsIdMap = (ResultSetMap) partitionResultStateMap.computeIfAbsent(jobId, +k -> new ResultSetMap()); -ResultState[] resultStates = rsIdMap.get(rsId); -if (resultStates == null) { -resultStates = new ResultState[nPartitions]; -rsIdMap.put(rsId, resultStates); -} +ResultState[] resultStates = rsIdMap.createOrGetResultStates(rsId, nPartitions); resultStates[partition] = dpw.getResultState(); } @@ -141,7 +132,7 @@ public class DatasetPartitionManager implements IDatasetPartitionManager { throw new HyracksException("Unknown JobId " + jobId); } -ResultState[] resultStates = rsIdMap.get(resultSetId); +ResultState[] resultStates = rsIdMap.getResultStates(resultSetId); if (resultStates == null) { throw new HyracksException("Unknown JobId: " + jobId + " ResultSetId: " + resultSetId); } @@ -161,49 +152,16 @@ public class DatasetPartitionManager implements IDatasetPartitionManager { @Override public synchronized void removePartition(JobId jobId, ResultSetId resultSetId, int partition) { ResultSetMap rsIdMap = (ResultSetMap) partitionResultStateMap.get(jobId); -if (rsIdMap != null) { -ResultState[] resultStates = rsIdMap.get(resultSetId); -if (resultStates != null) { -ResultState state = resultStates[partition]; -if (state != null) { -state.closeAndDelete(); -LOGGER.fine("Removing partition: " + partition + " for JobId: " + jobId); -} -resultStates[partition] = null; -boolean stateEmpty = true; -for (int i = 0; i < resultStates.length; i++) { -if (resultStates[i] != null) { -stateEmpty = false; -break; -} -} -if (stateEmpty) { -rsIdMap.remove(resultSetId); -} -} -if (rsIdMap.isEmpty()) { -partitionResultStateMap.remove(jobId); -} +if (rsIdMap != null && rsIdMap.removePartition(jobId, resultSetId, partition)) { +partitionResultStateMap.remove(jobId); } } @Override public