IT/Software career thread: Invert binary trees for dollars.

alavaz

Trakanon Raider
2,001
713
One of the things he mentioned was that I didn't have experience with 5 nine datacenters... Which I found ridiculous because I hadn't even mentioned (nor did my resume) anything like that nor had he asked. He just kind of told me that I didn't. I really didn't know what to say to it since none of my jobs had ever really quantified reliability in nine's like that. He was also hung up on perl scripting, which the zombies said they barely used. I told him I'm actually pretty good with it, but I guess because it wasn't in bold on my resume or something he assumed I didn't know any.

He was undeniably douchy, but didn't really seem like a dick or anything. I think he really thought he was doing the right thing. Unfortunately, I'm sure he'll steer that ship straight into an iceberg eventually though.
 

alavaz

Trakanon Raider
2,001
713
Perl was awesome in it's time though. I did a ton of cgi shit back in the day. My high school teacher was impressed as fuck when I showed him how I could add text to a webpage on the fly with a perl cgi script I wrote.
 

Tenks

Bronze Knight of the Realm
14,163
606
Perl is still alright. It just is far more niche now with the advent of Python. Normally if you couldn't easily do it in shell script you'd do it in perl script. Now there isn't really a great reason to go from shell to perl when you could just go from shell to python and get far more features.
 

Palum

what Suineg set it to
23,299
33,232
Anyone I've ever met that's a Perl guru is a crotchety ol Man

Fuck you I only act like a crotchety old man I don't look like one!

Man I've used Perl for some fucked up shit over the years. I had to use it to build a fucking weird ass spreadsheet in excel from odd reports to mimic ask ancient excel 2000 report EXACTLY, because newer versions of excel did not like the piles of VBA running the sheet and threw errors constantly. So I found an excel library that was deprecated but still functioned and updated a few methods and read this broken daily report but out by a legacy system and modernized it to open in excel 2010.
 

Deathwing

<Bronze Donator>
16,366
7,363
I started out with Perl and moved to Python. You can do some powerful stuff with Perl, but that same power almost always made code comprehension fucking hard.
 

a_skeleton_03

<Banned>
29,948
29,762
Who does scalable architecture design in GCE or AWS or Azure.

I am having trouble wrapping my head around how to design a dynamic and scalable system when I have a static set up now.
 

Ao-

¯\_(ツ)_/¯
<WoW Guild Officer>
7,879
507
Who does scalable architecture design in GCE or AWS or Azure.

I am having trouble wrapping my head around how to design a dynamic and scalable system when I have a static set up now.
I've done some and went through some of the solution design training... what do you need?
 

a_skeleton_03

<Banned>
29,948
29,762
I've done some and went through some of the solution design training... what do you need?
So right now my mentally is heavily stuck in the static resources and having a hard time working out how to design a move over to a scalable platform.

There is a new full revision of Xenforo so I am going to spin up a test forum to figure out addon functionality before migrating over to it and this would be the logical time to pursue dynamic resource allocation. I will go over how we are configured now and then outline how I see the change and maybe you can understand my disconnect.

Right now we are on an E3-1270 which has 8 cpu cores, 32GB of RAM and 400GB of drive space. We run CentOS and it maintains the mysql daemon (MariaDB), the nginx web server, memcached, and elasticsearch is hosted via script to AWS. Backups are done via a crobjob to AWS S3 buckets as well. We use about 16GB of RAM right now pretty much steadily and have a decent amount of drive space utilized. Our processor usage is low from what I can tell but I don't run any tools to monitor it long term.

I don't know how to design an instance or whatever and even what things I split out, other than ES, so that it can scale. We of course have plenty of hours with very little usage and then times where we jump up significantly. The only way I know how to interact with a server is static allocation, whether that is creating a VM with resources or going bare metal. For my private usage I do a docker concept but I am not sure that is how we could do things here.

So if I was running it in a docker setup I would use the nginx, mariadb, and memcached as images and map them all to the same resources on the host. What I don't know is how that looks in a cloud environment and how I tell them to use as little resources as they need and then scale up exponentially.

What does my end state look like? I would like a scalable web server on each coast. I would like a real time reach back to a single sql database or replication real time to each if that is faster. I would like a CDN concept for attachments that can scale depending on our usage so that we can default to attachments without having an allocated disk for that.
 

alavaz

Trakanon Raider
2,001
713
I don't have much experience building scalable shit but from the research I've done for some stuff at work, the basic idea is that you set up the ELB for your web front ends and then use the cloudwatch service to start/stop additional instances as you hit certain utilization thresholds. The DB probably needs to be clustered using whatever clustering software there is for Maria and then the same premise for cloudwatch. Amazon also has cloudfront for CDN type services. I think the main effort would be setting up the forum software to be scalable as a lot of times they aren't designed that way out of the box.
 

a_skeleton_03

<Banned>
29,948
29,762
I don't have much experience building scalable shit but from the research I've done for some stuff at work, the basic idea is that you set up the ELB for your web front ends and then use the cloudwatch service to start/stop additional instances as you hit certain utilization thresholds. The DB probably needs to be clustered using whatever clustering software there is for Maria and then the same premise for cloudwatch. Amazon also has cloudfront for CDN type services. I think the main effort would be setting up the forum software to be scalable as a lot of times they aren't designed that way out of the box.
Yeah the software is all php really, I just don't think I understand that portion as well. Web scaling and sql isn't too bad and I get those concepts well. I just don't know what I put the web scalers "in front of" for the forum php software. That piece right there I don't know how to scale on demand, I know how to make it on a dedicated server or a static VPS though :D
 

Ao-

¯\_(ツ)_/¯
<WoW Guild Officer>
7,879
507
Yeah the software is all php really, I just don't think I understand that portion as well. Web scaling and sql isn't too bad and I get those concepts well. I just don't know what I put the web scalers "in front of" for the forum php software. That piece right there I don't know how to scale on demand, I know how to make it on a dedicated server or a static VPS though :D
Auto scaling group? I don't understand how the server software would cluster to do that, but it's how we've usually handled it.

Part of this is making sure the software as written is cloud native (and supports a bunch of the typical cloud scaling shit) rather than you forcing it into the cloud.
 

Kazmus

<Silver Donator>
3
4
I work with AWS a lot and can probably help you get whatever you need set up there.

Spoiled for length feel free to ask any questions

I don't have any experience with Xenforo so I'm guessing a bit in regards to how it will interact with some of the other resources.

For an AWS setup you would want to get each part split out and scaled independently. Using either auto scaling groups where you manage the VMs yourself or with the managed services offered by AWS.

An auto scaling group is a collection of resources where you specify the type of ec2 instance (vm), the AMI, and how many of them you want.
  • These can be scaled based on utilization
    • e.g 75% cpu utilization for more than 5 minutes then +1 instance
    • These can be tricky to tune when you factor in how long it takes to for a new resoure to come available
  • A schedule based on the number of instance you want
    • e.g. Starting at 1am you want a minimum of 2 instance with a maximum of 3
    • e.g. Starting at 9am you want a minimum of 4 instance with a maximum of 5

That auto scaling group is associated a launch configuration which will configure the instance to your desired state.
  • When an auto scaling group creates a new instance it will run this
    • It can be a simple shell script/yum install X/Y/Z
    • A chef cookbook or puppet module to handle more complex configuration
  • At this point we can interact with our other AWS resources, which is how we can automate some things. For example when creating a web server you don't point the reverse proxy at an IP you point at the DNS addresse produced for the app server elb which amazon will populate once that resource is created.

All of this stuff is pretty easy to automate, and as far as a high level setup it would be something like:
  • Create an auto scaling group of NGINX servers.
    • What does NGINX do in this setup? Is it mostly a reverse proxy over to Xenforo and serving some static assets?
    • The launch config for these would configure the reverse proxy to point at the point at the ELB for the Xenforo servers
  • Create an ELB that points to the auto scaling group of the Xenforo servers. This will produce a DNS A record so the web server cluster has a consistent place to direct all traffic to
  • Create an auto scaling group of Xenforo servers
    • This will be the tricky part to get configured, as other have mentioned. Both from how the software works like how does it handle sessions when a person is bouncing between servers (this is probably where memcache comes in?) or would there need to be some sort of session stickiness. Also can the install be totally automated (even down to db connection strings) or are any manual steps needed?
  • The resources Xenforo needs you have more options as this is where the AWS managed services are available to you. I'm guessing most of this stuff is configured in Xenforo in some sort of admin screen where you put connection strings and password? Depending on how Xenforo uses these systems will probably determine the uses cases here.
  • For MySQL you can use the AWS RDS service (Amazon Relational Database Service (RDS) – AWS). RDS handles backups automatically and it has a number of high availability/fail over options.
    • Alternatively you can maintain the DB instance/cluster yourself with either an autoscaling group (which means your launch configuration will have to be aware of the other instances and join the cluster properly) or you just make a single instance and make good/frequent backups.
  • For memcache amazon offers the service ElasticCache (which can either be memcache or redis backed). Or again we could have some sort of auto scaling group.
  • Elasticsearch same deal. There is an AWS managed service. The trick here might be in authorization. The AWS version requires requests be signed with the proper credential so the Xenforo servers talking to it would probably need some sort of plugin to sign the requests or the Elasticsearch service would have to allow unrestricted access to everything in the VPC (it would not be reachable from the internet).
    • Again the alternative is a auto scaling group of elasticsearch servers. I believe the best practice for elasticsearch is to scale based on a master/replica/controller setup but at the scale here it is probably easier to just have a cluster of servers that all do everything.
  • For the attachment/cloudfront stuff. That would require some sort of Xenforo plugin/setting I am guessing. If Xenforo can be configured to upload to S3 then it is easy to have it push the attachments there and put a distribution in front of it.


