forked from apache/ratis
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge Nicholas's maven change from master
- Loading branch information
Showing
107 changed files
with
1,328 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# raft | ||
A java implementation of Raft protocol for Hadoop ecosystem |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!-- | ||
Licensed 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. See accompanying LICENSE file. | ||
--> | ||
<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"> | ||
<modelVersion>4.0.0</modelVersion> | ||
<parent> | ||
<artifactId>raft-project-dist</artifactId> | ||
<groupId>com.hortonworks.raft</groupId> | ||
<version>1.0-SNAPSHOT</version> | ||
<relativePath>../raft-project-dist</relativePath> | ||
</parent> | ||
|
||
<artifactId>raft-client</artifactId> | ||
<name>Raft Client</name> | ||
|
||
<dependencies> | ||
<dependency> | ||
<artifactId>raft-common</artifactId> | ||
<groupId>com.hortonworks.raft</groupId> | ||
<scope>provided</scope> | ||
</dependency> | ||
|
||
<dependency> | ||
<groupId>org.slf4j</groupId> | ||
<artifactId>slf4j-api</artifactId> | ||
<scope>compile</scope> | ||
</dependency> | ||
|
||
<dependency> | ||
<groupId>com.google.guava</groupId> | ||
<artifactId>guava</artifactId> | ||
<scope>compile</scope> | ||
</dependency> | ||
|
||
<dependency> | ||
<groupId>com.google.protobuf</groupId> | ||
<artifactId>protobuf-java</artifactId> | ||
<scope>compile</scope> | ||
</dependency> | ||
|
||
<dependency> | ||
<groupId>org.apache.hadoop</groupId> | ||
<artifactId>hadoop-common</artifactId> | ||
</dependency> | ||
</dependencies> | ||
|
||
<build> | ||
<plugins> | ||
<plugin> | ||
<artifactId>maven-deploy-plugin</artifactId> | ||
<configuration> | ||
<skip>true</skip> | ||
</configuration> | ||
</plugin> | ||
<plugin> | ||
<groupId>org.apache.rat</groupId> | ||
<artifactId>apache-rat-plugin</artifactId> | ||
<configuration> | ||
</configuration> | ||
</plugin> | ||
</plugins> | ||
</build> | ||
</project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,137 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!-- | ||
Licensed 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. See accompanying LICENSE file. | ||
--> | ||
<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"> | ||
<modelVersion>4.0.0</modelVersion> | ||
<parent> | ||
<artifactId>raft-project-dist</artifactId> | ||
<groupId>com.hortonworks.raft</groupId> | ||
<version>1.0-SNAPSHOT</version> | ||
<relativePath>../raft-project-dist</relativePath> | ||
</parent> | ||
|
||
<artifactId>raft-common</artifactId> | ||
<name>Raft Common</name> | ||
|
||
<dependencies> | ||
<dependency> | ||
<groupId>org.slf4j</groupId> | ||
<artifactId>slf4j-api</artifactId> | ||
</dependency> | ||
|
||
<dependency> | ||
<groupId>com.google.guava</groupId> | ||
<artifactId>guava</artifactId> | ||
</dependency> | ||
|
||
<dependency> | ||
<groupId>com.google.protobuf</groupId> | ||
<artifactId>protobuf-java</artifactId> | ||
<scope>compile</scope> | ||
</dependency> | ||
|
||
<dependency> | ||
<groupId>org.apache.hadoop</groupId> | ||
<artifactId>hadoop-common</artifactId> | ||
</dependency> | ||
</dependencies> | ||
|
||
<build> | ||
<plugins> | ||
<plugin> | ||
<groupId>org.apache.hadoop</groupId> | ||
<artifactId>hadoop-maven-plugins</artifactId> | ||
<executions> | ||
<execution> | ||
<id>version-info</id> | ||
<phase>generate-resources</phase> | ||
<goals> | ||
<goal>version-info</goal> | ||
</goals> | ||
<configuration> | ||
<source> | ||
<directory>${basedir}/src/main</directory> | ||
<includes> | ||
<include>java/**/*.java</include> | ||
<include>proto/**/*.proto</include> | ||
</includes> | ||
</source> | ||
</configuration> | ||
</execution> | ||
<execution> | ||
<id>compile-protoc</id> | ||
<phase>generate-sources</phase> | ||
<goals> | ||
<goal>protoc</goal> | ||
</goals> | ||
<configuration> | ||
<protocVersion>${protobuf.version}</protocVersion> | ||
<protocCommand>${protoc.path}</protocCommand> | ||
<imports> | ||
<param>${basedir}/src/main/proto</param> | ||
</imports> | ||
<source> | ||
<directory>${basedir}/src/main/proto</directory> | ||
<includes> | ||
<include>Raft.proto</include> | ||
<include>RaftClientProtocol.proto</include> | ||
</includes> | ||
</source> | ||
<output>${project.build.directory}/generated-sources/java</output> | ||
</configuration> | ||
</execution> | ||
</executions> | ||
</plugin> | ||
|
||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-antrun-plugin</artifactId> | ||
<executions> | ||
<execution> | ||
<id>create-log-dir</id> | ||
<phase>process-test-resources</phase> | ||
<goals> | ||
<goal>run</goal> | ||
</goals> | ||
<configuration> | ||
<target> | ||
<delete dir="${test.build.data}"/> | ||
<mkdir dir="${test.build.data}"/> | ||
<mkdir dir="${raft.log.dir}"/> | ||
|
||
<copy toDir="${project.build.directory}/test-classes"> | ||
<fileset dir="${basedir}/src/main/conf"/> | ||
</copy> | ||
</target> | ||
</configuration> | ||
</execution> | ||
</executions> | ||
</plugin> | ||
|
||
<plugin> | ||
<groupId>org.apache.rat</groupId> | ||
<artifactId>apache-rat-plugin</artifactId> | ||
<configuration> | ||
<excludes> | ||
<exclude>.idea/**</exclude> | ||
<exclude>src/main/conf/*</exclude> | ||
</excludes> | ||
</configuration> | ||
</plugin> | ||
</plugins> | ||
</build> | ||
|
||
</project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
# 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. | ||
|
||
# Define some default values that can be overridden by system properties | ||
raft.root.logger=INFO,console | ||
raft.log.dir=. | ||
raft.log.file=raft.log | ||
|
||
# Define the root logger to the system property "raft.root.logger". | ||
log4j.rootLogger=${raft.root.logger} | ||
|
||
# Logging Threshold | ||
log4j.threshold=ALL | ||
|
||
# Null Appender | ||
log4j.appender.NullAppender=org.apache.log4j.varia.NullAppender | ||
|
||
# | ||
# Rolling File Appender - cap space usage at 5gb. | ||
# | ||
raft.log.maxfilesize=256MB | ||
raft.log.maxbackupindex=20 | ||
log4j.appender.RFA=org.apache.log4j.RollingFileAppender | ||
log4j.appender.RFA.File=${raft.log.dir}/${raft.log.file} | ||
|
||
log4j.appender.RFA.MaxFileSize=${raft.log.maxfilesize} | ||
log4j.appender.RFA.MaxBackupIndex=${raft.log.maxbackupindex} | ||
|
||
log4j.appender.RFA.layout=org.apache.log4j.PatternLayout | ||
|
||
# Pattern format: Date LogLevel LoggerName LogMessage | ||
log4j.appender.RFA.layout.ConversionPattern=%d{ISO8601} %p %c: %m%n | ||
# Debugging Pattern format | ||
#log4j.appender.RFA.layout.ConversionPattern=%d{ISO8601} %-5p %c{2} (%F:%M(%L)) - %m%n | ||
|
||
|
||
# | ||
# Daily Rolling File Appender | ||
# | ||
log4j.appender.DRFA=org.apache.log4j.DailyRollingFileAppender | ||
log4j.appender.DRFA.File=${raft.log.dir}/${raft.log.file} | ||
|
||
# Rollover at midnight | ||
log4j.appender.DRFA.DatePattern=.yyyy-MM-dd | ||
|
||
log4j.appender.DRFA.layout=org.apache.log4j.PatternLayout | ||
|
||
# Pattern format: Date LogLevel LoggerName LogMessage | ||
log4j.appender.DRFA.layout.ConversionPattern=%d{ISO8601} %p %c: %m%n | ||
# Debugging Pattern format | ||
#log4j.appender.DRFA.layout.ConversionPattern=%d{ISO8601} %-5p %c{2} (%F:%M(%L)) - %m%n | ||
|
||
|
||
# | ||
# console | ||
# Add "console" to rootlogger above if you want to use this | ||
# | ||
log4j.appender.console=org.apache.log4j.ConsoleAppender | ||
log4j.appender.console.target=System.err | ||
log4j.appender.console.layout=org.apache.log4j.PatternLayout | ||
log4j.appender.console.layout.ConversionPattern=%d{yy/MM/dd HH:mm:ss} %p %c{2}: %m%n |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Oops, something went wrong.