Class StoragePersonaAccessor

java.lang.Object
com.linkedin.venice.persona.StoragePersonaAccessor

public class StoragePersonaAccessor extends Object
Zookeeper accessor for StoragePersona objects, allowing for read/write to persona paths.

The data structure on ZK would be: /Persona/StoragePersona/$name, where $name is specified at creation. Nothing in the accessor is cached locally.

  • Field Details

  • Constructor Details

    • StoragePersonaAccessor

      public StoragePersonaAccessor(String clusterName, HelixAdapterSerializer adapter, org.apache.helix.zookeeper.impl.client.ZkClient zkClient)
  • Method Details

    • createPersona

      public void createPersona(String name, long quotaNumber, Set<String> storesToEnforce, Set<String> owners)
      Note that this method does not return an error if the persona already exists. It is up to the caller, i.e. StoragePersonaRepository to throw an error in this case.
    • createPersona

      public void createPersona(StoragePersona persona)
    • updatePersona

      public void updatePersona(StoragePersona persona)
    • deletePersona

      public void deletePersona(StoragePersona persona)
    • deletePersona

      public void deletePersona(String personaName)
    • containsPersona

      public boolean containsPersona(String name)
    • getPersonaFromZk

      public StoragePersona getPersonaFromZk(String name)
    • getAllPersonasFromZk

      public List<StoragePersona> getAllPersonasFromZk()