Create migration script for lifecycle events