Skip to content
Permalink
Browse files

fix merge conflicts

  • Loading branch information...
ZacBlanco committed May 16, 2019
1 parent d3e55bd commit 732d1bc6e3adcefb778fc6918c80bdb91356344e
@@ -24,13 +24,10 @@
import com.google.protobuf.ByteString;

import java.util.List;
<<<<<<< HEAD
import java.util.Map;
import java.util.Set;

import javax.annotation.Nullable;
=======
import java.util.Set;
>>>>>>> master

/**
* Base class for read only inodes.
@@ -23,13 +23,10 @@
import com.google.protobuf.ByteString;

import java.util.List;
<<<<<<< HEAD
import java.util.Map;
import java.util.Set;

import javax.annotation.Nullable;
=======
import java.util.Set;
>>>>>>> master

/**
* Read-only view of an inode.
@@ -34,11 +34,8 @@

import java.util.HashSet;
import java.util.List;
<<<<<<< HEAD
import java.util.Map;
=======
import java.util.Set;
>>>>>>> master

import javax.annotation.Nullable;
import javax.annotation.concurrent.NotThreadSafe;
@@ -176,14 +173,14 @@ public AccessControlList getACL() {
}

@Override
<<<<<<< HEAD
@Nullable
public Map<String, ByteString> getXAttr() {
return mXAttr;
=======
}

@Override
public Set<String> getMediumTypes() {
return mMediumTypes;
>>>>>>> master
}

/**
@@ -455,19 +452,20 @@ public T setUfsFingerprint(String ufsFingerprint) {
}

/**
<<<<<<< HEAD
* @param xAttr The new set of extended attributes
* @return the updated object
*/
public T setXAttr(Map<String, ByteString> xAttr) {
mXAttr = xAttr;
=======
return getThis();
}

/**
* @param mediumTypes the medium types to pin to
* @return the updated object
*/
public T setMediumTypes(Set<String> mediumTypes) {
mMediumTypes = mediumTypes;
>>>>>>> master
return getThis();
}

@@ -569,13 +567,11 @@ public void updateFromEntry(UpdateInodeEntry entry) {
if (entry.hasUfsFingerprint()) {
setUfsFingerprint(entry.getUfsFingerprint());
}
<<<<<<< HEAD
if (entry.getXAttrCount() > 0) {
setXAttr(entry.getXAttrMap());
=======
}
if (entry.getMediumTypeCount() != 0) {
setMediumTypes(new HashSet<>(entry.getMediumTypeList()));
>>>>>>> master
}
}

@@ -619,11 +615,8 @@ public boolean equals(Object o) {
.add("group", mAcl.getOwningGroup())
.add("permission", mAcl.getMode())
.add("ufsFingerprint", mUfsFingerprint)
<<<<<<< HEAD
.add("mediatypes", mMediumTypes)
.add("xAttr", mXAttr);
=======
.add("mediatypes", mMediumTypes);
>>>>>>> master
}

protected InodeMeta.Inode.Builder toProtoBuilder() {
@@ -639,17 +632,13 @@ public boolean equals(Object o) {
.setPersistenceState(getPersistenceState().name())
.setIsPinned(isPinned())
.setAccessAcl(ProtoUtils.toProto(getACL()))
<<<<<<< HEAD
.setUfsFingerprint(getUfsFingerprint());
.setUfsFingerprint(getUfsFingerprint())
.addAllMediumType(getMediumTypes());
Map<String, ByteString> vals;
if ((vals = getXAttr()) != null) {
inode.putAllXAttr(vals);
}
return inode;
=======
.setUfsFingerprint(getUfsFingerprint())
.addAllMediumType(getMediumTypes());
>>>>>>> master
}

/**
@@ -29,6 +29,7 @@
import java.util.Map;

import javax.annotation.concurrent.NotThreadSafe;

import java.util.HashSet;

/**
@@ -208,14 +209,11 @@ public static MutableInodeDirectory fromJournalEntry(InodeDirectoryEntry entry)
} else {
ret.mDefaultAcl = new DefaultAccessControlList();
}
<<<<<<< HEAD
ret.setMediumTypes(new HashSet<>(entry.getMediumTypeList()));
if (entry.getXAttrCount() > 0) {
ret.setXAttr(entry.getXAttrMap());
}
=======

ret.setMediumTypes(new HashSet<>(entry.getMediumTypeList()));
>>>>>>> master
return ret;
}

@@ -259,17 +257,12 @@ public JournalEntry toJournalEntry() {
.setTtlAction(ProtobufUtils.toProtobuf(getTtlAction()))
.setDirectChildrenLoaded(isDirectChildrenLoaded())
.setAcl(ProtoUtils.toProto(mAcl))
<<<<<<< HEAD
.setDefaultAcl(ProtoUtils.toProto(mDefaultAcl));
.setDefaultAcl(ProtoUtils.toProto(mDefaultAcl))
.addAllMediumType(getMediumTypes());
Map<String, ByteString> vals;
if ((vals = getXAttr()) != null) {
inodeDirectory.putAllXAttr(vals);
}
=======
.setDefaultAcl(ProtoUtils.toProto(mDefaultAcl))
.addAllMediumType(getMediumTypes())
.build();
>>>>>>> master
return JournalEntry.newBuilder().setInodeDirectory(inodeDirectory).build();
}

@@ -309,10 +302,7 @@ public static MutableInodeDirectory fromProto(InodeOrBuilder inode) {
.setDirectChildrenLoaded(inode.getHasDirectChildrenLoaded())
.setChildCount(inode.getChildCount())
.setDefaultACL((DefaultAccessControlList) ProtoUtils.fromProto(inode.getDefaultAcl()))
<<<<<<< HEAD
.setMediumTypes(new HashSet<>(inode.getMediumTypeList()))
.setXAttr(inode.getXAttrMap());
=======
.setMediumTypes(new HashSet<>(inode.getMediumTypeList()));
>>>>>>> master
}
}
@@ -460,6 +460,7 @@ public static MutableInodeFile create(long blockContainerId, long parentId, Stri
public JournalEntry toJournalEntry() {
InodeFileEntry.Builder inodeFile = InodeFileEntry.newBuilder()
.addAllBlocks(getBlockIds())
.addAllMediumType(getMediumTypes())
.setBlockSizeBytes(getBlockSizeBytes())
.setCacheable(isCacheable())
.setCompleted(isCompleted())
@@ -479,17 +480,11 @@ public JournalEntry toJournalEntry() {
.setTtl(getTtl())
.setTtlAction(ProtobufUtils.toProtobuf(getTtlAction()))
.setUfsFingerprint(getUfsFingerprint())
<<<<<<< HEAD
.setAcl(ProtoUtils.toProto(mAcl));
Map<String, ByteString> vals;
if ((vals = getXAttr()) != null) {
inodeFile.putAllXAttr(vals);
}
=======
.setAcl(ProtoUtils.toProto(mAcl))
.addAllMediumType(getMediumTypes())
.build();
>>>>>>> master
return JournalEntry.newBuilder().setInodeFile(inodeFile).build();
}

@@ -540,13 +535,9 @@ public static MutableInodeFile fromProto(InodeOrBuilder inode) {
.setReplicationMax(inode.getReplicationMax())
.setReplicationMin(inode.getReplicationMin())
.setPersistJobId(inode.getPersistJobId())
<<<<<<< HEAD
.setTempUfsPath(inode.getPersistJobTempUfsPath())
.setXAttr(inode.getXAttrMap());
=======
.setShouldPersistTime(inode.getShouldPersistTime())
.setTempUfsPath(inode.getPersistJobTempUfsPath())
.setMediumTypes(new HashSet<>(inode.getMediumTypeList()));
>>>>>>> master
.setMediumTypes(new HashSet<>(inode.getMediumTypeList()))
.setXAttr(inode.getXAttrMap());
}
}

0 comments on commit 732d1bc

Please sign in to comment.
You can’t perform that action at this time.