oveits / ProvisioningEngine

Ruby on Rails based ProvisioningEngine Frontend for provisioning of legacy systems via Apache Camel Backend (SOAP/XML+SPML+File import)
3 stars 6 forks source link

Heroku customer provisioning hangs in "waiting for provisioning" #57

Closed oveits closed 8 years ago

oveits commented 8 years ago

The Simulator on Heroku is non-functional, currently (unfortunately for 2 months already! I need to create an automatic check in future!)

Heroku was running in simulation async mode. If I try to provision a customer, the provisioning gets stuck in "waiting for provisioning" forever. I can see, that someone has tried to test the simulator, but I cannot see the corresponding jobs.#

The latest build from development tree (2 months ago) has failed with following error:

-----> Using Ruby version: ruby-2.0.0
...
Gem::InstallError: devise requires Ruby version >= 2.1.0.

The Gemfile does not specify the ruby version and currently, Heroku is claiming that it will use ruby version 2.2.4 in this case; see this ruby support page.

Full log:

-----> Using set buildpack heroku/ruby
-----> Ruby app detected
-----> Compiling Ruby/Rails
-----> Using Ruby version: ruby-2.0.0
###### WARNING:
       Removing `Gemfile.lock` because it was generated on Windows.
       Bundler will do a full resolve so native gems are handled properly.
       This may result in unexpected gem versions being used in your app.
       In rare occasions Bundler may not be able to resolve your dependencies at all.
       https://devcenter.heroku.com/articles/bundler-windows-gemfile
