-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
21 changed files
with
158 additions
and
63 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 15 additions & 0 deletions
15
src/PersistedCache.PostgreSql/PostgreSqlPersistedCacheOptions.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
using PersistedCache.Sql; | ||
|
||
namespace PersistedCache.PostgreSql; | ||
|
||
public class PostgreSqlPersistedCacheOptions : SqlPersistedCacheOptions | ||
{ | ||
public PostgreSqlPersistedCacheOptions(string connectionString) : base(connectionString) | ||
{ | ||
} | ||
|
||
/// <summary> | ||
/// The search path/schema to use for the cache (default: public). | ||
/// </summary> | ||
public string Schema { get; set; } = "public"; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
using System.Text.Json; | ||
|
||
namespace PersistedCache.Sql; | ||
|
||
public interface ISqlPersistedCacheOptions | ||
{ | ||
/// <summary> | ||
/// The name of the table to use for the cache. | ||
/// </summary> | ||
/// <exception cref="ArgumentException">Thrown when the table name is null or empty.</exception> | ||
string TableName { get; set; } | ||
|
||
/// <summary> | ||
/// Whether to create the table if it does not exist. | ||
/// </summary> | ||
bool CreateTableIfNotExists { get; set; } | ||
|
||
/// <summary> | ||
/// The connection string to use for the cache. | ||
/// </summary> | ||
string ConnectionString { get; } | ||
|
||
/// <summary> | ||
/// Whether to purge expired entries. | ||
/// </summary> | ||
bool PurgeExpiredEntries { get; set; } | ||
|
||
/// <summary> | ||
/// The interval at which to purge expired entries. | ||
/// </summary> | ||
TimeSpan PurgeInterval { get; set; } | ||
|
||
/// <summary> | ||
/// The options to use for JSON serialization. | ||
/// </summary> | ||
JsonSerializerOptions JsonOptions { get; set; } | ||
} |
Oops, something went wrong.