You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would like to submit a proposal for an OpenFaaS template that uses F# and ASP.NET Core with .NET v6.0 (latest stable release). Here is a link to the repo containing the template: https://github.com/zakaluka/fsharp-httprequest-template
Why I made this template
While there are some .NET templates (csharp, csharp-httprequest, csharp-kestrel), all of them are C# specific. While both F# and C# are .NET languages and (at least in my template) utilize ASP.NET Core under the hood, functional ASP.NET Core programming in F# is often accomplished using a wrapper like Giraffe (which is used here) or Saturn (not used in this template).
This new template uses Giraffe and the functional style advocated by Giraffe to build and expose a web service. Despite the addition of Giraffe, the template is relatively minimal and does not create a dependency on a database or other external platform.
Uses on .NET 6 (latest GA) and of-watchdog 0.9.6. This means that it uses Kestrel already because it is the default launch profile in .NET v6 and there is no need for separate templates like C# has.
Uses F# programming paradigms for familiarity
Provides working solution OOTB, user only has to tweak the routing and function to meet their needs.
Easy to add dependencies, perform builds, testing, etc. using built-in .NET tools (dotnet package add ...)
Why not to use this template?
Requires the latest .NET 6. Can be downgraded easily (in the easiest instance, by modifying the 2 .fspoj files) to .NET v5, .NET Core v3, or .NET Framework v4.x, but this would be an end-user activity.
Does not provide a built-in framework like SAFE Stack - the template is purposely kept minimal in the spirit of FaaS solutions. However, all dependencies can be easily added by the user if they want to use SAFE or another framework.
Does not use a non-ASP.NET Core web platform, like Suave or NancyFX.
Thank you for your time and consideration.
The text was updated successfully, but these errors were encountered:
zakaluka
changed the title
Submission : F# of-watchdog http template
Submission : F# of-watchdog http template (ASP.NET Core v6)
Jun 13, 2022
Update: Modified the routing function so that no change is required by the user - they can just modify the FunctionHandler body to take the desired action. The FunctionHanlder receives both path and query parameters (for GET), plus has access to other elements such as the payload of a POST (not implemented in sample).
Hello,
I would like to submit a proposal for an OpenFaaS template that uses F# and ASP.NET Core with .NET v6.0 (latest stable release). Here is a link to the repo containing the template: https://github.com/zakaluka/fsharp-httprequest-template
Why I made this template
While there are some .NET templates (
csharp
,csharp-httprequest
,csharp-kestrel
), all of them are C# specific. While both F# and C# are .NET languages and (at least in my template) utilize ASP.NET Core under the hood, functional ASP.NET Core programming in F# is often accomplished using a wrapper like Giraffe (which is used here) or Saturn (not used in this template).This new template uses Giraffe and the functional style advocated by Giraffe to build and expose a web service. Despite the addition of Giraffe, the template is relatively minimal and does not create a dependency on a database or other external platform.
Why to use this template?
dotnet package add ...
)Why not to use this template?
.fspoj
files) to .NET v5, .NET Core v3, or .NET Framework v4.x, but this would be an end-user activity.Thank you for your time and consideration.
The text was updated successfully, but these errors were encountered: