Repository: incubator-rya Updated Branches: refs/heads/master b5a0164f0 -> 770bd7e4a
RYA-446 Daemonifying Query Manager Project: http://git-wip-us.apache.org/repos/asf/incubator-rya/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-rya/commit/5b489dc0 Tree: http://git-wip-us.apache.org/repos/asf/incubator-rya/tree/5b489dc0 Diff: http://git-wip-us.apache.org/repos/asf/incubator-rya/diff/5b489dc0 Branch: refs/heads/master Commit: 5b489dc0b6fb95ee9cd738cf2536c959ff09171e Parents: b5a0164 Author: Andrew Smith <[email protected]> Authored: Tue Jan 16 12:39:34 2018 -0500 Committer: Valiyil <[email protected]> Committed: Fri Mar 9 12:59:32 2018 -0500 ---------------------------------------------------------------------- extras/rya.streams/pom.xml | 1 + extras/rya.streams/query-manager/pom.xml | 74 ++++++++++++++++++++ .../querymanager/QueryManagerDaemon.java | 49 +++++++++++++ pom.xml | 5 ++ 4 files changed, 129 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-rya/blob/5b489dc0/extras/rya.streams/pom.xml ---------------------------------------------------------------------- diff --git a/extras/rya.streams/pom.xml b/extras/rya.streams/pom.xml index 51c7cd8..810af54 100644 --- a/extras/rya.streams/pom.xml +++ b/extras/rya.streams/pom.xml @@ -39,6 +39,7 @@ <module>api</module> <module>client</module> <module>integration</module> + <module>query-manager</module> </modules> <profiles> http://git-wip-us.apache.org/repos/asf/incubator-rya/blob/5b489dc0/extras/rya.streams/query-manager/pom.xml ---------------------------------------------------------------------- diff --git a/extras/rya.streams/query-manager/pom.xml b/extras/rya.streams/query-manager/pom.xml new file mode 100644 index 0000000..3a13c6a --- /dev/null +++ b/extras/rya.streams/query-manager/pom.xml @@ -0,0 +1,74 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- +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. +--> +<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> + + <parent> + <groupId>org.apache.rya</groupId> + <artifactId>rya.streams.parent</artifactId> + <version>3.2.12-incubating-SNAPSHOT</version> + </parent> + + <modelVersion>4.0.0</modelVersion> + <artifactId>rya.streams.query-manager</artifactId> + + <name>Apache Rya Streams Query Manager</name> + <description> + This module contains the Rya Streams Query Manager. + </description> + + <dependencies> + <!-- Rya dependencies --> + <dependency> + <groupId>org.apache.rya</groupId> + <artifactId>rya.streams.client</artifactId> + </dependency> + + <!-- Apache Daemon dependencies --> + <dependency> + <groupId>commons-daemon</groupId> + <artifactId>commons-daemon</artifactId> + <version>1.1.0</version> + </dependency> + </dependencies> + <build> + <plugins> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-shade-plugin</artifactId> + <executions> + <execution> + <phase>package</phase> + <goals> + <goal>shade</goal> + </goals> + <configuration> + <transformers> + <transformer implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer"> + <mainClass>org.apache.rya.streams.querymanager.QueryManagerDaemon</mainClass> + </transformer> + <transformer implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer" /> + </transformers> + </configuration> + </execution> + </executions> + </plugin> + </plugins> + </build> +</project> http://git-wip-us.apache.org/repos/asf/incubator-rya/blob/5b489dc0/extras/rya.streams/query-manager/src/main/java/org/apache/rya/streams/querymanager/QueryManagerDaemon.java ---------------------------------------------------------------------- diff --git a/extras/rya.streams/query-manager/src/main/java/org/apache/rya/streams/querymanager/QueryManagerDaemon.java b/extras/rya.streams/query-manager/src/main/java/org/apache/rya/streams/querymanager/QueryManagerDaemon.java new file mode 100644 index 0000000..2ab0ad8 --- /dev/null +++ b/extras/rya.streams/query-manager/src/main/java/org/apache/rya/streams/querymanager/QueryManagerDaemon.java @@ -0,0 +1,49 @@ +/* + * 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 org.apache.rya.streams.querymanager; + +import org.apache.commons.daemon.Daemon; +import org.apache.commons.daemon.DaemonContext; +import org.apache.commons.daemon.DaemonInitException; + +import edu.umd.cs.findbugs.annotations.DefaultAnnotation; +import edu.umd.cs.findbugs.annotations.NonNull; + +@DefaultAnnotation(NonNull.class) +public class QueryManagerDaemon implements Daemon { + @Override + public void init(final DaemonContext context) throws DaemonInitException, Exception { + System.out.println("Initializing Query Manager Daemon."); + } + + @Override + public void start() throws Exception { + System.out.println("Starting Query Manager Daemon."); + } + + @Override + public void stop() throws Exception { + System.out.println("Stopping Query Manager Daemon."); + } + + @Override + public void destroy() { + System.out.println("Query Manager Daemon Destroyed."); + } +} \ No newline at end of file http://git-wip-us.apache.org/repos/asf/incubator-rya/blob/5b489dc0/pom.xml ---------------------------------------------------------------------- diff --git a/pom.xml b/pom.xml index 406bf20..532324a 100644 --- a/pom.xml +++ b/pom.xml @@ -404,6 +404,11 @@ under the License. </dependency> <dependency> <groupId>org.apache.rya</groupId> + <artifactId>rya.streams.client</artifactId> + <version>${project.version}</version> + </dependency> + <dependency> + <groupId>org.apache.rya</groupId> <artifactId>rya.streams.kafka</artifactId> <version>${project.version}</version> </dependency>
