Gamestudio Links
Zorro Links
Newest Posts
Trading Journey
by howardR. 04/24/24 20:04
M1 Oversampling
by Petra. 04/24/24 10:34
Zorro FIX plugin - Experimental
by flink. 04/21/24 07:12
Data from CSV not parsed correctly
by EternallyCurious. 04/20/24 21:39
Scripts not found
by juergen_wue. 04/20/24 18:51
zorro 64bit command line support
by 7th_zorro. 04/20/24 10:06
StartWeek not working as it should
by jcl. 04/20/24 08:38
folder management functions
by VoroneTZ. 04/17/24 06:52
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
3 registered members (vicknick, howardR, sleakz), 674 guests, and 3 spiders.
Key: Admin, Global Mod, Mod
Newest Members
Mega_Rod, EternallyCurious, howardR, 11honza11, ccorrea
19048 Registered Users
Previous Thread
Next Thread
Print Thread
Rating: 5
Page 1 of 2 1 2
Blog post: Reading an HTTP Stream Using C++ Boost Beast #475621
12/28/18 21:32
12/28/18 21:32
Joined: Feb 2017
Posts: 1,725
Chicago
AndrewAMD Offline OP
Serious User
AndrewAMD  Offline OP
Serious User

Joined: Feb 2017
Posts: 1,725
Chicago
I made a blog post for you broker plugin programmers out there. (Are shameless plugs allowed?)

In many (most?) cases, a simple call-and-response model is fine for a REST API plugin.

But what if you have many assets to track and your broker has a nasty rate limit? Or what if you have highly leveraged positions and every last tick counts? What if there's a high likelihood of a flash crash for your assets?

If any of these are true, you should consider streaming the data. Just some food for thought.

https://www.vitaltrades.com/2018/12/28/reading-an-http-stream-using-c-boost-beast/

In this blog post, I stream from the Oanda API in demo mode. Enjoy! laugh

Re: Blog post: Reading an HTTP Stream Using C++ Boost Beast [Re: AndrewAMD] #475625
12/29/18 18:03
12/29/18 18:03
Joined: Aug 2017
Posts: 102
Spain
B
Brax Offline
Member
Brax  Offline
Member
B

Joined: Aug 2017
Posts: 102
Spain
Interesting content Andrew.

I suppouse you'd already thought about it, but i will say it: Put a subscription mechanism so we can follow your posts.

Looking forward for more content.

Bye.

Re: Blog post: Reading an HTTP Stream Using C++ Boost Beast [Re: Brax] #475636
12/30/18 12:33
12/30/18 12:33
Joined: Dec 2016
Posts: 71
F
firecrest Offline
Junior Member
firecrest  Offline
Junior Member
F

Joined: Dec 2016
Posts: 71
Nice blog. I like it. If there are any new posts. Do let me know

Re: Blog post: Reading an HTTP Stream Using C++ Boost Beast [Re: firecrest] #475650
12/31/18 12:34
12/31/18 12:34
Joined: Jul 2000
Posts: 27,982
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,982
Frankfurt
Good stuff!

Re: Blog post: Reading an HTTP Stream Using C++ Boost Beast [Re: Brax] #475692
01/03/19 22:06
01/03/19 22:06
Joined: Feb 2017
Posts: 1,725
Chicago
AndrewAMD Offline OP
Serious User
AndrewAMD  Offline OP
Serious User

Joined: Feb 2017
Posts: 1,725
Chicago
Originally Posted By: brax
Interesting content Andrew.

I suppouse you'd already thought about it, but i will say it: Put a subscription mechanism so we can follow your posts.

Looking forward for more content.

Bye.


Subscribe button is up! I also put up an RSS feed link.

Originally Posted By: firecrest
Nice blog. I like it. If there are any new posts. Do let me know

Originally Posted By: jcl
Good stuff!


Thank you! laugh

Re: Blog post: Reading an HTTP Stream Using C++ Boost Beast [Re: AndrewAMD] #475722
01/05/19 04:53
01/05/19 04:53
Joined: Feb 2017
Posts: 1,725
Chicago
AndrewAMD Offline OP
Serious User
AndrewAMD  Offline OP
Serious User

Joined: Feb 2017
Posts: 1,725
Chicago
I have a new blog post, it's a brief introduction to the DTC protocol.
https://www.vitaltrades.com/2019/01/04/an-introduction-to-the-dtc-protocol/

Let me know if there are any topics you’d like me to discuss. laugh

Re: Blog post: Reading an HTTP Stream Using C++ Boost Beast [Re: AndrewAMD] #475728
01/05/19 16:14
01/05/19 16:14
Joined: Feb 2015
Posts: 652
Milano, Italy
M
MatPed Offline
User
MatPed  Offline
User
M

Joined: Feb 2015
Posts: 652
Milano, Italy
Hi AndrewAMD,
I am an average programmer. I can code my trading ideas, but I have never tried to work with api or interfaces.
I would like to interface Zorro with the rest API of Darwinex, now in beta Test.
Where do you think wshould I start? I mean learning path or any other ideas.

Thank you

Last edited by MatPed; 01/06/19 11:34.
Re: Blog post: Reading an HTTP Stream Using C++ Boost Beast [Re: AndrewAMD] #475730
01/05/19 16:27
01/05/19 16:27
Joined: Aug 2017
Posts: 102
Spain
B
Brax Offline
Member
Brax  Offline
Member
B

Joined: Aug 2017
Posts: 102
Spain
Originally Posted By: AndrewAMD

