Project

General

Profile

« Previous | Next » 

Revision 6276

remove extraneous update() call when create() does the call for us

View differences:

src/edu/ucsb/nceas/metacat/MetacatHandler.java
1859 1859
                  try {
1860 1860
                    sysMeta = createSystemMetadata(newdocid, user, groups);
1861 1861
                    IdentifierManager.getInstance().createSystemMetadata(sysMeta);
1862
                    IdentifierManager.getInstance().updateSystemMetadata(sysMeta);
1863 1862
                    
1864 1863
                  } catch ( McdbDocNotFoundException dnfe ) {
1865 1864
                    logMetacat.debug(
src/edu/ucsb/nceas/metacat/dataone/CNodeService.java
542 542
	      sysmeta.setDateSysMetadataModified(new Date());
543 543
	      try {
544 544
			    IdentifierManager.getInstance().createSystemMetadata(sysmeta);
545
			    IdentifierManager.getInstance().updateSystemMetadata(sysmeta);
546 545
			    // force replication of this record
547 546
			    ForceReplicationSystemMetadataHandler forceReplication = 
548 547
			    	new ForceReplicationSystemMetadataHandler(guid.getValue(), null);
src/edu/ucsb/nceas/metacat/dataone/D1NodeService.java
949 949
        sysmeta.getDateSysMetadataModified());
950 950

  
951 951
    //insert the system metadata
952
		try {
953
	    IdentifierManager.getInstance().createSystemMetadata(sysmeta);
954
		  IdentifierManager.getInstance().updateSystemMetadata(sysmeta);
955
		  
956
		} catch (McdbDocNotFoundException e) {
952
	try {
953
		IdentifierManager.getInstance().createSystemMetadata(sysmeta);
954
	  
955
	} catch (McdbDocNotFoundException e) {
957 956
      throw new ServiceFailure("1030", "Error inserting system metadata: " + 
958 957
      	e.getClass() + ": " + e.getMessage());
959 958
      
src/edu/ucsb/nceas/metacat/dataone/CrudService.java
1479 1479
        //insert the system metadata
1480 1480
        try {
1481 1481
			IdentifierManager.getInstance().createSystemMetadata(sysmeta);
1482
			IdentifierManager.getInstance().updateSystemMetadata(sysmeta);
1483 1482
		} catch (Exception e) {
1484 1483
            throw new ServiceFailure("1030", "Error inserting system metadata: " + e.getClass() + ": " + e.getMessage());
1485 1484
		}

Also available in: Unified diff