protected void updateWorkflow(Workflow workflow) throws ApsSystemException {
Map<String, Workflow> config = this.getWorkflowConfig();
config.put(workflow.getTypeCode(), workflow);
try {
String xml = new ContentWorkflowDOM().createConfigXml(config);
this.getConfigManager().updateConfigItem(JpcontentworkflowSystemConstants.CONTENT_WORKFLOW_CONFIG_ITEM, xml);
this.setWorkflowConfig(config);
} catch (Exception e) {
this.loadConfig();
ApsSystemUtils.logThrowable(e, this, "updateWorkflow");