Having the web servers in additional regions is easy enough to do. Though I would see how the performance is in a single region before going down that road. I'd also need to understand the interactions between Xenforo and the various datasources better. If it is really chatty with MySQL it will is going to add a lot of overhead with all those round trips/a read replica of some sort may be required. But if it caches most of the data in memcache/elasticsearch it may be enough to have those in both regions.


What I laid out about is assuming just using EC2 instances/VMs. It is possible to do approximately that with containers using EC2 Container Service (Amazon ECS - run containerized applications in production) though there is an additional layer of configuration there. In that case you just make one auto scaling group for ECS and then ECS handles maintaining the running tasks. You configure application load balancers to route the traffic between your tasks. There are similar scaling options but I am less familiar with them.
 
  • 3Like
Reactions: 2 users

Tenks

Bronze Knight of the Realm
14,163
606
I've always been a bit interested in game programming. Luckily my tech lead said web service development has been rotting his brain so asked if I wanted to make a game with him. He's shipped games before coming here so I jumped at the opportunity. So far so good. Things are coming along. We have a "Hackathon" here where we are given a few days to create something and present. Technically this is our hackathon project despite starting early. Somethings I learned:

#1) Game programming isn't as hard as everyone makes it out to be. All problems are solved. You just get a different dictionary of terms to google for and in general there is less information.
#2) Although I'm using Unity I also did UE4 w/ C++ and complicated pointer math for a gameplay engineer is gone. Literally the only difference I see here is UE4 has ugly C++ syntax. Our internal systems also have abstracted away almost all pointer stuff.
#3) Not only is game programming not as hard as perception there are some things that are remarkably easy. As a platform engineer you need to assess all sorts of different angles and integration points. Games you pretty much have a directive, you write to it and you go. You aren't doing 20 layers of OOP abstraction. You just code. Not to say there aren't best practices but I'm finding the architecture more straightforward and simplistic.

Again this is some quick stuff from doing simple gameplay engineering. Yes the engine guys will still need complicated math and low-level language knowledge. But again most of these problems are solved.
 

agripa

Molten Core Raider
587
498
Yes. Take them up on it. Get the extra stuff at night. Take all the SANS courses you can. Get some challenge coins. Get the polo shirt.

They understand the cost is like ~$8k right?

Yeah they understand the cost. They way underpay their employees, so it is a way for them trying to keep me for another year.
 
Last edited:
  • 1Like
Reactions: 1 user

chaos

Buzzfeed Editor
17,324
4,839
SEC504 is a good course, I haven't taken it but everyone I know who has loved it. GCIH is a good cert to have, too.
 

Nija

<Silver Donator>
1,909
3,725
@a_skeleton_03 if you move this forum over to AWS I expect your costs to go up at least 4x. I'm kind of amazed you are using elasticsearch on aws. I have always used a dedicated server (32 cores and 48gb ram for $65/mo) for my elasticsearch needs. The same hardware in AWS would cost me a kidney each month.
 

Noodleface

A Mod Real Quick
37,961
14,508
I've always been a bit interested in game programming. Luckily my tech lead said web service development has been rotting his brain so asked if I wanted to make a game with him. He's shipped games before coming here so I jumped at the opportunity. So far so good. Things are coming along. We have a "Hackathon" here where we are given a few days to create something and present. Technically this is our hackathon project despite starting early. Somethings I learned:

#1) Game programming isn't as hard as everyone makes it out to be. All problems are solved. You just get a different dictionary of terms to google for and in general there is less information.
#2) Although I'm using Unity I also did UE4 w/ C++ and complicated pointer math for a gameplay engineer is gone. Literally the only difference I see here is UE4 has ugly C++ syntax. Our internal systems also have abstracted away almost all pointer stuff.
#3) Not only is game programming not as hard as perception there are some things that are remarkably easy. As a platform engineer you need to assess all sorts of different angles and integration points. Games you pretty much have a directive, you write to it and you go. You aren't doing 20 layers of OOP abstraction. You just code. Not to say there aren't best practices but I'm finding the architecture more straightforward and simplistic.

Again this is some quick stuff from doing simple gameplay engineering. Yes the engine guys will still need complicated math and low-level language knowledge. But again most of these problems are solved.
Been meaning to get into this myself. Who does graphics? That's one of my biggest concerns is I'm no artist.