Search in sources :

Example 1 with MerkleBlobMeta

use of com.hedera.services.state.merkle.MerkleBlobMeta in project hedera-services by hashgraph.

the class FcmToJsonUtil method convertStorageToJson.

@Test
void convertStorageToJson() throws Exception {
    String[] round60Locs = { // "/Users/tinkerm/Dev/hgn3/hedera-services/hedera-node/n0-storage-round60.fcm",
    "/Users/tinkerm/Dev/hgn3/hedera-services/hedera-node/n1-storage-round60.fcm" // "/Users/tinkerm/Dev/hgn3/hedera-services/hedera-node/n2-storage-round60.fcm",
    // "/Users/tinkerm/Dev/hgn3/hedera-services/hedera-node/n3-storage-round60.fcm",
    };
    ConstructableRegistry.registerConstructable(new ClassConstructorPair(MerkleLong.class, MerkleLong::new));
    ConstructableRegistry.registerConstructable(new ClassConstructorPair(MerkleBlobMeta.class, MerkleBlobMeta::new));
    ConstructableRegistry.registerConstructable(new ClassConstructorPair(MerkleOptionalBlob.class, MerkleOptionalBlob::new));
    for (String dumpLoc : round60Locs) {
        System.out.println("Reading " + dumpLoc);
        PojoFs.fromDisk(dumpLoc).asJsonTo(jsonSuffixed(dumpLoc));
    }
}
Also used : MerkleLong(com.swirlds.common.merkle.utility.MerkleLong) MerkleOptionalBlob(com.hedera.services.state.merkle.MerkleOptionalBlob) MerkleBlobMeta(com.hedera.services.state.merkle.MerkleBlobMeta) ClassConstructorPair(com.swirlds.common.constructable.ClassConstructorPair) Test(org.junit.jupiter.api.Test)

Aggregations

MerkleBlobMeta (com.hedera.services.state.merkle.MerkleBlobMeta)1 MerkleOptionalBlob (com.hedera.services.state.merkle.MerkleOptionalBlob)1 ClassConstructorPair (com.swirlds.common.constructable.ClassConstructorPair)1 MerkleLong (com.swirlds.common.merkle.utility.MerkleLong)1 Test (org.junit.jupiter.api.Test)1