Skip to content

Conversation

@davidchase
Copy link
Contributor

@davidchase davidchase commented Aug 20, 2025

Add .NET 8 Environment to Fission

Summary

This PR introduces a new .NET 8 runtime environment for Fission, providing modern C# serverless function execution with the latest .NET 8 SDK and runtime capabilities.

What's New

  • Complete .NET 8 environment with runtime and builder images for serverless function execution
  • Dual deployment modes:
    • --code for quick single-file deployments with runtime compilation
    • --src for complex projects with builder compilation and NuGet package support
  • ASP.NET Core 8.0 minimal API runtime server with improved performance
  • Full async/await support with native Task-based function execution

Examples Included

  • HelloWorld - Basic function demonstration
  • HttpTriggerExample - HTTP context detection and routing
  • AsyncFunctionExample - Async/await pattern implementation
  • MultiFileExample - Complex MVC-pattern project with services and models

Docker Images

Runtime: fission/dotnet8-env
Builder: fission/dotnet8-builder

Usage

Create environment

fission env create --name dotnet8
--image fission/dotnet8-env
--builder fission/dotnet8-builder

Deploy single file

fission fn create --name hello --env dotnet8 --code hello.cs

Deploy project

fission fn create --name myapp --env dotnet8 --src project.zip

Related to #421

"version": "1.31.1"
}
],[
{
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should only keep dotnet8 entry here and remove rest of entries probably.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove dotnet20 and dotnet from this file and others? or just this file?

- 'php7/**'
dotnet:
- 'dotnet/**'
dotnet20:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you also check code in donet20 and if we can consolidate both ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what do you mean by consolidate both by looking at dotnet20 code?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think let it be, I was exploring if we can keep only one env.
But this can done later once dotnet8 is released

Copy link
Member

@sanketsudake sanketsudake left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be good to have some tests around this if possible

@davidchase
Copy link
Contributor Author

@sanketsudake tests added

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR introduces a complete .NET 8 runtime environment for Fission, enabling modern C# serverless function execution with dual deployment modes and comprehensive example implementations.

Key changes:

  • Complete .NET 8 environment with runtime and builder images supporting both single-file (--code) and multi-file project (--src) deployments
  • ASP.NET Core 8.0 minimal API runtime with async/await support and improved performance
  • Four comprehensive examples demonstrating different usage patterns from basic functions to complex MVC-style projects

Reviewed Changes

Copilot reviewed 73 out of 81 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
dotnet8/Dockerfile Runtime container with .NET 8 SDK and ASP.NET Core web server
dotnet8/builder/Dockerfile Builder container for compiling source packages with NuGet support
dotnet8/Fission.DotNet/ Complete ASP.NET Core runtime application with specialized services
dotnet8/Fission.DotNet.Common/ Shared library providing Fission context and interface definitions
dotnet8/examples/ Four example projects showcasing different deployment patterns
environments.json Environment metadata and configuration
skaffold.yaml Build configuration for both runtime and builder images

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

throw new ArgumentNullException(nameof(context));
}

/*var function = this._functionStoreService.GetFunction();
Copy link

Copilot AI Aug 22, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Large block of commented-out code (lines 58-202) should be removed to improve maintainability. If this code needs to be preserved, consider moving it to version control history or documentation.

Copilot uses AI. Check for mistakes.
Copy link
Member

@sanketsudake sanketsudake left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving and merging as need for community.
I dont have expertise in .net runtime, but considering contribution as it is.
We would keep incorporating user feedback as it comes in.

@sanketsudake sanketsudake merged commit f9bb405 into fission:master Aug 22, 2025
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants