Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 8 years ago.
Improve this question
I'm looking into writing a cross-platform (Windows/Debian/Darwin/Red Hat) service and am comparing language options. I really appreciate Go's cross-platform threading abilities and easy cross-compiling, but I want to make sure I'll be able to easily reach any native (eg. Windows Service) APIs when needed.
What sort of things should I be considering to drive my language decision?
Go has full support for calling into arbitrary Win32 API's via its core syscall package.
While calling out to raw Win32 via syscall is not exactly pretty to write (mostly because you're crossing the managed/unmanaged boundary, and back) and has no support from the compiler (akin to, say, that of Delphi), this works just OK, and generation of wrapper functions for such API calls can be automated—the Go core packages use this facility for themselves, other popular examples include the odbc package.
Note that there already exists winsvc—a library which interfaces Go with the Windows SCM and event log.
Also look at service which provides unified API for turning your program into a daemon/service using platform-native tools (it uses winsvc on Windows, IIRC).
Related
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 4 years ago.
Improve this question
I want to go with Xamarin.Forms project. Now, I am bit confuse for consuming Rest API for this project. Performance matters.
There are many available but can any body please suggest me which should be best for Xamarin.Forms(.Net Standard)?
Microsoft Http Libraries or third party libraries like Refit, RESTSharp, PortableRest, etc.
Please suggest
All of these options are viable. I think the performance differences between these libraries will be marginal. So, it mostly comes down to what you feel comfortable with.
I like to use Refit because it will take a lot of redundant code out of your hands and you just have to focus on the contract. All the code for the actual calls is generated at compile-time (and thus won't impact your performance at runtime).
Also have a look at how well the library is maintained and if it's active. If you choose one that is already inactive for a while, chances are that you will start relying on older software versions which might not be what you want.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 2 years ago.
Improve this question
I have Compact Logix Ethernet/Ip PLC. I want to make small scada/hmi on my pc with C#. I can use visual studio 2017 windows forms. I will take some data from plc to pc and I will show on c# and changed some picture image.
how can I do communication C# and Allen Bradley PLC via ethernet/IP. I need your helps, sample programs, libraries, support, advises.
Look at AdvancedHMI. It is an HMI/SCADA Visual Studio toolkit with AB drivers. You can do most HMI stuff without writing code, but you can also use VB or C# for advanced tasks.
Look at EEIP Library. They have a C# and Java library for Ethernet/IP communication. They even offer some videos on YouTube on how to use it. But be aware, that some of this free libraries have some rough edges or bugs with them. Personally, I would use Modbus or another PLC before using Ethernet/IP along with a PC.
There is an open-source project called libplctag which has a few .NET wrappers, some of which are on nuget: https://www.nuget.org/packages/libplctag/, https://www.nuget.org/packages/PlcTag.Net/
Full disclosure: I'm one of the authors of the first wrapper.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
So I'm curious about this. I assume the building of operating systems is a monumental task, especially with all the back end stuff that an os involves. I was curious if I wanted to rework the front end of an operating system, but take advantage of existing architecture/backend, what would be the best resources to use? Also, can you guys point to any examples of well designed front ends of operating systems that aren't really mainstream? It seems like everyone uses pretty large well known OS.
Yes, you can. But like you said, it's a huge, huge task. I am not sure of windows or mac, but in Linux you have options to do so. You can download a Kernel from https://www.kernel.org/ and write applications around it.
If your goal is to make applications around the kernel, then look at linux application development resources. Check out linux desktop environments https://en.wikipedia.org/wiki/Desktop_environment#History_and_common_use to see which one is good.
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 7 years ago.
Improve this question
Yes, while i'm working on node.js, i still love perl, :)
The old web product is based on old perl CGI, i'm looking to the simplest way to fix XSS/Sql injection/etc. web security holes, within a week including testing, :(
So for
Catalyst
Dancer
Mason
Maypole
Mojolicious
which one should i use in the ARM platform ?
Thank you !
You have fallen foul of the primarily opinion-based off-topic categorisation, and your question will probably be closed very soon. However I think it's worth offering a few guidelines here
First of all you should absorb what is written in CGI::Alternatives as it is a reasonable summary of the subject
Next you should separate the HTML generation functionality of your existing CGI code from the interface itself, and consider replacements for each of them separately. If you were to use HTML::Tiny together with CGI::Simple then your code would have to change very little and you would have achieved better partitioning of functionality
Ideally you will move on to one of the many templating systems such as Template Toolkit, together with one of the frameworks, which is the topic of your question. In the end you will need to do a lot of research and many trials to discover how well each framework fits your requirement, in terms of both the feature list and the convenience and clarity of the API
All I can do here is say that I am very fond of the Mojolicious suite and suggest that it may be a good starting point. The API focuses on command chaining in a way similar to Ruby, and there is a Mojolicious::Plugin::CGI accessory which will allow you to execute CGI scripts unchanged during your migration
Note however that all of the frameworks that you mention, as well as several others, will have their proponents. That is why you must make the selection yourself, as such recommendations will be influenced primarily by familiarity, and without your own knowledge of the requirements of your project
Unfortunately I cannot speak to the security issues of the various options, but I hope that has helped a little
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
Why does modern os implement a kind of hirarchy of calling internal functions?
like in windows when you call ReadFile function you acually call to NtReadFile.
Why doesnt windows call directly into NtReadFile?
What will happen if the os will call into internal function directly?
The current version of Windows is based on Windows NT, which was started in 1989. Back then they didn't know what OS/API would be popular so they designed Windows NT to have a generic native API (NtReadFile) and multiple subsystems (Windows, POSIX, OS/2) that would translate calls into that native API.
In 1989 Windows was not popular, and the designers intended that OS/2 would be the primary subsystem. It was only after Microsoft left the OS/2 partnership with IBM and Windows 3.0 came out in 1990 and became very popular that they decided to make a Windows subsystem. As a result, the Win32 subsystem was created to translate calls like ReadFile into NtReadFile.
Decoupling and legacy. You have to remember that NT was originally designed as a microkernel that would support multiple APIs on top of it, with the default API of course being the already established WIN32 API.
If you call NtReadFile directly you are no longer using the WIN32 API.