-----> Installing dependencies using bundler 1.11.2
       Your app was upgraded to bundler 1.11.2.
       Previously you had a successful deploy with bundler 1.9.7.

       If you see problems related to the bundler version please refer to:
       https://devcenter.heroku.com/articles/bundler-version
       Running: bundle install --without development:test --path vendor/bundle --binstubs vendor/bundle/bin -j4
       Fetching gem metadata from https://rubygems.org/...........
       Fetching version metadata from https://rubygems.org/...
       Fetching dependency metadata from https://rubygems.org/..
       Resolving dependencies...........................................................................................................................................................................................................................
       Rubygems 2.0.14.1 is not threadsafe, so your gems will be installed one at a time. Upgrade to Rubygems 2.1.0 or higher to enable parallel gem installation.
       Installing rake 11.1.2
       Using i18n 0.7.0
       Using json 1.8.3
       Using minitest 5.8.4
       Using thread_safe 0.3.5
       Using builder 3.2.2
       Using erubis 2.7.0
       Using mini_portile2 2.0.0
       Using rack 1.6.4
       Installing mime-types-data 3.2016.0221
       Using sass 3.2.19
       Using thor 0.19.1
       Using coffee-script-source 1.10.0
       Using execjs 2.6.0
       Installing formtastic_i18n 0.6.0
       Using arel 6.0.3
       Using bundler 1.11.2
       Using hike 1.2.3
       Installing multi_json 1.11.3
       Using tilt 1.4.1
       Using addressable 2.4.0
       Installing bcrypt 3.1.11 with native extensions
       Using cookiejar 0.3.0
       Using daemons 1.2.3
       Using orm_adapter 0.5.0
       Installing eventmachine 1.2.0.1 with native extensions
       Using http_parser.rb 0.6.0
       Using pg 0.15.1
       Using rails_serve_static_assets 0.0.5
       Installing rails_stdout_logging 0.0.5
       Using rdoc 4.2.2
       Using tzinfo 1.2.2
       Using nokogiri 1.6.7.2
       Using rack-test 0.6.3
       Using rack-protection 1.5.3
       Using warden 1.2.6
       Installing mime-types 3.0
       Using bourbon 3.2.4
       Using figaro 1.1.1
       Using coffee-script 2.4.1
       Installing autoprefixer-rails 6.3.6
       Installing uglifier 3.0.0
       Using sprockets 2.12.4
       Using em-socksify 0.3.1
       Using rails_12factor 0.0.2
       Using sdoc 0.4.1
       Installing activesupport 4.2.6
       Using loofah 2.0.3
       Using sinatra 1.4.7
       Installing mail 2.6.4
       Using bootstrap-sass 3.3.5
       Using em-http-request 1.1.3
       Using rails-deprecated_sanitizer 1.0.3
       Using globalid 0.3.6
       Using arbre 1.0.3
       Installing activemodel 4.2.6
       Using delayed_job 4.1.1
       Using jbuilder 2.4.1
       Using rails-html-sanitizer 1.0.3
       Using rails-dom-testing 1.0.7
       Installing activejob 4.2.6
       Installing activerecord 4.2.6
       Using activemodel-globalid 0.1.1
       Installing actionview 4.2.6
       Using polyamorous 1.3.0
       Using delayed_job_active_record 4.1.0
       Using delayed_job_web 1.2.5
       Using seed_dump 3.2.4
       Installing actionpack 4.2.6
       Installing actionmailer 4.2.6
       Installing railties 4.2.6
       Installing formtastic 3.1.4
       Using has_scope 0.6.0
       Using kaminari 0.16.3
       Using sprockets-rails 2.3.3
       Using ransack 1.7.0
       Using coffee-rails 4.0.1
       Installing responders 2.1.2
       Installing jquery-rails 4.1.1
       Using jquery-ui-rails 5.0.5
       Using respond-rails 1.0.1
       Installing rails 4.2.6
       Using sass-rails 4.0.5
       Using turbolinks 2.5.3
       Using inherited_resources 1.6.0
       Installing devise 4.0.1
       Gem::InstallError: devise requires Ruby version >= 2.1.0.
       Using jquery-turbolinks 2.1.0
       Using activeadmin 1.0.0.pre2
       An error occurred while installing devise (4.0.1), and Bundler cannot continue.
       Make sure that `gem install devise -v '4.0.1'` succeeds before bundling.
       Bundler Output: Fetching gem metadata from https://rubygems.org/...........
       Fetching version metadata from https://rubygems.org/...
       Fetching dependency metadata from https://rubygems.org/..
       Resolving dependencies...........................................................................................................................................................................................................................
       Rubygems 2.0.14.1 is not threadsafe, so your gems will be installed one at a time. Upgrade to Rubygems 2.1.0 or higher to enable parallel gem installation.
       Installing rake 11.1.2
       Using i18n 0.7.0
       Using json 1.8.3
       Using minitest 5.8.4
       Using thread_safe 0.3.5
       Using builder 3.2.2
       Using erubis 2.7.0
       Using mini_portile2 2.0.0
       Using rack 1.6.4
       Installing mime-types-data 3.2016.0221
       Using sass 3.2.19
       Using thor 0.19.1
       Using coffee-script-source 1.10.0
       Using execjs 2.6.0
       Installing formtastic_i18n 0.6.0
       Using arel 6.0.3
       Using bundler 1.11.2
       Using hike 1.2.3
       Installing multi_json 1.11.3
       Using tilt 1.4.1
       Using addressable 2.4.0
       Installing bcrypt 3.1.11 with native extensions
       Using cookiejar 0.3.0
       Using daemons 1.2.3
       Using orm_adapter 0.5.0
       Installing eventmachine 1.2.0.1 with native extensions
       Using http_parser.rb 0.6.0
       Using pg 0.15.1
       Using rails_serve_static_assets 0.0.5
       Installing rails_stdout_logging 0.0.5
       Using rdoc 4.2.2
       Using tzinfo 1.2.2
       Using nokogiri 1.6.7.2
       Using rack-test 0.6.3
       Using rack-protection 1.5.3
       Using warden 1.2.6
       Installing mime-types 3.0
       Using bourbon 3.2.4
       Using figaro 1.1.1
       Using coffee-script 2.4.1
       Installing autoprefixer-rails 6.3.6
       Installing uglifier 3.0.0
       Using sprockets 2.12.4
       Using em-socksify 0.3.1
       Using rails_12factor 0.0.2
       Using sdoc 0.4.1
       Installing activesupport 4.2.6
       Using loofah 2.0.3
       Using sinatra 1.4.7
       Installing mail 2.6.4
       Using bootstrap-sass 3.3.5
       Using em-http-request 1.1.3
       Using rails-deprecated_sanitizer 1.0.3
       Using globalid 0.3.6
       Using arbre 1.0.3
       Installing activemodel 4.2.6
       Using delayed_job 4.1.1
       Using jbuilder 2.4.1
       Using rails-html-sanitizer 1.0.3
       Using rails-dom-testing 1.0.7
       Installing activejob 4.2.6
       Installing activerecord 4.2.6
       Using activemodel-globalid 0.1.1
       Installing actionview 4.2.6
       Using polyamorous 1.3.0
       Using delayed_job_active_record 4.1.0
       Using delayed_job_web 1.2.5
       Using seed_dump 3.2.4
       Installing actionpack 4.2.6
       Installing actionmailer 4.2.6
       Installing railties 4.2.6
       Installing formtastic 3.1.4
       Using has_scope 0.6.0
       Using kaminari 0.16.3
       Using sprockets-rails 2.3.3
       Using ransack 1.7.0
       Using coffee-rails 4.0.1
       Installing responders 2.1.2
       Installing jquery-rails 4.1.1
       Using jquery-ui-rails 5.0.5
       Using respond-rails 1.0.1
       Installing rails 4.2.6
       Using sass-rails 4.0.5
       Using turbolinks 2.5.3
       Using inherited_resources 1.6.0
       Installing devise 4.0.1

       Gem::InstallError: devise requires Ruby version >= 2.1.0.
       Using jquery-turbolinks 2.1.0
       Using activeadmin 1.0.0.pre2
       An error occurred while installing devise (4.0.1), and Bundler cannot continue.
       Make sure that `gem install devise -v '4.0.1'` succeeds before bundling.
 !
 !     Failed to install gems via Bundler.
 !
 !     Push rejected, failed to compile Ruby app
oveits commented 8 years ago

The Heroku "waiting for provisioning" was caused by an empty target. This has caused the HTTP header to be in a wrong format. heroku logs has shown

2016-07-05T17:49:50.650357+00:00 app[worker.1]: [Worker(host:077d41cf-3efc-4b5f-b99c-e1a84018fc76 pid:3)] Job ActiveJob::QueueAdapters::DelayedJobAdapter::JobWrapper (id=45) FAILED (6 prior attempts) with RuntimeError: HttpPostRequest: wrong headerInput ("action=List Customers, customerName=Customer1, ") type or format

i.e. the action is ending with a comma, since I expect a non-empty target specification.

The heroku build problems persists and will be handled in a different issue.

oveits commented 8 years ago

If I run the ProvisioningEngine in foreground mode, I get an error like "We're sorry, but something went wrong. If you are the application owner check the logs for more information." instead of the provisioning stuck in "waiting for provisioning". If I specify that the test target is "OSPIP = 1.1.1.1", then it works fine again.

Since I do not want the users to change the targets, I have added a new enhancement issue #58: "Add a new parameter that allows to disable target management (i.e. hide the edit, destroy and new buttons for targets)"