﻿<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <configSections>
    <sectionGroup name="elmah">
      <section name="security" requirePermission="false" type="Elmah.SecuritySectionHandler, Elmah" />
      <section name="errorLog" requirePermission="false" type="Elmah.ErrorLogSectionHandler, Elmah" />
    </sectionGroup>
    <section name="nlog" type="NLog.Config.ConfigSectionHandler, NLog" />
    <section name="couchbase" type="Couchbase.Configuration.CouchbaseClientSection, Couchbase" />
  </configSections>
  <appSettings>
    <add key="Redis-HostName" value="127.0.0.1" />
    <add key="ClientSettingsProvider.ServiceUri" value="" />
    <add key="SpotifyRateLimitPerSecond" value="40" />

    <add key="FetchSpotifyCharts_Delay_Milliseconds" value="500" />

    <add key="AggregatedPlaylistImportTask_RecalculateOnly" value="false" />
    <add key="AggregatedPlaylistImportTask_RecalculateOnly_StartDateIncluding" value="2021-07-07" />
    <add key="AggregatedPlaylistImportTask_RecalculateOnly_EndDateExcluding" value="2021-07-08" />

    <add key="UpdatePlaylistInfo_Personalized_Spotify_ClientId" value="***REMOVED***" />
    <add key="UpdatePlaylistInfo_Personalized_Spotify_ClientSecret" value="***REMOVED***" />

    
    <!-- PROD SYNC JOB settings  
    <add key="SpotifyWebApiClientId" value="***REMOVED***" />
    <add key="SpotifyWebApiClientSecret" value="***REMOVED***" />-->
<!-- Apollo PROD SETTINGS 
    <add key="ApolloAudience" value="https://apollo-private-api/" />
    <add key="ApolloClientId" value="***REMOVED***" />
    <add key="ApolloClientSecret" value="***REMOVED***" />
    <add key="ApolloTokenServiceURL" value="https://prod-dna-apps.auth0.com/oauth/token" />
    <add key="ApolloUrl" value="https://privateapi-auth0.filtr.com" />
-->

    <!-- Dev spotify settings 
	<add key="SpotifyWebApiClientId" value="***REMOVED***" />
	<add key="SpotifyWebApiClientSecret" value="***REMOVED***" />
	-->

    <!-- Dev spotify SECONDARY settings key from dev vendor (BORIS) 
	<add key="SpotifyWebApiClientId" value="***REMOVED***" />
	<add key="SpotifyWebApiClientSecret" value="***REMOVED***" />
	-->
    <!-- PROD spotify settings 	
    <add key="SpotifyWebApiClientId" value="***REMOVED***" />
    <add key="SpotifyWebApiClientSecret" value="***REMOVED***" />
    -->
    <!--AWSProfileName is used to reference an account that has been registered with the SDK.
If using AWS Toolkit for Visual Studio then this value is the same value shown in the AWS Explorer.
It is also possible to register an account using the <solution-dir>/packages/AWSSDK-X.X.X.X/tools/account-management.ps1 PowerShell script
that is bundled with the nuget package under the tools folder.

		<add key="AWSProfileName" value="" />
