weird issue with utility
I have a little utility I run on my dev box which calls data-fetching processes on my production box. Usually works great: cfloop index=i from=0 to=-90 step=-1 cfhttp url=http://production.com/?Date=#DateFormat(DateAdd('d', i, now()), 'm/d/')# /cfloop But now I have it pointed at a different process and here's what happens: 1. I tell utility to go 2. Using Fusion Reactor, I can see that http://production.com/?Date=4/15/2014 has been called and is running on production 3. When, that finishes, http://production.com/?Date=4/14/2014 is *not* called but my utility keeps spinning as if it's still doing its thing Any ideas? -- John Bliss - http://www.linkedin.com/in/jbliss ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:358333 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: weird issue with utility
I have a little utility I run on my dev box which calls data-fetching processes on my production box. Usually works great: cfloop index=i from=0 to=-90 step=-1 cfhttp url=http://production.com/?Date=#DateFormat(DateAdd('d', i, now()), 'm/d/')# /cfloop But now I have it pointed at a different process and here's what happens: 1. I tell utility to go 2. Using Fusion Reactor, I can see that http://production.com/?Date=4/15/2014 has been called and is running on production 3. When, that finishes, http://production.com/?Date=4/14/2014 is *not* called but my utility keeps spinning as if it's still doing its thing Any ideas? I'm pretty sure that HTTP requests made from CF, by default, will run serially rather than concurrently. So, until the first URL finishes and CF gets a completed response, the loop won't go to the next one. You can avoid this by using CFTHREAD, although that may cause other problems if you're not careful - I'm not sure I'd want to use 90 threads in a production environment. Dave Watts, CTO, Fig Leaf Software 1-202-527-9569 http://www.figleaf.com/ http://training.figleaf.com/ Fig Leaf Software is a Veteran-Owned Small Business (VOSB) on GSA Schedule, and provides the highest caliber vendor-authorized instruction at our training centers, online, or onsite. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:358334 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: weird issue with utility
Right. Usually, it runs serially just fine. With this production URL, it behaves in the way I described. On Tue, Apr 15, 2014 at 3:42 PM, Dave Watts dwa...@figleaf.com wrote: I have a little utility I run on my dev box which calls data-fetching processes on my production box. Usually works great: cfloop index=i from=0 to=-90 step=-1 cfhttp url=http://production.com/?Date=#DateFormat(DateAdd('d', i, now()), 'm/d/')# /cfloop But now I have it pointed at a different process and here's what happens: 1. I tell utility to go 2. Using Fusion Reactor, I can see that http://production.com/?Date=4/15/2014 has been called and is running on production 3. When, that finishes, http://production.com/?Date=4/14/2014 is *not* called but my utility keeps spinning as if it's still doing its thing Any ideas? I'm pretty sure that HTTP requests made from CF, by default, will run serially rather than concurrently. So, until the first URL finishes and CF gets a completed response, the loop won't go to the next one. You can avoid this by using CFTHREAD, although that may cause other problems if you're not careful - I'm not sure I'd want to use 90 threads in a production environment. Dave Watts, CTO, Fig Leaf Software 1-202-527-9569 http://www.figleaf.com/ http://training.figleaf.com/ Fig Leaf Software is a Veteran-Owned Small Business (VOSB) on GSA Schedule, and provides the highest caliber vendor-authorized instruction at our training centers, online, or onsite. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:358335 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: weird issue with utility
Right. Usually, it runs serially just fine. With this production URL, it behaves in the way I described. I would then assume that this production URL is taking much longer to complete. Dave Watts, CTO, Fig Leaf Software 1-202-527-9569 http://www.figleaf.com/ http://training.figleaf.com/ Fig Leaf Software is a Veteran-Owned Small Business (VOSB) on GSA Schedule, and provides the highest caliber vendor-authorized instruction at our training centers, online, or onsite. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:358336 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: weird issue with utility
It sounds like maybe the first cfhttp call from the client is ending with maybe a 500 error at the production.com URI and not really returning a response to the client. In that instance I can see the first iteration in the client side loop just stalling, while on the end point side, Fusion Reactor thinks the request is done. Do you get output on the client side when just calling the first iteration... cfloop index=i from=0 to=-90 step=-1 cfhttp url=http://production.com/?Date=#DateFormat(DateAdd('d', i, now()), 'm/d/')# cfdump var=#cfhttp# cfbreak /cfloop Byron Mann Lead Engineer Architect HostMySite.com On Tue, Apr 15, 2014 at 3:32 PM, John M Bliss bliss.j...@gmail.com wrote: I have a little utility I run on my dev box which calls data-fetching processes on my production box. Usually works great: cfloop index=i from=0 to=-90 step=-1 cfhttp url=http://production.com/?Date=#DateFormat(DateAdd('d', i, now()), 'm/d/')# /cfloop But now I have it pointed at a different process and here's what happens: 1. I tell utility to go 2. Using Fusion Reactor, I can see that http://production.com/?Date=4/15/2014 has been called and is running on production 3. When, that finishes, http://production.com/?Date=4/14/2014 is *not* called but my utility keeps spinning as if it's still doing its thing Any ideas? -- John Bliss - http://www.linkedin.com/in/jbliss ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:358337 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: weird issue with utility
Good idea. I'll check... On Tue, Apr 15, 2014 at 4:13 PM, Byron Mann byronos...@gmail.com wrote: It sounds like maybe the first cfhttp call from the client is ending with maybe a 500 error at the production.com URI and not really returning a response to the client. In that instance I can see the first iteration in the client side loop just stalling, while on the end point side, Fusion Reactor thinks the request is done. Do you get output on the client side when just calling the first iteration... cfloop index=i from=0 to=-90 step=-1 cfhttp url=http://production.com/?Date=#DateFormat(DateAdd('d', i, now()), 'm/d/')# cfdump var=#cfhttp# cfbreak /cfloop Byron Mann Lead Engineer Architect HostMySite.com On Tue, Apr 15, 2014 at 3:32 PM, John M Bliss bliss.j...@gmail.com wrote: I have a little utility I run on my dev box which calls data-fetching processes on my production box. Usually works great: cfloop index=i from=0 to=-90 step=-1 cfhttp url=http://production.com/?Date=#DateFormat(DateAdd('d', i, now()), 'm/d/')# /cfloop But now I have it pointed at a different process and here's what happens: 1. I tell utility to go 2. Using Fusion Reactor, I can see that http://production.com/?Date=4/15/2014 has been called and is running on production 3. When, that finishes, http://production.com/?Date=4/14/2014 is *not* called but my utility keeps spinning as if it's still doing its thing Any ideas? -- John Bliss - http://www.linkedin.com/in/jbliss ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:358338 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: weird issue with utility
I would suggest you log the responses you get back from the cfhttp request which may tell you if there is a problem. On Tue, Apr 15, 2014 at 8:32 PM, John M Bliss bliss.j...@gmail.com wrote: I have a little utility I run on my dev box which calls data-fetching processes on my production box. Usually works great: cfloop index=i from=0 to=-90 step=-1 cfhttp url=http://production.com/?Date=#DateFormat(DateAdd('d', i, now()), 'm/d/')# /cfloop But now I have it pointed at a different process and here's what happens: 1. I tell utility to go 2. Using Fusion Reactor, I can see that http://production.com/?Date=4/15/2014 has been called and is running on production 3. When, that finishes, http://production.com/?Date=4/14/2014 is *not* called but my utility keeps spinning as if it's still doing its thing Any ideas? -- John Bliss - http://www.linkedin.com/in/jbliss ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:358339 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm