From 9bee77c11ce2b888cf69f12622624e644459c01b Mon Sep 17 00:00:00 2001 From: Kris Brandow Date: Wed, 11 Apr 2018 14:36:51 -0400 Subject: [PATCH] Add copyright license to core library files Added script to add license to files. This script does not add the license to files that already have the license added. GODRIVER-353 Change-Id: Id2000cd36804c397864f85ca211fdb8ed600cb7c --- core/addr/addr.go | 6 +++++ core/addr/addr_test.go | 6 +++++ core/command/aggregate.go | 6 +++++ core/command/buildinfo.go | 6 +++++ core/command/command.go | 6 +++++ core/command/command_test.go | 6 +++++ core/command/count.go | 6 +++++ core/command/create_indexes.go | 6 +++++ core/command/cursor.go | 6 +++++ core/command/delete.go | 6 +++++ core/command/distinct.go | 6 +++++ core/command/doc.go | 6 +++++ core/command/drop_indexes.go | 6 +++++ core/command/errors.go | 6 +++++ core/command/find.go | 6 +++++ core/command/find_and_modify.go | 6 +++++ core/command/find_one_delete.go | 6 +++++ core/command/find_one_replace.go | 6 +++++ core/command/find_one_update.go | 6 +++++ core/command/get_more.go | 6 +++++ core/command/getlasterror.go | 6 +++++ core/command/handshake.go | 6 +++++ core/command/insert.go | 6 +++++ core/command/ismaster.go | 6 +++++ core/command/kill_cursors.go | 6 +++++ core/command/list_collections.go | 6 +++++ core/command/list_databases.go | 6 +++++ core/command/list_indexes.go | 6 +++++ core/command/namespace.go | 6 +++++ core/command/opreply.go | 6 +++++ core/command/update.go | 6 +++++ core/connection/addr.go | 6 +++++ core/connection/connection.go | 6 +++++ core/connection/connection_test.go | 6 +++++ core/connection/error.go | 6 +++++ core/connection/listener.go | 6 +++++ core/connection/options.go | 6 +++++ core/connection/pool.go | 6 +++++ core/connection/proxy.go | 6 +++++ core/connection/server.go | 6 +++++ core/connection/tlsconfig.go | 6 +++++ core/connection/tlsconfig_clone_17.go | 6 +++++ core/description/description.go | 6 +++++ core/description/feature.go | 6 +++++ core/description/feature_test.go | 6 +++++ core/description/max_staleness_spec_test.go | 6 +++++ core/description/selector_spec_test.go | 6 +++++ core/description/selector_test.go | 6 +++++ core/description/selector_write_test.go | 6 +++++ core/description/server.go | 6 +++++ core/description/server_kind.go | 6 +++++ core/description/server_selector.go | 6 +++++ core/description/shared_spec_test.go | 6 +++++ core/description/topology.go | 6 +++++ core/description/topology_kind.go | 6 +++++ core/description/version.go | 6 +++++ core/description/version_range.go | 6 +++++ core/description/version_range_test.go | 6 +++++ core/description/version_test.go | 6 +++++ core/dispatch/aggregate.go | 6 +++++ core/dispatch/command.go | 6 +++++ core/dispatch/count.go | 6 +++++ core/dispatch/create_indexes.go | 6 +++++ core/dispatch/delete.go | 6 +++++ core/dispatch/delete_indexes.go | 6 +++++ core/dispatch/dispatch.go | 6 +++++ core/dispatch/dispatch_test.go | 6 +++++ core/dispatch/distinct.go | 6 +++++ core/dispatch/find.go | 6 +++++ core/dispatch/find_one_and_delete.go | 6 +++++ core/dispatch/find_one_and_replace.go | 6 +++++ core/dispatch/find_one_and_update.go | 6 +++++ core/dispatch/insert.go | 6 +++++ core/dispatch/list_collections.go | 6 +++++ core/dispatch/list_databases.go | 6 +++++ core/dispatch/list_indexes.go | 6 +++++ core/dispatch/update.go | 6 +++++ core/integration/aggregate_test.go | 6 +++++ core/integration/command_test.go | 6 +++++ core/integration/connection_test.go | 6 +++++ core/integration/integration.go | 6 +++++ core/integration/list_collections_test.go | 6 +++++ core/integration/list_databases_test.go | 6 +++++ core/integration/list_indexes_test.go | 6 +++++ core/integration/main_test.go | 6 +++++ core/integration/pool_test.go | 6 +++++ core/integration/server_test.go | 6 +++++ core/result/result.go | 6 +++++ core/tag/tag.go | 6 +++++ core/tag/tag_test.go | 6 +++++ core/topology/connection.go | 6 +++++ core/topology/cursor.go | 6 +++++ core/topology/fsm.go | 6 +++++ .../initial_dns_seedlist_discovery_test.go | 6 +++++ core/topology/sdam_spec_test.go | 6 +++++ core/topology/server.go | 6 +++++ core/topology/server_options.go | 6 +++++ core/topology/server_rtt_test.go | 6 +++++ core/topology/topology.go | 6 +++++ core/topology/topology_options.go | 6 +++++ core/topology/topology_test.go | 6 +++++ core/version/version.go | 6 +++++ core/wiremessage/appenders.go | 6 +++++ core/wiremessage/command.go | 6 +++++ core/wiremessage/command_reply.go | 6 +++++ core/wiremessage/compressed.go | 6 +++++ core/wiremessage/delete.go | 6 +++++ core/wiremessage/get_more.go | 6 +++++ core/wiremessage/header.go | 6 +++++ core/wiremessage/insert.go | 6 +++++ core/wiremessage/kill_cursors.go | 6 +++++ core/wiremessage/msg.go | 6 +++++ core/wiremessage/query.go | 6 +++++ core/wiremessage/query_test.go | 6 +++++ core/wiremessage/readers.go | 6 +++++ core/wiremessage/reply.go | 6 +++++ core/wiremessage/reply_test.go | 6 +++++ core/wiremessage/update.go | 6 +++++ core/wiremessage/wiremessage.go | 6 +++++ etc/add-license.sh | 23 +++++++++++++++++++ 120 files changed, 737 insertions(+) create mode 100755 etc/add-license.sh diff --git a/core/addr/addr.go b/core/addr/addr.go index a5d4c05177..a589c6f7b4 100644 --- a/core/addr/addr.go +++ b/core/addr/addr.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package addr import ( diff --git a/core/addr/addr_test.go b/core/addr/addr_test.go index 487d3280d8..9d8ea71005 100644 --- a/core/addr/addr_test.go +++ b/core/addr/addr_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package addr import ( diff --git a/core/command/aggregate.go b/core/command/aggregate.go index 822f924de1..9a5501c5d2 100644 --- a/core/command/aggregate.go +++ b/core/command/aggregate.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/buildinfo.go b/core/command/buildinfo.go index 0d85557742..f8e04a6baa 100644 --- a/core/command/buildinfo.go +++ b/core/command/buildinfo.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/command.go b/core/command/command.go index 9ffd3e1242..9a57a01445 100644 --- a/core/command/command.go +++ b/core/command/command.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/command_test.go b/core/command/command_test.go index d47dcf0d9b..c55407035c 100644 --- a/core/command/command_test.go +++ b/core/command/command_test.go @@ -1 +1,7 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command diff --git a/core/command/count.go b/core/command/count.go index 6cd2156ecd..30fd75999c 100644 --- a/core/command/count.go +++ b/core/command/count.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/create_indexes.go b/core/command/create_indexes.go index 61d96d6f10..d27545b742 100644 --- a/core/command/create_indexes.go +++ b/core/command/create_indexes.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/cursor.go b/core/command/cursor.go index 0a5017ee1b..0576264aa0 100644 --- a/core/command/cursor.go +++ b/core/command/cursor.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/delete.go b/core/command/delete.go index 1b44734874..b2dc2ad7af 100644 --- a/core/command/delete.go +++ b/core/command/delete.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/distinct.go b/core/command/distinct.go index 806d634695..cc3f1db119 100644 --- a/core/command/distinct.go +++ b/core/command/distinct.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/doc.go b/core/command/doc.go index 9df17c0ce9..ea7a308d11 100644 --- a/core/command/doc.go +++ b/core/command/doc.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + // Package command contains abstractions for operations that can be performed against a MongoDB // deployment. The types in this package are meant to provide a general set of commands that a // user can run against a MongoDB database without knowing the version of the database. diff --git a/core/command/drop_indexes.go b/core/command/drop_indexes.go index e1c41379c6..0aa5289460 100644 --- a/core/command/drop_indexes.go +++ b/core/command/drop_indexes.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/errors.go b/core/command/errors.go index 8d2721f0e7..47d583a924 100644 --- a/core/command/errors.go +++ b/core/command/errors.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/find.go b/core/command/find.go index 7141afda68..e0597b878a 100644 --- a/core/command/find.go +++ b/core/command/find.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/find_and_modify.go b/core/command/find_and_modify.go index 8229eb0cee..8c10821704 100644 --- a/core/command/find_and_modify.go +++ b/core/command/find_and_modify.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/find_one_delete.go b/core/command/find_one_delete.go index 1724638368..5fdf4c896e 100644 --- a/core/command/find_one_delete.go +++ b/core/command/find_one_delete.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/find_one_replace.go b/core/command/find_one_replace.go index 7cf5cbe00e..a8d019c84c 100644 --- a/core/command/find_one_replace.go +++ b/core/command/find_one_replace.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/find_one_update.go b/core/command/find_one_update.go index 71c787550f..8222ba59e6 100644 --- a/core/command/find_one_update.go +++ b/core/command/find_one_update.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/get_more.go b/core/command/get_more.go index eb3849b6e0..e0c64d4c6f 100644 --- a/core/command/get_more.go +++ b/core/command/get_more.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/getlasterror.go b/core/command/getlasterror.go index d57df860bc..31e4beffa6 100644 --- a/core/command/getlasterror.go +++ b/core/command/getlasterror.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/handshake.go b/core/command/handshake.go index 9f01d2dd0d..c17b5f506d 100644 --- a/core/command/handshake.go +++ b/core/command/handshake.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/insert.go b/core/command/insert.go index b868a7cdf7..6c72396a0d 100644 --- a/core/command/insert.go +++ b/core/command/insert.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/ismaster.go b/core/command/ismaster.go index 8bfebf928b..c5b326966a 100644 --- a/core/command/ismaster.go +++ b/core/command/ismaster.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/kill_cursors.go b/core/command/kill_cursors.go index 38827ecf6f..c184e72390 100644 --- a/core/command/kill_cursors.go +++ b/core/command/kill_cursors.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/list_collections.go b/core/command/list_collections.go index 9a4a7f8b92..74864aee59 100644 --- a/core/command/list_collections.go +++ b/core/command/list_collections.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/list_databases.go b/core/command/list_databases.go index c51b26c8ed..429a809419 100644 --- a/core/command/list_databases.go +++ b/core/command/list_databases.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/list_indexes.go b/core/command/list_indexes.go index 2756638b0f..5ba6f07c9a 100644 --- a/core/command/list_indexes.go +++ b/core/command/list_indexes.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/namespace.go b/core/command/namespace.go index 9d2a5182c0..2a4f41308b 100644 --- a/core/command/namespace.go +++ b/core/command/namespace.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/opreply.go b/core/command/opreply.go index 2df961511a..fe6405dedf 100644 --- a/core/command/opreply.go +++ b/core/command/opreply.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/command/update.go b/core/command/update.go index 3e1f17f2d3..6ba3247135 100644 --- a/core/command/update.go +++ b/core/command/update.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package command import ( diff --git a/core/connection/addr.go b/core/connection/addr.go index 9cc9b1f20e..4d8976d96a 100644 --- a/core/connection/addr.go +++ b/core/connection/addr.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package connection const defaultPort = "27017" diff --git a/core/connection/connection.go b/core/connection/connection.go index 7be8555edf..8334e5417b 100644 --- a/core/connection/connection.go +++ b/core/connection/connection.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + // Package connection contains the types for building and pooling connections that can speak the // MongoDB Wire Protocol. Since this low level library is meant to be used in the context of either // a driver or a server there are some extra identifiers on a connection so one can keep track of diff --git a/core/connection/connection_test.go b/core/connection/connection_test.go index afc5181a93..910fe84c92 100644 --- a/core/connection/connection_test.go +++ b/core/connection/connection_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package connection import ( diff --git a/core/connection/error.go b/core/connection/error.go index a2d5071a7c..bda3a756f9 100644 --- a/core/connection/error.go +++ b/core/connection/error.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package connection import "fmt" diff --git a/core/connection/listener.go b/core/connection/listener.go index 8dc20d501a..76f4f7d941 100644 --- a/core/connection/listener.go +++ b/core/connection/listener.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package connection // Listener is a generic mongodb network protocol listener. It can return connections diff --git a/core/connection/options.go b/core/connection/options.go index bc93650631..9d149817b6 100644 --- a/core/connection/options.go +++ b/core/connection/options.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package connection import ( diff --git a/core/connection/pool.go b/core/connection/pool.go index e3abf5122f..950c125cac 100644 --- a/core/connection/pool.go +++ b/core/connection/pool.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package connection import ( diff --git a/core/connection/proxy.go b/core/connection/proxy.go index 25278c394a..a0d684675b 100644 --- a/core/connection/proxy.go +++ b/core/connection/proxy.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package connection import "github.com/mongodb/mongo-go-driver/core/wiremessage" diff --git a/core/connection/server.go b/core/connection/server.go index d2c538cc4c..033d0d7b1b 100644 --- a/core/connection/server.go +++ b/core/connection/server.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package connection import "context" diff --git a/core/connection/tlsconfig.go b/core/connection/tlsconfig.go index daf4a25d72..0536418061 100644 --- a/core/connection/tlsconfig.go +++ b/core/connection/tlsconfig.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package connection import ( diff --git a/core/connection/tlsconfig_clone_17.go b/core/connection/tlsconfig_clone_17.go index 4b52364fdc..a753dfd1e1 100644 --- a/core/connection/tlsconfig_clone_17.go +++ b/core/connection/tlsconfig_clone_17.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package connection import "crypto/tls" diff --git a/core/description/description.go b/core/description/description.go index dbad20a312..758b112f85 100644 --- a/core/description/description.go +++ b/core/description/description.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package description // Unknown is an unknown server or topology kind. diff --git a/core/description/feature.go b/core/description/feature.go index 3b3e2e4dbf..4be7fd6ac6 100644 --- a/core/description/feature.go +++ b/core/description/feature.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package description import ( diff --git a/core/description/feature_test.go b/core/description/feature_test.go index 13818a32eb..5710d2fe1e 100644 --- a/core/description/feature_test.go +++ b/core/description/feature_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package description import ( diff --git a/core/description/max_staleness_spec_test.go b/core/description/max_staleness_spec_test.go index 9bf12f6924..ee6f5b892e 100644 --- a/core/description/max_staleness_spec_test.go +++ b/core/description/max_staleness_spec_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package description import ( diff --git a/core/description/selector_spec_test.go b/core/description/selector_spec_test.go index 55a5a01354..8c2185e9f9 100644 --- a/core/description/selector_spec_test.go +++ b/core/description/selector_spec_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package description import ( diff --git a/core/description/selector_test.go b/core/description/selector_test.go index 85239ad5c2..75277d6d28 100644 --- a/core/description/selector_test.go +++ b/core/description/selector_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package description import ( diff --git a/core/description/selector_write_test.go b/core/description/selector_write_test.go index 19f8d9ad74..fa080ad883 100644 --- a/core/description/selector_write_test.go +++ b/core/description/selector_write_test.go @@ -1 +1,7 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package description diff --git a/core/description/server.go b/core/description/server.go index a535501016..0d35f56aa0 100644 --- a/core/description/server.go +++ b/core/description/server.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package description import ( diff --git a/core/description/server_kind.go b/core/description/server_kind.go index 647cac3625..657791be8b 100644 --- a/core/description/server_kind.go +++ b/core/description/server_kind.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package description // ServerKind represents the type of a server. diff --git a/core/description/server_selector.go b/core/description/server_selector.go index 087bae28f6..4eb1757f72 100644 --- a/core/description/server_selector.go +++ b/core/description/server_selector.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package description import ( diff --git a/core/description/shared_spec_test.go b/core/description/shared_spec_test.go index 11e77e05d2..aca33aeb71 100644 --- a/core/description/shared_spec_test.go +++ b/core/description/shared_spec_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package description import ( diff --git a/core/description/topology.go b/core/description/topology.go index d057a2e3e9..200761c1aa 100644 --- a/core/description/topology.go +++ b/core/description/topology.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package description import ( diff --git a/core/description/topology_kind.go b/core/description/topology_kind.go index 4e580a357d..69f817739a 100644 --- a/core/description/topology_kind.go +++ b/core/description/topology_kind.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package description // TopologyKind represents a specific topology configuration. diff --git a/core/description/version.go b/core/description/version.go index acf6be4ee5..60cda4eb0b 100644 --- a/core/description/version.go +++ b/core/description/version.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package description import "strconv" diff --git a/core/description/version_range.go b/core/description/version_range.go index 3a14a3a9a9..984dff89e9 100644 --- a/core/description/version_range.go +++ b/core/description/version_range.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package description import "fmt" diff --git a/core/description/version_range_test.go b/core/description/version_range_test.go index d897439514..8df28ea3ce 100644 --- a/core/description/version_range_test.go +++ b/core/description/version_range_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package description import "testing" diff --git a/core/description/version_test.go b/core/description/version_test.go index 7551921025..06d1d404c4 100644 --- a/core/description/version_test.go +++ b/core/description/version_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package description import ( diff --git a/core/dispatch/aggregate.go b/core/dispatch/aggregate.go index 226ba7a7d4..cbb2286ff6 100644 --- a/core/dispatch/aggregate.go +++ b/core/dispatch/aggregate.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package dispatch import ( diff --git a/core/dispatch/command.go b/core/dispatch/command.go index d60e748939..db4715b3ae 100644 --- a/core/dispatch/command.go +++ b/core/dispatch/command.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package dispatch import ( diff --git a/core/dispatch/count.go b/core/dispatch/count.go index 371a824e90..53fa8cea88 100644 --- a/core/dispatch/count.go +++ b/core/dispatch/count.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package dispatch import ( diff --git a/core/dispatch/create_indexes.go b/core/dispatch/create_indexes.go index c870098121..84842b3d9d 100644 --- a/core/dispatch/create_indexes.go +++ b/core/dispatch/create_indexes.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package dispatch import ( diff --git a/core/dispatch/delete.go b/core/dispatch/delete.go index 23f8d2c5d8..4e2fdcf728 100644 --- a/core/dispatch/delete.go +++ b/core/dispatch/delete.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package dispatch import ( diff --git a/core/dispatch/delete_indexes.go b/core/dispatch/delete_indexes.go index 8a237e8637..5b8a272add 100644 --- a/core/dispatch/delete_indexes.go +++ b/core/dispatch/delete_indexes.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package dispatch import ( diff --git a/core/dispatch/dispatch.go b/core/dispatch/dispatch.go index 3d2d923c43..d484026bdb 100644 --- a/core/dispatch/dispatch.go +++ b/core/dispatch/dispatch.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package dispatch import ( diff --git a/core/dispatch/dispatch_test.go b/core/dispatch/dispatch_test.go index 2ac8529a43..cff14e816c 100644 --- a/core/dispatch/dispatch_test.go +++ b/core/dispatch/dispatch_test.go @@ -1 +1,7 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package dispatch diff --git a/core/dispatch/distinct.go b/core/dispatch/distinct.go index 4413681fe8..c3a925fa3b 100644 --- a/core/dispatch/distinct.go +++ b/core/dispatch/distinct.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package dispatch import ( diff --git a/core/dispatch/find.go b/core/dispatch/find.go index 879190d374..3911e3d55c 100644 --- a/core/dispatch/find.go +++ b/core/dispatch/find.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package dispatch import ( diff --git a/core/dispatch/find_one_and_delete.go b/core/dispatch/find_one_and_delete.go index 886e35f121..4be4eaaf2f 100644 --- a/core/dispatch/find_one_and_delete.go +++ b/core/dispatch/find_one_and_delete.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package dispatch import ( diff --git a/core/dispatch/find_one_and_replace.go b/core/dispatch/find_one_and_replace.go index 8e0c9b9722..007e4be248 100644 --- a/core/dispatch/find_one_and_replace.go +++ b/core/dispatch/find_one_and_replace.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package dispatch import ( diff --git a/core/dispatch/find_one_and_update.go b/core/dispatch/find_one_and_update.go index 5f4b19f361..ed6a66a0a8 100644 --- a/core/dispatch/find_one_and_update.go +++ b/core/dispatch/find_one_and_update.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package dispatch import ( diff --git a/core/dispatch/insert.go b/core/dispatch/insert.go index 747cd4669b..1b3143a7a0 100644 --- a/core/dispatch/insert.go +++ b/core/dispatch/insert.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package dispatch import ( diff --git a/core/dispatch/list_collections.go b/core/dispatch/list_collections.go index 73ea693b74..5f5465bae0 100644 --- a/core/dispatch/list_collections.go +++ b/core/dispatch/list_collections.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package dispatch import ( diff --git a/core/dispatch/list_databases.go b/core/dispatch/list_databases.go index ac83fe27b4..c88ee5941e 100644 --- a/core/dispatch/list_databases.go +++ b/core/dispatch/list_databases.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package dispatch import ( diff --git a/core/dispatch/list_indexes.go b/core/dispatch/list_indexes.go index 9435a7b7c7..0e1aead4f0 100644 --- a/core/dispatch/list_indexes.go +++ b/core/dispatch/list_indexes.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package dispatch import ( diff --git a/core/dispatch/update.go b/core/dispatch/update.go index 8d1d8f15c9..52a2e013f9 100644 --- a/core/dispatch/update.go +++ b/core/dispatch/update.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package dispatch import ( diff --git a/core/integration/aggregate_test.go b/core/integration/aggregate_test.go index 5dfd0ef60e..8ce28f2c0e 100644 --- a/core/integration/aggregate_test.go +++ b/core/integration/aggregate_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package integration import ( diff --git a/core/integration/command_test.go b/core/integration/command_test.go index 04a201c7ff..ae617998fe 100644 --- a/core/integration/command_test.go +++ b/core/integration/command_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package integration import ( diff --git a/core/integration/connection_test.go b/core/integration/connection_test.go index ecd5b51d12..d1db383c83 100644 --- a/core/integration/connection_test.go +++ b/core/integration/connection_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package integration import ( diff --git a/core/integration/integration.go b/core/integration/integration.go index b22145abaf..147548de54 100644 --- a/core/integration/integration.go +++ b/core/integration/integration.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package integration import ( diff --git a/core/integration/list_collections_test.go b/core/integration/list_collections_test.go index d8e7a5002c..c7d2596682 100644 --- a/core/integration/list_collections_test.go +++ b/core/integration/list_collections_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package integration import ( diff --git a/core/integration/list_databases_test.go b/core/integration/list_databases_test.go index 1eda4e9dd9..78d86913e9 100644 --- a/core/integration/list_databases_test.go +++ b/core/integration/list_databases_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package integration import ( diff --git a/core/integration/list_indexes_test.go b/core/integration/list_indexes_test.go index 359d41a717..d68b3df8a9 100644 --- a/core/integration/list_indexes_test.go +++ b/core/integration/list_indexes_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package integration import ( diff --git a/core/integration/main_test.go b/core/integration/main_test.go index abb58ee40c..f092fdbaa5 100644 --- a/core/integration/main_test.go +++ b/core/integration/main_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package integration import ( diff --git a/core/integration/pool_test.go b/core/integration/pool_test.go index 3041320a4d..204675dd1b 100644 --- a/core/integration/pool_test.go +++ b/core/integration/pool_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package integration import ( diff --git a/core/integration/server_test.go b/core/integration/server_test.go index 591507a36a..5bffb5c944 100644 --- a/core/integration/server_test.go +++ b/core/integration/server_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package integration import ( diff --git a/core/result/result.go b/core/result/result.go index 7b3e61b3eb..9861d8b164 100644 --- a/core/result/result.go +++ b/core/result/result.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + // Package result contains the results from various operations. package result diff --git a/core/tag/tag.go b/core/tag/tag.go index cbb37fa70a..c10bd3e536 100644 --- a/core/tag/tag.go +++ b/core/tag/tag.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package tag // Tag is a name/vlaue pair. diff --git a/core/tag/tag_test.go b/core/tag/tag_test.go index 74687242ac..bc2c1944ce 100644 --- a/core/tag/tag_test.go +++ b/core/tag/tag_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package tag import ( diff --git a/core/topology/connection.go b/core/topology/connection.go index 54618e76f1..d608301f92 100644 --- a/core/topology/connection.go +++ b/core/topology/connection.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package topology import ( diff --git a/core/topology/cursor.go b/core/topology/cursor.go index 0c5c28f61d..773fe2fca7 100644 --- a/core/topology/cursor.go +++ b/core/topology/cursor.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package topology import ( diff --git a/core/topology/fsm.go b/core/topology/fsm.go index 0e11b5472e..adf15c0543 100644 --- a/core/topology/fsm.go +++ b/core/topology/fsm.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package topology import ( diff --git a/core/topology/initial_dns_seedlist_discovery_test.go b/core/topology/initial_dns_seedlist_discovery_test.go index 85faabdac3..7c541dd388 100644 --- a/core/topology/initial_dns_seedlist_discovery_test.go +++ b/core/topology/initial_dns_seedlist_discovery_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package topology import ( diff --git a/core/topology/sdam_spec_test.go b/core/topology/sdam_spec_test.go index 6ea07929e5..f416c5dd6b 100644 --- a/core/topology/sdam_spec_test.go +++ b/core/topology/sdam_spec_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package topology import ( diff --git a/core/topology/server.go b/core/topology/server.go index 7db6b4f903..4da25919f2 100644 --- a/core/topology/server.go +++ b/core/topology/server.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package topology import ( diff --git a/core/topology/server_options.go b/core/topology/server_options.go index fce78d81a3..149c64b506 100644 --- a/core/topology/server_options.go +++ b/core/topology/server_options.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package topology import ( diff --git a/core/topology/server_rtt_test.go b/core/topology/server_rtt_test.go index 9fa7225646..174899aa73 100644 --- a/core/topology/server_rtt_test.go +++ b/core/topology/server_rtt_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package topology import ( diff --git a/core/topology/topology.go b/core/topology/topology.go index f3ab4511f4..dab9ee1bf1 100644 --- a/core/topology/topology.go +++ b/core/topology/topology.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + // Package topology contains types that handles the discovery, monitoring, and selection // of servers. This package is designed to expose enough inner workings of service discovery // and monitoring to allow low level applications to have fine grained control, while hiding diff --git a/core/topology/topology_options.go b/core/topology/topology_options.go index 2361e19d3f..9a87837827 100644 --- a/core/topology/topology_options.go +++ b/core/topology/topology_options.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package topology import ( diff --git a/core/topology/topology_test.go b/core/topology/topology_test.go index 1faa711581..839ae378c3 100644 --- a/core/topology/topology_test.go +++ b/core/topology/topology_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package topology import ( diff --git a/core/version/version.go b/core/version/version.go index 8f1ea4bb5f..9f946fc366 100644 --- a/core/version/version.go +++ b/core/version/version.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package version // Driver is the current version of the driver. diff --git a/core/wiremessage/appenders.go b/core/wiremessage/appenders.go index b7f5b0b928..3d9f784bfe 100644 --- a/core/wiremessage/appenders.go +++ b/core/wiremessage/appenders.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package wiremessage func appendInt32(b []byte, i int32) []byte { diff --git a/core/wiremessage/command.go b/core/wiremessage/command.go index e10212e29f..3308974b5a 100644 --- a/core/wiremessage/command.go +++ b/core/wiremessage/command.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package wiremessage import "github.com/mongodb/mongo-go-driver/bson" diff --git a/core/wiremessage/command_reply.go b/core/wiremessage/command_reply.go index cedcb3498a..dcebc85625 100644 --- a/core/wiremessage/command_reply.go +++ b/core/wiremessage/command_reply.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package wiremessage import "github.com/mongodb/mongo-go-driver/bson" diff --git a/core/wiremessage/compressed.go b/core/wiremessage/compressed.go index c4bb9d0877..c6a10eb2fb 100644 --- a/core/wiremessage/compressed.go +++ b/core/wiremessage/compressed.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package wiremessage // Compressed represents the OP_COMPRESSED message of the MongoDB wire protocol. diff --git a/core/wiremessage/delete.go b/core/wiremessage/delete.go index e9233eb4ce..794f0c143d 100644 --- a/core/wiremessage/delete.go +++ b/core/wiremessage/delete.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package wiremessage import "github.com/mongodb/mongo-go-driver/bson" diff --git a/core/wiremessage/get_more.go b/core/wiremessage/get_more.go index 7bd6411aca..7b114e3942 100644 --- a/core/wiremessage/get_more.go +++ b/core/wiremessage/get_more.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package wiremessage // GetMore represents the OP_GET_MORE message of the MongoDB wire protocol. diff --git a/core/wiremessage/header.go b/core/wiremessage/header.go index 24895c3eb0..994ec0663c 100644 --- a/core/wiremessage/header.go +++ b/core/wiremessage/header.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package wiremessage import ( diff --git a/core/wiremessage/insert.go b/core/wiremessage/insert.go index f700ea2f2b..3be60b716c 100644 --- a/core/wiremessage/insert.go +++ b/core/wiremessage/insert.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package wiremessage import "github.com/mongodb/mongo-go-driver/bson" diff --git a/core/wiremessage/kill_cursors.go b/core/wiremessage/kill_cursors.go index 7e3fd12445..7a5f01136b 100644 --- a/core/wiremessage/kill_cursors.go +++ b/core/wiremessage/kill_cursors.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package wiremessage // KillCursors represents the OP_KILL_CURSORS message of the MongoDB wire protocol. diff --git a/core/wiremessage/msg.go b/core/wiremessage/msg.go index 7de2f7c985..0a969d2a2f 100644 --- a/core/wiremessage/msg.go +++ b/core/wiremessage/msg.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package wiremessage import "github.com/mongodb/mongo-go-driver/bson" diff --git a/core/wiremessage/query.go b/core/wiremessage/query.go index 217ee9484c..34c1dbf766 100644 --- a/core/wiremessage/query.go +++ b/core/wiremessage/query.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package wiremessage import ( diff --git a/core/wiremessage/query_test.go b/core/wiremessage/query_test.go index 496aaa1f74..5c35b36cd7 100644 --- a/core/wiremessage/query_test.go +++ b/core/wiremessage/query_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package wiremessage import ( diff --git a/core/wiremessage/readers.go b/core/wiremessage/readers.go index 1cb2482c88..b7a81b7ac6 100644 --- a/core/wiremessage/readers.go +++ b/core/wiremessage/readers.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package wiremessage import ( diff --git a/core/wiremessage/reply.go b/core/wiremessage/reply.go index ad2274e4a1..72da8d168b 100644 --- a/core/wiremessage/reply.go +++ b/core/wiremessage/reply.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package wiremessage import ( diff --git a/core/wiremessage/reply_test.go b/core/wiremessage/reply_test.go index 16aaa07341..bc5eb0b8c7 100644 --- a/core/wiremessage/reply_test.go +++ b/core/wiremessage/reply_test.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package wiremessage import ( diff --git a/core/wiremessage/update.go b/core/wiremessage/update.go index 7a4b644317..a8bd2b3963 100644 --- a/core/wiremessage/update.go +++ b/core/wiremessage/update.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + package wiremessage import "github.com/mongodb/mongo-go-driver/bson" diff --git a/core/wiremessage/wiremessage.go b/core/wiremessage/wiremessage.go index cc3bdd020a..b20020f8f1 100644 --- a/core/wiremessage/wiremessage.go +++ b/core/wiremessage/wiremessage.go @@ -1,3 +1,9 @@ +// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + // Package wiremessage contains types for speaking the MongoDB Wire Protocol. Since this low // level library is meant to be used in the context of a driver and in the context of a server // all of the flags and types of the wire protocol are implemented. For each op there are two diff --git a/etc/add-license.sh b/etc/add-license.sh new file mode 100755 index 0000000000..21fb31ff20 --- /dev/null +++ b/etc/add-license.sh @@ -0,0 +1,23 @@ +#!/bin/sh + +copyright=$'// Copyright (C) MongoDB, Inc. 2017-present. +// +// Licensed under the Apache License, Version 2.0 (the "License"); you may +// not use this file except in compliance with the License. You may obtain +// a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 +' + +add_copyright() { + local line=$(head -n 1 $1) + if [ "$line" == "// Copyright (C) MongoDB, Inc. 2017-present." ]; then + echo "$1 already has copyright notice" >&2 + return + fi + + echo "$copyright" | cat - $1 > temp && mv temp $1 +} + +for file in "$@" +do + add_copyright "$file" +done