This commit is contained in:
@@ -29,14 +29,13 @@ namespace AyaNova.Core
|
||||
{
|
||||
|
||||
//License server address
|
||||
private const string LICENSE_SERVER_URL = "https://rockfish.ayanova.com/";
|
||||
// private const string LICENSE_SERVER_URL = "https://rockfish.ayanova.com/";
|
||||
|
||||
// #if (DEBUG)
|
||||
//IF TESTING LOCAL DEV ROCKFISH:
|
||||
// private const string LICENSE_SERVER_URL = "http://localhost:3001/";
|
||||
// #else
|
||||
// private const string LICENSE_SERVER_URL = "https://rockfish.ayanova.com/";
|
||||
// #endif
|
||||
#if (DEBUG)
|
||||
private const string LICENSE_SERVER_URL = "http://localhost:3001/";
|
||||
#else
|
||||
private const string LICENSE_SERVER_URL = "https://rockfish.ayanova.com/";
|
||||
#endif
|
||||
|
||||
//Unlicensed token
|
||||
private const string UNLICENSED_TOKEN = "UNLICENSED";
|
||||
@@ -492,7 +491,11 @@ namespace AyaNova.Core
|
||||
/// Fetch a key, validate it and install it in the db then initialize with it
|
||||
/// </summary>
|
||||
/// <returns>Result string</returns>
|
||||
internal static async Task<string> FetchKeyAsync(AyaNova.Api.ControllerHelpers.ApiServerState apiServerState, AyContext ct, ILogger log, bool calledFromInternalJob)
|
||||
#if (DEBUG)
|
||||
internal static async Task<string> FetchKeyAsync(AyaNova.Api.ControllerHelpers.ApiServerState apiServerState, AyContext ct, ILogger log, bool calledFromInternalJob, bool devTestTrial=false)
|
||||
#else
|
||||
internal static async Task<string> FetchKeyAsync(AyaNova.Api.ControllerHelpers.ApiServerState apiServerState, AyContext ct, ILogger log, bool calledFromInternalJob)
|
||||
#endif
|
||||
{
|
||||
if (calledFromInternalJob)
|
||||
log.LogTrace($"Fetching license for DBID {LicenseDbId} (called by job)");
|
||||
@@ -500,7 +503,16 @@ namespace AyaNova.Core
|
||||
log.LogInformation($"Fetching license for DBID {LicenseDbId}");
|
||||
|
||||
var FetchRequest = new dtoFetchRequest() { DbId = LicenseDbId };
|
||||
#if (DEBUG)
|
||||
string sUrl = $"{LICENSE_SERVER_URL}rvf";
|
||||
if (devTestTrial)
|
||||
{
|
||||
sUrl += "?dtt=true";//signal to rockfish to provide a key immediately for dev testing
|
||||
}
|
||||
#else
|
||||
string sUrl = $"{LICENSE_SERVER_URL}rvf";
|
||||
#endif
|
||||
|
||||
try
|
||||
{
|
||||
// string ResponseText = await ServiceProviderProvider.HttpClientFactory.CreateClient().GetStringAsync(sUrl);
|
||||
|
||||
Reference in New Issue
Block a user