<body><script type="text/javascript"> function setAttributeOnload(object, attribute, val) { if(window.addEventListener) { window.addEventListener('load', function(){ object[attribute] = val; }, false); } else { window.attachEvent('onload', function(){ object[attribute] = val; }); } } </script> <div id="navbar-iframe-container"></div> <script type="text/javascript" src="https://apis.google.com/js/plusone.js"></script> <script type="text/javascript"> gapi.load("gapi.iframes:gapi.iframes.style.bubble", function() { if (gapi.iframes && gapi.iframes.getContext) { gapi.iframes.getContext().openChild({ url: 'https://www.blogger.com/navbar.g?targetBlogID\x3d8211560\x26blogName\x3dTech+Tips,+Tricks+%26+Trivia\x26publishMode\x3dPUBLISH_MODE_BLOGSPOT\x26navbarType\x3dBLUE\x26layoutType\x3dCLASSIC\x26searchRoot\x3dhttp://mvark.blogspot.com/search\x26blogLocale\x3den\x26v\x3d2\x26homepageUrl\x3dhttp://mvark.blogspot.com/\x26vt\x3d-5147029996388199615', where: document.getElementById("navbar-iframe-container"), id: "navbar-iframe" }); } }); </script>

Tech Tips, Tricks & Trivia

by 'Anil' Radhakrishna
A seasoned developer's little discoveries and annotated bookmarks.

Search from over a hundred HOW TO articles, Tips and Tricks

Compared: Microservices with AWS Lambda and Azure Service Fabric

Monday, January 16, 2017
From the deck on Microservices with AWS Lambda and Azure Service Fabric by Paul Affentranger

AWS Lambda Azure Service Fabric
Features • Functional approach
• Stateless
• “Serverless” compute service
• Runs code on events
• Extends AWS services
• Provides back-end service
• High-availability
• Built-in Fault Tolerance
• Automatic scaling
• Integrated Security Model
• Java, Node.js, and Python
• Massively scalable
• Self-healing
• Programmming in .NET, Java or node.js.
• Stateless and stateful
• Actor Model
• Highly reliable.
• Simplify by stateful microservices in place of caches
• Deploy to Azure or to on-premises clouds
• Running on Windows or Linux
• Develop with a "datacenter on your machine"
• Deploy support
• Applications at higher density
• Different Versions side by side
• Manage lifecycle without downtime
• Upgrade independently
• Monitor and diagnose
• Scale up or scale down your cluster Azure Service Fabric
Philosophy Functional More OO
State Stateless Stateless & Stateful
Persistence External Integrated
Reliable Messaging External Integrated
Languages Java, Node.js and Python Java, Node.js and .NET
Environments AWS only Azure, Azure Stack, Windows and Linux (Cloud and On-premises)
Use General Opinionated (for Microservices)
Deployment External Tool Integrated

What they have in common:
  • High-availability
  • Built-in Fault Tolerance
  • Automatic scaling
  • Integrated Security
  • Monitoring and logging
Azure Service Fabric is the first among the PaaS providers to offer an end-to-end experience for the development and management of microservices.

Labels: , ,

Compared: Azure Service Fabric & Azure Cloud Services

Sunday, January 15, 2017
A fundamental difference between Cloud Services and Service Fabric is the relationship between VMs, workloads, and applications.

Services Density Comparison - click to enlarge image

Related: Comparison of App Service, Cloud Services, Virtual Machines, and Service Fabric

Labels: ,

This Week I Learned - Week #197

Saturday, January 14, 2017
This Week I Learned -

Nearly every major IT player has latched onto the open source container movement driven by Docker Inc.

Azure Site Recovery is much cheaper than running a backup data center. Site Recovery keeps images of all your active servers so that you can switch over to them in a disaster.

* Jet.com did not find Azure Service Fabric to be production ready for their use cases (as of Sep-16) due to the long time it takes to deploy and lack of documentation & tooling

* Channel 9 is producing a lot more videos for developers than earlier like this one on SOLID, Design Patterns with theory, code examples, best practices.

.NET has three main runtimes:
1) .NET Framework - The .NET framework helps you create mobile, desktop, and web applications that run on Windows PCs, devices and servers.
2) .NET Core - .NET Core gives you a fast and modular platform for creating server applications that run on Windows, Linux and Mac.
3) Mono for Xamarin - Xamarin brings .NET to iOS and Android

* The fast evolving nature of Azure services make much of the content of printed books outdated soon after they are published.

* When you upload any photograph to your Facebook account, they look at the actual content of the photograph and try to determine what objects and scenes are inside the image. Facebook creates machine generated captions to make your pictures more accessible to blind users.

ChakraCore – the core of the Chakra JavaScript engine that powers Microsoft Edge – is open-sourced under the MIT license

There are multiple ways to convert an image into base64 string or a data: URL containing the base64-encoded image, using javascript

On average across the web, images make up 64% of the bytes of a page

In 2008, Bhavish Aggarwal graduated from IIT to join Microsoft and then, in 2010, quit to start Ola.

* There are passionate followers for Bart Simpson's chalkboard quotes and Alfred Neuman's one-liners

Refusing to eat to protest conditions in prison is illegal in Iran. Ironically, the embassy of Britain in Tehran is on Bobby Sands Street, renamed for the Provisional I.R.A. member who was imprisoned in Northern Ireland and died in 1981 after refusing to eat for 66 days.

The only difference between digital addiction and other addictions is that this is a socially condoned behavior.... Become very conscious of what is important to you, what really nourishes you, and devote more time and attention to it.

