Class PreboardedAuditServiceImpl
java.lang.Object
ubic.gemma.persistence.service.expression.experiment.PreboardedAuditServiceImpl
- All Implemented Interfaces:
PreboardedAuditService
Implementation of
PreboardedAuditService: a thin co-bean that exists
so recordPreboardedCreated(PreboardedExperiment, String) is invoked
through a Spring proxy and the @Audited aspect can intercept its
return path and emit the PreboardedCreatedEvent.
The AuditedAspect can only locate an Auditable target on
the argument list (see AuditedAspect#findAuditable); the original
imperative call in PreboardedExperimentServiceImpl.createPreboarded
targeted a freshly constructed PreboardedExperiment that was not in
the argument list. Hoisting to this co-bean lets the target be passed in as
the first argument.
The Transactional default propagation (REQUIRED) joins
the wrapping @Transactional on createPreboarded.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidrecordPreboardedCreated(PreboardedExperiment preboarded, String accession) Record aPreboardedCreatedEventagainst the freshly persisted preboarded with a note that interpolates the accession.
-
Constructor Details
-
PreboardedAuditServiceImpl
public PreboardedAuditServiceImpl()
-
-
Method Details
-
recordPreboardedCreated
@Transactional @Audited(value=PreboardedCreatedEvent.class, messageSpel="'Preboarded created for accession ' + #accession") public void recordPreboardedCreated(PreboardedExperiment preboarded, String accession) Record aPreboardedCreatedEventagainst the freshly persisted preboarded with a note that interpolates the accession. Dispatch is via the@Auditedaspect.The
Auditedannotation drives emission through theAuditedAspect; this method body is intentionally a logging-only marker so the proxy-intercepted return triggers exactly onePreboardedCreatedEvent.- Specified by:
recordPreboardedCreatedin interfacePreboardedAuditService- Parameters:
preboarded- the freshly persisted preboarded; receives the audit rowaccession- the accession the preboarded was created for; included in the note
-