Closed Pip1987 closed 8 months ago
Hi Phil, thanks for these issues. I have created an errata item for them here: https://github.com/markjprice/apps-services-net8/blob/main/docs/errata/errata.md#page-462---implementing-a-function-that-works-with-queues-and-blobs
message
parameter I think might have been caused by something else: I had not created a .http
test file to trigger the check generation. I think you might have run the other test file that calls the NumbersToWords
function. I think that because that's exactly what I did too! And that doesn't trigger the queue. So I thought it was broken too initially. But then I noticed the missing test file and tried again and it worked correctly. I also updated the Azure packages to their current latest and they still work with the message
parameter as a string
as in the book. If you change the parameter to a QueueMessage
then that'd work too but only if you also make more changes throughout the code to convert the message.Body
into a string value for printing.Keep up the great work!
When i copied the CheckGeneratorFunctions from the book I noticed I had missing using references
I needed to change
public byte[] Run( [QueueTrigger("checksQueue")] string message)
topublic byte[] Run([QueueTrigger("checksQueue")] Azure.Storage.Queues.Models.QueueMessage message)
and the following mislabeled variables.log.LogInformation($"Blobs folder: {folder}");
to_logger.LogInformation($"Blobs folder: {folder}");
log.LogError(ex.Message);
to_logger.LogError(ex.Message);