question

KUMARManish-6461 avatar image
0 Votes"
KUMARManish-6461 asked MikeUrnun commented

migrating an azure function from V2 to V3. error coming when adding MvcJsonMvcOptionsSetup

Currently migrating my azure function from V2 to V3. My function is broken into the following lines in startup.cs file:
public override void Configure(IFunctionsHostBuilder mybuilder)
{
mybuilder.Services.AddTransient<IConfigureOptions<MvcOptions>, MvcJsonMvcOptionsSetup>();
}
Using.netcore3.1, I have read "functions-versions#breaking-changes-between-2x-and-3x" and other documents as well. It seems I have to use Microsoft.AspNetCore.Mvc.NewtonsoftJson rather than Microsoft.AspNetCore.Mvc.Formatters.Json.Internal.


azure-functions
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

MikeUrnun avatar image
0 Votes"
MikeUrnun answered MikeUrnun commented

Hello @KUMARManish-6461

I found the following issues to be related and insightful:

I would look to try this workaround but after reading through discussions in the above issues, it seems better to use NewtonsoftJson for now.


· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Hi @KUMARManish-6461 - just checking in here, any luck with the workaround referenced above?

0 Votes 0 ·