Skip to content

Commit

Permalink
add maven deploy setup
Browse files Browse the repository at this point in the history
  • Loading branch information
fritzprix committed Apr 28, 2019
1 parent 5534c05 commit 8071d95
Show file tree
Hide file tree
Showing 4 changed files with 60 additions and 17 deletions.
26 changes: 26 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,31 @@ more vulnerable to DNS poisoning. so here I propose another alternative for the
> By sending concurrent DNS query to multiple DNS provider other than system default and accepting response which arrives first can provide guarantee on max response time

## Using Gradle
1. Add Repository
```groovy
allprojects {
repositories {
...
maven {
url 'https://raw.githubusercontent.com/fritzprix/robust-dns/releases'
}
maven {
url 'https://raw.githubusercontent.com/fritzprix/robust-dns/snapshots'
}
...
}
}
```
2. Add Dependency
```groovy
dependencies {
...
implementation 'com.doodream:robust-dns:1.0.0'
implementation 'dnsjava:dnsjava:2.1.8'
...
}
```

## dependencies
- dnsjava
47 changes: 32 additions & 15 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,14 @@

<groupId>com.doodream</groupId>
<artifactId>robust-dns</artifactId>
<version>1.0.0-SNAPSHOT</version>
<version>1.0.0</version>
<packaging>jar</packaging>


<name>robust-dns</name>
<description>DNS library for Java</description>
<url></url>

<profiles>
<profile>
<id>debug</id>
Expand All @@ -18,6 +23,23 @@
</profile>
</profiles>

<distributionManagement>
<repository>
<id>robust-dns</id>
<name>robust-dns</name>
<url>git:releases://git@github.com:fritzprix/robust-dns.git</url>
</repository>
<snapshotRepository>
<id>robust-dns</id>
<name>robust-dns</name>
<url>git:snapshots://git@github.com:fritzprix/robust-dns.git</url>
</snapshotRepository>
<site>
<id>robust-dns</id>
<url>git:site://git@github.com:fritzprix/robust-dns.git</url>
</site>
</distributionManagement>

<!-- start of wagon-git plugin configuration-->
<pluginRepositories>
<pluginRepository>
Expand All @@ -32,6 +54,7 @@
<slf4j_version>1.7.25</slf4j_version>
<gson_version>2.8.5</gson_version>
<maven.repository>maven_repository</maven.repository>
<github.global.server>github</github.global.server>
</properties>

<licenses>
Expand All @@ -41,15 +64,15 @@
<distribution>repo</distribution>
</license>
</licenses>

<!-- https://github.com/fritzprix/robust-dns.git-->
<build>
<!-- <extensions>-->
<!-- <extension>-->
<!-- <groupId>ar.com.synergian</groupId>-->
<!-- <artifactId>wagon-git</artifactId>-->
<!-- <version>0.3.1</version>-->
<!-- </extension>-->
<!-- </extensions>-->
<extensions>
<extension>
<groupId>ar.com.synergian</groupId>
<artifactId>wagon-git</artifactId>
<version>0.2.5</version>
</extension>
</extensions>
<resources>
<resource>
<directory>src/main/resources</directory>
Expand Down Expand Up @@ -109,17 +132,11 @@
<artifactId>rxjava</artifactId>
<version>${rxjava_version}</version>
</dependency>
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<version>${lombok_version}</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>${slf4j_version}</version>
</dependency>

<dependency>
<groupId>dnsjava</groupId>
<artifactId>dnsjava</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,6 @@ public void handleException(Object o, Exception e) {
}
});
}
}).subscribeOn(Schedulers.io());
}).timeout(10L, TimeUnit.SECONDS).subscribeOn(Schedulers.io());
}
}
2 changes: 1 addition & 1 deletion src/test/java/com/doodream/robustdns/DnsAgingTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public DnsAgingTest() throws Exception {
}

@Test(timeout = 5000L)
public void test_lookup() throws Exception{
public void test_lookup() throws Exception {
System.out.println(resolver.resolve("www.google.com").blockingGet());
}
}

0 comments on commit 8071d95

Please sign in to comment.