Skip to content

Commit

Permalink
update nuget; fix PubSubConsumerViaSdk getting message
Browse files Browse the repository at this point in the history
  • Loading branch information
Yongguang Zhu committed Sep 13, 2023
1 parent 3cc3a6b commit b9e6da9
Show file tree
Hide file tree
Showing 8 changed files with 14 additions and 7 deletions.
2 changes: 1 addition & 1 deletion BindingsWithSdk/BindingsWithSdk.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Dapr.AspNetCore" Version="1.9.0" />
<PackageReference Include="Dapr.AspNetCore" Version="1.11.0" />
</ItemGroup>

</Project>
4 changes: 2 additions & 2 deletions ConfigurationWithSdk/ConfigurationWithSdk.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Dapr.AspNetCore" Version="1.9.0" />
<PackageReference Include="Dapr.Extensions.Configuration" Version="1.9.0" />
<PackageReference Include="Dapr.AspNetCore" Version="1.11.0" />
<PackageReference Include="Dapr.Extensions.Configuration" Version="1.11.0" />
</ItemGroup>

</Project>
2 changes: 1 addition & 1 deletion PubSubConsumer/Controllers/SleepController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public async Task<IActionResult> PostAsync(TinyCloudEvent<MessageInput> model)
// var payload = await sr.ReadToEndAsync();
// _logger.LogInformation(payload);
//}
_logger.LogInformation(model.Data.Name);
_logger.LogInformation($"name: {model.Data.Name} source: {model.Source}");
return Ok();
}
}
Expand Down
2 changes: 1 addition & 1 deletion PubSubConsumer/Controllers/WakeupController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public async Task<IActionResult> PostAsync(TinyCloudEvent<MessageInput> model)
// var payload = await sr.ReadToEndAsync();
// _logger.LogInformation(payload);
//}
_logger.LogInformation(model.Data.Name);
_logger.LogInformation($"name: {model.Data.Name} source: {model.Source}");
return Ok();
}
}
Expand Down
6 changes: 6 additions & 0 deletions PubSubConsumer/Models/TinyCloudEvent.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,11 @@ public class TinyCloudEvent<T>
{
[JsonPropertyName("data")]
public T Data { get; set; }

[JsonPropertyName("pubsubname")]
public string Pubsubname { get; set; }

[JsonPropertyName("source")]
public string Source { get; set; }
}
}
1 change: 1 addition & 0 deletions PubSubConsumerViaSdk/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@

app.MapControllers();

app.UseCloudEvents();
app.MapSubscribeHandler();

app.Run();
2 changes: 1 addition & 1 deletion SecretsManagementWithSdk/SecretsManagementWithSdk.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Dapr.Client" Version="1.9.0" />
<PackageReference Include="Dapr.Client" Version="1.11.0" />
</ItemGroup>

</Project>
2 changes: 1 addition & 1 deletion StateManagementWithSdk/StateManagementWithSdk.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Dapr.Client" Version="1.9.0" />
<PackageReference Include="Dapr.Client" Version="1.11.0" />
</ItemGroup>

</Project>

0 comments on commit b9e6da9

Please sign in to comment.