Welcome to NexusFi: the best trading community on the planet, with over 150,000 members Sign Up Now for Free
Genuine reviews from real traders, not fake reviews from stealth vendors
Quality education from leading professional traders
We are a friendly, helpful, and positive community
We do not tolerate rude behavior, trolling, or vendors advertising in posts
We are here to help, just let us know what you need
You'll need to register in order to view the content of the threads and start contributing to our community. It's free for basic access, or support us by becoming an Elite Member -- see if you qualify for a discount below.
-- Big Mike, Site Administrator
(If you already have an account, login at the top of the page)
I'm trying to communicate between strategies in NinjaTrader and I don't want to use IO. I'd like something faster and a bit easier to implement in other strategies later. I'm thinking of a parent console application that manages the communication between them all, but I'm wondering what other solutions you've come up with.
To date I've tried communicating via windows messages, which didn't work because of the limitations of NinjaTrader as well as cross thread communication and IPC, but the threads aren't Thread Pool and IPC won't work for the same reasons windows messages won't work.
So before I go balls to the wall with my console manager, I was wondering if anybody had come up with something better or just an alternative, as I'd rather not do this. At this point, it may be my only option though.
Can you help answer these questions from other members on NexusFi?
you could use .net remoting, or any of the open source message bus programs for .net.. there are several of them on codeplex and/or googlecode, most include a console message host, no need to roll your own =)
Nice sefstrat; precisely what I was looking for. And the ability to make it a background process is awesome!
Edit:
I am finding it incredibly difficult to get setup with Mass Transit, I can't even get their samples to work. Their documentation is sparse to put it best, and there seems to be no correlation between the documentation they do have and their actual source code available for download. Can you provide an abstract version of how you're doing it? I don't want to steal your code or anything, but maybe just give an idea of how to even get started with it?
EditEdit:
I found a better implementation, at least for me, that I seem to be having some luck with. NServiceBus, I was able to get up and running in about 2 minutes compared to the all day event that was Mass Transit. There's another good looking service bus implementation called Rhino. Anyway, just because it didn't work for me doesn't mean it won't work for someone else, I'm just including these others so people will know their options. Thanks again, sefstrat.
Though just what I need, I am finding these programs incredibly difficult to use.
I have been trying to develop a method to run two strategies at once.
One strategy is to calculate the signal. (Calculate on Bar Close = true) It then sends the Close[0] price to the 2nd strategy once the signal = true. The 2nd strategy (Calculate on Bar Close = false) places a limit order 2 ticks +- the Close[0]. So if the price moves away from the order without being filled, a cancel order can be initiated.
Now I have looked at the DataTransfer Class and am completely lost as to how to setup communication. As I recall, it simply calculated PnL figures.
Using these 3rd party programs with VS seems a little difficult.