/// <summary> /// Query popular topics expirations /// </summary> /// <param name="timeRange">Time range</param> /// <param name="hostAppHandle">Host app handle</param> /// <param name="expiration">Expiration time</param> /// <returns>Topic feed entities</returns> public async Task <IList <ITopicFeedEntity> > QueryPopularTopicsExpirations(TimeRange timeRange, string hostAppHandle, DateTime expiration) { CTStore store = await this.tableStoreManager.GetStore(ContainerIdentifier.PopularTopics); RankFeedTable table = this.tableStoreManager.GetTable(ContainerIdentifier.PopularTopics, TableIdentifier.PopularTopicsExpirationsFeed) as RankFeedTable; string feedKey = this.GetPopularTopicsFeedKey(timeRange, hostAppHandle); var result = await store.QueryRankFeedByScoreAsync(table, ContainerIdentifier.PopularTopics.ToString(), feedKey, 0, expiration.ToFileTime()); var convertedResults = result.Select(item => StoreSerializers.MinimalTopicRankFeedEntityDeserialize(item.ItemKey)); return(convertedResults.ToList <ITopicFeedEntity>()); }