* One in eight deaths worldwide is due to high blood pressure. The condition is the main risk factor for heart and kidney disease, and it greatly increases the chances of a stroke. It is commonly thought of as a disease of affluence. But the data say otherwise. The well-known causes of high blood pressure include lack of exercise, being overweight, and diets that include too much salt and alcohol and not enough fruit and vegetables (which are a source of potassium, linked with lower blood pressure). Efforts to curb blood pressure need to start much earlier in life and go beyond treatment and changes in individual lifestyles - Economist

* "Facebook makes you produce media for free & sells personal info profit from your craving."

* Uber unveiled a website, Uber Movement, that will allow users to compare average trip times and see what effect something like a baseball game might have on traffic patterns. Uber plans to provide access to anonymized data from over 2 billion trips to help improve urban planning around the world..it would balance that demand for information with concerns about user privacy and the need to protect competitive data that could prove valuable to rivals like Lyft, Hailo and Grab, which are vying for riders across many of the same markets.

* It was on Mount Chimborazo, south-west of Quito in modern-day Ecuador, that Alexander Von Humboldt was struck by the idea of nature working as a whole, thus conceiving of what we would now call ecosystems. It was Humboldt’s travel journal, Personal Narrative, that introduced the young Charles Darwin to the idea of scientific exploration. Humboldt is considered the father of the environmental movement.

Mithridatism, the practice of protecting oneself against a poison by gradually self-administering non-lethal amounts, is used to treat peanut allergies.

* A unibrow (or monobrow; called synophrys in medicine) is a single eyebrow created when the two eyebrows meet in the middle above the bridge of the nose. It is a recessive genetic trait.

* In the TV series, Elementary,  Sherlock Holmes is shown as a consultant to the New York City Police Department.  The storytelling in the series is fast paced and suspects are confronted with all the evidence.

* Two-thirds of the world’s remaining greater one-horned rhinoceros population are sheltered in Kaziranga National Park in India

Labels: , , , ,

Containers vs. Virtual Machines in Azure

Tuesday, January 10, 2017
Containers have been called the next generation of virtualization because they provide application abstraction in much the same way that VMs provide hardware abstraction. Instead of virtualizing the hardware like a VM, a container virtualizes at the OS level. Containers run at a layer on top of the host OS and they share the OS kernel. Containers have much lower overhead than VMs and a much smaller footprint.

Containers are not replacements for VMs or operating systems. You install containers on VMs

Containers and virtual machines have similar resource isolation and allocation benefits - but a different architectural approach allows containers to be more portable and efficient.
click to enlarge image
A high-level feature comparison of VMs and containers -

Feature VMs Containers
"Default" security support to a greater degree to a slightly lesser degree
Memory on disk required Complete OS plus apps App requirements only
Time taken to start up Substantially Longer: Boot of OS plus app loading Substantially shorter: Only apps need to start because kernel is already running
Portability Portable With Proper Preparation Portable within image format; typically smaller
Image Automation Varies widely depending on OS and apps Docker registry; others


Taxi Aggregators challenged in Hyderabad

Saturday, January 07, 2017
Taxi aggregators have disrupted transportation services across the globe & faced stiff opposition. The week long cab strike in Hyderabad has bought to the fore the positions of cab drivers, taxi aggregators and the local Government. Some facts that have come out -

According to the Telangana Cab Drivers and Owners Association (TCDOA) which has a membership of only 7,000 drivers, Hyderabad has about 1.2 lakh cabs of which 90,000 are running under Ola and Uber. Ola and Uber have attracted many people to join the cab-leasing programme that allows them to run a car on lease and earn Rs 60,000-70,000 per month. Several new drivers have joined in this programme to own a car at the end of four years with a minimum payment. Currently, over 20,000 cars have been registered with Ola while more than 33,000 cabs with Uber run in the city.  Ola pays an minimum business guarantee (MBG) of Rs 2,200 for nine rides a day and Rs 5,800 for 17 rides a day, even if the rides worth is below that amount. Similarly, Uber pays Rs 1,000 for rides worth Rs 600 per day, Rs 1,400 for rides worth Rs 800 per day, Rs 5,800 for rides worth Rs 2,700 per day and Rs 7,000 for rides worth Rs 3,300 per day. The cab drivers have been working for more than 18 hours a day to avail these incentives. The drivers have to bear 30-35 per cent of their income for fuel expenses, 20 per cent aggregator's commission and 7 per cent taxes, according to the cab associations - Business Standard

According to a TCDOA leader, Ola and Uber have turned drivers into slaves, even while claiming them as “partners”. Cars are being offered at the down payment of Rs.24,000, but earnings are not enough to pay the EMIs which are cut online from the drivers’ accounts. The Association's demands include stopping new cab driver registrations immediately as the existing cabs are not able to get enough business and scrapping of shared cabs. They have other objections against the cab hailing companies, like keeping the driver uninformed about the customer’s details, distance from the pick-up location, making drivers responsible for cancellation of bookings.

Cab drivers in the past have resorted to dirty tricks like fake bookings to claim incentives. A scamster would carry the mobile phone while riding a bike rather than a car and get his friends to book rides. Such drivers would thus exploit the incentive structure as are not paid based on actual fares they earn but the targets that are set and incentives.

During the hey days, monthly earnings shot from Rs 10,000-14,000 (usual salary of a cab driver) to 70,000 and above. 80 per cent of the 80,000 odd cabbies associated with Ola and Uber in the city are owners-cum-drivers - ToI