<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 09:01:55 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>[JAVA-4381] mongodb-driver-legacy MANIFEST.MF should not include Automatic-Module-Name</title>
                <link>https://jira.mongodb.org/browse/JAVA-4381</link>
                <project id="10006" key="JAVA">Java Driver</project>
                    <description>&lt;p&gt;The mogodb-driver-legacy jar is not intended to include an Automatic-Module-Name in its MANIFEST.MF, but it does. The reason it should not is because it is not a valid Java module. One of the rules for modules is that the classes in any given package can not be split among multiple modules, and due to the way that packages were structured since the beginning of the driver, we had no choice but to split the &quot;com.mongodb&quot; package between mongodb-driver-core and mongodb-driver-legacy. That&apos;s because many of the classes that are used by the non-legacy API, e.g. &lt;tt&gt;com.mongodb.ReadPreference&lt;/tt&gt;, are in the core mongodb-driver-core, while many of the legacy API classes, like &lt;tt&gt;com.mongodb.DBCollection&lt;/tt&gt; are in the mongodb-driver-legacy jar.&lt;/p&gt;

&lt;p&gt;See section 2.3 of &lt;a href=&quot;http://openjdk.java.net/projects/jigsaw/spec/sotms/#readability&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;The State of the Module System&lt;/a&gt; for a more rigorous explanation of the restrictions on splitting packages across multiple modules:&lt;/p&gt;

&lt;blockquote&gt;&lt;p&gt;The module system ensures that every dependence is fulfilled by precisely one other module, that the module graph is acyclic, that every module reads at most one module defining a given package, and that modules defining identically-named packages do not interfere with each other.&lt;/p&gt;&lt;/blockquote&gt;

&lt;p&gt;That&apos;s why the &lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/blob/r4.3.3/driver-legacy/build.gradle&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;build.gradle&lt;/a&gt; for driver-legacy doesn&apos;t specify an automatic module name.  Compare that, for example to the &lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/blob/r4.3.3/driver-sync/build.gradle#L46&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;build.gradle&lt;/a&gt; for driver-sync, which does.&lt;/p&gt;

&lt;p&gt;However, in &lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/blob/master/gradle/publish.gradle&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;publish.gradle&lt;/a&gt; we incorrectly specify a default Automatic-Module-Name for &lt;em&gt;all&lt;/em&gt; jar files, and that&apos;s why mongdb-driver-legacy is ending up with one in its MANIFEST.  And to add insult to injury, it&apos;s using the archiveBaseName as the name, and the archiveBaseName is not even a valid module name (since it contains dashes).&lt;/p&gt;

&lt;p&gt;We should remove this configuration from publish.gradle and rely on each jar to specify its own Automatic-Module-Name, and in the case of the legacy jar, not specify one at all.&lt;/p&gt;</description>
                <environment></environment>
        <key id="1912903">JAVA-4381</key>
            <summary>mongodb-driver-legacy MANIFEST.MF should not include Automatic-Module-Name</summary>
                <type id="1" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14703&amp;avatarType=issuetype">Bug</type>
                                            <priority id="10300" iconUrl="https://jira.mongodb.org/images/icons/priorities/medium.svg">Unknown</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="13201">Fixed</resolution>
                                        <assignee username="ross@mongodb.com">Ross Lawley</assignee>
                                    <reporter username="jeff.yemin@mongodb.com">Jeffrey Yemin</reporter>
                        <labels>
                    </labels>
                <created>Fri, 29 Oct 2021 02:20:30 +0000</created>
                <updated>Sat, 28 Oct 2023 11:20:57 +0000</updated>
                            <resolved>Tue, 2 Nov 2021 13:01:53 +0000</resolved>
                                                    <fixVersion>4.4.0</fixVersion>
                                    <component>Packaging</component>
                                        <votes>0</votes>
                                    <watches>6</watches>
                                                                                                                <comments>
                            <comment id="4358390" author="JIRAUSER1264941" created="Wed, 16 Feb 2022 12:38:58 +0000"  >&lt;p&gt;Hello,&lt;/p&gt;

&lt;p&gt;since the legacy driver is not a proper component how can it be used in an osgi environment? The current setup even with the fix does not seem to work as classes are spread around two modules.&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;Regards,&lt;/p&gt;

&lt;p&gt;&#160;Martin&lt;/p&gt;</comment>
                            <comment id="4166695" author="jeff.yemin" created="Wed, 3 Nov 2021 13:51:21 +0000"  >&lt;p&gt;The 4.4.0-beta2 release is now available on Maven Central.  Please give it a try.&lt;/p&gt;</comment>
                            <comment id="4165443" author="michael.pearson@canva.com" created="Tue, 2 Nov 2021 22:55:58 +0000"  >&lt;p&gt;Yeah we would like to move onto a stable version, but we also need to move fairly soon.&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;I think we could stomach moving onto a beta version, so if you&apos;d be able to release another beta that&apos;d be great.&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;</comment>
                            <comment id="4164367" author="jeff.yemin" created="Tue, 2 Nov 2021 17:29:27 +0000"  >&lt;p&gt;Hi &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=michael.pearson%40canva.com&quot; class=&quot;user-hover&quot; rel=&quot;michael.pearson@canva.com&quot;&gt;michael.pearson@canva.com&lt;/a&gt;, it&apos;s technically feasible, but given the diversity of tool chains out in the wild and our lack of testing with those tool chains, it feels risky to merge this in a patch release. I&apos;m concerned that someone will try to upgrade to 4.3.4 and it will break their build.  On the other hand, the Automatic-Module-Name is incorrect and that seems like a bug that should be fixed ASAP.&lt;/p&gt;

&lt;p&gt;Is the issue for you that you can&apos;t wait another week or two for 4.4.0 to come out, or that you are not in a position to upgrade to a new minor release even once it does come out.  If it&apos;s the former, we could build another beta containing this fix and you could rely on that.  In terms of quality, I would consider the beta production-ready.  There are just a few more features we are trying to get in before GA.&lt;/p&gt;
</comment>
                            <comment id="4164340" author="michael.pearson@canva.com" created="Tue, 2 Nov 2021 17:22:22 +0000"  >&lt;p&gt;Would it be possible to backport this to 4.3.x?&#160;&lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/pull/816&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-java-driver/pull/816&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="4162840" author="xgen-internal-githook" created="Tue, 2 Nov 2021 13:00:51 +0000"  >&lt;p&gt;Author:&lt;/p&gt;
{&apos;name&apos;: &apos;Ross Lawley&apos;, &apos;email&apos;: &apos;ross.lawley@gmail.com&apos;, &apos;username&apos;: &apos;rozza&apos;}
&lt;p&gt;Message: Fix mongodb-driver-legacy MANIFEST.MF (#815)&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;https://jira.mongodb.org/browse/JAVA-4381&quot; title=&quot;mongodb-driver-legacy MANIFEST.MF should not include Automatic-Module-Name&quot; class=&quot;issue-link&quot; data-issue-key=&quot;JAVA-4381&quot;&gt;&lt;del&gt;JAVA-4381&lt;/del&gt;&lt;/a&gt;&lt;br/&gt;
Branch: master&lt;br/&gt;
&lt;a href=&quot;https://github.com/mongodb/mongo-java-driver/commit/9de04c01b1880bc51be740d75a03c6b8b5d36c9d&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/mongodb/mongo-java-driver/commit/9de04c01b1880bc51be740d75a03c6b8b5d36c9d&lt;/a&gt;&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                        <issuelink>
            <issuekey id="1063309">JAVA-3566</issuekey>
        </issuelink>
                            </outwardlinks>
                                                                <inwardlinks description="is related to">
                                                        </inwardlinks>
                                    </issuelinktype>
                    </issuelinks>
                <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                                                                                                                                                                                                                    <customfield id="customfield_13552" key="com.go2group.jira.plugin.crm:crm_generic_field">
                        <customfieldname>Case</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue><![CDATA[[5002K00000z9P9EQAU]]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                    <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|hr3muf:</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>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            </customfields>
    </item>
</channel>
</rss>