BATCH-219 and BATCH-330: Created ExecutionAttributes, which are stored in the table BATCH_STEP_EXECUTION_ATTRIBUTES.

This commit is contained in:
lucasward
2008-02-05 02:32:58 +00:00
parent 625480382c
commit 96a11b3bb7
7 changed files with 24 additions and 21 deletions

View File

@@ -15,7 +15,7 @@
*/
package org.springframework.batch.core.domain;
import org.springframework.batch.item.StreamContext;
import org.springframework.batch.item.ExecutionAttributes;
/**
* Represents a contribution to a {@link StepExecution}, buffering changes
@@ -30,7 +30,7 @@ public class StepContribution {
private StepExecution execution;
private StreamContext streamContext;
private ExecutionAttributes streamContext;
private int commitCount;
@@ -69,15 +69,15 @@ public class StepContribution {
*
* @param streamContext
*/
public void setStreamContext(StreamContext streamContext) {
public void setStreamContext(ExecutionAttributes streamContext) {
this.streamContext = streamContext;
}
/**
* Public getter for the {@link StreamContext}.
* Public getter for the {@link ExecutionAttributes}.
* @return the stream context
*/
public StreamContext getStreamContext() {
public ExecutionAttributes getStreamContext() {
return streamContext;
}

View File

@@ -18,7 +18,7 @@ package org.springframework.batch.core.domain;
import java.util.Date;
import org.springframework.batch.item.StreamContext;
import org.springframework.batch.item.ExecutionAttributes;
import org.springframework.batch.repeat.ExitStatus;
/**
@@ -51,7 +51,7 @@ public class StepExecution extends Entity {
private Date endTime = null;
private StreamContext streamContext = new StreamContext();
private ExecutionAttributes streamContext = new ExecutionAttributes();
private ExitStatus exitStatus = ExitStatus.UNKNOWN;
@@ -88,11 +88,11 @@ public class StepExecution extends Entity {
taskCount++;
}
public StreamContext getStreamContext() {
public ExecutionAttributes getStreamContext() {
return streamContext;
}
public void setStreamContext(StreamContext statistics) {
public void setStreamContext(ExecutionAttributes statistics) {
this.streamContext = statistics;
}

View File

@@ -16,7 +16,7 @@
package org.springframework.batch.core.domain;
import org.springframework.batch.item.StreamContext;
import org.springframework.batch.item.ExecutionAttributes;
/**
* <p>
@@ -49,7 +49,7 @@ public class StepInstance extends Entity {
private BatchStatus status;
private StreamContext streamContext = new StreamContext();
private ExecutionAttributes streamContext = new ExecutionAttributes();
private int stepExecutionCount = 0;
@@ -84,11 +84,11 @@ public class StepInstance extends Entity {
this.stepExecutionCount = stepExecutionCount;
}
public StreamContext getStreamContext() {
public ExecutionAttributes getStreamContext() {
return streamContext;
}
public void setStreamContext(StreamContext streamContext) {
public void setStreamContext(ExecutionAttributes streamContext) {
this.streamContext = streamContext;
}

View File

@@ -22,7 +22,7 @@ import org.springframework.batch.core.domain.JobInstance;
import org.springframework.batch.core.domain.JobParameters;
import org.springframework.batch.core.domain.StepExecution;
import org.springframework.batch.core.domain.StepInstance;
import org.springframework.batch.item.StreamContext;
import org.springframework.batch.item.ExecutionAttributes;
/**
* <p>
@@ -30,7 +30,7 @@ import org.springframework.batch.item.StreamContext;
* must first be obtained using the findOrCreateJob method. Once a Job and it's
* related steps are obtained, they can be updated. It should be noted that any
* reconstituted steps are expected to contain restart data <strong>if the step
* says it wants to be restored after a restart, and {@link StreamContext}
* says it wants to be restored after a restart, and {@link ExecutionAttributes}
* exists.</strong>
* </p>
*