www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - high performance client server solution in D?

reply biocyberman <biocyberman gmail.com> writes:
I am considering to use D and its library to build a high 
performance client-server application. The client will be a cross 
platform (Windows, Mac, Linux) GUI program that can synchronize 
analysis results with the remote central server, and analyze data 
locally. It will also visualize big data files (about 10GB of 
binary data each). The term 'high performance' means it can serve 
several hundreds users with desktop application speed. Further 
more, heavy computation tasks will be done locally on the client 
side. This description is still vague, I know. But that's the 
best I can give for now.

I would choose 'dlangui' and check 'vibe.d' for a start. However, 
I do not need to access the central server via web browsers. Hope 
that you can give some thoughts about this design, what GUI 
library to use, and what back-end library to use.
Mar 23 2017
next sibling parent rikki cattermole <rikki cattermole.co.nz> writes:
On 24/03/2017 2:07 AM, biocyberman wrote:
 I am considering to use D and its library to build a high performance
 client-server application. The client will be a cross platform (Windows,
 Mac, Linux) GUI program that can synchronize analysis results with the
 remote central server, and analyze data locally. It will also visualize
 big data files (about 10GB of binary data each). The term 'high
 performance' means it can serve several hundreds users with desktop
 application speed. Further more, heavy computation tasks will be done
 locally on the client side. This description is still vague, I know. But
 that's the best I can give for now.

 I would choose 'dlangui' and check 'vibe.d' for a start. However, I do
 not need to access the central server via web browsers. Hope that you
 can give some thoughts about this design, what GUI library to use, and
 what back-end library to use.
Yeah go with vibe.d as a starting point for communication. Add a serializer on top to handle the messagers and you'd be good to go. It shouldn't matter what GUI toolkit you use, you will end up writing custom drawing code for that large of data. Otherwise you will hit performance problems.
Mar 23 2017
prev sibling next sibling parent Andrea Fontana <nospam example.com> writes:
On Thursday, 23 March 2017 at 13:07:54 UTC, biocyberman wrote:
 I would choose 'dlangui' and check 'vibe.d' for a start. 
 However, I do not need to access the central server via web 
 browsers. Hope that you can give some thoughts about this 
 design, what GUI library to use, and what back-end library to 
 use.
Maybe you can give a try to zeromq library binding/wrapper for D.
Mar 23 2017
prev sibling parent reply Laeeth Isharc <laeethnospam nospam.laeeth.com> writes:
On Thursday, 23 March 2017 at 13:07:54 UTC, biocyberman wrote:
 I am considering to use D and its library to build a high 
 performance client-server application. The client will be a 
 cross platform (Windows, Mac, Linux) GUI program that can 
 synchronize analysis results with the remote central server, 
 and analyze data locally. It will also visualize big data files 
 (about 10GB of binary data each). The term 'high performance' 
 means it can serve several hundreds users with desktop 
 application speed. Further more, heavy computation tasks will 
 be done locally on the client side. This description is still 
 vague, I know. But that's the best I can give for now.

 I would choose 'dlangui' and check 'vibe.d' for a start. 
 However, I do not need to access the central server via web 
 browsers. Hope that you can give some thoughts about this 
 design, what GUI library to use, and what back-end library to 
 use.
cerealed, orange, and msgpack for serialisation/deserialisation (see code.dlang.org). Depends how complicated your D structures are. I found of those three msgpack handles more (for what I am doing), but vibed json serialiseToPrettyJSON (sp?) etc covers some that msgpack chokes on (trouble with Algebraic and TaggedAlgebraic from what I remember). However for speed asdf has better performance. But I guess for binary data you may as well use msgpack. I use nanomsg over 0MQ as I was burned a couple of years back by a problem I encountered using Salt Stack (which was then based on 0MQ) where I think if the server hangs up mid-connection than it's not completely straightforward to get the clients talking to it again. 0MQ is certainly more stable. I find nanomsg easier to use, and I haven't found too many problems with it (IPC on Windows not implemented/didn't work). If you use either, you might want to protect sockets if it isn't on internal network. stunnel worked fine for me. Dlangui was fine for GUI and very happy with it on linux and Windows. Much quicker to develop for that than in browser, was our experience.
Mar 23 2017
parent biocyberman <biocyberman gmail.com> writes:
 Laeeth Isharc and rikki cattermole: Thank you for your inputs. 
Msgpack is definitely something I will consider. I tried search 
some show cases and open-source projects of this kind for Dlang 
but still haven't found one. Those applications will give clearer 
ideas.
Mar 23 2017