Implement mutex lock on database entity attributes
Implement mutex lock on database entity attributes
Appears to fix all outstanding segfault issues