updated perftest to latest dependencies

This commit is contained in:
Adrian Cole 2010-12-27 22:12:51 +01:00
parent 4f45d00acc
commit dc7914c1f5
2 changed files with 12 additions and 12 deletions

View File

@ -35,9 +35,9 @@
--> -->
<appengine.home>YOUR_APPENGINE_HOME</appengine.home> <appengine.home>YOUR_APPENGINE_HOME</appengine.home>
<jclouds.test.loopcount>100</jclouds.test.loopcount> <jclouds.test.loopcount>100</jclouds.test.loopcount>
<jclouds.test.identity>${jclouds.aws.accesskeyid}</jclouds.test.identity> <jclouds.test.identity>${test.aws.identity}</jclouds.test.identity>
<jclouds.test.credential>${jclouds.aws.secretaccesskey}</jclouds.test.credential> <jclouds.test.credential>${test.aws.credential}</jclouds.test.credential>
<jclouds.test.initializer>org.jclouds.aws.s3.blobstore.integration.S3TestInitializer</jclouds.test.initializer> <test.initializer>org.jclouds.aws.s3.blobstore.integration.S3TestInitializer</test.initializer>
</properties> </properties>
<dependencies> <dependencies>
@ -54,12 +54,12 @@
<dependency> <dependency>
<groupId>com.amazonaws</groupId> <groupId>com.amazonaws</groupId>
<artifactId>aws-java-sdk</artifactId> <artifactId>aws-java-sdk</artifactId>
<version>1.0.007</version> <version>1.1.1</version>
</dependency> </dependency>
<dependency> <dependency>
<groupId>net.java.dev.jets3t</groupId> <groupId>net.java.dev.jets3t</groupId>
<artifactId>jets3t</artifactId> <artifactId>jets3t</artifactId>
<version>0.7.4</version> <version>0.8.0</version>
</dependency> </dependency>
<dependency> <dependency>
<groupId>${project.groupId}</groupId> <groupId>${project.groupId}</groupId>
@ -151,8 +151,8 @@
<value>${jclouds.test.credential}</value> <value>${jclouds.test.credential}</value>
</property> </property>
<property> <property>
<name>jclouds.test.initializer</name> <name>test.initializer</name>
<value>${jclouds.test.initializer}</value> <value>${test.initializer}</value>
</property> </property>
<property> <property>
<name>jclouds.test.loopcount</name> <name>jclouds.test.loopcount</name>

View File

@ -68,8 +68,8 @@ public abstract class BaseJCloudsPerformanceLiveTest extends BasePerformanceLive
@Override @Override
protected Future<?> putByteArray(String bucket, String key, byte[] data, String contentType) { protected Future<?> putByteArray(String bucket, String key, byte[] data, String contentType) {
S3Object object = newObject(key); S3Object object = newObject(key);
object.getMetadata().setContentType(contentType);
object.setPayload(data); object.setPayload(data);
object.getPayload().getContentMetadata().setContentType(contentType);
return getApi().putObject(bucket, object); return getApi().putObject(bucket, object);
} }
@ -78,8 +78,8 @@ public abstract class BaseJCloudsPerformanceLiveTest extends BasePerformanceLive
@Override @Override
protected Future<?> putFile(String bucket, String key, File data, String contentType) { protected Future<?> putFile(String bucket, String key, File data, String contentType) {
S3Object object = newObject(key); S3Object object = newObject(key);
object.getMetadata().setContentType(contentType);
object.setPayload(data); object.setPayload(data);
object.getPayload().getContentMetadata().setContentType(contentType);
return getApi().putObject(bucket, object); return getApi().putObject(bucket, object);
} }
@ -94,19 +94,19 @@ public abstract class BaseJCloudsPerformanceLiveTest extends BasePerformanceLive
S3Object object = newObject(key); S3Object object = newObject(key);
object.setPayload(data); object.setPayload(data);
try { try {
object.getPayload().setContentLength(new Long(data.available())); object.getPayload().getContentMetadata().setContentLength(new Long(data.available()));
} catch (IOException e) { } catch (IOException e) {
Throwables.propagate(e); Throwables.propagate(e);
} }
object.getPayload().setContentType(contentType); object.getPayload().getContentMetadata().setContentType(contentType);
return getApi().putObject(bucket, object); return getApi().putObject(bucket, object);
} }
@Override @Override
protected Future<?> putString(String bucket, String key, String data, String contentType) { protected Future<?> putString(String bucket, String key, String data, String contentType) {
S3Object object = newObject(key); S3Object object = newObject(key);
object.getMetadata().setContentType(contentType);
object.setPayload(data); object.setPayload(data);
object.getPayload().getContentMetadata().setContentType(contentType);
return getApi().putObject(bucket, object); return getApi().putObject(bucket, object);
} }
} }