June 30, 2015

Architecting on AWS, Day 2

EC2 Instance & AMI When launched, remember permissions are by default deny-all. This means connecting via SSH (or otherwise) to access your instance will require a KeyPair.

Keep in mind that <username> will differ by your instance type: Amazon AMI: ec2-user Ubuntu AMI: ubuntu Default: root RDS Best Practices Choose DB instance class carefully Use Amazon EBS optimized instances Use Provisioned IOPS for production Use Multi-AZ for high availability Use read replicas scaling needs cross-region replication additional failure recovery CloudFront General Separate CNAME for static content static content cached, dynamic content straight from origin most efficient more effort to setup and manage Point entire URL to CloudFront easiest to…

June 29, 2015

Architecting on AWS, Day 1

I have the great pleasure of participating in a 3 day course Architecting on AWS and wanted to share a high level understanding as a way to both share the basics for anyone “on the fence” for jumping to AWS or not, and also selfishly to help me understand and remember more clearly as I go through the course.

Some interesting things I’ve learned today:

June 26, 2015

Load all mapped Entity classes from Doctrine

Ever wanted to create a simple dropdown of all the Entity classes you have mapped in Doctrine? I have! For a recent project I needed to create a sample API form and load the entity type first, so I needed a way to properly load every Entity that’s mapped programmatically and not with an ugly manually created array:

For this, I also applied Doctrine’s Inflector so I could make the key value of my array the pluralized version of the entity name. This was useful for my purposes, but probably isn’t a standard use case. Most use cases I imagine would simply want the simple class name: