deploy_revision getting stack level too deep


#1

I’m running into a weird issue that hasn’t come up for me in previous
cookbooks…

I’m getting:

SystemStackError

stack level too deep

from the deploy_revision provider.

I am having a rather difficult time getting anything meaningful out of
it in terms of debugging information.
Any ideas? What more info can I provide that might help?

Centos 6.4, chef 11.4.4 (can’t switch to 11.6+ yet because my new file
provider broke my code… i know… ironic…)

-Jesse


#2

do you have recursion somewhere in the code? can u share the debug logs?

On Wed, Jan 22, 2014 at 6:16 PM, Jesse Campbell hikeit@gmail.com wrote:

I’m running into a weird issue that hasn’t come up for me in previous
cookbooks…

I’m getting:

SystemStackError

stack level too deep

from the deploy_revision provider.

I am having a rather difficult time getting anything meaningful out of
it in terms of debugging information.
Any ideas? What more info can I provide that might help?

Centos 6.4, chef 11.4.4 (can’t switch to 11.6+ yet because my new file
provider broke my code… i know… ironic…)

-Jesse


#3

[2014-01-23T00:34:30+00:00] INFO: Processing deploy_revision[xxxxx] action
deploy (/var/cache/chef/cookbooks/application/providers/default.rb
line 122https://github.com/poise/application/blob/2.0.4/providers/default.rb#L122
)
[2014-01-23T00:34:30+00:00] INFO: Running queued delayed notifications
before re-raising exception
[2014-01-23T00:34:30+00:00] DEBUG: Re-raising exception: SystemStackError -
deploy_revision[xxxxx]
(/var/cache/chef/cookbooks/application/providers/default.rb line 122) had
an error: SystemStackError: stack level too deep
/opt/chef/embedded/lib/ruby/gems/1.9.1/gems/chef-11.4.4/lib/chef/provider.rb:46
[2014-01-23T00:34:30+00:00] ERROR: Running exception handlers

with application v 2.0.4
updating to 4.1.4https://github.com/poise/application/compare/2.0.4...v4.1.4didn’t
fix.

maybe something in the method_missing overrides?

On Wed, Jan 22, 2014 at 9:33 PM, Ranjib Dey dey.ranjib@gmail.com wrote:

do you have recursion somewhere in the code? can u share the debug logs?

On Wed, Jan 22, 2014 at 6:16 PM, Jesse Campbell hikeit@gmail.com wrote:

I’m running into a weird issue that hasn’t come up for me in previous
cookbooks…

I’m getting:

SystemStackError

stack level too deep

from the deploy_revision provider.

I am having a rather difficult time getting anything meaningful out of
it in terms of debugging information.
Any ideas? What more info can I provide that might help?

Centos 6.4, chef 11.4.4 (can’t switch to 11.6+ yet because my new file
provider broke my code… i know… ironic…)

-Jesse


#4

here’s a cleaner version of the code that is still failing:

53: deploy_revision(“idp”) do
54: deploy_to "/srv/idp"
55: scm_provider Chef::Provider::File::Deploy
56: repo "/srv/war_download/foo.war"
57: end

the log output with debug:
[2014-01-23T15:12:26+00:00] INFO: Processing deploy_revision[idp]
action deploy (sch_sso::idp_app line 53)
[2014-01-23T15:12:26+00:00] INFO: Running queued delayed notifications
before re-raising exception
[2014-01-23T15:12:26+00:00] DEBUG: Re-raising exception:
SystemStackError - deploy_revision[idp] (sch_sso::idp_app line 53) had
an error: SystemStackError: stack level too deep
/opt/chef/embedded/lib/ruby/gems/1.9.1/gems/chef-11.4.4/lib/chef/provider.rb:46

and the “compiled resource”:
Compiled Resource:

Declared in /var/cache/chef/cookbooks/sch_sso/recipes/idp_app.rb:53:in

