manticore 0.6.4-java → 0.7.0-java

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 00b846373d0dce20d74cb4e2434868f908006e63
4
- data.tar.gz: e136b3550efea6343291f9264d45ff1b6fa24448
2
+ SHA256:
3
+ metadata.gz: 508b2d2c3ce9fc25ca2ac915954807783cc8266aac23936a6896d103121a2f0c
4
+ data.tar.gz: a8ac97bd7fb22df23ac164d5f06f3a35c926d9eac57ae7bfb8e84c0c8d9e7907
5
5
  SHA512:
6
- metadata.gz: 6a02ebe1e15e565212f135d760cb83eaaaecbd73f8664c9470ef14feb00a163d76a8383918f3b51a28018853c8e88c0bb1f5af7eae28f9f5e0f7840806b70d79
7
- data.tar.gz: 74f89a4d46806461ae86b2554ac418ebd3673e8b4c55a4add68da84d88cb54418ada667d1f4673f549782b693982e4f2a4ec84fb41f8248fd9fab1a2a150e817
6
+ metadata.gz: 56a60c747c187ddd1255e5da7cbc2ad78570c2ebf5390841298f45366133b48c857df8ac7b7b8bdbbb5194546e3b3112a8c08b5109c66a1299f6fe787ae890fc
7
+ data.tar.gz: 78e29e767486b820f1d1a280ae4db04b1ad33eccb7da7538bae9e48116305b44d069dc13ee322484146f9cce28b6edf71e868d73be8e075957404c50a99416eb
@@ -8,7 +8,7 @@
8
8
  - $HOME/.m2
9
9
  before_script:
10
10
  - apt update && apt install -y git
11
- - gem install ruby-maven bundler
11
+ - gem install ruby-maven
12
12
  - bundle install --path vendor/bundle
13
13
  script:
14
14
  - bundle exec rake
@@ -1,23 +1,20 @@
1
+ dist: xenial
1
2
  language: ruby
2
- sudo: false
3
3
  cache:
4
4
  - bundler
5
5
  - directories:
6
6
  - $HOME/.m2
7
7
  rvm:
8
- - jruby-1.7
9
- - jruby-9.0.5.0
8
+ - jruby-9.1.17.0 # Ruby 2.3
9
+ - jruby-9.2.13.0 # Ruby 2.5
10
10
  jdk:
11
- - oraclejdk8
12
- - openjdk7
11
+ - openjdk9
12
+ - openjdk11
13
13
  before_install:
14
- - gem install ruby-maven bundler
15
- - bundle install
14
+ - gem install bundler -v 1.17.3
16
15
  matrix:
17
16
  include:
18
- - rvm: jruby-9.2.0.0
19
- jdk: oraclejdk8
20
17
  - rvm: jruby-head
21
- jdk: oraclejdk8
18
+ jdk: openjdk10
22
19
  allow_failures:
23
20
  - rvm: jruby-head
@@ -1,8 +1,9 @@
1
1
  ## v0.6
2
2
 
3
- ### v0.6.5
3
+ ### v0.7.0
4
4
 
5
- (unreleased)
5
+ * Drop support for JRuby 1.7. It probably still works, but we don't test against it anymore
6
+ * Fix a thread safety issue with regards to adding requests to the parallel execution queue while the client is already processing a queue (#80)
6
7
 
7
8
  ### v0.6.4
8
9
 
data/Gemfile CHANGED
@@ -8,8 +8,9 @@ group :development, :test do
8
8
  gem "rspec", "~> 3.0"
9
9
  gem "rspec-its"
10
10
  gem "httpclient", "~> 2.3"
11
- gem "rack", "~> 1.5"
11
+ gem "rack", ">= 2.1.4"
12
12
  gem "rake-compiler"
13
13
  gem "gserver"
14
14
  gem "simplecov"
15
+ gem "json"
15
16
  end
@@ -20,17 +20,12 @@ module Faraday
20
20
  ParallelManager.new
21
21
  end
22
22
 
23
- def initialize(app, connection_options = {})
24
- @connection_options = connection_options
25
- super(app)
26
- end
27
-
28
23
  def client(env)
29
24
  @client ||= begin
30
25
  opts = {}
31
26
  if ssl = env[:ssl].to_hash
32
27
  opts[:ssl] = {}
33
- opts[:ssl][:verify] = :disable if ssl[:verify] == false
28
+ opts[:ssl][:verify] = ssl[:verify] unless ssl[:verify].nil?
34
29
  opts[:ssl][:ca_file] = ssl[:ca_file]
35
30
  opts[:ssl][:client_cert] = ssl[:client_cert]
36
31
  opts[:ssl][:client_key] = ssl[:client_key]
@@ -223,7 +223,7 @@ module Manticore
223
223
  @client = builder.build
224
224
  finalize @client, :close
225
225
  @options = options
226
- @async_requests = []
226
+ @async_requests = Queue.new
227
227
  @stubs = {}
228
228
  end
229
229
 
@@ -334,8 +334,9 @@ module Manticore
334
334
  # @return [Array] An array of the responses from the requests executed.
335
335
  def execute!
336
336
  method = executor.java_method(:submit, [java.util.concurrent.Callable.java_class])
337
- result = @async_requests.map { |r| method.call r }
338
- @async_requests.clear
337
+
338
+ result = []
339
+ result << method.call(@async_requests.pop) until @async_requests.empty?
339
340
  result.map do |future|
340
341
  begin
341
342
  future.get
@@ -1,3 +1,3 @@
1
1
  module Manticore
2
- VERSION = "0.6.4"
2
+ VERSION = "0.7.0"
3
3
  end
@@ -27,9 +27,9 @@ Gem::Specification.new do |spec|
27
27
 
28
28
  spec.add_dependency "openssl_pkcs8_pure"
29
29
 
30
- spec.add_development_dependency "bundler", "~> 1.3"
30
+ spec.add_development_dependency "bundler"
31
31
  spec.add_development_dependency "rake"
32
- spec.add_development_dependency "jar-dependencies"
32
+ spec.add_development_dependency "jar-dependencies", "~> 0.4.1"
33
33
 
34
34
  spec.requirements << "jar org.apache.httpcomponents:httpclient, '~> 4.5.0'"
35
35
  spec.requirements << "jar org.apache.httpcomponents:httpmime, '~> 4.5.0'"
@@ -563,7 +563,7 @@ describe Manticore::Client do
563
563
  describe "#head" do
564
564
  it "works" do
565
565
  response = client.head(local_server)
566
- expect(JSON.load(response.body)).to be_nil
566
+ expect(response.body).to be_nil
567
567
  end
568
568
  end
569
569
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: manticore
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.4
4
+ version: 0.7.0
5
5
  platform: java
6
6
  authors:
7
7
  - Chris Heald
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-06-28 00:00:00.000000000 Z
11
+ date: 2020-09-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  requirement: !ruby/object:Gem::Requirement
@@ -17,8 +17,8 @@ dependencies:
17
17
  - !ruby/object:Gem::Version
18
18
  version: '0'
19
19
  name: openssl_pkcs8_pure
20
- prerelease: false
21
20
  type: :runtime
21
+ prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - ">="
@@ -27,17 +27,17 @@ dependencies:
27
27
  - !ruby/object:Gem::Dependency
28
28
  requirement: !ruby/object:Gem::Requirement
29
29
  requirements:
30
- - - "~>"
30
+ - - ">="
31
31
  - !ruby/object:Gem::Version
32
- version: '1.3'
32
+ version: '0'
33
33
  name: bundler
34
- prerelease: false
35
34
  type: :development
35
+ prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - "~>"
38
+ - - ">="
39
39
  - !ruby/object:Gem::Version
40
- version: '1.3'
40
+ version: '0'
41
41
  - !ruby/object:Gem::Dependency
42
42
  requirement: !ruby/object:Gem::Requirement
43
43
  requirements:
@@ -45,8 +45,8 @@ dependencies:
45
45
  - !ruby/object:Gem::Version
46
46
  version: '0'
47
47
  name: rake
48
- prerelease: false
49
48
  type: :development
49
+ prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - ">="
@@ -55,17 +55,17 @@ dependencies:
55
55
  - !ruby/object:Gem::Dependency
56
56
  requirement: !ruby/object:Gem::Requirement
57
57
  requirements:
58
- - - ">="
58
+ - - "~>"
59
59
  - !ruby/object:Gem::Version
60
- version: '0'
60
+ version: 0.4.1
61
61
  name: jar-dependencies
62
- prerelease: false
63
62
  type: :development
63
+ prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
- - - ">="
66
+ - - "~>"
67
67
  - !ruby/object:Gem::Version
68
- version: '0'
68
+ version: 0.4.1
69
69
  description: Manticore is an HTTP client built on the Apache HttpCore components
70
70
  email:
71
71
  - cheald@mashable.com
@@ -136,8 +136,7 @@ requirements:
136
136
  - jar commons-logging:commons-logging, '~> 1.2'
137
137
  - jar commons-codec:commons-codec, '~> 1.9'
138
138
  - jar org.apache.httpcomponents:httpcore, '~> 4.4.4'
139
- rubyforge_project:
140
- rubygems_version: 2.6.14.1
139
+ rubygems_version: 3.0.6
141
140
  signing_key:
142
141
  specification_version: 4
143
142
  summary: Manticore is an HTTP client built on the Apache HttpCore components