Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Do not merge] Convert solution to the new csproj format #93

Open
wants to merge 12 commits into
base: master
Choose a base branch
from

Conversation

0xced
Copy link
Contributor

@0xced 0xced commented May 31, 2018

Although the documentation (Additions to the csproj format for .NET Core) seems to imply that this is a .NET Core feature, it works with .NET Framework too and is much easier to maintain.

With this commit, the OctoPack feature is gone, it will need some work to reintegrate.

Note that this pull request depends on #91 to be merged first and should be rebased before merging.

@0xced
Copy link
Contributor Author

0xced commented May 31, 2018

The build failed with this error:

C:\projects\sbmanager\src\SbManager.Tests\SbManager.Tests.csproj(1,1): error MSB4041: The default XML namespace of the project must be the MSBuild XML namespace. If the project is authored in the MSBuild 2003 format, please add xmlns="http://schemas.microsoft.com/developer/msbuild/2003" to the element. If the project has been authored in the old 1.0 or 1.2 format, please convert it to MSBuild 2003 format.

So I tried to add an .appveyor.yml file to the repository for configuring the Visual Studio 2017 image but the same error occurred. I guess you have configured AppVeyor to ignore appveyor.yml. Could you please configure AppVeyor to use the Visual Studio 2017 image to verify that the build and the tests still succeed?

@0xced 0xced force-pushed the Project-Sdk branch 4 times, most recently from d1c83bf to 6f47081 Compare June 5, 2018 20:58
0xced added 12 commits June 6, 2018 20:27
The [`Microsoft.Azure.ServiceBus`](https://www.nuget.org/packages/Microsoft.Azure.ServiceBus/) package conforms to .NET Standard and thus works fine on Linux and macOS (using Mono). The WindowsAzure.ServiceBus package can't run on Mono since it depends on kernel32.dll.

Required incidental changes:

* Upgrade target framework from v4.6 to v4.7.1
* Swith to async code
* Upgrade `Newtonsoft.Json` from version 9 to version 10
* Delete IsBodyConsumed and State for which I have found no equivalent
* Take a dependency on `Mossharbor.AzureWorkArounds.ServiceBus` since management is not (yet) supported with a service bus connection string, see Azure/azure-service-bus-dotnet#65
* Use a local version of `Mossharbor.AzureWorkArounds.ServiceBus` since `GetQueues()` and `GetTopics()` are not implemented in the published package Mossharbor/AzureWorkArounds.ServiceBus#6
Continuous integration on AppVeyor uses C# 5
Microsoft.Azure.ServiceBus now provides this feature with `EntityNameHelper.FormatDeadLetterPath()`
This was omitted when refactoring to use Microsoft.Azure.ServiceBus
The features of Serilog.Sinks.Literate have now been merged into the default Serilog console sink.

The motivation behind this change is to be able to easily change the theme `WriteTo.Console(theme: ConsoleTheme.None)` so that the output in the JetBrains Rider console isn't white text on white background.
The Microsoft.Azure.ServiceBus library targets .NET Standard 2.0 which is actually compatible with .NET Framework 4.6.1, see https://github.com/dotnet/standard/blob/release/2.0.0/docs/versions.md
Although the [documentation (Additions to the csproj format for .NET Core)][1] seems to imply that this is a .NET Core feature, it works with .NET Framework too and is much easier to maintain.

With this commit, the OctoPack feature is gone because the new .csproj format is not yet supported by OctoPack. Here is the [suggested workaround][2]:
> We have this support on our radar, but don't have an ETA at this stage.
In the meantime, you could try running `dotnet publish` and then run `octo.exe pack` against the publish output folder.

[1]: https://docs.microsoft.com/en-us/dotnet/core/tools/csproj
[2]: OctopusDeploy/Issues#3822 (comment)

# Conflicts:
#	src/SbManager/SbManager.csproj
#	src/SbManager/packages.config
@drewfreyling
Copy link
Contributor

Still need the pipeline changed for this PR? I was hesitant to initially but no direction has changed to make this azure only I'm happy to make the change?

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