1592 Commits

Author SHA1 Message Date
Jesse Glick
65a5ec8164 [JCLOUDS-1200] Mark nonserializable fields in HttpResponseException and subtypes as transient. 2018-05-21 22:13:04 -07:00
Andrew Gaul
1f6ec343c0 Upgrade to SpotBugs 3.1.3
This replaces FindBugs.  Also address a few violations.
2018-05-21 22:06:27 -07:00
Ignasi Barrera
b29f716a02
JCLOUDS-1294: Attempt to retry RetryableErrors in Azure ARM 2018-05-04 11:03:43 +02:00
Ignasi Barrera
d2f566d725 Consider the zone id filter in the location supplier 2018-04-17 10:41:11 +02:00
Andrew Gaul
f6d47b9c0e JCLOUDS-1333: Fix Java 8 and Guava 21 issues 2018-04-10 08:17:35 -07:00
andreaturli
d17487b223 fix typo in project.version
- from 2.2.0-SNAPSHOST to 2.2.0-SNAPSHOT
2018-02-21 16:45:43 +01:00
andreaturli
a5db565581 Next development version 2.2.0-SNAPSHOST 2018-02-16 11:23:12 +01:00
andreaturli
9273bd56ad Apache jclouds 2.1.0-rc3 release 2018-02-16 11:20:21 +01:00
Ignasi Barrera
9fef6ed06b JCLOUDS-1362: Better password generation utility 2018-01-08 08:39:20 +01:00
Andrew Gaul
11640b6c2e Correct RandomByteSource.read return value
Previously read returned a value between -128 and 127.  -1 indicates
end of stream, causing issues for callers.  Instead return values
between 0 and 255 as intended.
2018-01-04 15:12:29 -08:00
Andrew Gaul
50026c8f2d Return Atmos objectID as ETag
Previously Atmos returned null.  Also rework the fix for JCLOUDS-339
which does not reproduce with AT&T Synaptic.  Fixes gaul/s3proxy#247.
2017-11-11 14:20:49 -08:00
Andrew Gaul
46759f8bda Fix a few Coverity defects 2017-11-05 20:12:47 -08:00
Andrew Gaul
31f528263a JCLOUDS-1340: Disable BackoffLimitedRetryHandlerTest
These often fail in our continuous integration tests.
2017-09-11 18:47:04 -07:00
Andrew Gaul
64553eda5f JCLOUDS-1340: Improve BackoffLimitedRetryHandlerTest asserts
These emit a more specific error message.
2017-09-11 13:13:39 -07:00
Andrew Gaul
7704893650 Remove Inject on constructors for abstract classes
This is not meaningful since these classes cannot be instantiated.
Found via error-prone.
2017-09-07 23:37:24 -07:00
Andrew Gaul
e7d0c29ce1 JCLOUDS-1101: Skip JDK 9 methods in tests 2017-08-30 10:39:40 -07:00
Tim Peierls
e08acc6ed6 JCLOUDS-1334: Guava 23 compatiblity
Reflective creation of SimpleTimeLimiter to allow compatibility with
Guava 23.0.  SimpleTimeLimiter.create(ExecutorService) was introduced
in Guava 22.0 to replace the SimpleTimeLimiter(ExecutorService)
constructor, which was deprecated in Guava 22.0 and removed in Guava
23.0.
2017-08-26 20:19:06 -07:00
Andrew Gaul
517323fbd5 JCLOUDS-1225: Address Guava 18 MoreExecutors changes
Fixed with:

find -name \*.java | xargs sed -i 's/sameThreadExecutor/newDirectExecutorService/g'
2017-08-22 17:14:22 -07:00
Andrew Gaul
a493e2ca2f JCLOUDS-1225: Address Guava 18 Objects changes
Fixed with:

