C++11/Boost ACE-Replacement-Branch

What?

As TC now officially supports C++11, I forked off a while ago to find out if the ACE framework could be completely replaced by a combination of new C++11 features and Boost.

As it looks pretty promising I reintegrated that branch into the TC repository.

How?

Boost has been added as an external library, since adding it directly into TC (similar to the ACE-lite) has proven to be highly annoying and tedious work.

This means to compile this fork, Boost 1.55 is required to be installed on the system.

For windows it is recommended to install the precompiled binaries:

x64: http://sourceforge.net/projects/boost/files/boost-binaries/1.55.0-build2/boost_1_55_0-msvc-12.0-64.exe/download

x86: http://sourceforge.net/projects/boost/files/boost-binaries/1.55.0-build2/boost_1_55_0-msvc-12.0-32.exe/download

You also need to add an environment variable pointing to your boost installation, e.g.

BOOST_ROOT=c:Boost

Where?

https://github.com/TrinityCore/TrinityCore/commits/boost

Why?

(The following is mostly just IMHO)

With C++11 adding a lot of missing features most of the ACE-based implemented can be replaced by non-framework equivalents.

I chose Boost to fill the missing feature gaps because the documentation is vastly superior than what ACE has to offer. I always found ACE sort of over-engineered and forcing patterns pointless over complicated patterns on developers (Signal handling is a pretty good example for that, why use a class when a callback function could be enough).

But of course this whole topic is probably more a religious discussion

Roadmap

As a reasonable start I chose to deal with authserver first. As of writing this post all authserver code has been completely “de-ACEed” (networking, signal handling, etc.) and currently the focus is on Shared.

Shared as the name says, is also a requirement for authserver and if all ACE usages are removed from Shared it should be possible to completely remove the ACE dependency from authserver.

If this succeeds worldserver would be up next.

As ACE has been fully replaced on Shared and authserver and thus delinked from the projects the roadmap focus changes to worldserver and game projects.

How can i help?

As it is with TC master branch: By pull requests

Couple of notes for that:

[ul][li]Of course you are free to throw in whatever you like, but working in alignment with the very rough road-map above should give usable results faster[/li][li]Please don’t strangle me (or other TC) devs if your pull request for this branch doesn’t get merged immediately, after all it is just a proof-of-concept prototype[/li][li]If you replace things please make sure there are no used features lost[/li][li]Also to avoid people working on the same code, especially if larger changes are involved, maybe drop a quick shout in here that you are working on it to avoid redundancy[/li][/ul]
Disclaimer

[ul][li]This is just a proof-of-concept prototype, it may never be merged into master at all[/li][li]It may not support all platforms/setups that are currently supported on vanilla TC, development has only been done on x64 Win8 + VS2013 and Gentoo 13.0 x64 + GCC 4.7.3 so far[/li][li]There is no guarantee for progress[/li][li]There haven’t been any performance tests yet, mainly because authserver isn’t that performance critical in the first place[/li][li]So far i am not planning on keeping this branch sync with master, this is mainly because working on ACE related code means poking around in the guts of TC and this is likely to cause tons of merge errors[/li][/ul]
Known issues

[ul][li]The RemoteAccessThread is currently broken due to ACE_TP_Reactor being a bitch (as usual). As i found no point in digging into that it probably will be fixed once ACE gets killed from that part of the code.[/li][/ul]

good changes await us

Quick update:

“Delinking ACE from Shared and authserver”

https://github.com/TrinityCore/TrinityCore/commit/66c94ce965b763a3c144c0e542e7329a24a3a2e3

Update:

ACE has been removed from the code in its entirety, we now need people to test the branch and report any possible issues.

Boost branch has just been merged into master.