switch to flat file storage

This commit is contained in:
Luke Pulverenti
2013-06-17 16:35:43 -04:00
parent 95f471e8c3
commit e677a57bf1
44 changed files with 958 additions and 1594 deletions

View File

@@ -215,7 +215,7 @@ namespace MediaBrowser.Server.Implementations.Session
var key = item.GetUserDataKey();
var data = await _userDataRepository.GetUserData(user.Id, key).ConfigureAwait(false);
var data = _userDataRepository.GetUserData(user.Id, key);
data.PlayCount++;
data.LastPlayedDate = DateTime.UtcNow;
@@ -226,7 +226,7 @@ namespace MediaBrowser.Server.Implementations.Session
}
await _userDataRepository.SaveUserData(user.Id, key, data, CancellationToken.None).ConfigureAwait(false);
// Nothing to save here
// Fire events to inform plugins
EventHelper.QueueEventIfNotNull(PlaybackStart, this, new PlaybackProgressEventArgs
@@ -266,7 +266,7 @@ namespace MediaBrowser.Server.Implementations.Session
if (positionTicks.HasValue)
{
var data = await _userDataRepository.GetUserData(user.Id, key).ConfigureAwait(false);
var data = _userDataRepository.GetUserData(user.Id, key);
UpdatePlayState(item, data, positionTicks.Value);
await _userDataRepository.SaveUserData(user.Id, key, data, CancellationToken.None).ConfigureAwait(false);
@@ -307,7 +307,7 @@ namespace MediaBrowser.Server.Implementations.Session
var key = item.GetUserDataKey();
var data = await _userDataRepository.GetUserData(user.Id, key).ConfigureAwait(false);
var data = _userDataRepository.GetUserData(user.Id, key);
if (positionTicks.HasValue)
{