I bought M1 MacBook Air. It is the fastest computer I have, and I have been a GNOME/GNU/Linux user for long time. It is obvious conclusion that I need practical Linux desktop environment on Apple Silicon.
Fortunately, Linux already works on Apple Silicon/M1. But how practical is it?
- Two native ports exist.
This gist lists challenges you run into when building offline-first applications based on IndexedDB, including open-source libraries like Firebase, pouchdb and AWS amplify (more).
Note that some of the following issues affect only Safari. Out of the major browsers, Chrome's IndexedDB implementation is the best.
When this bug occurs, every time you use the indexeddb, the WAL file grows. Garbage collection doesn't seem to be working, so after a while, you end up with gigabytes of data.
import ec2 = require('@aws-cdk/aws-ec2'); | |
import cdk = require('@aws-cdk/core'); | |
import { Fn, Tag, Resource } from '@aws-cdk/core'; | |
import { AmazonLinuxImage, UserData, InstanceType } from '@aws-cdk/aws-ec2'; | |
import { Role, ServicePrincipal, ManagedPolicy, CfnInstanceProfile } from '@aws-cdk/aws-iam' | |
/** | |
* Create my own Ec2 resource and Ec2 props as these are not yet defined in CDK | |
* These classes abstract low level details from CloudFormation |
// Require the framework and instantiate it | |
const api = require('lambda-api')() | |
// Define a route | |
api.get('/status', async (req, res) => { | |
return { status: 'ok' } | |
}) | |
api.get('/README.md', async (req, res) => { | |
res.sendFile('./README.md') |
class Thunder { } | |
class Fire { } | |
protocol Pokemon { | |
typealias PokemonType | |
func attack(move:PokemonType) | |
} | |
struct Pikachu: Pokemon { | |
typealias PokemonType = Thunder |
Run this from an ec2 instance in the us-west-1 region.
It will create two queues and feed messages into the first queue with a timestamp, this message will then be read and the difference between the message timestamp and the current time computed and pushed into a response queue. Reading these times will give you the latency between publishing to a queue and receiving the message.