find -name \*.java | xargs sed -i 's/Objects.[Tt]oStringHelper/More&/g'
find -name \*.java | xargs sed -i 's/Objects.firstNonNull/More&/g'
find -name \*.java | xargs sed -i 's/^\(import com.google.common.base.\)\(Objects.*\)/\1More\2\n\1\2/g'
find -name \*.java | xargs java -jar google-java-format-1.3-all-deps.jar -i --fix-imports-only --skip-sorting-imports
2017-08-22 17:12:53 -07:00
Chaithanya Ganta
e331a000d1 JCLOUDS-1322: Remove Expect header for requests with empty body
Signed-off-by: Chaithanya Ganta <ganta@adobe.com>
2017-08-21 21:05:02 -07:00
Andrew Gaul
7cbc16d99c Address false positive int overflow error
Found via error-prone 2.1.0
2017-08-21 18:29:15 -07:00
Svetoslav Neykov
640e04b315 Generate fixed length passwords
Avoids bugs where tests succeed with an average sized password but fail when the password length is at the allowed extremes.
2017-08-08 20:21:21 +03:00
William L. Thomson Jr
6de7974a66 core/src/main/java/org/jclouds/rest/internal/TransformerForRequest.java:
Fix for Java 1.8 and Guice 4.1. Not sure if this is correct, but does
compile. Committing to see if it passes tests to confirm fix or not.

