f135ta / SimpleProxy

Simple Proxy implementation for Net Core using Castle Dynamic Proxy

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

InvocationContext is not thread safe?

htzhang2 opened this issue · comments

Two threads both write to InvocationContext in BeforeInvoke method:

  1. Thread1:
    invocationCopntext.SetTemporaryData("temp", "value1");

  2. Thread2:
    invocationCopntext.SetTemporaryData("temp", "value2");

This seems corrupt invocationContext.

Is there a thread safe solution?