-->
  </appSettings>
  <couchbase>
    <servers bucket="default" bucketPassword="">
      <add uri="http://127.0.0.1:8091/pools/default" />
    </servers>
    <keyTransformer type="Enyim.Caching.Memcached.TigerHashKeyTransformer, Enyim.Caching" />
  </couchbase>
  <elmah>
    <security allowRemoteAccess="false" />
    <errorLog type="Elmah.MySqlErrorLog, Elmah" connectionStringName="dbErrorLogging" applicationName="Sony.Filtr.ScheduledTask" />
  </elmah>
  <!--PROD CONNECTION STRING

  <connectionStrings>
    <add name="db" connectionString="Server=prod-apollo-aurora-cluster.cluster-cjzbf0a3lwld.us-east-1.rds.amazonaws.com;Database=dbSony_dbo;Uid=sony;Pwd=***REMOVED***;CharSet=utf8mb4;Convert Zero Datetime=True;UseCompression=true;default command timeout=2000;Connection Timeout=2000;" providerName="MySql.Data.MySqlClient" />
    <add name="dbReadOnly" connectionString="Server=prod-apollo-aurora-cluster.cluster-ro-cjzbf0a3lwld.us-east-1.rds.amazonaws.com;Database=dbSony_dbo;Uid=sony;Pwd=***REMOVED***;CharSet=utf8mb4;Convert Zero Datetime=True;UseCompression=true;default command timeout=2000;Connection Timeout=2000;" providerName="MySql.Data.MySqlClient" />
    <add name="dbErrorLogging" connectionString="Server=prod-apollo-aurora-cluster.cluster-cjzbf0a3lwld.us-east-1.rds.amazonaws.com;Database=elmah;Uid=sony;Pwd=***REMOVED***;CharSet=utf8;UseCompression=true;" providerName="MySql.Data.MySqlClient" />
  </connectionStrings>-->
  <!-- DEV CONNECTION STRINGS -->
  <connectionStrings>
    <add name="db" connectionString="Default Command Timeout=600;Server=dev-apollo-aurora-cep.cluster-custom-cic9zqsxd2y6.us-east-1.rds.amazonaws.com;Database=dbSony_dbo;Uid=sony;Pwd=***REMOVED***;CharSet=utf8mb4;Convert Zero Datetime=True;UseCompression=true;" providerName="MySql.Data.MySqlClient" />
    <add name="dbReadOnly" connectionString="Default Command Timeout=600;Server=dev-apollo-aurora-cep.cluster-custom-cic9zqsxd2y6.us-east-1.rds.amazonaws.com;Database=dbSony_dbo;Uid=sony;Pwd=***REMOVED***;CharSet=utf8mb4;Convert Zero Datetime=True;UseCompression=true;" providerName="MySql.Data.MySqlClient" />
    <add name="dbErrorLogging" connectionString="Server=dev-apollo-aurora-cep.cluster-custom-cic9zqsxd2y6.us-east-1.rds.amazonaws.com;Database=elmah;Uid=sony;Pwd=***REMOVED***;CharSet=utf8;" providerName="MySql.Data.MySqlClient" />
  </connectionStrings>
  <startup>
    <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.1" />
  </startup>
  <runtime>
    <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
      <dependentAssembly>
        <assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-11.0.0.0" newVersion="11.0.0.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="System.Data.SQLite" publicKeyToken="db937bc2d44ff139" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-1.0.93.0" newVersion="1.0.93.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="BookSleeve" publicKeyToken="9056fda458ff61cf" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-1.3.41.0" newVersion="1.3.41.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="System.Net.Http.Primitives" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-4.2.29.0" newVersion="4.2.29.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="MySql.Data" publicKeyToken="c5687fc88969c44d" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-8.0.13.0" newVersion="8.0.13.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="MoreLinq" publicKeyToken="384d532d7e88985d" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-1.1.18418.0" newVersion="1.1.18418.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="System.Net.Http.Formatting" publicKeyToken="31bf3856ad364e35" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-5.2.7.0" newVersion="5.2.7.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="System.Threading.Tasks" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-2.6.10.0" newVersion="4.0.11.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="EntityFramework" publicKeyToken="b77a5c561934e089" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-6.0.0.0" newVersion="6.0.0.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="System.Reflection" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-4.1.2.0" newVersion="4.1.2.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="System.Reflection.TypeExtensions" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-4.1.0.0" newVersion="4.1.0.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="NodaTime" publicKeyToken="4226afe0d9b296d1" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-2.2.3.0" newVersion="2.2.3.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="System.Buffers" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-4.0.3.0" newVersion="4.0.3.0" />
      </dependentAssembly>
      <dependentAssembly>
        <assemblyIdentity name="System.Net.Http" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
        <bindingRedirect oldVersion="0.0.0.0-4.2.0.0" newVersion="4.2.0.0" />
      </dependentAssembly>
    </assemblyBinding>
  </runtime>
  <system.data>
    <DbProviderFactories>
      <clear />
      <add name="MySQL Data Provider" invariant="MySql.Data.MySqlClient" description=".Net Framework Data Provider for MySQL" type="MySql.Data.MySqlClient.MySqlClientFactory, MySql.Data, Version=6.2.2.0, Culture=neutral, PublicKeyToken=C5687FC88969C44D" />
    </DbProviderFactories>
  </system.data>
  <system.web>
    <membership defaultProvider="ClientAuthenticationMembershipProvider">
      <providers>
        <add name="ClientAuthenticationMembershipProvider" type="System.Web.ClientServices.Providers.ClientFormsAuthenticationMembershipProvider, System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" serviceUri="" />
      </providers>
    </membership>
    <roleManager defaultProvider="ClientRoleProvider" enabled="true">
      <providers>
        <add name="ClientRoleProvider" type="System.Web.ClientServices.Providers.ClientRoleProvider, System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" serviceUri="" cacheTimeout="86400" />
      </providers>
    </roleManager>
  </system.web>
  <nlog xmlns="http://www.nlog-project.org/schemas/NLog.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <variable name="brief" value="${longdate} - ${message}" />
    <variable name="verbose" value="${longdate} | ${machinename} | ${processid} | ${processname} | ${level} | ${logger} | ${message} | ${exception:format=tostring:maxInnerExceptionLevel=2}" />
    <targets>
      <target name="logfile" xsi:type="File" fileName="logs/${logger}-${shortdate}.txt" layout="${verbose}" />
      <target name="console" xsi:type="ColoredConsole" layout="${brief}" />
    </targets>
    <rules>
      <logger name="*" minlevel="Debug" writeTo="logfile,console" />
    </rules>
  </nlog>
  <system.net>
    <mailSettings>
      <smtp deliveryMethod="Network">
        <network host="email-smtp.us-east-1.amazonaws.com" port="25" userName="***REMOVED***" password="***REMOVED***" enableSsl="true" />
      </smtp>
    </mailSettings>
  </system.net>
</configuration>