Modified per @nacx on jclouds PR1036
https://github.com/jclouds/jclouds/pull/1036#issuecomment-319904820
2017-08-03 19:22:21 +02:00
Svetoslav Neykov
7e496723ab Move Passwords implementation to jclouds-core to be reused by providers 2017-07-27 20:54:31 +03:00
Andrew Gaul
78104938e5 JCLOUDS-1325: Ignore Unicode BOM in XML parser
This caused failures to parse Azure Queue Storage list requests.
2017-07-27 10:41:45 -07:00
Svetoslav Neykov
2487b0c513 Use separate credential stores per context
With a shared credential store the configuration of one compute service leaks in all others, causing the wrong credentials to be used when not overriden.
2017-07-27 14:57:06 +03:00
Andrew Gaul
0bc935dd57 Remove clojure bindings
These have not seen any development in many years.
2017-07-10 11:39:11 -07:00
Ignasi Barrera
db2f86bcec
JCLOUDS-1295: Support deprecated date formats in the Expires header 2017-05-29 16:59:42 +03:00
Geoff Macartney
28c3c33bf0 Temporarily use a custom annotation instead of @SinceApiVersion.
The intention is to use @SinceApiVersion for this purpose, but that
would affect a number of APIs, and we would want to have good test
coverage before merging that change (in
FormSignerUtils#getAnnotatedApiVersion). However, there is some issue
wth certain tests at resent that means we cannot successfully test
all APIs that make use of @SinceApiVersion in order to assure
ourselves that FormSignerUtils will not introduce some problem.

See https://github.com/jclouds/jclouds/pull/1102#issuecomment-302682049
for details.

This annotation is introduced as a temporary measure in order to
decouple the functionality of FormSignerUtils#getAnnotatedApiVersion
from @SinceApiVersion and the tests in question. It can be removed and
replaced by @SinceApiVersion when those tests are fixed.

Designates that a method overrides the {@link ApiVersion} on the class
with a specific value.
2017-05-29 10:24:52 +02:00
Ignasi Barrera
e5063aea12 Fix default executor rejection policies 2017-04-24 08:17:18 +02:00
Andrew Gaul
9342cad895 JCLOUDS-885: Add utility to gzip data
Useful for integration tests which expect gzip data.
2017-04-19 23:58:54 -07:00
Andrew Gaul
e058973abc Ensure SOME_CONSTANTS are static final
Found via error-prone.
2017-03-17 16:59:41 -07:00
Andrew Gaul
cff54601ea Make inner classes static
Found via error-prone.
2017-03-17 16:42:32 -07:00
Andrea Turli
38cb34e123 [JCLOUDS-1233] bump jax-rs version 2017-02-15 11:16:26 +01:00
Geoff Macartney
717b75a34e Fix O(n^2) response time for "list-security-groups" on openstack-nova.
For https://issues.apache.org/jira/browse/JCLOUDS-1235.

This change takes the approach of storing the information about the
overall list of groups within the `SecurityGroupInRegion` when it is
created, so that any subsequent conversion operation has access to all
the groups in the same region as the one to be converted.

It also collapses the functionality of `NovaSecurityGroupToSecurityGroup`,
`SecurityGroupRuleToIpPermission` and `FindSecurityGroupWithNameAndReturnTrue`
all into `NovaSecurityGroupInRegionToSecurityGroup`, and deletes the
now unused-classes SecurityGroupRuleToIpPermission,
NovaSecurityGroupToSecurityGroup and associated tests.
2017-02-13 12:30:18 +01:00
Andrew Gaul
1c524cadbb Correct regex in ExpandProperties
Previously Android choked on this incomplete regex.
2017-01-25 00:21:48 -08:00
Ignasi Barrera
36cb2a1c72 JCLOUDS-1227: Allow to configure regions with the same URI 2017-01-18 10:05:30 +01:00
Zack Shoylev
eda96a0ab9 Allow ipv6 address blocks 2017-01-10 14:33:36 -06:00
Vijay Panghal
f3c3f3b306 Make user agent header configurable
Jclouds sends default user agent string with each request to cloud
services. But some of the application would like to overide this and
send custom user agent instead.

This commit define a string property to overide this default user agent
string. This property will be applied to all outgoing http request to
cloud services

JCLOUDS-819
2016-12-20 11:02:19 +01:00
Ignasi Barrera
d290705419 Next development version 2.1.0-SNAPSHOT 2016-11-15 01:12:59 +01:00
Ignasi Barrera
6a3a37f4e0 Apache jclouds 2.0.0-rc3 release 2016-11-09 22:30:45 +01:00
Ignasi Barrera
0b48d4a25a Make code compatible with newer OSGi framework versions 2016-11-03 09:43:36 +01:00
Ignasi Barrera
cfe22389a8 Resource management moved to the caller 2016-10-25 15:19:20 +02:00
Ignasi Barrera
a43acaffce JCLOUDS-1187: Do not load Json payloads to memory when serializing objects 2016-10-25 15:19:20 +02:00
Andrew Gaul
3c9f66b8e9 Avoid lower-case l literal suffix
Readers can confuse this with 1.  Found via error-prone.  Fixed via:

find -name \*.java | xargs sed -i 's/\( [0-9][0-9]*\)l/\1L/g'
find -name \*.java | xargs sed -i 's/\(([0-9][0-9]*\)l/\1L/g'
2016-10-23 14:24:35 -07:00
Andrew Gaul
8117574c83 Avoid C-style array declarations
Found via error-prone.
2016-10-23 13:51:59 -07:00
Ignasi Barrera
8030e53f32 Move digital ocean rate limit handler to core to make it reusable 2016-10-19 16:56:51 +02:00
Zack Shoylev
00f7ee0738 jclouds was not properly retrying on an expect: 100-continue PUT request that requires re-athentication because of java protocol code
JCLOUDS-1179 This fix also addresses the same problem with other providers

No currently working tests because of https://github.com/square/okhttp/issues/675

This is a common problem in other tools as well https://curl.haxx.se/mail/lib-2004-08/0002.html
2016-10-13 12:17:19 -05:00
Andrew Gaul
7cde28a4d2 JCLOUDS-1074: Guava 20 compatibility
* dynamically call TypeToken.isSupertypeOf with Guava 19 and later and
  TypeToken.isAssignableFrom with Guava 18 and earlier
* consume or ignore values from methods with CheckReturnValue
* replace usage of removed Iterators.emptyIterator
2016-09-06 21:49:20 -07:00
Duncan Grant
7aad599721 Fix autovalue class loading in karaf
When Class.forName is called for a class in a different bundle it will
fail as the default karaf class loader won't load classes from other
bundles.

I have fixed this by using the classloader of the original
(non-autovalue) type and assuming it will be in the same bundle as the
autovalue type (I think this is a reasonable assumtion).

So far the only place where I've actually seen this being an issue is
when using the jclouds-labs-google provider within karaf. It fails
when serialising the Firewall.Rule class within a FirewallOptions
object.
2016-09-05 14:11:59 +02:00