A Korean financial company runs a profitable HFT(High Frequency Trading) system with DMA(Direct Market Access) to KRX(Korea Exchange). We rewrote trading strategies and related code from C++ to Rust, and the system recently got deployed to production.
Posted byrust2 months ago
The project has been up for 16 months, the trading has been up for 10 months, it has been profitable for 9 months, Rust build integration has been set up for 10 months, trading strategy rewrite has been worked for 7 months, the final push took a month. The final push required Rust version beating (already quite optimized) C++ version in latency in all cases, even if it is just a little bit. This was achieved. (Although to be honest, it was actually achieved by switching active development to Rust and putting C++ version in maintenance mode.)
Click here to subscribe to SonyLIV: Click here to watch full episodes of Ladies. Ladies special ep 21. Published on Jan 23, 2019. Click here to subscribe to SonyLIV: Click here to. Click here to subscribe to SonyLIV: Click here to Subscribe to SET India:.
x86_64-pc-windows-msvc target is used with Visual Studio MSBuild based build system for release and x86_64-unknown-linux-gnu target is used with CMake based build system for CI. bindgen and cbindgen are used for C++ FFI. C++17 standard is used, with Visual Studio 2017 and GCC 8. Rust toolchain used is stable channel and immediately updated after the release. Cargo dependencies are locked and updated discretionally. vcpkg is used for C++ package management, both on Windows and Linux. CI was CircleCI 1.0 running on Ubuntu 16.04 LTS, but switched to CircleCI 2.0 with Docker with freedom from dealing with old versions. Deployment is automated by PowerShell Remoting.
Ask me anything, although I can't say I will answer anything. If you are interested in work, PM me. This is posted in the hope that it would be useful as a precedent, because we experienced such resistance first hand.
85 comments
Posted by4 years ago
Archived
I am trying to understand the compilation/build process in Rust language and differences compared to other new language like Go and D or C++.
Can you please shed some light on how build process works in Rust and what are the fundamental differences between these languages? Any blog post/discussion forum, links would be appreciated.
Edit: I read following blogs but doesn't give enough information on comparative differences.
Edit: Found interesting information here: https://mail.mozilla.org/pipermail/rust-dev/2012-October/002465.html
4 comments
I haven't worked for very large organizations and I've never worked for a company that had a 'Build Server'.
What is their purpose? Why aren't the developers building the project on their local machines, or are they? Are some projects so large that more powerful machines are needed to build it in a reasonable amount of time?
The only place I see a Build Server being useful is for continuous integration with the build server constantly building what is committed to the repository. Is it I have just not worked on projects large enough?
Someone, please enlighten me: What is the purpose of a build server?
Will
114k4747 gold badges288288 silver badges375375 bronze badges
KingNestorKingNestor
25.7k4545 gold badges108108 silver badges145145 bronze badges
closed as primarily opinion-based by EJoshuaS, TylerH, Adriaan, gunr2171, Astik AnandNov 6 '17 at 19:55
Many good questions generate some degree of opinion based on expert experience, but answers to this question will tend to be almost entirely based on opinions, rather than facts, references, or specific expertise. If this question can be reworded to fit the rules in the help center, please edit the question.
18 Answers
The reason given is actually a huge benefit. Builds that go to QA should only ever come from a system that builds only from the repository. This way build packages are reproducible and traceable. Developers manually building code for anything except their own testing is dangerous. Too much risk of stuff not getting checked in, being out of date with other people's changes, etc. etc.
mkbmkb
11.1k11 gold badge2222 silver badges4646 bronze badges
Build servers are important for several reasons.
10.7k88 gold badges4949 silver badges8888 bronze badges
What is their purpose?
Take load of developer machines, provide a stable, reproducible environment for builds.
Why aren't the developers building the project on their local machines, or are they?
Because with complex software, amazingly many things can go wrong when just 'compiling through'. problems I have actually encountered:
We've got an amazing stability increase since all public releases start with a get from source control onto an empty folder. Before, there were lots of 'funny problems' that 'went away when Joe gave me a new DLL'.
Are some projects so large that more powerful machines are needed to build it in a reasonable amount of time?
What's 'reasonable'? If I run a batch build on my local machine, there are many things I can't do. Rather than pay developers for builds to complete, pay IT to buy a real build machine already.
Is it I have just not worked on projects large enough?
Size is certainly one factor, but not the only one.
peterchenpeterchen
33.3k1818 gold badges8888 silver badges169169 bronze badges
A build server is a distinct concept to a Continuous Integration server. The CI server exists to build your projects when changes are made. By contrast a Build server exists to build the project (typically a release, against a tagged revision) on a clean environment. It ensures that no developer hacks, tweaks, unapproved config/artifact versions or uncommitted code makes it into the released code.
Rich SellerRich Seller
74.1k2121 gold badges163163 silver badges169169 bronze badges
The build server is used to build everyone's code when it is checked in. Your code may compile locally, but you most likely won't have all the change made by everyone else all the time.
kemiller2002kemiller2002
98k2323 gold badges177177 silver badges235235 bronze badges
I agree with the answers so far in regards to stability, tracability, and reproducability. (Lots of 'ity's, right?). Having ONLY ever worked for large companies (Health Care, Finance) with MANY build servers, I would add that it's also about security. Ever seen the movie Office Space? If a disgruntled developer builds a banking application on his local machine and no one else looks at it or tests it.. BOOM. Superman III.
GregGreg
It's necessary to have a 'clean' environment free of artifacts of previous versions (and configuration changes) in order to ensure that builds and tests work and don't depend on the artifacts. An effective way to isolate is to create a separate build server.
paulwhitpaulwhit
5,81444 gold badges2424 silver badges3030 bronze badges
These machines are used for several reasons, all trying to help you provide a superior product.
One use is to simulate a typical end user configuration. The product might work on your computer, with all your development tools and libraries set up, but the end user most likely won't have the same configuration as you. For that matter, other developers won't have the exact same setup as you either. If you have a hardcoded path somewhere in your code, it will probably work on your machine, but when Dev El O'per tries to build the same code, it won't work.
Also they can be used to monitor who broke the product last, with what update, and where the product regressed at. Whenever new code is checked in, the build server builds it, and if it fails, its clear that something is wrong and the user who committed last is at fault.
samozsamoz
28.3k4949 gold badges129129 silver badges182182 bronze badges
To add on what has already been said :
An ex-colleague worked on the Microsoft Office team and told me a complete build sometimes took 9 hours. That would suck to do it on YOUR machine, wouldn't it?
Andrei RîneaAndrei Rînea
12.8k1313 gold badges104104 silver badges156156 bronze badges
For consistent quality and to get the build 'off your machine' to spot environment errors and so that any files you forget to check in to source control also show up as build errors.
I also use it to create installers as these take a lot of time to do on the desktop with code signing etc.
Ryan O'NeillRyan O'Neill
3,35244 gold badges4141 silver badges5959 bronze badges
We use one so that we know that the production/test boxes have the same libraries and versions of those libraries installed as what is available on the build server.
RC.RC.
23.1k77 gold badges6464 silver badges8989 bronze badges
It's about management and testing for us. With a build server we always know that we can build our main 'trunk' line from version control. We can create a master install with one-click and publish it to the web. We can run all of our unit tests each time code is checked in to make sure it works. By collecting all these tasks into a single machine it makes it easier to get it right repeatedly.
Paul AlexanderPaul Alexander
25.4k1111 gold badges8686 silver badges139139 bronze badges
You are right that developers could build on their own machines.
But these are some of the things our build server buys us, and we're hardly sophisticated build makers:
1,80522 gold badges2727 silver badges3636 bronze badges
Maybe i'm the only one..
I think everyone agrees that one should
But no one cares about automatically built versions.When something was broken in an automatic build, but it's not anymore - who cares? It's a work in progress. Someone fixed it.
When you want to do a release version, you run a build from the repository. And i'm pretty sure you want to tag the version in the repository at that time and not every six hours when the server does it's work.
So, maybe a 'build server' is just a misnomer and it's actually a 'continous test server'. Otherwise it sounds pretty much useless.
StroboskopStroboskop
2,78855 gold badges2929 silver badges4747 bronze badges
A build server gets you a sort of second opinion of your code. When you check it in, the code is checked. If it works, the code has a minimum quality.
BurkhardBurkhard
11.9k2121 gold badges7878 silver badges9898 bronze badges
Additionally, remember that low level languages take much longer to compile than high level languages. It's easy to think 'Well look, my .Net project compiles in a couple of seconds! What's the big deal?' Awhile back I had to mess with some C code and I had forgotten how much longer it takes to compile.
Spencer RuportSpencer Ruport
31.4k1010 gold badges7676 silver badges130130 bronze badges
A build server is used to schedule compile tasks (e.g. nightly builds) of usually large projects located in a repository that can sometimes take more than a couple of hours.
citn
Cargo Rustc Envcitn
70333 gold badges1111 silver badges2828 bronze badges
Rust Conditional Compilation
A build server also gives you a basis for escrow, being able to capture all the parts necessary to reproduce a build in the case that others may have rights to take ownership.
8,78366 gold badges3434 silver badges5353 bronze badges
Rust Buidl Process C Code For MinecraftNot the answer you're looking for? Browse other questions tagged continuous-integrationbuild-processagilebuild-server or ask your own question.Comments are closed.
|
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |