Normally it would be, but this is a scenario where the user has a
degree of freedom in doing their insert, and if it fails I still need
the non-database actions that happened in the handler to go through
while the database actions are rolled back.
Scenario:
1.) user inputs data
2.) handler
Yeah, I don't like doing anything hack-ish in production. During dev
is fine (and fun), but I like a solid solution.
However, I do think what you've suggested will work. I wrote an
interceptor to apply advice to handlers and also to run them within
execute() but I was having the error catching
I would have thought that a transaction failing would be a pretty extreme
error. I.e. it is unexpected, and not something your application logic
would be built around.
In which case, a global error handler would seem to be the best fit to catch
it and provide a nice error message to the client,
I'm looking through the code, and I'm seeing that you have a try/catch
inside the Transaction itself.
For a transaction to be rolled back, the exception needs to bubble out to
the Transaction code.
It's exactly the same as if I did:
cftransaction
cftry
//do stuff
cfthrow
Hey Mark,
Sorry, the try / catches were something I had been messing with later
on. Anyway, the real issue I guess then, is, how can I avoid throwing
page errors and still be able to handle my transactions? I need the
transaction to fail when an error throws, but still be caught by the
system so
I may have worked out a nice solution, actually, let me give it a
shot...
On Jul 11, 7:07 pm, Mark Mandel mark.man...@gmail.com wrote:
I'm looking through the code, and I'm seeing that you have a try/catch
inside the Transaction itself.
For a transaction to be rolled back, the exception
You can just send me a .zip file with a controller and AOP applied etc, you
know ;o) Should be much easier.
Mark
On Thu, Jul 9, 2009 at 8:41 AM, whostheJBoss dotfus...@changethings.orgwrote:
I'll set you up an account on my server for the foo site, I'll just
have you change your host file
Okie dokie.
On Jul 8, 4:21 pm, Mark Mandel mark.man...@gmail.com wrote:
You can just send me a .zip file with a controller and AOP applied etc, you
know ;o) Should be much easier.
Mark
On Thu, Jul 9, 2009 at 8:41 AM, whostheJBoss
dotfus...@changethings.orgwrote:
I'll set you up an
I have uploaded the file to the Google Group.
On Jul 8, 4:21 pm, Mark Mandel mark.man...@gmail.com wrote:
You can just send me a .zip file with a controller and AOP applied etc, you
know ;o) Should be much easier.
Mark
On Thu, Jul 9, 2009 at 8:41 AM, whostheJBoss
Any thoughts on this? I can repeat this behavior under multiple
configurations.
On Jul 3, 8:09 pm, whostheJBoss dotfus...@changethings.org wrote:
Sorry, here:
http://www.pastey.net/117046
On Jul 3, 6:21 pm, Mark Mandel mark.man...@gmail.com wrote:
I tried accessing the link.. it's
Actually, thanks for chasing this up.
Fun question for you then -
When you are using transaction.execute() (or even the AOP) within the
handler, and you intentionally throw an error to try and rollback the
Transaction, do you see any of the Transfer Transaction elements in the tag
context?
I'm
Ok Mark, I've made a detailed, clear and rich example for you. I
didn't want to lose formatting, so I posted it here:
http://www.oneclickpost.com/post/2OJ7dD0xtN/
This explains the exact behavior I am seeing and my configuration
attempts that are producing it.
If I made any typos, I apologize,
I tried accessing the link.. it's timing out.
I will try it again later.
Mark
On Fri, Jul 3, 2009 at 7:59 PM, whostheJBoss dotfus...@changethings.orgwrote:
Ok Mark, I've made a detailed, clear and rich example for you. I
didn't want to lose formatting, so I posted it here:
Sorry, here:
http://www.pastey.net/117046
On Jul 3, 6:21 pm, Mark Mandel mark.man...@gmail.com wrote:
I tried accessing the link.. it's timing out.
I will try it again later.
Mark
On Fri, Jul 3, 2009 at 7:59 PM, whostheJBoss
dotfus...@changethings.orgwrote:
Ok Mark, I've made a
I was just coming here to update this thread...
I posted this to Railo's group:
http://groups.google.com/group/railo/browse_thread/thread/a34c465edcd85263
It seems that Railo is failing to rollback, not Transfer.
On Jul 2, 12:38 am, Mark Mandel mark.man...@gmail.com wrote:
Does Railo not
From Micha:
this was a failure (only in version 3.1.0.015 to 3.1.019) we have
already fixed, please update to newest release 3.1.0.020 on
dev.railo.ch
or wait for release coming today/tomorrow on www.
Go figure!
On Jul 2, 12:53 am, whostheJBoss dotfus...@changethings.org wrote:
I was just
What DB is this on?
Is this your modified code? I believe you made significant changes to the
way transaction AOP worked?
Mark
On Wed, Jul 1, 2009 at 8:52 PM, whostheJBoss dotfus...@changethings.orgwrote:
Perhaps I'm doing this totally wrong, but this is what I'm trying...
I have a bean
It's on MySQL 5, and no, this is a clean Transfer, not the modified
AOP version.
On Jul 1, 4:00 am, Mark Mandel mark.man...@gmail.com wrote:
What DB is this on?
Is this your modified code? I believe you made significant changes to the
way transaction AOP worked?
Mark
On Wed, Jul 1, 2009
Well, I've managed to get it working, not sure what was going on.
However, when I run the event that does the create, it traces that it
was advised. However, if I run the event again it does not. So, it
only advises the first time. What could be causing this?
On Jul 1, 5:54 am, Mark Mandel
Ok, it's back to giving me problems. I don't know what the issue is
here.
Mark, do you think you can you shoot me over one very simple working
example of AOP advice with a service layer in ColdBox? Doesn't have to
be anything complicated, just one simple example where the handler
calls the
You don't want to be advising the method on every call. Once the object has
AOP advice applied to it, it's done. You don't have to do any more work.
The documentation shows a clear example of how to use the AOP:
Yes, I did that example exactly before, that's what this is based on.
So the trace I see that says weaving advice the first time, that
just means it's modifying the method? Even though I don't see that
trace the next time, the advice is still there?
On Jul 1, 2:36 pm, Mark Mandel
On Thu, Jul 2, 2009 at 10:43 AM, whostheJBoss dotfus...@changethings.orgwrote:
Yes, I did that example exactly before, that's what this is based on.
So the trace I see that says weaving advice the first time, that
just means it's modifying the method? Even though I don't see that
trace the
23 matches
Mail list logo