aboutsummaryrefslogtreecommitdiffstats
path: root/component
diff options
context:
space:
mode:
authorHarald Musum <musum@verizonmedia.com>2021-04-06 14:19:35 +0200
committerGitHub <noreply@github.com>2021-04-06 14:19:35 +0200
commit778894b29b13831115c19ff13285541a10ab2d30 (patch)
tree62ea7aa8689a3d5421f54cd0ac6c5290e82f23dc /component
parent5df00bb90a04082847440716bcb6146bdda0ca06 (diff)
Revert "Gjoranv/merge di into core (rebased)"
Diffstat (limited to 'component')
-rw-r--r--component/CMakeLists.txt2
-rw-r--r--component/abi-spec.json15
-rwxr-xr-xcomponent/pom.xml7
-rw-r--r--component/src/main/java/com/yahoo/container/di/componentgraph/Provider.java26
-rw-r--r--component/src/main/java/com/yahoo/container/di/componentgraph/package-info.java12
5 files changed, 8 insertions, 54 deletions
diff --git a/component/CMakeLists.txt b/component/CMakeLists.txt
new file mode 100644
index 00000000000..87d0a4989ba
--- /dev/null
+++ b/component/CMakeLists.txt
@@ -0,0 +1,2 @@
+# Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
+install_fat_java_artifact(component)
diff --git a/component/abi-spec.json b/component/abi-spec.json
index 0e33fde3c5a..2dfa3e0d71d 100644
--- a/component/abi-spec.json
+++ b/component/abi-spec.json
@@ -348,20 +348,5 @@
"public bridge synthetic java.lang.Object clone()"
],
"fields": []
- },
- "com.yahoo.container.di.componentgraph.Provider": {
- "superClass": "java.lang.Object",
- "interfaces": [
- "com.yahoo.component.Deconstructable"
- ],
- "attributes": [
- "public",
- "interface",
- "abstract"
- ],
- "methods": [
- "public abstract java.lang.Object get()"
- ],
- "fields": []
}
} \ No newline at end of file
diff --git a/component/pom.xml b/component/pom.xml
index 4d7b716445a..75b07643c7e 100755
--- a/component/pom.xml
+++ b/component/pom.xml
@@ -12,7 +12,7 @@
<relativePath>../parent/pom.xml</relativePath>
</parent>
<artifactId>component</artifactId>
- <packaging>jar</packaging>
+ <packaging>container-plugin</packaging>
<version>7-SNAPSHOT</version>
<dependencies>
<dependency>
@@ -59,6 +59,11 @@
<build>
<plugins>
<plugin>
+ <groupId>com.yahoo.vespa</groupId>
+ <artifactId>bundle-plugin</artifactId>
+ <extensions>true</extensions>
+ </plugin>
+ <plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<executions>
diff --git a/component/src/main/java/com/yahoo/container/di/componentgraph/Provider.java b/component/src/main/java/com/yahoo/container/di/componentgraph/Provider.java
deleted file mode 100644
index 3fd3195e5dd..00000000000
--- a/component/src/main/java/com/yahoo/container/di/componentgraph/Provider.java
+++ /dev/null
@@ -1,26 +0,0 @@
-// Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
-package com.yahoo.container.di.componentgraph;
-
-import com.yahoo.component.Deconstructable;
-
-/**
- * <p>Provides a component of the parameter type T.
- * If (and only if) dependency injection does not have a component of type T,
- * it will request one from the Provider providing type T.</p>
- *
- * <p>Providers are useful in these situations:</p>
- * <ul>
- * <li>Some code is needed to create the component instance in question.</li>
- * <li>The component creates resources that must be deconstructed.</li>
- * <li>A fallback component should be provided in case the application (or system)
- * does not provide a component instance.</li>
- * </ul>
- *
- * @author Tony Vaagenes
- * @author gjoranv
- */
-public interface Provider<T> extends Deconstructable {
-
- T get();
-
-}
diff --git a/component/src/main/java/com/yahoo/container/di/componentgraph/package-info.java b/component/src/main/java/com/yahoo/container/di/componentgraph/package-info.java
deleted file mode 100644
index 054abe9cff9..00000000000
--- a/component/src/main/java/com/yahoo/container/di/componentgraph/package-info.java
+++ /dev/null
@@ -1,12 +0,0 @@
-// Copyright Verizon Media. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
-/**
- * Note that this package also exists in another Vespa module, for historical
- * reasons. All Java classes should be kept in this module, and the other
- * module's package should remain empty.
- */
-@ExportPackage
-@PublicApi
-package com.yahoo.container.di.componentgraph;
-
-import com.yahoo.api.annotations.PublicApi;
-import com.yahoo.osgi.annotation.ExportPackage;