Skip to content

Instantly share code, notes, and snippets.

View iamjono's full-sized avatar
🏠
Working from home in a COVID Reclusion

Jonathan Guthrie iamjono

🏠
Working from home in a COVID Reclusion
View GitHub Profile
@RockfordWei
RockfordWei / demo.swift
Created August 22, 2017 14:55
How to reuse Perfect Swift MySQL connection threaded safely.
import MySQL
import PerfectThread
#if os(Linux)
import Glibc
#else
import Darwin
#endif
let mysql = MySQL()
let lock = Threading.Lock()