Subscribe button is up! I also put up an RSS feed link.


Cool!

---

In my case, i am quite interested in system design in general. That is, how to properly design and code a robust and reliable system.

Machine learning applied to trading is another must topic.

Re: Blog post: Reading an HTTP Stream Using C++ Boost Beast [Re: MatPed] #475731
01/05/19 16:29
01/05/19 16:29
Joined: Aug 2017
Posts: 102
Spain
B
Brax Offline
Member
Brax  Offline
Member
B

Joined: Aug 2017
Posts: 102
Spain
Originally Posted By: MatPed
Hi AndrewAMD,
I am an average programmer. I can code my trading ideas, but I have never tried to work with api or interfaces.
I would like to interface Zorro with the rest API of Darwinex, now in beta Test.
Where do you think wshould I start? I mean learning pasth or any other idea.

Thank you


Very good point, i really would like to see a post about this topic. It would be very educational.

Re: Blog post: Reading an HTTP Stream Using C++ Boost Beast [Re: Brax] #475778
01/07/19 19:15
01/07/19 19:15
Joined: Feb 2017
Posts: 1,725
Chicago
AndrewAMD Offline OP
Serious User
AndrewAMD  Offline OP
Serious User

Joined: Feb 2017
Posts: 1,725
Chicago
Originally Posted By: MatPed
Hi AndrewAMD,
I am an average programmer. I can code my trading ideas, but I have never tried to work with api or interfaces.
I would like to interface Zorro with the rest API of Darwinex, now in beta Test.
Where do you think wshould I start? I mean learning path or any other ideas.

Thank you
I suppose I can write about making a darwinex plugin, and then I can share my code. But there is some fundamental knowledge that needs to be understood:

1) How to write a DLL for Windows.
2) How to get this DLL to work nicely with Zorro.
3) How to use Zorro's handy http functions with a REST API.
4) How to import these functions using the plugin interface.
5) And then how to write a plugin. Maybe cover Darwinex as an example.

Well, you can look up most of these things, but I suppose it doesn't hurt to write a mini-series and get some bonus traffic on my site. Does that sound good? laugh

Originally Posted By: brax
In my case, i am quite interested in system design in general. That is, how to properly design and code a robust and reliable system.

Machine learning applied to trading is another must topic.
I'll add these to my maybe list. I'll need to come up with some ideas.

Re: Blog post: Reading an HTTP Stream Using C++ Boost Beast [Re: AndrewAMD] #475793
01/08/19 10:04
01/08/19 10:04
Joined: Feb 2015
Posts: 652
Milano, Italy
M
MatPed Offline
User
MatPed  Offline
User
M

Joined: Feb 2015
Posts: 652
Milano, Italy
Hi Andrew,
thank you for your interest in looking into the knowledge transfer process to develop the Darwinex API plugin.
I am aware that develop a broker plugin is not an easy task. The idea behind the need of the plugin is to generate a TS based on Markowitz/Dual Momentum Strategy using selected Darwins.unfortunately due to the specific nature of the Darwin assets this is plugin is, basically a must, because the EOD quota are not available anywhere else.

There are several Zorro traders active on Darwinex and I will be more than happy to share in the DW Community the link at your website in order to generate as much as traffic is possible.
This is the link to the API testing section https://community.darwinex.com/t/darwin-api-beta-testers-wanted/4566

Ciao

Re: Blog post: Reading an HTTP Stream Using C++ Boost Beast [Re: MatPed] #475797
01/08/19 12:49
01/08/19 12:49
Joined: Feb 2017
Posts: 1,725
Chicago
AndrewAMD Offline OP
Serious User
AndrewAMD  Offline OP
Serious User

Joined: Feb 2017
Posts: 1,725
Chicago
I dug into the Darwinex API a little bit, and I can tell you off the bat that this REST API is a little trickier to implement because it currently only **streams** quotes, there are no snapshots. As you might imagine, streaming is not for beginners. Anyways, I know how to do it, but I cannot use Zorro's http library to stream.

Also, is there a particular reason why you want to use the REST API instead of the MT4/5 bridge? What advantages are you expecting?

Re: Blog post: Reading an HTTP Stream Using C++ Boost Beast [Re: AndrewAMD] #475806
01/08/19 15:40
01/08/19 15:40
Joined: Feb 2015
Posts: 652
Milano, Italy
M
MatPed Offline
User
MatPed  Offline
User
M

Joined: Feb 2015
Posts: 652
Milano, Italy
Thank You Andrew, the task is the stream the history not the tick values. For Darwinex project I have in mind EOD data are enough.

ciao

Re: Blog post: Reading an HTTP Stream Using C++ Boost Beast [Re: MatPed] #475832
01/09/19 17:40
01/09/19 17:40
Joined: Feb 2017
Posts: 1,725
Chicago
AndrewAMD Offline OP
Serious User
AndrewAMD  Offline OP
Serious User

Joined: Feb 2017
Posts: 1,725
Chicago
In that case, I'll do a write-up on how to download historical data from any REST API. You won't need a plugin for that, just a Zorro script. laugh

Re: Blog post: Reading an HTTP Stream Using C++ Boost Beast [Re: AndrewAMD] #475856
01/10/19 14:23
01/10/19 14:23
Joined: Feb 2015
Posts: 652
Milano, Italy
M
MatPed Offline
User
MatPed  Offline
User
M

Joined: Feb 2015
Posts: 652
Milano, Italy
great. Respect, man!

Page 1 of 2 1 2

Moderated by  Petra 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1