Skip to content
This repository has been archived by the owner on May 23, 2023. It is now read-only.

Add nullable annotation to Tracer#extract #284

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions opentracing-api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,17 @@
<main.basedir>${project.basedir}/..</main.basedir>
<main.java.version>1.6</main.java.version>
<main.signature.artifact>java16</main.signature.artifact>
<findbugs.jsr305.version>3.0.2</findbugs.jsr305.version>
</properties>

<dependencies>
<dependency>
<groupId>com.google.code.findbugs</groupId>
<artifactId>jsr305</artifactId>
<optional>true</optional><!-- needed only for annotations -->
</dependency>
</dependencies>

<build>
<plugins>
<plugin>
Expand Down
3 changes: 3 additions & 0 deletions opentracing-api/src/main/java/io/opentracing/Tracer.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@

import io.opentracing.propagation.Format;

import javax.annotation.Nullable;

/**
* Tracer is a simple, thin interface for Span creation and propagation across arbitrary transports.
*/
Expand Down Expand Up @@ -103,6 +105,7 @@ public interface Tracer {
* @see io.opentracing.propagation.Format
* @see io.opentracing.propagation.Format.Builtin
*/
@Nullable
<C> SpanContext extract(Format<C> format, C carrier);


Expand Down
8 changes: 8 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@
<mockito.version>1.10.19</mockito.version>
<awaitility.version>3.0.0</awaitility.version>
<logback.version>1.2.3</logback.version>
<findbugs-jsr305.version>3.0.2</findbugs-jsr305.version>

<animal-sniffer-maven-plugin.version>1.15</animal-sniffer-maven-plugin.version>
<coveralls-maven-plugin.version>4.3.0</coveralls-maven-plugin.version>
Expand Down Expand Up @@ -164,6 +165,13 @@
<artifactId>mockito-all</artifactId>
<version>${mockito.version}</version>
</dependency>

<dependency>
<groupId>com.google.code.findbugs</groupId>
<artifactId>jsr305</artifactId>
<version>${findbugs-jsr305.version}</version>
<optional>true</optional><!-- needed only for annotations -->
</dependency>
</dependencies>
</dependencyManagement>

Expand Down