`from_file’

deploy_revision(“idp”) do
provider Chef::Provider::Deploy::Revision
action :deploy
retries 0
retry_delay 2
deploy_to "/srv/idp"
repository_cache "cached-copy"
purge_before_symlink [“log”, “tmp/pids”, “public/system”]
create_dirs_before_symlink [“tmp”, “public”, “config”]
symlink_before_migrate {“config/database.yml”=>“config/database.yml”}
symlinks {“system”=>“public/system”, “pids”=>“tmp/pids”, “log”=>“log”}
revision "HEAD"
remote "origin"
scm_provider Chef::Provider::Deploy
keep_releases 5
cookbook_name "sch_sso"
recipe_name "idp_app"
repo "/srv/war_download/foo.war"
end

On Wed, Jan 22, 2014 at 11:16 PM, Alastair Firth alfirth@gmail.com wrote:

[2014-01-23T00:34:30+00:00] INFO: Processing deploy_revision[xxxxx] action
deploy (/var/cache/chef/cookbooks/application/providers/default.rb line 122)
[2014-01-23T00:34:30+00:00] INFO: Running queued delayed notifications
before re-raising exception
[2014-01-23T00:34:30+00:00] DEBUG: Re-raising exception: SystemStackError -
deploy_revision[xxxxx]
(/var/cache/chef/cookbooks/application/providers/default.rb line 122) had an
error: SystemStackError: stack level too deep
/opt/chef/embedded/lib/ruby/gems/1.9.1/gems/chef-11.4.4/lib/chef/provider.rb:46
[2014-01-23T00:34:30+00:00] ERROR: Running exception handlers

with application v 2.0.4
updating to 4.1.4 didn’t fix.

maybe something in the method_missing overrides?

On Wed, Jan 22, 2014 at 9:33 PM, Ranjib Dey dey.ranjib@gmail.com wrote:

do you have recursion somewhere in the code? can u share the debug logs?

On Wed, Jan 22, 2014 at 6:16 PM, Jesse Campbell hikeit@gmail.com wrote:

I’m running into a weird issue that hasn’t come up for me in previous
cookbooks…

I’m getting:

SystemStackError

stack level too deep

from the deploy_revision provider.

I am having a rather difficult time getting anything meaningful out of
it in terms of debugging information.
Any ideas? What more info can I provide that might help?

Centos 6.4, chef 11.4.4 (can’t switch to 11.6+ yet because my new file
provider broke my code… i know… ironic…)

-Jesse


#5

Ah hah!

Chef::Provider::File::Deploy is in application_java/libraries, and
application_java wasn’t loaded on the vm.

would be nice if the scm_provider change, pointing at something that
didn’t exist, gave a classnotfound exception instead of “stack level
too deep”

On Thu, Jan 23, 2014 at 10:13 AM, Jesse Campbell hikeit@gmail.com wrote:

here’s a cleaner version of the code that is still failing:

53: deploy_revision(“idp”) do
54: deploy_to "/srv/idp"
55: scm_provider Chef::Provider::File::Deploy
56: repo "/srv/war_download/foo.war"
57: end

the log output with debug:
[2014-01-23T15:12:26+00:00] INFO: Processing deploy_revision[idp]
action deploy (sch_sso::idp_app line 53)
[2014-01-23T15:12:26+00:00] INFO: Running queued delayed notifications
before re-raising exception
[2014-01-23T15:12:26+00:00] DEBUG: Re-raising exception:
SystemStackError - deploy_revision[idp] (sch_sso::idp_app line 53) had
an error: SystemStackError: stack level too deep
/opt/chef/embedded/lib/ruby/gems/1.9.1/gems/chef-11.4.4/lib/chef/provider.rb:46

and the “compiled resource”:
Compiled Resource:

Declared in /var/cache/chef/cookbooks/sch_sso/recipes/idp_app.rb:53:in

`from_file’

deploy_revision(“idp”) do
provider Chef::Provider::Deploy::Revision
action :deploy
retries 0
retry_delay 2
deploy_to "/srv/idp"
repository_cache "cached-copy"
purge_before_symlink [“log”, “tmp/pids”, “public/system”]
create_dirs_before_symlink [“tmp”, “public”, “config”]
symlink_before_migrate {“config/database.yml”=>“config/database.yml”}
symlinks {“system”=>“public/system”, “pids”=>“tmp/pids”, “log”=>“log”}
revision "HEAD"
remote "origin"
scm_provider Chef::Provider::Deploy
keep_releases 5
cookbook_name "sch_sso"
recipe_name "idp_app"
repo "/srv/war_download/foo.war"
end

On Wed, Jan 22, 2014 at 11:16 PM, Alastair Firth alfirth@gmail.com wrote:

[2014-01-23T00:34:30+00:00] INFO: Processing deploy_revision[xxxxx] action
deploy (/var/cache/chef/cookbooks/application/providers/default.rb line 122)
[2014-01-23T00:34:30+00:00] INFO: Running queued delayed notifications
before re-raising exception
[2014-01-23T00:34:30+00:00] DEBUG: Re-raising exception: SystemStackError -
deploy_revision[xxxxx]
(/var/cache/chef/cookbooks/application/providers/default.rb line 122) had an
error: SystemStackError: stack level too deep
/opt/chef/embedded/lib/ruby/gems/1.9.1/gems/chef-11.4.4/lib/chef/provider.rb:46
[2014-01-23T00:34:30+00:00] ERROR: Running exception handlers

with application v 2.0.4
updating to 4.1.4 didn’t fix.

maybe something in the method_missing overrides?

On Wed, Jan 22, 2014 at 9:33 PM, Ranjib Dey dey.ranjib@gmail.com wrote:

do you have recursion somewhere in the code? can u share the debug logs?

On Wed, Jan 22, 2014 at 6:16 PM, Jesse Campbell hikeit@gmail.com wrote:

I’m running into a weird issue that hasn’t come up for me in previous
cookbooks…

I’m getting:

SystemStackError

stack level too deep

from the deploy_revision provider.

I am having a rather difficult time getting anything meaningful out of
it in terms of debugging information.
Any ideas? What more info can I provide that might help?

Centos 6.4, chef 11.4.4 (can’t switch to 11.6+ yet because my new file
provider broke my code… i know… ironic…)

-Jesse


#6

On Thursday, January 23, 2014 at 7:32 AM, Jesse Campbell wrote:

Ah hah!

Chef::Provider::File::Deploy is in application_java/libraries, and
application_java wasn’t loaded on the vm.

would be nice if the scm_provider change, pointing at something that
didn’t exist, gave a classnotfound exception instead of “stack level
too deep”

This is definitely a bug, might be an error in a const_missing handler we have set up for back compat.


Daniel DeLeo