Winning Strategy Games

Serverless ecomm platform for board games and accessories

Visit Website
March 1, 2019 Social Media Live

I setup the respective social media accounts with Facebook, Twitter, Pintrist and Instagram. For the most part, they are just stub accounts with minimal content and no followers. In the coming days, I'll began posting and building up a reputation on those platforms.

Comment

December 30, 2018 Soft Launch!

Today, I deployed progress to production. https://winningstrategy.games is officially live!

I proceeded with posting the sitemap to bing and google. Within a few days, indexing had begun. There are some minor crawl errors to address, but things are otherwise looking good.

For now, WSG is just a fancy product browser. No account or cart management yet. I'm going to start in on an admin for product management, up till now, products could only be updated via the API.

Comment

December 21, 2018 Sitemap and Page Cache = SEO

I've decided that I really want a January 1st go live with the product data. Even though we are no-where near ready for checkouts, getting those product pages up and getting google indexing it is essential for long-term SEO.

I started by preparing lambda routines that would nightly prepare sitemaps for all the product data. Putting all the products into one sitemap would be too huge. It's also too much to process at once. So I organized the sitemaps by product category. Each category is processed one at a time, in-sequence for their products. A sitemap index identifies each.

Next was the AMP compliant static page cache. Angular pages are not very search engine crawler friendly. This is because they are javascript heavy and rendered client side. I needed to be able to serve up a static version of each page, in under 50ms, so that the crawler can index it.

I prepared a lambda routine that would conduct a server-side render of the page and write the HTML to S3. I also updated the CloudFront distribution as such that it would route inbound request for any product page to the respective cached page in S3. The pages include structured JSON+LD data and a bootstrap to load the angular PWA app. The end result, a fully functional site for users with javascript disabled. To keep the pages up-to-date, I registered an on-update data stream from Dynamo back into Lambda to asynchrously re-render the pages. Any source that updates the product data will result in an updated page cache.

Comment

December 14, 2018 Rolling Product Update Sync

Getting good product data is hard. For Social Inertia, I had to individual curate those listings by pulling content from the manufacturers, publishers, and various gaming communities. That good data is what made Social Inertia successful in the first place. WSG would flounder if it couldn't get the same quality of data.

My distributor does not have a REST API for product details, but they do have an ordering interface exclusively available to retailers. The data is there.

I prepared an HTML scraper that could invoke those product details pages, parse out the details, and route them back in through my product API. This includes getting references to images that could be queued for download.

I wanted to make sure I didn't inundate my distributor's platform with crawls and scrapes. So I setup another queue for products in need of updating. A Lambda routine pops a product of the queue once a minute, fakes a log in to the distributor to get a session cookie, and then scrapes the product's data. It takes about a week to roll through the entire product inventory and capture data, but that's a healthy spread. Product details will now be perpetually up-to-date.

Next up: resizing those uber-huge images to be web and social media friendly.

Comment

December 7, 2018 Product Inventory Sync from Distributor

My distributor has a warehouses across the country with a massive inventory. Additionally, they can ship and deliver to me with in 2 days. I already offer free 2-day shipping on my inventory via Social Inertia. So theoretically, I can do on-demand ordering and turnaround on shipping within 5-7 business days with my distributors entire available inventory.

That will only work if I have reasonable up-to-date details about their available products and stock. Porting that over and regularly updating it is essential. Not to mention that all that product data is an SEO gold mine.

One caveat. My distributor doesn't have an API (or do they...). What they do have is an zip-compressed csv of SKU's and inventory levels by warehouse.

I prepared a Lambda routine to run nightly and download that ZIP, decompress it, and then stream some 50,000 lines into an aws SQS Stream. Writing all that to Dynamo in real-time would thrash it. SQS uses concurrency limits to invoke the messages in batches back to Lambda for processing and updating in Dynamo.

After some tweaking, I have the system automatically syncing new SKU's and available inventory for 50,000 products from the distributor nightly with minimal load on the system.

Unfortunately, all this products are missing images and descriptions. That's not too useful...

Comment

December 2, 2018 Product Data Sync from Shopify

I already have some very well curated data in an existing ecommerce platform over at shopify. I intend to offer my inventory on both sites during the interim transition. To avoid overselling, it was essential that any changes in shopify products or inventory be replicated over to Winning Strategy Games.

Shopify has an admin rest API as well as support for third-party application's webhooks. I started by preparing a script that could access Shopify's REST API, download all my product data, and inject it into my WSG platform. Success! We have products.

However, having shopify push on change is far more efficient than pulling periodically. I added a REST endpoint over at WSG to accept updates to product data. Success again! As an added bonus, Shopify polls with updated inventory every time an order is processed through any of the sales channels (inventory is already listed at Ebay and Shopify). Everyone is synced up to avoid any over-selling incidents.

Comment

November 25, 2018 Angular Product Browser - Up on stage

Angular driven Progressive Web Apps handle much of their business logic and rendering client-side. This lifts the burden off the server while providing a more fluid user experience.

I prepared an Angular project and began integrating with the REST API. Within a week, I had basic features for searching products, browsing lists, and viewing details.

ElasticSearch was also pulled into the mix. I added triggers into the service endpoints so that any data posted into Dynamo would be replicated into ElasticSearch simultaneously. Front-end searches are now ES powered.

Comment

November 18, 2018 API Gateway + Lambda + Dynamo = JSON REST API

I plan to develop the site as an Angular powered PWA site. Before we delve into that, I'll need a JSON based REST endpoint for fetching and injecting product data.

Built on top of my Dexterity framework (https://www.npmjs.com/package/@smartsoftware/dexterity), I prepared all the models, lambda service, and api gateway endpoints for resource management around products.

It's time to start getting some data in.

Comment

November 1, 2018 Landing Page Goes Up

During development, I want to start building up some SEO ranking. I designed a logo and prepared a basic landing page with some content of what's to come.

The static content site is deployed on AWS's S3 with a CloudFront distribution caching it. I also proceeded with registering the site on Google Search Console and Bing's Webmaster tools. Analytics tracking is also integrated.

I'm going to progress with backend development.

Comment

October 14, 2018 DBA Filed with State of Nevada

I already sell board games and accessories online under the name Social Inertia (https://store.socialinertia.com). Admittedly, it's not great for SEO. Social Inertia relies on shopify.

I have decided that I want to rebrand as Winning Strategy Games in 2019 and build it on a more robust platform. When the business license for Social Inertia came up for renew, I added a DBA for Winning Strategy Games in the state of Nevada.

Comment

About

Winning Strategy Games is a demo project for a serverless ecommerce platform that includes a series of automation routines that permits the content and product management of a high-volume site.