Skip to content
This repository has been archived by the owner on Feb 4, 2019. It is now read-only.

upgrade to java 8 #108

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
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
Original file line number Diff line number Diff line change
Expand Up @@ -69,15 +69,15 @@ public static <T> ServiceTracker createServiceCacheTracker(final BundleContext c
@Override
public Object addingService(ServiceReference reference) {
Object service = super.addingService(reference);
if (serviceToken.isAssignableFrom(service.getClass())) {
if (serviceToken.isSupertypeOf(service.getClass())) {
cacheManager.bindService((T) service);
}
return service;
}

@Override
public void removedService(ServiceReference reference, Object service) {
if (serviceToken.isAssignableFrom(service.getClass())) {
if (serviceToken.isSupertypeOf(service.getClass())) {
cacheManager.unbindService((T) service);
}
super.removedService(reference, service);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ public void start(final BundleContext context) throws Exception {
@Override
public Object addingService(ServiceReference reference) {
Object obj = super.addingService(reference);
if (CHEF_TOKEN.isAssignableFrom(obj.getClass())) {
if (CHEF_TOKEN.isSupertypeOf(obj.getClass())) {
String serviceId = String.valueOf(reference.getProperty(Constants.SERVICE_ID));
registerRecipeProviderForService(context, serviceId, (ApiContext<ChefApi>) obj);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,22 +19,11 @@

package org.jclouds.karaf.commands.blobstore;

import java.io.File;
import java.io.IOException;
import java.io.InputStream;

import org.apache.felix.gogo.commands.Argument;
import org.apache.felix.gogo.commands.Command;
import org.apache.felix.gogo.commands.Option;
import org.jclouds.blobstore.BlobStore;
import org.jclouds.blobstore.KeyNotFoundException;

import com.google.common.base.Charsets;
import com.google.common.base.Strings;
import com.google.common.io.CharStreams;
import com.google.common.io.Files;
import com.google.common.io.InputSupplier;

@Command(scope = "jclouds", name = "blobstore-blob-exists", description = "Checks existence of blob on the blobstore")
public class BlobExistsCommand extends BlobStoreCommandWithOptions {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,10 @@
import org.apache.felix.gogo.commands.CommandException;
import org.apache.felix.gogo.commands.Option;
import org.jclouds.blobstore.BlobStore;
import org.jclouds.blobstore.KeyNotFoundException;

import com.google.common.base.Charsets;
import com.google.common.base.Strings;
import com.google.common.io.CharStreams;
import com.google.common.io.Closeables;
import com.google.common.io.Files;
import com.google.common.io.InputSupplier;

@Command(scope = "jclouds", name = "blobstore-read", description = "Reads data from the blobstore")
public class BlobReadCommand extends BlobStoreCommandWithOptions {
Expand Down
2 changes: 1 addition & 1 deletion feature-labs/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ limitations under the License.
<descriptor>file:${project.build.directory}/feature/feature.xml</descriptor>
</descriptors>
<distribution>org.apache.karaf.features:framework</distribution>
<javase>1.7</javase>
<javase>1.8</javase>
<framework>
<feature>framework</feature>
</framework>
Expand Down
2 changes: 1 addition & 1 deletion feature/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ limitations under the License.
<descriptor>file:${project.build.directory}/feature/feature.xml</descriptor>
</descriptors>
<distribution>org.apache.karaf.features:framework</distribution>
<javase>1.7</javase>
<javase>1.8</javase>
<framework>
<feature>framework</feature>
</framework>
Expand Down
1 change: 1 addition & 0 deletions feature/src/main/feature/feature.xml
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ limitations under the License.
<bundle dependency='true'>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.jersey-core/${jersey.bundle.version}</bundle>
<bundle dependency='true'>mvn:com.google.code.gson/gson/${gson.version}</bundle>
<bundle>mvn:org.apache.jclouds/jclouds-core/${jclouds.version}</bundle>
<requirement>osgi.ee;filter:="(&amp;(osgi.ee=JavaSE)(!(version>=1.9)))"</requirement>
</feature>

<feature name='jclouds-blobstore' description='jclouds - blobstore' version='${project.version}'>
Expand Down
10 changes: 5 additions & 5 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -149,8 +149,8 @@ limitations under the License.
<artifactId>maven-compiler-plugin</artifactId>
<version>${maven-compiler-plugin.version}</version>
<configuration>
<source>1.6</source>
<target>1.6</target>
<source>${jdk.version}</source>
<target>${jdk.version}</target>
</configuration>
</plugin>
<plugin>
Expand Down Expand Up @@ -183,14 +183,14 @@ limitations under the License.
</modules>

<properties>
<jdk.version>1.7</jdk.version>
<jdk.version>1.8</jdk.version>
<aopalliance.bundle.version>1.0_5</aopalliance.bundle.version>
<bcprov.version>1.51</bcprov.version>
<easymock.version>3.0</easymock.version>
<felix.configadmin.version>1.8.0</felix.configadmin.version>
<groovy.version>2.4.4</groovy.version>
<gson.version>2.5</gson.version>
<guava.version>18.0</guava.version>
<guava.version>21.0</guava.version>
<guava.test.version>10.0</guava.test.version>
<guice.version>3.0</guice.version>
<httpclient.version>4.3.4</httpclient.version>
Expand All @@ -212,7 +212,7 @@ limitations under the License.
<junit.version>4.8.2</junit.version>
<jzlib.bundle.version>1.0.7_1</jzlib.bundle.version>
<jzlib.version>1.0.7</jzlib.version>
<karaf.version>4.0.9</karaf.version>
<karaf.version>4.2.0</karaf.version> <!-- osgi version 6, java version supported 8 / 9 / 10 -->
<net.oauth.bundle.version>20100527_1</net.oauth.bundle.version>
<netty.bundle.version>3.5.9.Final</netty.bundle.version>
<osgi.version>6.0.0</osgi.version>
Expand Down