Skip to content

Remove support for pre-3.6 server releases #988

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

Merged
merged 4 commits into from
Sep 13, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 2 additions & 29 deletions .evergreen/.evg.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1503,22 +1503,6 @@ axes:
display_name: "3.6"
variables:
VERSION: "3.6"
- id: "3.4"
display_name: "3.4"
variables:
VERSION: "3.4"
- id: "3.2"
display_name: "3.2"
variables:
VERSION: "3.2"
- id: "3.0"
display_name: "3.0"
variables:
VERSION: "3.0"
- id: "2.6"
display_name: "2.6"
variables:
VERSION: "2.6"
- id: os
display_name: OS
values:
Expand Down Expand Up @@ -1701,18 +1685,14 @@ buildvariants:
- name: "static-analysis"

- matrix_name: "tests-zlib-compression"
matrix_spec: { compressor : "zlib", auth: "noauth", ssl: "nossl", jdk: "jdk8",
version: ["3.6", "4.0", "4.2", "4.4", "5.0", "6.0", "latest"],
topology: "standalone", os: "linux" }
matrix_spec: { compressor : "zlib", auth: "noauth", ssl: "nossl", jdk: "jdk8", version: "*", topology: "standalone", os: "linux" }
display_name: "${version} ${compressor} ${topology} ${auth} ${ssl} ${jdk} ${os} "
tags: ["tests-variant"]
tasks:
- name: "test"

- matrix_name: "tests-snappy-compression"
matrix_spec: { compressor : "snappy", auth: "noauth", ssl: "nossl", jdk: "jdk8",
version: ["3.4", "3.6", "4.0", "4.2", "4.4", "5.0", "6.0", "latest"],
topology: "standalone", os: "linux" }
matrix_spec: { compressor : "snappy", auth: "noauth", ssl: "nossl", jdk: "jdk8", version: "*", topology: "standalone", os: "linux" }
display_name: "${version} ${compressor} ${topology} ${auth} ${ssl} ${jdk} ${os} "
tags: ["tests-variant"]
tasks:
Expand All @@ -1727,13 +1707,6 @@ buildvariants:
tasks:
- name: "test"

- matrix_name: "tests-jdk8-unsecure"
matrix_spec: { auth: "noauth", ssl: "nossl", jdk: "jdk8", version: ["2.6", "3.0", "3.2", "3.4"], topology: "*", os: "linux" }
display_name: "${version} ${topology} ${auth} ${ssl} ${jdk} ${os} "
tags: ["tests-variant"]
tasks:
- name: "test"

