ModelCatalogException
Namespace: Meshmakers.Octo.ConstructionKit.Contracts
Indicates an exception during model catalog operations
public class ModelCatalogException : Exception, ISerializable
Inheritance Object → Exception → ModelCatalogException
Implements ISerializable
Properties
IsModelNotFound
True when the exception says that a model is not in the catalog (as opposed to the catalog not being readable).
public bool IsModelNotFound { get; private set; }
Property Value
IsRequestTimeout
True when a catalog request got no answer in time in any of its attempts.
public bool IsRequestTimeout { get; private set; }
Property Value
TargetSite
public MethodBase TargetSite { get; }
Property Value
Message
public string Message { get; }
Property Value
Data
public IDictionary Data { get; }
Property Value
InnerException
public Exception InnerException { get; }
Property Value
HelpLink
public string HelpLink { get; set; }
Property Value
Source
public string Source { get; set; }
Property Value
HResult
public int HResult { get; set; }
Property Value
StackTrace
public string StackTrace { get; }
Property Value
Methods
PublishFailed(CkModelId, String, Exception)
internal static Exception PublishFailed(CkModelId modelId, string catalogName, Exception exception)
Parameters
modelId CkModelId
catalogName String
exception Exception
Returns
GitHubRequestFailed(String, String, Int32, String, Int32, Exception)
A GitHub Contents API call gave up. Octokit's own message is the constant "An error occurred with this API request" - the status code and GitHub's error text live on properties nobody logs - so a failed publish told an operator nothing about whether it was a rate limit, a 5xx or a stale ref. Put all of it into the message the publish command prints, plus which file and how many attempts, so the next occurrence is diagnosable from the build log alone.
internal static Exception GitHubRequestFailed(string operation, string path, int statusCode, string apiErrorMessage, int attempts, Exception inner)
Parameters
operation String
path String
statusCode Int32
apiErrorMessage String
attempts Int32
inner Exception
Returns
UnpublishFailed(CkModelId, String, Exception)
internal static Exception UnpublishFailed(CkModelId modelId, string catalogName, Exception exception)
Parameters
modelId CkModelId
catalogName String
exception Exception
Returns
VersionWithdrawn(CkModelId, String, String, Nullable<DateTime>)
The version number was unpublished earlier and is burned — it is never published again, because tenants and caches may hold the old file.
internal static Exception VersionWithdrawn(CkModelId modelId, string catalogName, string reason, Nullable<DateTime> withdrawnAt)
Parameters
modelId CkModelId
catalogName String
reason String
withdrawnAt Nullable<DateTime>
Returns
CatalogUnreachable(String, String)
The source of truth of a catalog could not be read, so a decision that needs the whole catalog (the
unpublish dependents check) is not taken. Same rule and code as the publish gate (OCTO-CK202).
internal static Exception CatalogUnreachable(string catalogName, string reason)
Parameters
catalogName String
reason String
Returns
UnpublishRefusedDependents(CkModelId, String, IReadOnlyList<UnpublishDependent>)
Unpublish is refused while published models still depend on the version.
internal static Exception UnpublishRefusedDependents(CkModelId modelId, string catalogName, IReadOnlyList<UnpublishDependent> dependents)
Parameters
modelId CkModelId
catalogName String
dependents IReadOnlyList<UnpublishDependent>
Returns
UnpublishReasonRequired(String)
The public catalog needs a reason for every unpublish.
internal static Exception UnpublishReasonRequired(string catalogName)
Parameters
catalogName String
Returns
ModelAlreadyExists(CkModelId, String)
internal static Exception ModelAlreadyExists(CkModelId ckModelId, string catalogName)
Parameters
ckModelId CkModelId
catalogName String
Returns
ErrorDuringModelLoad(CkModelId, String, OperationResult)
internal static Exception ErrorDuringModelLoad(CkModelId ckModelId, string catalogName, OperationResult operationResult)
Parameters
ckModelId CkModelId
catalogName String
operationResult OperationResult
Returns
ModelNotFound(CkModelId, String)
Creates an exception that indicates that a model was not found in a specific repository.
public static Exception ModelNotFound(CkModelId ckModelId, string catalogName)
Parameters
ckModelId CkModelId
catalogName String
Returns
ModelCatalogNotFound(String)
internal static Exception ModelCatalogNotFound(string catalogName)
Parameters
catalogName String
Returns
ModelNotFoundInCatalogs(CkModelId)
internal static Exception ModelNotFoundInCatalogs(CkModelId ckModelId)
Parameters
ckModelId CkModelId
Returns
CatalogDoesNotSupportSourceIdentifier(String)
internal static Exception CatalogDoesNotSupportSourceIdentifier(string catalogName)
Parameters
catalogName String
Returns
CatalogNotWritable(String)
internal static Exception CatalogNotWritable(string catalogName)
Parameters
catalogName String
Returns
GitHubTokenMissing()
internal static Exception GitHubTokenMissing()
Returns
GitHubPagesUriMissing()
internal static Exception GitHubPagesUriMissing()
Returns
InvalidGitHubRepository(String, String)
internal static Exception InvalidGitHubRepository(string catalogName, string uri)
Parameters
catalogName String
uri String
Returns
InvalidModelLibraryCatalogFile(CkModelIdVersionRange, String, String)
internal static Exception InvalidModelLibraryCatalogFile(CkModelIdVersionRange ckModelIdVersionRange, string catalogName, string uri)
Parameters
ckModelIdVersionRange CkModelIdVersionRange
catalogName String
uri String
Returns
InvalidModelLibraryCatalogFile(CkModelIdVersionRange, String, String, Exception)
internal static Exception InvalidModelLibraryCatalogFile(CkModelIdVersionRange ckModelIdVersionRange, string catalogName, string uri, Exception innerException)
Parameters
ckModelIdVersionRange CkModelIdVersionRange
catalogName String
uri String
innerException Exception
Returns
RequestTimeoutGitHubRepository(String, String)
internal static Exception RequestTimeoutGitHubRepository(string repositoryName, string valueGitHubPagesUri)
Parameters
repositoryName String
valueGitHubPagesUri String
Returns
PartialCache(String)
The last refresh read the catalog only partly, so its cache cannot answer as a complete inventory.
internal static ModelCatalogException PartialCache(string catalogName)
Parameters
catalogName String
Returns
CatalogRequestTimedOut(String, String, Exception)
A catalog index request got no answer in time (a server that accepts the connection and never responds); the refresh fails instead of hanging the build.
internal static Exception CatalogRequestTimedOut(string catalogName, string url, Exception innerException)
Parameters
catalogName String
url String
innerException Exception
Returns
CannotReadExistingModelVersionCatalog(CkModelId, String, String)
internal static Exception CannotReadExistingModelVersionCatalog(CkModelId modelId, string catalogName, string catalogPath)
Parameters
modelId CkModelId
catalogName String
catalogPath String
Returns
CannotReadExistingModelLibraryCatalog(CkModelId, String, String)
internal static Exception CannotReadExistingModelLibraryCatalog(CkModelId modelId, string catalogName, string catalogPath)
Parameters
modelId CkModelId
catalogName String
catalogPath String
Returns
CatalogNotEnabledToRead(String)
internal static Exception CatalogNotEnabledToRead(string catalogName)
Parameters
catalogName String
Returns
CatalogNotEnabledToWrite(String)
internal static Exception CatalogNotEnabledToWrite(string catalogName)
Parameters
catalogName String