<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Wed Feb 07 21:40:44 UTC 2024

It is possible to restrict the fields that are returned in this document by specifying the 'field' parameter in your request.
For example, to request only the issue key and summary append 'field=key&field=summary' to the URL of your request.
-->
<rss version="0.92" >
<channel>
    <title>MongoDB Jira</title>
    <link>https://jira.mongodb.org</link>
    <description>This file is an XML representation of an issue</description>
    <language>en-us</language>    <build-info>
        <version>9.7.1</version>
        <build-number>970001</build-number>
        <build-date>13-04-2023</build-date>
    </build-info>


<item>
            <title>[CSHARP-1807] Missing dependency on System.Runtime.InteropServices.RuntimeInformation</title>
                <link>https://jira.mongodb.org/browse/CSHARP-1807</link>
                <project id="10041" key="CSHARP">C# Driver</project>
                    <description>&lt;p&gt;The Nuget packages for 2.4.0-beta1 are missing a required dependency on the System.Runtime.InteropServices.RuntimeInformation Nuget package.&lt;/p&gt;

&lt;p&gt;The symptom is the following exception when attempting to communicate with MongoDB:&lt;/p&gt;

&lt;p/&gt;
&lt;div id=&quot;syntaxplugin&quot; class=&quot;syntaxplugin&quot; style=&quot;border: 1px dashed #bbb; border-radius: 5px !important; overflow: auto; max-height: 30em;&quot;&gt;
&lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;0&quot; width=&quot;100%&quot; style=&quot;font-size: 1em; line-height: 1.4em !important; font-weight: normal; font-style: normal; color: black;&quot;&gt;
		&lt;tbody &gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;  margin-top: 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;An unhandled exception of type &apos;System.IO.FileNotFoundException&apos; occurred in mscorlib.dll&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&amp;nbsp;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;Additional information: Could not load file or assembly &apos;System.Runtime.InteropServices.RuntimeInformation, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a&apos; or one of its &lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   margin-bottom: 10px;  width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;dependencies. The system cannot find the file specified.&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
			&lt;/tbody&gt;
&lt;/table&gt;
&lt;/div&gt;
&lt;p/&gt;</description>
                <environment></environment>
        <key id="326007">CSHARP-1807</key>
            <summary>Missing dependency on System.Runtime.InteropServices.RuntimeInformation</summary>
                <type id="1" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14703&amp;avatarType=issuetype">Bug</type>
                                            <priority id="3" iconUrl="https://jira.mongodb.org/images/icons/priorities/major.svg">Major - P3</priority>
                        <status id="6" iconUrl="https://jira.mongodb.org/images/icons/statuses/closed.png" description="The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.">Closed</status>
                    <statusCategory id="3" key="done" colorName="success"/>
                                    <resolution id="9">Done</resolution>
                                        <assignee username="robert@mongodb.com">Robert Stam</assignee>
                                    <reporter username="robert@mongodb.com">Robert Stam</reporter>
                        <labels>
                    </labels>
                <created>Sat, 22 Oct 2016 01:45:37 +0000</created>
                <updated>Mon, 21 Aug 2017 00:05:27 +0000</updated>
                            <resolved>Wed, 26 Oct 2016 15:17:36 +0000</resolved>
                                    <version>2.4.0-beta1</version>
                                    <fixVersion>2.4</fixVersion>
                                    <component>Connectivity</component>
                                        <votes>0</votes>
                                    <watches>4</watches>
                                                                                                                <comments>
                            <comment id="1652171" author="ianmercer" created="Sat, 19 Aug 2017 17:15:03 +0000"  >&lt;p&gt;I have been unable to get this to work at all under ASP.NET. I have tried both versions of the `System.Runtime.InteropServices.RuntimeInformation` from Nuget and have also tried linking directly to all of the DLLs in that package that could possibly work. I&apos;ve even tried creating my own `System.Runtime.InteropServices.RuntimeInformation` from source code.&lt;/p&gt;

&lt;p&gt;But in MongoDB.DriverCore there seems to be a hard dependency on a specific, signed version of the DLL: &lt;a href=&quot;https://github.com/mongodb/mongo-csharp-driver/blob/db9e7254075435fca9c4dab78eaca894793d5b78/src/MongoDB.Driver.Core/MongoDB.Driver.Core.csproj#L39&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-csharp-driver/blob/db9e7254075435fca9c4dab78eaca894793d5b78/src/MongoDB.Driver.Core/MongoDB.Driver.Core.csproj#L39&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;    `&amp;lt;Reference Include=&quot;System.Runtime.InteropServices.RuntimeInformation, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL&quot;&amp;gt;`&lt;/p&gt;

&lt;p&gt;Why is this reference so specific? And how do I get MongoDB 2.4 to work under ASP.NET now?&lt;/p&gt;