- matrix_name: "tests-jdk8-unsecure-standalone"
matrix_spec: { auth: "noauth", ssl: "nossl", jdk: "jdk8", version: ["3.6", "4.0", "4.2", "4.4", "5.0", "6.0", "latest"],
topology: "standalone", os: "linux" }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,12 +52,12 @@ public class ServerDescription {
* The minimum supported driver server version
* @since 3.8
*/
public static final String MIN_DRIVER_SERVER_VERSION = "2.6";
public static final String MIN_DRIVER_SERVER_VERSION = "3.6";
/**
* The minimum supported driver wire version
* @since 3.8
*/
public static final int MIN_DRIVER_WIRE_VERSION = 2;
public static final int MIN_DRIVER_WIRE_VERSION = 6;
/**
* The maximum supported driver wire version
* @since 3.8
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,25 +16,18 @@

package com.mongodb.internal.connection;

import com.mongodb.MongoNamespace;
import com.mongodb.ReadPreference;
import com.mongodb.RequestContext;
import com.mongodb.ServerApi;
import com.mongodb.WriteConcernResult;
import com.mongodb.annotations.ThreadSafe;
import com.mongodb.connection.ConnectionDescription;
import com.mongodb.internal.async.SingleResultCallback;
import com.mongodb.internal.binding.ReferenceCounted;
import com.mongodb.internal.bulk.DeleteRequest;
import com.mongodb.internal.bulk.InsertRequest;
import com.mongodb.internal.bulk.UpdateRequest;
import com.mongodb.internal.session.SessionContext;
import org.bson.BsonDocument;
import org.bson.FieldNameValidator;
import org.bson.codecs.Decoder;

import java.util.List;

/**
* An asynchronous connection to a MongoDB server with non-blocking operations.
*
Expand All @@ -57,36 +50,6 @@ public interface AsyncConnection extends ReferenceCounted {
*/
ConnectionDescription getDescription();

/**
* Insert the documents using the insert wire protocol and apply the write concern asynchronously.
* @param namespace the namespace
* @param ordered whether the writes are ordered
* @param insertRequest the insert request
* @param callback the callback to be passed the write result
*/
void insertAsync(MongoNamespace namespace, boolean ordered, InsertRequest insertRequest, RequestContext requestContext,
SingleResultCallback<WriteConcernResult> callback);

/**
* Update the documents using the update wire protocol and apply the write concern asynchronously.
* @param namespace the namespace
* @param ordered whether the writes are ordered
* @param updateRequest the update request
* @param callback the callback to be passed the write result
*/
void updateAsync(MongoNamespace namespace, boolean ordered, UpdateRequest updateRequest, RequestContext requestContext,
SingleResultCallback<WriteConcernResult> callback);

/**
* Delete the documents using the delete wire protocol and apply the write concern asynchronously.
* @param namespace the namespace
* @param ordered whether the writes are ordered
* @param deleteRequest the delete request
* @param callback the callback to be passed the write result
*/
void deleteAsync(MongoNamespace namespace, boolean ordered, DeleteRequest deleteRequest, RequestContext requestContext,
SingleResultCallback<WriteConcernResult> callback);

/**
* Execute the command.
*
Expand Down Expand Up @@ -127,52 +90,5 @@ <T> void commandAsync(String database, BsonDocument command, FieldNameValidator
ServerApi serverApi, RequestContext requestContext, boolean responseExpected, SplittablePayload payload,
FieldNameValidator payloadFieldNameValidator, SingleResultCallback<T> callback);

/**
* Execute the query asynchronously.
*
* @param namespace the namespace to query
* @param queryDocument the query document
* @param fields the field to include or exclude
* @param skip the number of documents to skip
* @param limit the maximum number of documents to return in all batches
* @param batchSize the maximum number of documents to return in this batch
* @param secondaryOk whether the query can run on a secondary
* @param tailableCursor whether to return a tailable cursor
* @param awaitData whether a tailable cursor should wait before returning if no documents are available
* @param noCursorTimeout whether the cursor should not timeout
* @param partial whether partial results from sharded clusters are acceptable
* @param oplogReplay whether to replay the oplog
* @param resultDecoder the decoder for the query result documents
* @param <T> the query result document type
* @param callback the callback to be passed the write result
* @since 3.1
*/
<T> void queryAsync(MongoNamespace namespace, BsonDocument queryDocument, BsonDocument fields,
int skip, int limit, int batchSize, boolean secondaryOk, boolean tailableCursor, boolean awaitData,
boolean noCursorTimeout, boolean partial, boolean oplogReplay, Decoder<T> resultDecoder,
RequestContext requestContext, SingleResultCallback<QueryResult<T>> callback);

/**
* Get more result documents from a cursor asynchronously.
*
* @param namespace the namespace to get more documents from
* @param cursorId the cursor id
* @param numberToReturn the number of documents to return
* @param resultDecoder the decoder for the query result documents
* @param callback the callback to be passed the query result
* @param <T> the type of the query result documents
*/
<T> void getMoreAsync(MongoNamespace namespace, long cursorId, int numberToReturn, Decoder<T> resultDecoder,
RequestContext requestContext, SingleResultCallback<QueryResult<T>> callback);

/**
* Asynchronously Kills the given list of cursors.
*
* @param namespace the namespace in which the cursors live
* @param cursors the cursors
* @param callback the callback that is called once the cursors have been killed
*/
void killCursorAsync(MongoNamespace namespace, List<Long> cursors, RequestContext requestContext, SingleResultCallback<Void> callback);

void markAsPinned(Connection.PinningMode pinningMode);
}
Loading