Skip to content

Commit

Permalink
Register serializer for SimpleAllele for Funcotator.
Browse files Browse the repository at this point in the history
  • Loading branch information
cmnbroad committed Jun 6, 2022
1 parent e3d541a commit b89425a
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
import de.javakaffee.kryoserializers.guava.ImmutableMapSerializer;
import htsjdk.samtools.*;
import htsjdk.variant.variantcontext.Allele;
import htsjdk.variant.variantcontext.SimpleAllele;
import htsjdk.variant.vcf.VCFHeaderLineType;
import htsjdk.variant.vcf.VCFInfoHeaderLine;
import org.apache.spark.serializer.KryoRegistrator;
Expand Down Expand Up @@ -68,13 +69,13 @@ public VCFInfoHeaderLine newInstance() {
return new VCFInfoHeaderLine("TMP", 2, VCFHeaderLineType.String, "");
}
});
registration = kryo.register(Allele.class);
registration = kryo.register(SimpleAllele.class);
registration.setInstantiator(new ObjectInstantiator<Allele>() {
public Allele newInstance() {
return Allele.create("TCGA");
}
});
}
}

@Override
public void registerClasses(Kryo kryo) {
Expand Down

0 comments on commit b89425a

Please # to comment.