I am currently writing my first dotnet core 2.0 application deployed to a Linux environment. The development has been on a Mac using a combination of the dotnet cli and Visual Studio for Mac.

In deploying the app to a QA site, we experienced an error I’ve never seen before

An exception occured reading app key DeviceId default value applied.
System.IO.IOException: The configured user limit (128) on the number of inotify instances has been reached.
at System.IO.FileSystemWatcher.StartRaisingEvents()
at System.IO.FileSystemWatcher.StartRaisingEventsIfNotDisposed()
at Microsoft.Extensions.FileProviders.Physical.PhysicalFilesWatcher.CreateFileChangeToken(String filter)
at Microsoft.Extensions.Primitives.ChangeToken.OnChange(Func`1 changeTokenProducer, Action changeTokenConsumer)
at Microsoft.Extensions.Configuration.Json.JsonConfigurationSource.Build(IConfigurationBuilder builder)
at Microsoft.Extensions.Configuration.ConfigurationBuilder.Build()
at app.Shared.Utilities.GetAppConfig[T](String key, T defaultValue) in /var/app/source/app/app.Shared/Utilities.cs:line 33
at System.IO.FileSystemWatcher.StartRaisingEvents()
at System.IO.FileSystemWatcher.StartRaisingEventsIfNotDisposed()
at Microsoft.Extensions.FileProviders.Physical.PhysicalFilesWatcher.CreateFileChangeToken(String filter)
at Microsoft.Extensions.Primitives.ChangeToken.OnChange(Func`1 changeTokenProducer, Action changeTokenConsumer)
at Microsoft.Extensions.Configuration.Json.JsonConfigurationSource.Build(IConfigurationBuilder builder)
at Microsoft.Extensions.Configuration.ConfigurationBuilder.Build()

I didn’t know where to start so I Googled the issue and landed on some StackOverflow questions and GitHub issues associated with the same issue. The most helpful questions and answers came from the following sources.

I am attending AWS re:invent. The conference has grown to about 35000 attendees and the sessions span not only the Venetian hotel but also Palazzo, Mirage, and Encore casinos.

re:invent offers an amazing opportunity to ask the AWS engineers questions you have about particular use cases. Often, it’s the minutiae between a couple options that can make all the difference in production.

What is the latency for re-sizing and re-scaling the Elastic Load Balancer (ELB)?

An AWS ELB is nothing more than an auto-scaling group for the instances that handle the incoming requests and forward them to an attached, healthy instance.

According to the Amazon engineers I spoke with, the scaling happens within minutes of consistently high traffic.

After hitting some threshold (this information is proprietary) on the number of instances running your ELB, AWS starts terminating the instances in favor of larger-sized instances.

Is it possible to re-size an RDS managed database without downtime?

When you set up an RDS database, you choose not only the underlying database engine (Postgres, SQL Server, etc) but also the instance size for the instance it runs on to determine the performance for the database.

Over time, you may decide that the database needs faster hardware to keep up with growing demand. According to the Amazon engineers I spoke to, databases cannot be resized without downtime. You will need to allot enough time for a snapshot of your database to be taken and then restored to a new instance

Is it possible to use CloudFront in front of a web service as a caching layer?

This is actually one of the common uses cases. Some teams have used CloudFront but set the TTL to 0, meaning that all requests to CloudFront are then forwarding the request to the origin and thus defeating the purpose. If you are using CloudFront as an edge serer for your web services, make sure you to set your TTL long enough to help manage calls to your service but short enough to keep your data fresh enough for your business needs to SLAs with your clients.

Is there a scenario where lambda functions are more expensive than running auto-scaled instances to serve your web services?

This is a tougher question that doesn’t have a clear or easy answer. I need to discuss the math with some of the engineers here and figure out the break-even point where actual EC2 instances are cheaper.

Speaking to a couple AWS solutions architects, the general guidance is that if your EC2 instance is consistently averaging > 40% CPU utilization, then it would be cheaper to run your API on a standard EC2 instance. Anything less than that, you’ll save money by running your lambda functions.

Why are we limited to 5 security groups per instance?

Performance in AWS degrades as a function of number of security groups attached to the instance. AWS set the initial limit to 5 to keep the multiplier low enough to maintain performance. If you are trying to achieve some micro-optimizations to your AWS architecture, you can also try consolidating some of your security groups to achieve an uptick in performance.

I attended Microsoft’s annual developer conference BUILD and am pretty excited about this new Microsoft that has emerged under the guidance and leadership of Satya Nadella. A lot of my surprise comes from the new services and APIs that Microsoft has announced at the conference.

The Cognitive Services APIs offer an amazing opportunity for creating new software that makes the works a better place and improves our everyday lives. Combine these services with the Bot Framework and you can build anything you can imagine.

Some of the surprises, however, are based not on what was said but rather what was not said.

Microsoft seems to have quietly moved away from KnockoutJS in favor of Anugular 2.0 (a Google library). The conference even had a couple Google engineers manning an Angular booth along-side the Azure and ASP.NET teams. The ASP.NET Core code lab session on front-end development integrates Angular 2 within the ASP.NET (5/Core) MVC (6/Core) applications.

This is an interesting and welcome change Microsoft is open and getting along with Google and demoing on Apple products. Instead of trying to force their stack on the dev community, Microsoft has allowed the organic winners in each arena to play nicely together and is updating their tools to help you integrate.

Windows Phone was also nowhere to be found. All mobile device demos were done on iPhones (at least the ones I saw). As much as they would love to be a true contender in the mobile device space, I’m happy to see Microsoft doubling down on their strengths.

The online world, it is a changing. Google updates their search engine all the time and what worked before may not only not work anymore, but it may be hurting you.
Also, SEO is a long game. Old tricks may provide bumps in traffic here and there but a clean implementation will provide steadier gains over the long haul.

Back to basics

First and foremost, you want to make sure you’re done with the basics.

WHO is coming to my site?

WHAT are they doing on my site?

WHERE are they coming from? How are they getting here?

WHY are they here?

WHEN do I have the most traffic? Weekends? Early morning?

Analytics

Do you know how many visitors your site has? Is your traffic mostly from desktop browsers (Desktops, laptops) or from mobile browsers (iPhone, Android Phones, Windows Phone, etc.) If the answer to this question is no, go ahead and install Google Analytics on your site. Adding Google Analytics to your site allows you to start tracking your site’s performance and see how many people are coming to your site, where they’re going on your site, and how long they’re spending on each page of your site. You can even get fancier by using Google Analytics to track events on your site (downloading a brochure, for example).

If your site is comprised of static HTML files, you’ll need to add the block of code to each of your pages.
Most modern content management systems (Drupal, WordPress, Joomla) will have some plugin that can facilitate your integration. For this site, I use the WordPress plugin Google Analycator and and it makes integrating Google Analytics very easy. The plugin also has an option to disable Google Analytics tracking when I’m logged in so my tests don’t count towards the analytics.

Do you know how your visitors got to your site?

Google Webmaster Tools was recently re-branded to Google Search Console. If your site isn’t showing on Google, or if some of your newer pages aren’t showing in search results, used Google Search Console to add an updated sitemap containing entries for your new pages.

Additionally, Google Search Console allows you to see how your site performs for different searches and allows you to track the change in search performance over the previous month.

Old/ “Black hat” techniques that need you need to stop right now

If your site has been around for a while and you added links to your site to all sort of random places around the web as a means of building links to your site, this may actually be hurting you. Google’s Search algorithm updates (Panda, Penguin) have started identifying these sorts of site and have assigned negative points to the sites linked to them.

Just like having a well indexed site linking to you helps your Google ranking, having a site that has received penalties linking to you will hurt your rankings. If you’ve noticed a dip in your rankings, do what you can to remove the links to your site and see how your traffic is affected over a couple weeks.

SEO and Search Page Rankings

SEO as it’s been known in the past few years is not so much dead as that it has evolved. The old mantra of “Content is king” still stand but now it’s also about how your data is presented in search results. What is your business’s social footprint? Yelp/Facebook/Google+ ratings and reviews, mentions on Twitter for mobile searches (http://techcrunch.com/2015/05/19/google-adds-tweets-to-its-mobile-search-results/)… these social signals can help your rankings and also improve how your business is presented in the search results.

The new features of iPhone 6 and iPhone 6 Plus are nice. I particularly like the updates they’ve made on the photo camera and video camera. The move to 60 fps video is amazing but is also cause for my biggest issue with the phone.

The 16GB of storage is simply not enough space to hold the operating system, your apps, the data for those apps (the pictures from your iMessage history will take up gigabytes of spaces over time), and these HD videos will fill up all of your storage in no time. This back of the napkin calculation assumes you don’t have any music on your phone.

Why are the lowest option 16GB but the next option is 64GB? The base model should have been 32GB. If this wasn’t an option, then the iPhone needs to catch up with all of the other phone and allow for external storage.

What I’m writing is in no way a ciricism of Node.js but the hype that some have blindly bought into. Javascript is a great language and Node.js is a good API built on Google’s V8 engine but it’s not the end all and be all that some people make it out to be.

But isn’t Node.js faster than ASP.NET? Well is depends.
Are we talking about development time?
Are we talking about time to first byte?
Are we talking about

But isn’t ASP.NET slow? Efficient, asynchronous .NET code can run circles around blocking Node.js code any day. Remember that while Node.JS allows you to develop non-blocking code, it is possible to still write blocking, synchronous code with Node.js.

Yes, Node.js makes writing non-blocking code easier, but so does .NET. I can write efficient, non-blocking code in .NET just as well as I could write in-efficient, blocking code in Node.js.

Javascript is a great, minimalistic language.
V8 is an amazing virtual machine…similar to Sun/Oracles JVM (Java) and Microsoft’s .NET framework and CLR.
Node.js is a phenominal set of libraries that have been built acount Google’s V8 engine.

It is a good language and platform, but it’s not the end all and be all that some people make it out to be.

BUT but…NPM!!

Java has maven and ivy

.NET has Nuget

Node.js has NPM

The package manager pattern has been around for a long time and has made things much easier for developers. NPM is a great package manager but it’s nothing new.

The dominance of Node.js (the new hotness) over ASP.NET and other (lets say older) server side technologies is accepted as canon in certain circles. Which is better? Like most open ended questions such as this one, the answer is depends?

Many people like to ask questions like “What’s the best language to use for XYZ?” and the answer is always the same…’It depends!’

In developing vacashare.com, I am using LESS to generate my CSS as I have found the technology to be a developer-friendly way of generating clean, flexible CSS. The Web Essentials extension for Visual Studio 2012 automatically compiles my LESS files into a .css and .min.css files ready for production use. The automated CSS generation combined with .NET Bundling allows for clean CSS for development and debugging purposes and a minified version for my production site. Having Web Essentials generate my .css file(s) doesn’t work, though, if the .less file is modified outside of Visual Studio.

Git publishing has been set up to the Azure website but any modifications to the LESS files are not compiled into a new CSS file until the project is opened in Visual Studio and Web Essentials does its thing. Any CSS changes made can be deployed by the Git publish but the changes will be overwritten when the .less file is modified in Visual Studio and the .css files are generated anew.

We are testing out MSBuild tasks that will allow the LESS files to be compiled into CSS files at compile time so that styling changes can be made without requiring Visual Studio (or even a Windows PC) and can be deployed via a Git Push. Installing .Less Msbuild Tasks into the Visual Studio project exposes a new build action “DotLess”. Look through the entire list of possible actions as the list is not in alphabetical order and may appear to be missing at first glance.

Once the tasks are installed into your project and the DotLess build action is set for the .less files, you can test things by making a change to the .less file and compiling the solution directly by command line using Msbuild.

The next test is to checkout our Git repository on non-Windows PC (in this case, Mac OSX Mavericks), making a modification to the .less file, kicking off a new build of the site using Git Publishing, and confirming that the site reflects the new styles.

Windows 8 is a testament to exactly how much people hate change. Look at Facebook, each time there’s a major change to their layout you people creating new page “bring back the old look”. When Windows 8 was released in 2012, the loudest grumbles were around the missing start button.

When Windows 95 was released, the loudest grumbles were around the new start button. People initially couldn’t imagine a Windows experience without the beloved Program Manager.

What I don’t understand is how the critics that say they want the start menu back over look an entire screen. Windows 8 boots you into what is essentially a full screen view of the start menu.

Microsoft is said to be bringing back the start menu for Windows 9. The team at WinFuture has posted a video of how this (new?) start menu will look and work on YouTube.

I recently moved from an iPhone to an Android phone. My immediate concern was how to move my contacts over between the two devices. iCloud backup of my contacts really came in handy for this.

First, make sure to have your contacts backed up to iCloud.

Log in to iCloud at https://www.icloud.com/ using your Apple ID and proceed to the contacts page. Select all of the contacts (CTRL+A for Windows, COMMAND+A for Mac), click the gear on the bottom left, and select export as vCard.

Now log in to your Google Contacts using your Google account. Click import and select the vCard file you just exported.

Upon completing the import, make sure to review your contacts and merge any duplicate contacts that may have resulted from the import. This is the perfect opportunity to clean up your contacts before syncing them with your phone.

I recently noticed that I had lost all my comments from the Enterpriseyness blog (this website, a WordPress site). I decided to look at the database table that stores my comments. By default, the comments are stored in wp_comments but you have the option to use any prefix other than ‘wp’ when you are setting up your WordPress site.

I decided to take a look at the comments table for some clues and was presented with the following error message:

#144 - Table './###/wp_comments' is marked as crashed and last (automatic?) repair failed

I am not a heavy MySQL user so I went off to Google and came across a few ideas. Before anything else, I made sure to back up my current database. Things are bad, I don’t want them getting worst. The first idea I came across was to simply attempt to repair the table manually

You can provide am id attribute to the and update the link to the page with #{id}. foo And update the link to the page with the focused element to http://www.example.com/mypage#focus If you have a link on the same page (on a navigation section, for example) you can just use foo to jump to the […]

It looks like their /shareArticle endpoint ignores query string parameters. The official share url for the video you YouTube is https://youtu.be/4wDVzjn9s9E and https://www.linkedin.com/sharing/share-offsite/?url=https://youtu.be/4wDVzjn9s9E seems to achieve what you're trying to do.

What you're asking about is polymorphism. In your scenario, you can achieve this by providing a default implementation in your abstract class (as a virtual method) and them allowing each sub-class to provide their own implementation by overriding the method. In SpaceshipController, change protected void updateSpaceshipMovement() to protected virtual void updateSpaceshipMovement(). This is telling the […]