Blazor & WASM in combination to get statistics from Spotify API for performing the song analysis. With separate microservices for auth, Spotify, user data tracking, and application, connected through gRPC with Polly.
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

TrackClientService.cs 631B

1234567891011121314151617181920212223
  1. using Grpc.Net.Client;
  2. using GrpcShared.DTO.Search;
  3. using GrpcShared.Interfaces;
  4. using NemAnBlazor.Services.Interfaces;
  5. using ProtoBuf.Grpc.Client;
  6. namespace NemAnBlazor.Services
  7. {
  8. public class TrackClientService : ITrackClientService
  9. {
  10. private ITrackService _serviceClient;
  11. public TrackClientService(GrpcChannel grpcChannel)
  12. {
  13. _serviceClient = grpcChannel.CreateGrpcService<ITrackService>();
  14. }
  15. public async Task<SearchResponse> GetListSearchAsync(SearchRequest request)
  16. {
  17. return await _serviceClient.ListSearchAsync(request);
  18. }
  19. }
  20. }