error handling and sequence commit