Trying to find out why I'm getting lock timeouts when reinit-ing

21 views
Skip to first unread message

Ryan Stille

unread,
Mar 12, 2014, 5:19:13 PM3/12/14
to model...@googlegroups.com
Hi, I'm trying to track down why I'm getting cflock timeouts when I reinit my MG app. I'm running MG 3.1.299, ColdSpring 1.2, on CF10.

We recently added a new service to our ColdSpring configuration. Now whenever I reinit my app (90% of the time) I get an exception:

A timeout occurred while attempting to lock bf_2FF19388-5056-8039-313716B9BA80BB20.bean_SessionService.
C:\inetpub\wwwroot\coldspring\beans\DefaultXmlBeanFactory.cfc (756)
C:\inetpub\wwwroot\coldspring\beans\DefaultXmlBeanFactory.cfc (632)
C:\inetpub\wwwroot\ModelGlue\gesture\externaladapters\ioc\ColdSpringAdapter.cfc (46)
C:\inetpub\wwwroot\ModelGlue\gesture\ModelGlue.cfc (228)
C:\inetpub\wwwroot\navpointcx\controller\Controller.cfc (19)

I've added debugging code to ColdSpring to log when beans are created and inited. They all take < 10ms. The "init" method on this new service just sets 2 config values and then returns "this". There's nothing in here that I can see that would be slowing things down.

I could see how other requests might get a lock timeout while they wait for me to reinit the framework, but I don't understand why I am getting a lock timeout since I'm the one reinitalizing.

How is another request creating beans and blocking me? Shouldn't only my request be the one creating beans?

I only get the timeout in production so it's hard to troubleshoot.

Thanks for any help.

Ryan Stille

unread,
Mar 12, 2014, 5:21:24 PM3/12/14
to model...@googlegroups.com
BTW, the start of that stack trace there, line 19 in the controller is this:
<cfset var SecurityService = getModelGlue().getBean("SecurityService") />

Ryan Stille

unread,
Mar 12, 2014, 6:08:34 PM3/12/14
to model...@googlegroups.com
I think it's related to another change we made at the same time - which is accessing the SecurityService from Application.cfc.

Dan Wilson

unread,
Mar 12, 2014, 7:10:36 PM3/12/14
to model...@googlegroups.com
It might be a conflicting lock in your code.

>From your description, it only happens in production, meaning it happens when concurrent users do the same thing, or try to use the same shared resource.

DDW

Wednesday, March 12, 2014 6:08 PM
I think it's related to another change we made at the same time - which is accessing the SecurityService from Application.cfc.
--
--
Model-Glue Sites:
Home Page: http://www.model-glue.com
Documentation: http://docs.model-glue.com
Bug Tracker: http://bugs.model-glue.com
Blog: http://www.model-glue.com/blog
 
You received this message because you are subscribed to the Google
Groups "model-glue" group.
To post to this group, send email to model...@googlegroups.com
To unsubscribe from this group, send email to
model-glue+...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/model-glue?hl=en
---
You received this message because you are subscribed to the Google Groups "model-glue" group.
To unsubscribe from this group and stop receiving emails from it, send an email to model-glue+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Wednesday, March 12, 2014 5:21 PM
BTW, the start of that stack trace there, line 19 in the controller is this:
<cfset var SecurityService = getModelGlue().getBean("SecurityService") />

On Wednesday, March 12, 2014 4:19:13 PM UTC-5, Ryan Stille wrote:
--
--
Model-Glue Sites:
Home Page: http://www.model-glue.com
Documentation: http://docs.model-glue.com
Bug Tracker: http://bugs.model-glue.com
Blog: http://www.model-glue.com/blog
 
You received this message because you are subscribed to the Google
Groups "model-glue" group.
To post to this group, send email to model...@googlegroups.com
To unsubscribe from this group, send email to
model-glue+...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/model-glue?hl=en
---
You received this message because you are subscribed to the Google Groups "model-glue" group.
To unsubscribe from this group and stop receiving emails from it, send an email to model-glue+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Wednesday, March 12, 2014 5:19 PM
Hi, I'm trying to track down why I'm getting cflock timeouts when I reinit my MG app. I'm running MG 3.1.299, ColdSpring 1.2, on CF10.

We recently added a new service to our ColdSpring configuration. Now whenever I reinit my app (90% of the time) I get an exception:

A timeout occurred while attempting to lock bf_2FF19388-5056-8039-313716B9BA80BB20.bean_SessionService.

C:\inetpub\wwwroot\coldspring\beans\DefaultXmlBeanFactory.cfc (756)
C:\inetpub\wwwroot\coldspring\beans\DefaultXmlBeanFactory.cfc (632)
C:\inetpub\wwwroot\ModelGlue\gesture\externaladapters\ioc\ColdSpringAdapter.cfc (46)
C:\inetpub\wwwroot\ModelGlue\gesture\ModelGlue.cfc (228)
C:\inetpub\wwwroot\navpointcx\controller\Controller.cfc (19)

I've added debugging code to ColdSpring to log when beans are created and inited. They all take < 10ms. The "init" method on this new service just sets 2 config values and then returns "this". There's nothing in here that I can see that would be slowing things down.

I could see how other requests might get a lock timeout while they wait for me to reinit the framework, but I don't understand why I am getting a lock timeout since I'm the one reinitalizing.

How is another request creating beans and blocking me? Shouldn't only my request be the one creating beans?

I only get the timeout in production so it's hard to troubleshoot.

Thanks for any help.
--
--
Model-Glue Sites:
Home Page: http://www.model-glue.com
Documentation: http://docs.model-glue.com
Bug Tracker: http://bugs.model-glue.com
Blog: http://www.model-glue.com/blog
 
You received this message because you are subscribed to the Google
Groups "model-glue" group.
To post to this group, send email to model...@googlegroups.com
To unsubscribe from this group, send email to
model-glue+...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/model-glue?hl=en
---
You received this message because you are subscribed to the Google Groups "model-glue" group.
To unsubscribe from this group and stop receiving emails from it, send an email to model-glue+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages