1

We are using PostSharp as our AOP engine and somehow it is acting really weird. I know that it puts hook points before and after the function and it logs LogEntry and LogSuccess events just before and after the attributed function is called.

I am having our event logging module configured such that user can be awarded different amount of points on both LogEntry and LogSuccess.

Now, when LogEntry happens and I have set it to give 10 points then the person gets 10 X 2 =20 points. But if I set user to get some points on LogSuccess then user does not get any points at all.

Somehow, I feel like LogEntry point value is overriding LogSuccess points.

I have no idea why it is doing that and on top of that I see exactly one event in my database with correct points there.

Has anybody observed this king of behavior from AOPs before?

Thanks,

Lost
  • 12,007
  • 32
  • 121
  • 193
  • 2
    It's difficult if not impossible, generally, to answer such question without seeing your source code (the aspect and how it is being applied to code). Also, using a decompiler may help you understanding how your code has been transformed by PostSharp. – Gael Fraiteur May 10 '12 at 07:14

0 Answers0