Class SourceCache<TContent>
ApiContentReferenceCacheBase<TContent> implementation that is built from the ISourceEndpoint.
Inheritance
Inherited Members
Namespace: Tableau.Migration.Engine.Endpoints.Caching
Assembly: Tableau.Migration.dll
Syntax
public class SourceCache<TContent> : ApiContentReferenceCacheBase<TContent>, IContentReferenceCache, IManifestUpdateSourceContentReferenceCache<TContent> where TContent : class, IContentReference
Type Parameters
| Name | Description |
|---|---|
| TContent | The content type. |
Constructors
SourceCache(IMigrationManifestEditor, IContentMappingRunner, IMigrationPipeline, ISourceEndpoint, IConfigReader, ILogger<SourceCache<TContent>>)
Creates a new SourceCache<TContent> object.
Declaration
public SourceCache(IMigrationManifestEditor manifest, IContentMappingRunner mappingRunner, IMigrationPipeline pipeline, ISourceEndpoint endpoint, IConfigReader configReader, ILogger<SourceCache<TContent>> logger)
Parameters
| Type | Name | Description |
|---|---|---|
| IMigrationManifestEditor | manifest | The manifest. |
| IContentMappingRunner | mappingRunner | The mapping runner. |
| IMigrationPipeline | pipeline | The migration pipeline. |
| ISourceEndpoint | endpoint | The source endpoint. |
| IConfigReader | configReader | A config reader. |
| ILogger<SourceCache<TContent>> | logger |
Properties
Name
Declaration
protected override string Name { get; }
Property Value
| Type | Description |
|---|---|
| string |
Overrides
Methods
ItemsLoadedAsync(IImmutableList<TContent>, CancellationToken)
Called after one or more items have been loaded into the cache from the store.
Declaration
protected override Task ItemsLoadedAsync(IImmutableList<TContent> items, CancellationToken cancel)
Parameters
| Type | Name | Description |
|---|---|---|
| IImmutableList<TContent> | items | The items that were loaded. |
| CancellationToken | cancel | The cancellation token to obey. |
Returns
| Type | Description |
|---|---|
| Task | A task to await. |
Overrides
UpdateManifestByContentUrlAsync(string, CancellationToken)
Attempts to update the manifest for a missing source content URL.
Declaration
public Task<IMigrationManifestEntryEditor?> UpdateManifestByContentUrlAsync(string contentUrl, CancellationToken cancel)
Parameters
| Type | Name | Description |
|---|---|---|
| string | contentUrl | The source content URL to search for. |
| CancellationToken | cancel | The cancellation token to obey. |
Returns
| Type | Description |
|---|---|
| Task<IMigrationManifestEntryEditor> | A task to await with the manifest entry for the source information, or null if the source item could not be found. |
UpdateManifestByIdAsync(Guid, CancellationToken)
Attempts to update the manifest for a missing source ID.
Declaration
public Task<IMigrationManifestEntryEditor?> UpdateManifestByIdAsync(Guid id, CancellationToken cancel)
Parameters
| Type | Name | Description |
|---|---|---|
| Guid | id | The source ID to search for. |
| CancellationToken | cancel | The cancellation token to obey. |
Returns
| Type | Description |
|---|---|
| Task<IMigrationManifestEntryEditor> | A task to await with the manifest entry for the source information, or null if the source item could not be found. |
UpdateManifestByLocationAsync(ContentLocation, CancellationToken)
Attempts to update the manifest for a missing source location.
Declaration
public Task<IMigrationManifestEntryEditor?> UpdateManifestByLocationAsync(ContentLocation location, CancellationToken cancel)
Parameters
| Type | Name | Description |
|---|---|---|
| ContentLocation | location | The source location to search for. |
| CancellationToken | cancel | The cancellation token to obey. |
Returns
| Type | Description |
|---|---|
| Task<IMigrationManifestEntryEditor> | A task to await with the manifest entry for the source information, or null if the source item could not be found. |