From d718458920160bbe2e121baf286734a8a9c5f9c0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Erlan=C2=A0Lucio=C2=A0?= <67064886+lucioerlan@users.noreply.github.com> Date: Sat, 11 Feb 2023 04:37:13 -0300 Subject: [PATCH] Update README.md greater clarity in documentation --- README.md | 83 ++++++++++++++++++++++++++++--------------------------- 1 file changed, 43 insertions(+), 40 deletions(-) diff --git a/README.md b/README.md index d842436..63279c1 100644 --- a/README.md +++ b/README.md @@ -1,73 +1,76 @@ # Google Cloud Search Database Connector -The Google Cloud Search Database Connector enables indexing content from any SQL database with a -JDBC 4.0 (or later compliant driver) with support for ACLs and change & delete detection. +The Google Cloud Search Database Connector allows for easy indexing of content from any SQL database with a JDBC 4.0 compliant driver. This includes support for access control lists (ACLs) and change & delete detection. -Before running the database connector, you should review the [access control list options](https://developers.google.com/cloud-search/docs/guides/database-connector#aclOptions). +Before using the database connector, it's recommended to review the [access control list options](https://developers.google.com/cloud-search/docs/guides/database-connector#aclOptions). to ensure your data is being indexed properly. +## Building the Connector - -## Build instructions +To build the Google Cloud Search Database Connector, follow these steps: 1. Build the connector a. Clone the connector repository from GitHub: - ``` - git clone https://github.com/google-cloudsearch/database-connector.git - cd database-connector - ``` + + ``` + git clone https://github.com/google-cloudsearch/database-connector.git + cd database-connector + ``` b. Checkout the desired version of the connector and build the ZIP file: - ``` - git checkout tags/v1-0.0.5 - mvn package - ``` - (To skip the tests when building the connector, use `mvn package -DskipTests`) + ``` + git checkout tags/v1-0.0.5 + mvn package + ``` -2. Install the connector + (If you want to skip the tests during the build process, use mvn package -DskipTests) The `mvn package` command creates a ZIP file containing the connector and its dependencies with a name like `google-cloudsearch-database-connector-v1-0.0.5.zip`. - a. Copy this ZIP file to the location where you want to install the connector. +2. Installing the Connector - b. Unzip the connector ZIP file. A directory with a name like - `google-cloudsearch-database-connector-v1-0.0.5` will be created. + To install the Google Cloud Search Database Connector, follow these steps: - c. Change into this directory. You should see the connector jar file, - `google-cloudsearch-database-connector-v1-0.0.5.jar`, as well as a `lib` - directory containing the connector's dependencies. + a. Copy the ZIP file to the desired installation location. + b. Unzip the connector ZIP file. This creates a directory with a name like + `google-cloudsearch-database-connector-v1-0.0.5` will be created. -3. Configure the connector + c. Change into the newly created directory. You should see the connector JAR file, + `google-cloudsearch-database-connector-v1-0.0.5.jar`, as well as a `lib` + directory containing the connector's dependencies. - a. Create a file containing the connector configuration parameters. Refer to the - [configuration documentation](https://developers.google.com/cloud-search/docs/guides/database-connector#configureDB) - for specifics and for parameter details. +3. Configuring the Connector +To configure the Google Cloud Search Database Connector, follow these steps: -4. Run the connector +a. Create a file with the connector configuration parameters. Refer to the +[configuration documentation](https://developers.google.com/cloud-search/docs/guides/database-connector#configureDB) +for specifics and for parameter details. - The connector should be run from the unzipped installation directory, **not** the source - code's `target` directory. +4. Running the Connector - ``` - java \ - -cp "google-cloudsearch-database-connector-v1-0.0.5.jar:mysql-connector-java-5.1.41-bin.jar" \ - com.google.enterprise.cloudsearch.database.DatabaseFullTraversalConnector \ - -Dconfig=mysql.config - ``` +To run the Google Cloud Search Database Connector, use the following command: - Where `mysql-connector-java-5.1.41-bin.jar` is the JDBC 4.0 driver for the database being used, - and `mysql.config` is the configuration file containing the parameters for the connector - execution. +The connector should be run from the unzipped installation directory, **not** the source +code's `target` directory. - **Note:** If the configuration file is not specified, a default file name of - `connector-config.properties` will be assumed. +``` +java \ + -cp "google-cloudsearch-database-connector-v1-0.0.5.jar:mysql-connector-java-5.1.41-bin.jar" \ + com.google.enterprise.cloudsearch.database.DatabaseFullTraversalConnector \ + -Dconfig=mysql.config +``` +Where `mysql-connector-java-5.1.41-bin.jar` is the JDBC 4.0 driver for the database being used, +and `mysql.config` is the configuration file containing the parameters for the connector +execution. + +**Note:** If the configuration file is not specified, a default file name of +`connector-config.properties` will be assumed. For further information on configuration and deployment of this connector, see [Deploy a Database Connector](https://developers.google.com/cloud-search/docs/guides/database-connector). -