Closed AndreasHoffmann2 closed 2 years ago
Thank you for asking this question.
The last commit was by me and I used to be one of the more active project collaborators before that, so I'll briefly offer my perspective.
I wish this project were still more active, and I'd quite probably keep contributing to it. The reason I suspended my activity here is that there hasn't been a major release in about 2 years, and I found it increasingly frustrating to see my contributions going nowhere. As long as there is no new release, all the time and work invested won't benefit anyone and is essentially wasted.
As to alternatives: I am not aware of a fully compatible drop-in replacement; however, there are libraries doing something similar, though off the top of my head, I don't remember them all.
For one thing, newer version of .NET have something called DispatchProxy
directly in the FCL, though I've never looked closely at it. It appears to be much less versatile than DynamicProxy.
Then there are new approaches that make use of Roslyn source generators to generate proxy code. One such library is Avatar. Using Roslyn instead of Reflection is a promising approach because it can keep up more easily with new language developments. Reflection simply doesn't have the same level of (language) feature parity as Roslyn.
Thank you vor the answer. It would be shame if this project was not developed any further.
I had a look into DispatchProxy
. Calling it "less versatile" is an understatement. I can describe the full functionality in a few words:
You create a subclass of DispatchProxy
with the method object Invoke(MethodInfo targetMethod, object[] args)
. Then, you can use DispatchProxy.Create
to create interface-implementations, where each call is redirected to this method.
That's it. Really.
If you want to forward this call to a target, you need to inject the target after the proxy's creation.
Fortunately, that slim package is still enough for my use-case.
I am currently wondering if this project is still maintained.
Short answer: yes, but that maintenance is severely lacking and lagging. We need to get our act together.
I do read everything, but unfortunately life has really gotten in the way. Castle Core 5.0 kept falling away in my inbox, but I've had it starred at the top of my inbox since Ian's comment 10 days ago in #602. Thanks for another push, I've logged #613 and plan to make progress tomorrow.
I'll close this for now.
I am currently wondering if this project is still maintained. Can anybody answer that?
Just wondering, since the last checkin has been more than a year ago.
Are there any alternatives to the DynamicProxy?