Distributed shared memory library for C++? [closed] - c++

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 3 years ago.
Improve this question
I am writing a distributed application framework in C++. One of the requirements is the provision of distributed shared memory. Rather than write my own from scratch (and potentially re-invent the wheel), I thought I would see if there were any pre-existing Open source libraries - a quick google search did not yield anything to useful.
Does anyone on here have any experience of a good C++ DSM library that they can recommend?
Ideally, the library will support MRMW (Multiple readers/multiple writers), but I can make do with MRSW (Multiple readers, single writer) if need be. I am developing on Linux.

Ace shared memory is for sharing on 1 platform.
Distributed Shared Memory is very much non-trivial as there are issues regarding transactionality to solve. To effectively use Distributed Shared Memory (even for a copy) you will find you need (among other things) distributed synchronization algorithms and protocols that need resiliency in the face of failure. (Shshooot! aint that always the way!)
Significant research papers have been written about these issues (see some of the chapter bibliographies of Taubenfield's book)
This is really a warning that "rolling your own" will be a significant project in and of itself.

Have you considered memcached ?
It is network distributed and it can be really fast.
It has bindings for lots of languages, you can access it from different OS and supports multiple writers multiple readers.

Try the ACE library, it has a lot of good stuff you'll like. They have a Shared_memory class in there but I'm not sure its a DSM - if not, they have plenty of other network/distributed stuff you might find interesting.

Related

Does a certified (ISO 26262 or similar) C++ standard library exist? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 2 years ago.
Improve this question
While certified C++ toolchains (compiler etc.) exist I did not find any certified C++ standard library (STL).
Does anyone know of someone providing this?
Certification demands strict following of ISO26262 and ASPICE standards, which would mean writting all documentation from system to unit level and also tests on all levels, parallel with documentation (see V model in ISO26262). Also, this would demand safety case for STL as "safety element out of context", which would demand inventing assumptions of use for all library parts and creating safety manual for user which will require use of library only in intended way. This would increase development cost for order of magnitude, and then market for this would be non-existent, as using it would demand writing custom memory manager which would allocate memory from statically allocated space, and then analyzing complete application to proof it'll newer need more memory then this preallocated amount, which would be major undertaking, so certified STL could theoretically exist, but mentioned reasons would probably prevent development of one.

Options for hot deployment [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
My requirement is to seamlessly hot deploy code update to a running service without losing the current status, including collection data. Is there any c++ framework out there I can use to develop such a solution?
You probably should read some research papers on dynamic software updating, e.g. on Kitsune (which you might use)
There is a major issue about updating the call stack (and instances in local variables); read also about continuations; and you might have some special case (if your application is event loop driven like most GUI applications are, you probably want to update the code outside of event handlers).
You certainly should think of dynamic software update very early in your design. Perhaps some terminology and concepts from garbage collection & persistence & serialization techniques are relevant.
Your requirement (to seamlessly hot deploy code update to a running service without losing the current status) is very hard and will need a lot of work (probably years) and is still a difficult & interesting research topic (definitely it is a good PhD subject).
You might want to use your own meta-programming techniques, that is generate most of the relevant C+++ support code by your own code generators.
If you already have a significant code base, you could consider customizing a recent GCC compiler with MELT (e.g. to query the compiler's internal representations and generate some code from them) -but even that means a lot of work-
PS. Coding in something better than C++, like Erlang or Common Lisp, would make your goal less difficult.

Communication method for data exchange between a server and several clients for 10+ years [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
We're running an experiment which will involve collecting data from multiple stations around the world. Each station will be providing HDF5 files with magnetic field measurements in a rate of 1 kHz and some auxiliary data in real time. The latency is going to be a few minutes.
I'm assigned to design this program (in C++, with clients/server model, with server being in linux and clients being cross-platform), and apparently I'll be designing this from scratch. My first concern is not to really do everything from scratch because this will be more error prone and pure wrong, so my question here is: What information/file transfer protocols/libraries should I use so that
The program can live for 10+ years with minimal maintenance
I can have very good support from the community for when I need help.
Since we need something relatively secure, my first thought was libssh (the only cross platform opensource library available out there for ssh), but then after discussing with some pros there I realized that the support there isn't so wonderful because only a few people work with libssh. The pros there hesitated in suggesting OpenSSL, but with OpenSSL I'll have to write my own authentication (apparently, I'm not an expert and that's why I'm asking).
What would you suggest? Please share your vision to whether I should go for OpenSSL, libssh, or something else.
PS: Please, if you're going to start off by saying this question is off-topic, move on and ignore it. Consider being helpful rather than critical.
If you require any additional information, please ask.
I think that OpenSSL might be a good choice.
No you do not have to "write you own authentication" - you just need to generate certificates and keys and put them in the right places - that is all.
I would suggest to look at the examples in <openssl-source-dir>/demos and <openssl-source-dir>/apps to get you started. Reading a book about OpenSSL would also be a good idea - for many other reasons (sometimes not directly related with SSL/TLS).
I hope that helps.

Is there any good boost::filesystem alternative? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
Is there any portable c++ library to work with the filesystem?
I know about boost::filesystem, but I need to know if there is any other.
Thanks!
POCO has similar functionality which you can find under Foundation/FileSystem.
There is at least one more solution worth mentioning - STLSoft, a set of BSD-like licensed libraries, contains a cross-platform wrapper under Windows & Unix native filesystem APIs - PlatformSTL project. The benefit in comparison with boost::filesystem is no need to build anything, the whole library is header-only, you can simply include it in your project. The bad side is lack of documentation though, I spent quite some time to figure out how to use it.
What about QT's QFileSystemModel or QFSFileEngine?
You can find it in the SSVUtils library: https://github.com/SuperV1234/SSVUtils
I found that for an application which needs a lot more than the filesystem API defined in the language it makes sense to encapsulate the filesystem API yourself and on a per application level.
Because in this case you usually need some very specific features (you surely do on the iPhone/MacOSX) and this will be not very portable and also missed by boost and others. In this case you need to go a bit higher in your abstraction layer.
Today the operating system API isn't that bad anymore. Writing a wrapper shouldn't take long.

qpThreads documentation [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 5 years ago.
Improve this question
Is there any documentation on qpThreads? In what way is it different from pthreads?
It looks like qpthread has become a sourceforge project. It hasn't changed in four or five years from the CVS repository and doesn't seem to contain any documentation. Chances are that if you don't have docs on it, then none exist save for the source code and headers of course.
I grabbed the source out of curiosity and it looks like a pretty standard threading implementation that is layered over pthreads. The largest difference is that pthreads is a C-style interface and qpThreads is an OO interface more akin to what you might find in Java. I haven't delved into it very deeply, but you might want to look at the interfaces like java.util.Timer and java.util.concurrent. Some of the interfaces look quite similar to what qpThreads offers.
You might want to investigate replacing it with Boost.thread or something more recent. Chances are that you will have better luck maintaining it. It shouldn't be that hard to do depending on how much code you have to deal with.
From a cursory look at google search results, qpThreads seems to be an obscure C++ threading class library. pthreads is a very widely used, POSIX-compliant, multi-platform threading C API.
The most important thing about using libraries is making sure they are actively maintained.
You should use a well known and heavily used library if possible. This way you will also have a vast number of people to ask questions if you have any.
Please see this similar SO question for more details:
Good c++ lib for threading (or use the search box for more).
Found some documentation finally.
Sourceforge qpthreads