&lt;p&gt;Update, after &lt;b&gt;much&lt;/b&gt; experimentation it seems web.config needs the following to work:&lt;/p&gt;

&lt;p&gt;      &amp;lt;dependentAssembly&amp;gt;&lt;br/&gt;
        &amp;lt;assemblyIdentity name=&quot;System.Runtime&quot; publicKeyToken=&quot;b03f5f7f11d50a3a&quot; culture=&quot;neutral&quot; /&amp;gt;&lt;br/&gt;
        &amp;lt;bindingRedirect oldVersion=&quot;0.0.0.0-4.1.2.0&quot; newVersion=&quot;4.1.2.0&quot; /&amp;gt;&lt;br/&gt;
      &amp;lt;/dependentAssembly&amp;gt;&lt;br/&gt;
      &amp;lt;dependentAssembly&amp;gt;&lt;br/&gt;
        &amp;lt;assemblyIdentity name=&quot;System.Runtime.InteropServices.RuntimeInformation&quot; publicKeyToken=&quot;b03f5f7f11d50a3a&quot; culture=&quot;neutral&quot; /&amp;gt;&lt;br/&gt;
        &amp;lt;bindingRedirect oldVersion=&quot;0.0.0.0-4.0.2.0&quot; newVersion=&quot;4.0.2.0&quot; /&amp;gt;&lt;br/&gt;
      &amp;lt;/dependentAssembly&amp;gt;&lt;/p&gt;

&lt;p&gt;Whatever redirects Nuget was putting there were incorrect (a 1 instead of a 2). This maybe isn&apos;t a MongoDB issue per se, perhaps in the Microsoft Nuget packages / version stamps??&lt;/p&gt;</comment>
                            <comment id="1629409" author="david@neuroticmedia.com" created="Sun, 23 Jul 2017 00:57:27 +0000"  >&lt;p&gt;I thought this was resolved, but in some flavors of .net 4.5 it is still an issue.  I ended up rolling back to 2.3 to get around it.  I tried to add the reference, but still had the issue.&lt;/p&gt;</comment>
                            <comment id="1464881" author="svarog" created="Sat, 24 Dec 2016 18:07:37 +0000"  >&lt;p&gt;This is still a problem when compiling under mono on linux.&lt;/p&gt;

&lt;p&gt;The current available nuget version doesn&apos;t support System.Runtime.InteropServices.RuntimeInformation&lt;br/&gt;
I&apos;m not even sure it&apos;s possible to get System.Runtime.InteropServices.RuntimeInformation to work in mono on linux, since it interops with Windows-specific functionality.&lt;/p&gt;</comment>
                            <comment id="1418266" author="xgen-internal-githook" created="Wed, 26 Oct 2016 15:16:49 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{u&apos;username&apos;: u&apos;rstam&apos;, u&apos;name&apos;: u&apos;rstam&apos;, u&apos;email&apos;: u&apos;robert@robertstam.org&apos;}
&lt;p&gt;Message: &lt;a href=&quot;https://jira.mongodb.org/browse/CSHARP-1807&quot; title=&quot;Missing dependency on System.Runtime.InteropServices.RuntimeInformation&quot; class=&quot;issue-link&quot; data-issue-key=&quot;CSHARP-1807&quot;&gt;&lt;del&gt;CSHARP-1807&lt;/del&gt;&lt;/a&gt;: Added missing dependency.&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-csharp-driver/commit/38db92888f1ac232c2a90eef20546bd51f905404&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-csharp-driver/commit/38db92888f1ac232c2a90eef20546bd51f905404&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="1418239" author="rstam" created="Wed, 26 Oct 2016 15:02:14 +0000"  >&lt;p&gt;This problem only seems to affect applications targeting the full .NET Framework.&lt;/p&gt;

&lt;p&gt;For .NET Core, we already have an indirect dependency on System.Runtime.InteropServices.RuntimeInformation through the dependency on NETStandard.Library.&lt;/p&gt;</comment>
                            <comment id="1414970" author="rstam" created="Sat, 22 Oct 2016 01:48:02 +0000"  >&lt;p&gt;You can work around this bug by manually adding a dependency to the System.Runtime.InteropServices.RuntimeInformation Nuget package to your own project.&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                                        </outwardlinks>
                                                        </issuelinktype>
                    </issuelinks>
                <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_15850" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|hrc6q7:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10558" key="com.pyxis.greenhopper.jira:gh-global-rank">
                        <customfieldname>Rank (Obsolete)</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>9223372036854775807</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                    <customfield id="customfield_10557" key="com.pyxis.greenhopper.jira:gh-sprint">
                        <customfieldname>Sprint</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue id="1329">C# Sprint 43</customfieldvalue>
    <customfieldvalue id="1362">C# Sprint 44</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            </customfields>
    </item>
</channel>
</rss>