Packages

trait ActiveContractSnapshot extends AnyRef

Provides snapshotting for active contracts.

Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. ActiveContractSnapshot
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Abstract Value Members

  1. abstract def bulkContractsTransferCounterSnapshot(contractIds: Set[LfContractId], requestCounter: RequestCounter)(implicit traceContext: TraceContext): Future[Map[LfContractId, TransferCounterO]]

    Returns a map to the latest transfer counter of the contract before the given request counter.

    Returns a map to the latest transfer counter of the contract before the given request counter. If the contract does not exist in the ACS, it returns a None.

    requestCounter

    The request counter *immediately before* which the state of the contracts shall be determined.

    Exceptions thrown

    java.lang.IllegalArgumentException if requestCounter is equal to RequestCounter.MinValue.

  2. abstract def changesBetween(fromExclusive: TimeOfChange, toInclusive: TimeOfChange)(implicit traceContext: TraceContext): Future[LazyList[(TimeOfChange, ActiveContractIdsChange)]]

    Returns all changes to the active contract set between the two timestamps (exclusive lower bound timestamp, inclusive upper bound timestamp) in the order of their changes.

    Returns all changes to the active contract set between the two timestamps (exclusive lower bound timestamp, inclusive upper bound timestamp) in the order of their changes. The provided lower bound must not be larger than the upper bound.

    fromExclusive

    The lower bound for the changes. Must not be larger than the upper bound.

    toInclusive

    The upper bound for the changes. Must not be smaller than the lower bound.

    Exceptions thrown

    java.lang.IllegalArgumentException If the intervals are in the wrong order.

  3. abstract def contractSnapshot(contractIds: Set[LfContractId], timestamp: CantonTimestamp)(implicit traceContext: TraceContext): Future[Map[LfContractId, CantonTimestamp]]

    Returns a map to the timestamp when the contract became active for the last time before or at the given timestamp.

    Returns a map to the timestamp when the contract became active for the last time before or at the given timestamp. Omits contracts that not active right after the given timestamp.

    timestamp

    The timestamp at which the activeness of the contracts shall be determined. Must be before the timestamp that corresponds to the head cursor in the com.digitalasset.canton.participant.protocol.RequestJournal for the state com.digitalasset.canton.participant.protocol.RequestJournal.RequestState.Clean. If this precondition is violated, the returned snapshot may be inconsistent, i.e., it may omit some contracts that were ActiveContractStore.Active at the given time and it may include contracts that were actually ActiveContractStore.Archived or ActiveContractStore.TransferredAway.

  4. abstract def packageUsage(pkg: PackageId, contractStore: ContractStore)(implicit traceContext: TraceContext): Future[Option[LfContractId]]

    Returns Some(contractId) if an active contract belonging to package pkg exists, otherwise returns None.

    Returns Some(contractId) if an active contract belonging to package pkg exists, otherwise returns None. The returned contractId may be any active contract from package pkg. The most recent contract state is used.

  5. abstract def snapshot(rc: RequestCounter)(implicit traceContext: TraceContext): Future[SortedMap[LfContractId, (RequestCounter, TransferCounterO)]]

    Returns all contracts that were active right after the given request counter, and when the contract became active for the last time before or at the given request counter.

    Returns all contracts that were active right after the given request counter, and when the contract became active for the last time before or at the given request counter.

    rc

    The request counter at which the snapshot shall be taken. Must be before the request counter that corresponds to the head cursor in the com.digitalasset.canton.participant.protocol.RequestJournal for the state com.digitalasset.canton.participant.protocol.RequestJournal.RequestState.Clean. If this precondition is violated, the returned snapshot may be inconsistent, i.e., it may omit some contracts that were ActiveContractStore.Active at the given counter and it may include contracts that were actually ActiveContractStore.Archived or ActiveContractStore.TransferredAway.

    returns

    A map from contracts to the latest request counter (no later than the given rc) when they became active again. It contains exactly those contracts that were active right after the given request counter. If a contract is created or transferred-in and archived or transferred-out at the same request counter, it does not show up in any snapshot. The map is sorted by cats.kernel.Order[com.digitalasset.canton.protocol.LfContractId].

  6. abstract def snapshot(timestamp: CantonTimestamp)(implicit traceContext: TraceContext): Future[SortedMap[LfContractId, (CantonTimestamp, TransferCounterO)]]

    Returns all contracts that were active right after the given timestamp, and when the contract became active for the last time before or at the given timestamp.

    Returns all contracts that were active right after the given timestamp, and when the contract became active for the last time before or at the given timestamp.

    timestamp

    The timestamp at which the snapshot shall be taken. Must be before the timestamp that corresponds to the head cursor in the com.digitalasset.canton.participant.protocol.RequestJournal for the state com.digitalasset.canton.participant.protocol.RequestJournal.RequestState.Clean. If this precondition is violated, the returned snapshot may be inconsistent, i.e., it may omit some contracts that were ActiveContractStore.Active at the given time and it may include contracts that were actually ActiveContractStore.Archived or ActiveContractStore.TransferredAway.

    returns

    A map from contracts to the latest timestamp (no later than the given timestamp) when they became active again. It contains exactly those contracts that were active right after the given timestamp. If a contract is created or transferred-in and archived or transferred-out at the same timestamp, it does not show up in any snapshot. The map is sorted by cats.kernel.Order[com.digitalasset.canton.protocol.LfContractId].

Concrete Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native() @HotSpotIntrinsicCandidate()
  6. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  7. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  8. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  9. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  10. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  11. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  12. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  13. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  14. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  15. def toString(): String
    Definition Classes
    AnyRef → Any
  16. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  17. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  18. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable]) @Deprecated @Deprecated
    Deprecated

Inherited from AnyRef

Inherited from Any

Ungrouped