As reported by a community member and confirmed by my research and discussions with the workflow team, the workflow documentation (a tutorial on the Workflow Framework and the MVC Learning Path) should include a call to
workflowInstanceLinkLocalService.deleteWorkflowInstanceLinks
in the deleteEntity method of the *LSI class, to avoid leaving orphaned DB entries in the workflowinstancelink table.
Here's the call in BlogsEntrylocalServiceImpl:
workflowInstanceLinkLocalService.deleteWorkflowInstanceLinks(
entry.getCompanyId(), entry.getGroupId(),
BlogsEntry.class.getName(), entry.getEntryId());