use of water.api.schemas3.KeyV3.JobKeyV3 in project h2o-3 by h2oai.
the class SplitFrameHandler method run.
public SplitFrameV3 run(int version, SplitFrameV3 sf) {
SplitFrame splitFrame = sf.createAndFillImpl();
Job job = splitFrame.exec();
SplitFrameV3 spv3 = new SplitFrameV3(splitFrame);
spv3.key = new KeyV3.JobKeyV3(job._key);
return spv3;
}
use of water.api.schemas3.KeyV3.JobKeyV3 in project h2o-3 by h2oai.
the class JobV3 method fillFromImpl.
// Version&Schema-specific filling from the impl
@Override
public JobV3 fillFromImpl(Job job) {
if (job == null)
return this;
// Handle fields in subclasses:
PojoUtils.copyProperties(this, job, PojoUtils.FieldNaming.ORIGIN_HAS_UNDERSCORES);
// TODO: make consistent and remove
PojoUtils.copyProperties(this, job, PojoUtils.FieldNaming.CONSISTENT);
key = new JobKeyV3(job._key);
description = job._description;
warnings = job.warns();
progress = job.progress();
progress_msg = job.progress_msg();
// Notice new state "CANCEL_PENDING".
if (job.isRunning())
if (job.stop_requested())
status = "CANCEL_PENDING";
else
status = "RUNNING";
else if (job.stop_requested())
status = "CANCELLED";
else
status = "DONE";
Throwable ex = job.ex();
if (ex != null)
status = "FAILED";
exception = ex == null ? null : ex.toString();
if (ex != null) {
StringWriter sw = new StringWriter();
PrintWriter pw = new PrintWriter(sw);
ex.printStackTrace(pw);
stacktrace = sw.toString();
}
msec = job.msec();
ready_for_view = job.readyForView();
Keyed dest_type = (Keyed) TypeMap.theFreezable(job._typeid);
dest = job._result == null ? null : KeyV3.make(dest_type.makeSchema(), job._result);
return this;
}
Aggregations