<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Java - TheCodeBuzz</title>
	<atom:link href="https://thecodebuzz.com/category/java/feed/" rel="self" type="application/rss+xml" />
	<link>https://thecodebuzz.com</link>
	<description>Best Practices for Software Development</description>
	<lastBuildDate>Sun, 18 Feb 2024 02:55:10 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	

<image>
	<url>https://thecodebuzz.com/wp-content/uploads/2022/11/cropped-android-chrome-512x512-1-1-51x51.jpg</url>
	<title>Java - TheCodeBuzz</title>
	<link>https://thecodebuzz.com</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Java- Apache Spark Connect to MongoDB</title>
		<link>https://thecodebuzz.com/java-apache-spark-connect-mongodb-read-write/</link>
					<comments>https://thecodebuzz.com/java-apache-spark-connect-mongodb-read-write/#respond</comments>
		
		<dc:creator><![CDATA[admin]]></dc:creator>
		<pubDate>Sat, 20 Jan 2024 23:47:53 +0000</pubDate>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Java- Apache Spark Connect to MongoDB]]></category>
		<category><![CDATA[Java- Apache Spark mongo example]]></category>
		<guid isPermaLink="false">https://www.thecodebuzz.com/?p=29823</guid>

					<description><![CDATA[<p>Java- Apache Spark Connect to MongoDB Today in this article, we will see how to perform Java- Apache Spark Connect to MongoDB with examples. We will make use of MongoDB Spark Connector which helps connect to MongoDB and allows us to read and write data between Java and MongoDB. Here&#8217;s a basic example demonstrating how [&#8230;]</p>
<p>The post <a href="https://thecodebuzz.com/java-apache-spark-connect-mongodb-read-write/">Java- Apache Spark Connect to MongoDB</a> first appeared on <a href="https://thecodebuzz.com">TheCodeBuzz</a>.</p>]]></description>
										<content:encoded><![CDATA[<h1 class="wp-block-heading"><strong>Java- Apache Spark Connect to MongoDB</strong></h1>



<figure class="wp-block-image size-large is-resized"><img fetchpriority="high" decoding="async" width="1024" height="361" src="https://www.thecodebuzz.com/wp-content/uploads/2024/01/Java-Spark-MongoDB-read-write-example-1024x361.jpg" alt="Java- Apache Spark Connect to MongoDB" class="wp-image-29834" style="width:776px;height:auto" srcset="https://thecodebuzz.com/wp-content/uploads/2024/01/Java-Spark-MongoDB-read-write-example-1024x361.jpg 1024w, https://thecodebuzz.com/wp-content/uploads/2024/01/Java-Spark-MongoDB-read-write-example-300x106.jpg 300w, https://thecodebuzz.com/wp-content/uploads/2024/01/Java-Spark-MongoDB-read-write-example-768x271.jpg 768w, https://thecodebuzz.com/wp-content/uploads/2024/01/Java-Spark-MongoDB-read-write-example-785x277.jpg 785w, https://thecodebuzz.com/wp-content/uploads/2024/01/Java-Spark-MongoDB-read-write-example.jpg 1174w" sizes="(max-width: 1024px) 100vw, 1024px" /></figure>



<p>Today in this article, we will see how to perform Java- Apache Spark Connect to MongoDB with examples.</p>



<p></p>



<p>We will make use of MongoDB Spark Connector which helps connect to MongoDB and allows us to read and write data between Java and MongoDB.</p>



<p></p>



<p>Here&#8217;s a basic example demonstrating how to read data from MongoDB, perform a transformation, and then write the results back to MongoDB.</p>



<p></p>



<p>We have below MongoDB collection,</p>



<figure class="wp-block-image size-full"><img decoding="async" width="454" height="630" src="https://www.thecodebuzz.com/wp-content/uploads/2024/01/JAVA-Spark-to-connect-MongoDB-read-write.jpg" alt="" class="wp-image-29831" srcset="https://thecodebuzz.com/wp-content/uploads/2024/01/JAVA-Spark-to-connect-MongoDB-read-write.jpg 454w, https://thecodebuzz.com/wp-content/uploads/2024/01/JAVA-Spark-to-connect-MongoDB-read-write-216x300.jpg 216w, https://thecodebuzz.com/wp-content/uploads/2024/01/JAVA-Spark-to-connect-MongoDB-read-write-375x520.jpg 375w" sizes="(max-width: 454px) 100vw, 454px" /></figure>



<p></p>



<h2 class="wp-block-heading">Install MongoDB Connector for Apache Spark in JAVA</h2>



<p></p>



<p>You can download the connector from the official MongoDB website or use Maven/Gradle to include it as a dependency in your project.</p>



<p></p>



<p>Please install MongoDB Spark Connector using the below command.</p>



<p></p>



<p><strong>Gradle Command</strong></p>



<p></p>



<pre class="wp-block-preformatted">implementation 'org.mongodb.spark:mongo-spark-connector_2.12:3.0.1' // Replace with the latest version
</pre>



<p></p>



<p><strong>Maven Dependency:</strong></p>



<p></p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: java; title: ; notranslate">
&lt;dependency&gt;
    &lt;groupId&gt;org.mongodb.spark&lt;/groupId&gt;
    &lt;artifactId&gt;mongo-spark-connector_2.12&lt;/artifactId&gt;
    &lt;version&gt;3.0.1&lt;/version&gt;
&lt;/dependency&gt;

</pre></div>


<p></p>



<p>Please replace the above using the latest version as supported </p>



<p></p>



<p>For more details please visit the official website: <a href="https://www.mongodb.com/products/spark-connector" target="_blank" rel="noopener" title="">https://www.mongodb.com/products/spark-connector</a></p>



<p></p>



<h2 class="wp-block-heading">Create a SparkSession Object</h2>



<p></p>



<p>Create a SparkSession Object to use for read and write operations,</p>



<p></p>



<p></p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: java; title: ; notranslate">
import org.apache.spark.SparkConf;
import org.apache.spark.api.java.JavaRDD;
import org.apache.spark.api.java.JavaSparkContext;
import org.apache.spark.sql.*;
import org.bson.Document;
import java.util.HashMap;
import java.util.Map;


public class SparkMongoDBTheCodeBuzz {
    public static void main(String&#x5B;] args) {
        // Configure Spark
        SparkConf sparkConf = new SparkConf()
                .setAppName(&quot;MongoDB Spark Connector Example&quot;)
                .setMaster(&quot;local&#x5B;*]&quot;)
                .set(&quot;spark.mongodb.input.uri&quot;, &quot;mongodb://host/TheCodeBuzz.Orders&quot;&quot;)
                .set(&quot;spark.mongodb.output.uri&quot;, &quot;mongodb://host/TheCodeBuzz.Orders&quot;&quot;);

       // Create a SparkContext
        JavaSparkContext jsc = new JavaSparkContext(sparkConf);

        // Create a SparkSession
        SparkSession spark = SparkSession.builder().config(sparkConf).getOrCreate();





</pre></div>


<p></p>



<p>We create a Spark session with the MongoDB connector configurations. </p>



<p></p>



<p>We will use the above <code>SparkSession</code> object to read, and write data to MongoDB, etc.</p>



<p></p>



<h2 class="wp-block-heading">Read Data from MongoDB using Spark</h2>



<p></p>



<p>You must specify the following configuration settings to read from MongoDB:</p>



<p></p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: java; title: ; notranslate">
import org.apache.spark.SparkConf;
import org.apache.spark.api.java.JavaRDD;
import org.apache.spark.api.java.JavaSparkContext;
import org.apache.spark.sql.*;
import org.bson.Document;
import java.util.HashMap;
import java.util.Map;


public class SparkMongoDBTheCodeBuzz {
    public static void main(String&#x5B;] args) {
        // Configure Spark
        SparkConf sparkConf = new SparkConf()
                .setAppName(&quot;MongoDB Spark Connector Example&quot;)
                .setMaster(&quot;local&#x5B;*]&quot;)
                .set(&quot;spark.mongodb.input.uri&quot;, &quot;mongodb://host/TheCodeBuzz.Orders&quot;&quot;)
                .set(&quot;spark.mongodb.output.uri&quot;, &quot;mongodb://host/TheCodeBuzz.Orders&quot;&quot;);

      // Create a SparkContext
        JavaSparkContext jsc = new JavaSparkContext(sparkConf);

        // Create a SparkSession
        SparkSession spark = SparkSession.builder().config(sparkConf).getOrCreate();

        // Read data from MongoDB
        JavaRDD&lt;Document&gt; mongoRDD = MongoSpark.load(jsc);

        // Perform transformations or analyses as needed
        // For example, you can convert the RDD to a DataFrame
        Dataset&lt;Row&gt; mongoDF = spark.createDataFrame(mongoRDD, Document.class);

        // Show the data
        mongoDF.show();
}
</pre></div>


<p></p>



<h2 class="wp-block-heading">Write data to MongoDB using Java Spark</h2>



<p></p>



<p>To write data from MongoDB, call the&nbsp;write function on your&nbsp;SparkSession&nbsp;object. </p>



<p></p>



<p>You must specify the following configuration settings to read from MongoDB,</p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: csharp; title: ; notranslate">
data = &#x5B;
  {

    &quot;Order&quot;: &quot;journal2&quot;,
    &quot;qty&quot;: 25,
    &quot;books&quot;: &#x5B;
      &quot;white&quot;
    ],
    &quot;domain&quot;: &#x5B;
      14
    ],
    &quot;Link&quot;: &quot;https://www.thecodebuzz.com/order/23456&quot;
  },
  {

    &quot;Order&quot;: &quot;journal1&quot;,
    &quot;qty&quot;: 25,
    &quot;books&quot;: &#x5B;
      &quot;black&quot;
    ],
    &quot;domain&quot;: &#x5B;
      15
    ],
    &quot;Link&quot;: &quot;https://www.thecodebuzz.com/order/2324&quot;
  }
]
</pre></div>


<p></p>



<p></p>



<p>Let&#8217;s save this JSON file in any temporary location and access it  </p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: java; title: ; notranslate">


       // Assume df is a DataFrame with the data you want to write to MongoDB
        Dataset&lt;Row&gt; df = spark.read().json(&quot;path/to/json/file&quot;);

        // Write data to MongoDB
        MongoSpark.write(df).option(&quot;TheCodeBuzz&quot;, &quot;Orders&quot;).mode(&quot;append&quot;).save();

        // Stop the Spark session
        spark.stop();


</pre></div>


<p></p>



<p>That&#8217;s all! Happy coding!</p>



<p></p>



<p>Does this help you fix your issue? </p>



<p></p>



<p>Do you have any better solutions or suggestions? Please sound off your comments below.</p>



<p></p>



<hr>



<p class=""></p>



<p class="has-background" style="background-color:#b6d9ac;font-size:18px"><br>Please <strong><em>bookmark </em></strong>this page and <em><strong>share </strong></em>it with your friends.                                                    Please <a href="https://www.thecodebuzz.com/subscription/" target="_blank" rel="noreferrer noopener"><em><mark style="background-color:rgba(0, 0, 0, 0)" class="has-inline-color has-luminous-vivid-orange-color"><strong>Subscribe</strong> </mark></em></a>to the blog to receive notifications on freshly published (2025) best practices and guidelines for software design and development.</p>




<br>



<hr>



<p class=""></p>



<p></p>



<p></p><p>The post <a href="https://thecodebuzz.com/java-apache-spark-connect-mongodb-read-write/">Java- Apache Spark Connect to MongoDB</a> first appeared on <a href="https://thecodebuzz.com">TheCodeBuzz</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://thecodebuzz.com/java-apache-spark-connect-mongodb-read-write/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Java &#8211; MongoDB Date Time query with examples</title>
		<link>https://thecodebuzz.com/java-mongodb-date-time-query-mongodb-java-client-libraries-examples/</link>
					<comments>https://thecodebuzz.com/java-mongodb-date-time-query-mongodb-java-client-libraries-examples/#respond</comments>
		
		<dc:creator><![CDATA[admin]]></dc:creator>
		<pubDate>Sat, 09 Dec 2023 17:55:45 +0000</pubDate>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Java - MongoDB Date Time query with examples]]></category>
		<guid isPermaLink="false">https://www.thecodebuzz.com/?p=29279</guid>

					<description><![CDATA[<p>Java- MongoDB Date Time query with examples Today, in this article will cover Java &#8211; MongoDB Date Time query with examples. Using Java code, we will see how to get records using a date filter like &#8216;greater than&#8217; OR &#8216;less than&#8217; or get the records between 2 dates. To achieve the same, We will use [&#8230;]</p>
<p>The post <a href="https://thecodebuzz.com/java-mongodb-date-time-query-mongodb-java-client-libraries-examples/">Java – MongoDB Date Time query with examples</a> first appeared on <a href="https://thecodebuzz.com">TheCodeBuzz</a>.</p>]]></description>
										<content:encoded><![CDATA[<h1 class="wp-block-heading">Java- MongoDB Date Time query with examples</h1>



<figure class="wp-block-image size-large"><img decoding="async" width="1024" height="361" src="https://www.thecodebuzz.com/wp-content/uploads/2023/12/Java-MongoDB-Date-Time-query-with-examples-1024x361.jpg" alt="" class="wp-image-29282" srcset="https://thecodebuzz.com/wp-content/uploads/2023/12/Java-MongoDB-Date-Time-query-with-examples-1024x361.jpg 1024w, https://thecodebuzz.com/wp-content/uploads/2023/12/Java-MongoDB-Date-Time-query-with-examples-300x106.jpg 300w, https://thecodebuzz.com/wp-content/uploads/2023/12/Java-MongoDB-Date-Time-query-with-examples-768x271.jpg 768w, https://thecodebuzz.com/wp-content/uploads/2023/12/Java-MongoDB-Date-Time-query-with-examples-785x277.jpg 785w, https://thecodebuzz.com/wp-content/uploads/2023/12/Java-MongoDB-Date-Time-query-with-examples.jpg 1174w" sizes="(max-width: 1024px) 100vw, 1024px" /></figure>



<p>Today, in this article will cover Java &#8211; MongoDB Date Time query with examples. </p>



<p></p>



<p>Using Java code, we will see how to get records using a date filter like &#8216;greater than&#8217; OR &#8216;less than&#8217; or get the records between 2 dates.</p>



<p></p>



<p>To achieve the same, We will use the <em><em>MongoDB Driver</em></em> <em>package</em> supported in JAVA. We will install the Mongo driver and query MongoDB using supported driver classes.</p>



<p></p>



<p> There are 2 types of Java MongoDB driver packages available.  </p>



<p></p>



<p>You can use one of the following drivers for your application to work with MongoDB based on what suits your requirements.</p>



<p></p>



<ul class="wp-block-list">
<li><a href="https://www.mongodb.com/docs/drivers/java/sync/current" target="_blank" rel="noopener" title="">Java Driver</a> &#8211; Used for synchronous Java applications.</li>



<li><a href="https://www.mongodb.com/docs/drivers/reactive-streams/" target="_blank" rel="noopener" title="">Reactive Streams Driver</a>  &#8211; used for asynchronous stream processing to use the Reactive Streams API.</li>
</ul>



<p></p>



<p>We will cover the below aspects in today&#8217;s article,</p>



<p></p>



<div class="wp-block-aioseo-table-of-contents"><ul><li><a href="#aioseo-getting-started">Getting started</a></li><li><a href="#aioseo-install-pymongo-pcakge">Use MongoDB Java Client Libraries</a></li><li><a href="#aioseo-add-pymongo-import-statements">Add MongoDB Import statements</a></li><li><a href="#aioseo-mongo-date-query-using-cli-or-compass-ui">Connecting to an Atlas Cluster in Java Applications</a></li><li><a href="#aioseo-date-greater-than-query">Java query &#8211; Mongo Date greater than query (&#8216;gt&#8217;)</a><ul><li><a href="#aioseo-define-the-date">Define the date</a></li><li><a href="#aioseo-define-the-filter">Define the filter</a></li><li><a href="#aioseo-get-the-results">Get the results</a></li><li><a href="#aioseo-below-is-the-complete-code">Complete sample code,</a></li><li><a href="#aioseo-mongo-atlas-ui">Mongo Atlas UI</a></li></ul></li><li><a href="#aioseo-node-js-mongo-date-less-than-query-lt">Java example &#8211; Mongo Date less than query (&#8216;lt&#8217;)</a></li><li><a href="#aioseo-node-js-mongo-date-less-than-and-greater-than-date-query">Java example &#8211; Mongo Date less than and greater than date query</a></li></ul></div>



<p></p>



<h2 class="wp-block-heading" id="aioseo-getting-started">Getting started</h2>



<p></p>



<p>Here below is a sample schema or document we shall use for the date range query,</p>



<p></p>



<figure class="wp-block-image size-large is-resized"><img loading="lazy" decoding="async" width="700" height="878" src="https://www.thecodebuzz.com/wp-content/uploads/2020/09/Add-the-new-field-to-document-in-a-MongoDB-Collection-using-_Id.jpg" alt="Node js mongodb date query" class="wp-image-12234" srcset="https://thecodebuzz.com/wp-content/uploads/2020/09/Add-the-new-field-to-document-in-a-MongoDB-Collection-using-_Id.jpg 700w, https://thecodebuzz.com/wp-content/uploads/2020/09/Add-the-new-field-to-document-in-a-MongoDB-Collection-using-_Id-239x300.jpg 239w, https://thecodebuzz.com/wp-content/uploads/2020/09/Add-the-new-field-to-document-in-a-MongoDB-Collection-using-_Id-415x520.jpg 415w" sizes="auto, (max-width: 700px) 100vw, 700px" /></figure>



<p></p>



<p></p>



<h2 class="wp-block-heading" id="aioseo-install-pymongo-pcakge">Use MongoDB Java Client Libraries </h2>



<p></p>



<p>Please install the Java MongoDB driver package to get support for the MongoClient connection class and properties. </p>



<p></p>



<p>For more details visit- <a href="https://mongodb.github.io/node-mongodb-native" target="_blank" rel="noopener" title=""> <em>https://mongodb.github.io/mongo-java-driver</em></a></p>



<p></p>



<p></p>



<h2 class="wp-block-heading" id="aioseo-add-pymongo-import-statements">Add MongoDB Import statements </h2>



<p></p>



<p>Please add below IMPORT namespaces </p>



<p></p>



<pre class="wp-block-preformatted">
import com.mongodb.MongoClient;
import com.mongodb.MongoClientURI;
import com.mongodb.client.MongoCollection;
import com.mongodb.client.MongoDatabase;
import org.bson.conversions.Bson;
</pre>



<p></p>



<p>Additionally, you can add below import statements for filter and timestamp query support </p>



<p></p>



<pre class="wp-block-code"><code>import java.text.SimpleDateFormat;
import java.util.Date;
import org.bson.Document;
import com.mongodb.client.FindIterable;
import static com.mongodb.client.model.Filters.lt;</code></pre>



<p></p>



<h2 class="wp-block-heading" id="aioseo-mongo-date-query-using-cli-or-compass-ui">Connecting to an Atlas Cluster in Java Applications</h2>



<p></p>



<p>Using the MongoClient class to define the MongoDB Connection,</p>



<p></p>



<pre class="wp-block-code"><code>
MongoClient mongoClient = new MongoClient(
    new MongoClientURI(
        "mongodb://localhost:27017/"
    )
);
</code></pre>



<pre class="wp-block-code"><code>MongoDatabase database = mongoClient.getDatabase("Books");
MongoCollection&lt;Document> collection = database.getCollection("Book");
FindIterable&lt;Document> result = collection.find(filter);</code></pre>



<p></p>



<p>Above you need to replace the &#8220;Books&#8221; database with your DB name.</p>



<p>Also please update the &#8220;Book&#8221; collection name with your collection name.</p>



<p></p>



<p>Here we will be using the below query to get the documents between <a href="https://www.thecodebuzz.com/mongodb-to-find-objects-between-two-dates/">two dates</a> in MongoDB Collection.</p>



<p></p>



<h2 class="wp-block-heading" id="aioseo-date-greater-than-query">Java query &#8211; Mongo Date greater than query (&#8216;gt&#8217;)</h2>



<p></p>



<h4 class="wp-block-heading" id="aioseo-define-the-date">Define the date </h4>



<p></p>



<pre class="wp-block-code"><code>SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd");
Date dateAdded= dateFormat.parse("2023-01-01");
</code></pre>



<p></p>



<h4 class="wp-block-heading" id="aioseo-define-the-filter">Define the filter </h4>



<p></p>



<p>Let&#8217;s define the date filter as below,</p>



<p></p>



<pre class="wp-block-code"><code>Document query = new Document("DateAdded", new Document("$gt", dateAdded));


</code></pre>



<h4 class="wp-block-heading" id="aioseo-get-the-results">Get the results </h4>



<p></p>



<pre class="wp-block-code"><code>
            MongoCursor&lt;Document> cursor = collection.find(query).iterator();

            // Iterating over the results
            while (cursor.hasNext()) {
                Document document = cursor.next();
                System.out.println(document.toJson());
            }</code></pre>



<p></p>



<p></p>



<h4 class="wp-block-heading" id="aioseo-below-is-the-complete-code">Complete sample code,</h4>



<p></p>



<pre class="wp-block-code"><code>
import com.mongodb.MongoClient;
import com.mongodb.MongoClientURI;
import com.mongodb.client.MongoCollection;
import com.mongodb.client.MongoDatabase;
import org.bson.conversions.Bson;
import java.text.SimpleDateFormat;
import java.util.Date;
import org.bson.Document;


MongoClient mongoClient = new MongoClient(
    new MongoClientURI(
        "mongodb://localhost:27017/"
    )
);





SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd");
Date dateAdded= dateFormat.parse("2023-01-01");


Document query = new Document("DateAdded", new Document("$gt", dateAdded));



MongoDatabase database = mongoClient.getDatabase("Books");
MongoCollection&lt;Document> collection = database.getCollection("Book");

MongoCursor&lt;Document> cursor = collection.find(query).iterator();

            // Iterating over the results
            while (cursor.hasNext()) {
                Document document = cursor.next();
                System.out.println(document.toJson());
            }


</code></pre>



<h4 class="wp-block-heading" id="aioseo-mongo-atlas-ui"><strong>Mongo Atlas UI</strong></h4>



<p></p>



<p>The above query produces the same result as indicated below using ATLAS UI,</p>



<p></p>



<figure class="wp-block-image size-large is-resized"><img loading="lazy" decoding="async" width="1024" height="433" src="https://www.thecodebuzz.com/wp-content/uploads/2020/12/MongoDB-Date-Range-query-examples-CLI-or-compass-1024x433.jpg" alt="node js datetime mongodb format, node.js isodate, node  insert datetime now, node mongodb date time query, " class="wp-image-13546" srcset="https://thecodebuzz.com/wp-content/uploads/2020/12/MongoDB-Date-Range-query-examples-CLI-or-compass-1024x433.jpg 1024w, https://thecodebuzz.com/wp-content/uploads/2020/12/MongoDB-Date-Range-query-examples-CLI-or-compass-300x127.jpg 300w, https://thecodebuzz.com/wp-content/uploads/2020/12/MongoDB-Date-Range-query-examples-CLI-or-compass-768x325.jpg 768w, https://thecodebuzz.com/wp-content/uploads/2020/12/MongoDB-Date-Range-query-examples-CLI-or-compass-1536x650.jpg 1536w, https://thecodebuzz.com/wp-content/uploads/2020/12/MongoDB-Date-Range-query-examples-CLI-or-compass-785x332.jpg 785w, https://thecodebuzz.com/wp-content/uploads/2020/12/MongoDB-Date-Range-query-examples-CLI-or-compass.jpg 1921w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<p></p>



<p></p>



<h2 class="wp-block-heading" id="aioseo-node-js-mongo-date-less-than-query-lt">Java example &#8211; Mongo Date less than query (&#8216;lt&#8217;)</h2>



<p></p>



<p>Let&#8217;s define JAVA  Mongo Datetime less than query (&#8216;lt&#8217;)</p>



<p></p>



<pre class="wp-block-code"><code># define date for the query 


SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd");
Date dateAdded= dateFormat.parse("2023-01-01");


Document query = new Document("DateAdded", new Document("$lt", dateAdded));

MongoDatabase database = mongoClient.getDatabase("Books");
MongoCollection&lt;Document> collection = database.getCollection("Book");

MongoCursor&lt;Document> cursor = collection.find(query).iterator();</code></pre>



<p></p>



<p></p>



<p></p>



<h2 class="wp-block-heading" id="aioseo-node-js-mongo-date-less-than-and-greater-than-date-query">Java example &#8211; Mongo Date less than and greater than date query </h2>



<p></p>



<pre class="wp-block-code"><code># define date for the query 

SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd");

Date startDateAdded= dateFormat.parse("2023-01-01");
Date endDateAdded= dateFormat.parse("2024-01-01");

# define filter for the query 


Document query = new Document("DateAdded", 
                new Document("$gt", startDateAdded)
                        .append("$lt", endDateAdded));

MongoDatabase database = mongoClient.getDatabase("Books");
MongoCollection&lt;Document> collection = database.getCollection("Book");

MongoCursor&lt;Document> cursor = collection.find(query).iterator();

</code></pre>



<p>For more details on <a href="https://www.thecodebuzz.com/node-js-mongodb-date-time-query-node-mongodb-native/">queries where no date</a> field in the schema is available, please visit this article,</p>



<p></p>



<ul class="wp-block-list">
<li><a href="https://www.thecodebuzz.com/query-mongodb-objectid-by-date-mongoshell-compass/" target="_blank" rel="noopener" title="Query MongoDB using ObjectId by Date -MongoShell">Query MongoDB using ObjectId by Date -MongoShell</a></li>
</ul>



<p></p>



<p></p>



<p style="font-size:18px">Do you have any <strong>comments or ideas or any better </strong>suggestions to share?</p>



<p class="has-small-font-size"></p>



<p style="font-size:18px">Please sound off your comments below.</p>



<p class="has-medium-font-size"></p>



<p class="has-medium-font-size"><strong>Happy Coding </strong>!!</p>



<p></p>



<p></p>



<hr>



<p class=""></p>



<p class="has-background" style="background-color:#b6d9ac;font-size:18px"><br>Please <strong><em>bookmark </em></strong>this page and <em><strong>share </strong></em>it with your friends.                                                    Please <a href="https://www.thecodebuzz.com/subscription/" target="_blank" rel="noreferrer noopener"><em><mark style="background-color:rgba(0, 0, 0, 0)" class="has-inline-color has-luminous-vivid-orange-color"><strong>Subscribe</strong> </mark></em></a>to the blog to receive notifications on freshly published (2025) best practices and guidelines for software design and development.</p>




<br>



<hr>



<p class=""></p>



<p></p><p>The post <a href="https://thecodebuzz.com/java-mongodb-date-time-query-mongodb-java-client-libraries-examples/">Java – MongoDB Date Time query with examples</a> first appeared on <a href="https://thecodebuzz.com">TheCodeBuzz</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://thecodebuzz.com/java-mongodb-date-time-query-mongodb-java-client-libraries-examples/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>The Java Bookshelf: 6 Must-Read Guides</title>
		<link>https://thecodebuzz.com/the-java-bookshelf-6-must-read-guides/</link>
					<comments>https://thecodebuzz.com/the-java-bookshelf-6-must-read-guides/#respond</comments>
		
		<dc:creator><![CDATA[admin]]></dc:creator>
		<pubDate>Fri, 08 Jul 2022 23:24:28 +0000</pubDate>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[best java books for beginners]]></category>
		<category><![CDATA[core java best books]]></category>
		<category><![CDATA[effective java]]></category>
		<category><![CDATA[head first java]]></category>
		<category><![CDATA[java 17 books]]></category>
		<category><![CDATA[java programming book pdf]]></category>
		<category><![CDATA[java programming books for beginners pdf]]></category>
		<category><![CDATA[textbook.java code]]></category>
		<category><![CDATA[The Java Bookshelf: 6 Must-Read Guides]]></category>
		<guid isPermaLink="false">https://www.thecodebuzz.com/?p=22835</guid>

					<description><![CDATA[<p>The Java Bookshelf: 6 Must-Read Guides Whether you’re a novice in Java or have years of experience, you can always enhance your knowledge and skills with books. Sure, practice means the most for a coder, but theory can give you direction and help look at problems in a new light, describe fundamental concepts that you [&#8230;]</p>
<p>The post <a href="https://thecodebuzz.com/the-java-bookshelf-6-must-read-guides/">The Java Bookshelf: 6 Must-Read Guides</a> first appeared on <a href="https://thecodebuzz.com">TheCodeBuzz</a>.</p>]]></description>
										<content:encoded><![CDATA[<h1 class="wp-block-heading"><strong>The Java Bookshelf: 6 Must-Read Guides</strong></h1>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="940" height="446" src="https://www.thecodebuzz.com/wp-content/uploads/2022/07/image.jpg" alt="The Java Bookshelf: 6 Must-Read Guides " class="wp-image-22836" srcset="https://thecodebuzz.com/wp-content/uploads/2022/07/image.jpg 940w, https://thecodebuzz.com/wp-content/uploads/2022/07/image-300x142.jpg 300w, https://thecodebuzz.com/wp-content/uploads/2022/07/image-768x364.jpg 768w, https://thecodebuzz.com/wp-content/uploads/2022/07/image-785x372.jpg 785w" sizes="auto, (max-width: 940px) 100vw, 940px" /></figure>



<p>Whether you’re a novice in Java or have years of experience, you can always enhance your knowledge and skills with books. Sure, practice means the most for a coder, but theory can give you direction and help look at problems in a new light, describe fundamental concepts that you can apply in practice.</p>



<p></p>



<p>A good source of theory is books.</p>



<p></p>



<p>So in this article, you’ll find six must-read Java books that you should add to your library. They cover various topics, including Java principles, framework, data structures, providing valuable resources for all Java programmers, from novices to experts.</p>



<p>Today in this article, we will cover below aspects,</p>



<div class="wp-block-aioseo-table-of-contents"><ul><li><a href="#aioseo-why-do-books-still-matter">Why Do Books Still Matter?</a></li><li><a href="#aioseo-great-java-books-you-should-check-out">Great Java Books You Should Check Out</a><ul><li><a href="#aioseo-head-first-java">Head First Java</a></li><li><a href="#aioseo-java-a-beginners-guide">Java: A beginner’s Guide</a></li><li><a href="#aioseo-head-first-design-patterns">Head First Design Patterns</a></li><li><a href="#aioseo-thinking-in-java">Thinking in Java</a></li><li><a href="#aioseo-effective-java">Effective Java</a></li><li><a href="#aioseo-clean-code">Clean Code</a></li></ul></li><li><a href="#aioseo-conclusion">Conclusion</a></li></ul></div>



<h2 class="wp-block-heading" id="aioseo-why-do-books-still-matter">Why Do Books Still Matter?</h2>



<p></p>



<p>Good question. The abundance of learning tools might make you think that books are a thing of the past. But reading is still your best ally because it allows you to exercise your analytical and comprehension abilities. And what better way to do that than with a piece written by an expert in your field.</p>



<p>That’s why books are important for progressing the never-ending learning curve of any programmer. Though you can also opt for alternative reading materials provided online like this<a href="https://codegym.cc/groups/posts" target="_blank" rel="noopener"> java programming Blog </a>from CodeGym.</p>



<p></p>



<h2 class="wp-block-heading" id="aioseo-great-java-books-you-should-check-out">Great Java Books You Should Check Out</h2>



<p></p>



<p>If you look at the piece from CodeGym’s blog about <a href="https://codegym.cc/groups/posts/best-java-books-for-beginners" target="_blank" rel="noopener">Java books</a>, the author agrees that “Head First Java” is a top choice for beginners, so let’s start this list it.</p>



<p></p>



<h3 class="wp-block-heading" id="aioseo-head-first-java"><a></a>Head First Java<strong></strong></h3>



<ul class="wp-block-list"><li><strong>Authors:</strong> Kathy Sierra &amp; Bert Bates</li><li><strong>Suitable for</strong> beginners</li></ul>



<p>This publication is quick and enjoyable, engaging you with a combination of riddles, great images, mysteries, and soul-searching conversations with famous Java objects.<strong></strong></p>



<p><br>This piece is a complete introduction to object-oriented coding and Java, despite the lighthearted presentation of this page-turner. It covers everything from the basic to expert level.</p>



<p>What else should you expect? A visually rich format created with your brain in mind. Instead of a text-heavy technique that drives you to sleep, you&#8217;ll understand Java through issues and challenges that will occupy your imagination.</p>



<p>If you’re one to collect hard copies, this title can become a great addition to your bookshelf. You’re more than likely to refer to it even after gaining some hands-on experience.</p>



<p></p>



<p></p>



<h3 class="wp-block-heading" id="aioseo-java-a-beginners-guide"><a></a>Java: A beginner’s Guide<strong></strong></h3>



<ul class="wp-block-list"><li><strong>Author:</strong> Herbert Schildt</li><li><strong>Suitable for</strong> beginners</li></ul>



<p></p>



<p>Herbert Schildt, a best-selling coding author, starts with the fundamentals, such as writing, constructing, and running a program. This book gets you up and running with keywords, grammar, and constructs that make up the backbone of the language.</p>



<p>Multicore programming, generic versions, lambda expressions, modules, and Swing are among the most sophisticated features covered in the book. An introduction to JShell, Java&#8217;s interactive programming tool, is given as an extra.</p>



<p>Most importantly, it&#8217;s presented in a clear, sharp, and straightforward manner so you don&#8217;t get your brain into trouble just reading it. The guide offers example code accompanied with an annotation that explains the programming principles demonstrated.</p>



<p></p>



<h3 class="wp-block-heading" id="aioseo-head-first-design-patterns"><a></a>Head First Design Patterns<strong></strong></h3>



<ul class="wp-block-list"><li><strong>Author:</strong> Eric Freeman and Elisabeth Robson</li><li><strong>Suitable for</strong> beginners</li></ul>



<p></p>



<p>If you want to become an efficient conder, understanding and applying design patterns is essential. How do they solve various difficulties? What is the best way to use them? You can find the answers in this book.</p>



<p></p>



<p></p>



<p>It also includes several helpful tools, such as workouts and memorization maps, that aid in learning design patterns. This book is an excellent way to start if you want to master basic Java design patterns and object-oriented design concepts.</p>



<p></p>



<p></p>



<h3 class="wp-block-heading" id="aioseo-thinking-in-java">Thinking in Java</h3>



<p></p>



<ul class="wp-block-list"><li><strong>Author:</strong> Bruce Eckel</li><li><strong>Suitable for</strong> beginners to experts</li></ul>



<p></p>



<p></p>



<p>You truly know a language when you start thinking in it. And this guidebook will show you how to do that. It contains over 600 functioning Java applications in over 650 compilation files, all of which have been rewritten for the latest edition of Java.</p>



<p></p>



<p></p>



<p>Thinking in Java starts with an object-oriented foundation for both novices and professionals, then goes to design patterns, XML, concurrency, and other topics. Overall, this is a book that will continue to be helpful to you even after you have spent years learning and writing in Java.</p>



<p></p>



<p></p>



<h3 class="wp-block-heading" id="aioseo-effective-java"><a></a>Effective Java</h3>



<ul class="wp-block-list"><li><strong>Author:</strong> Joshua Bloch</li><li><strong>Suitable for</strong> professionals</li></ul>



<p>For experienced Java programmers, this is a must-read book. The writing style of the author will engage you with topics but you’ll also learn a lot about the language and its APIs.</p>



<p>This book can be read on vacation while traveling or at your workplace. It&#8217;s simply fantastic. There&#8217;s no question that after reading this book, you&#8217;ll be a sharper problem-solver. But it’s only suitable for the ones who already have experience in Java.</p>



<p></p>



<p></p>



<h3 class="wp-block-heading" id="aioseo-clean-code"><a></a>Clean Code</h3>



<ul class="wp-block-list"><li><strong>Author:</strong> Robert C. Martin (aka Uncle Bob)</li><li><strong>Suitable for</strong> advanced coders</li></ul>



<p></p>



<p>Even terrible code can get the job done. However, if regulation isn&#8217;t well-written, it can knock a development team to its knees. Clean code presents a good view of how code should be written to be understandable and manageable.</p>



<p>Clean Code is broken down into three sections. The first section discusses the principles, patterns, and techniques for writing clean code. The second section contains a series of increasingly complicated case examples. Each case study is an activity in code cleanup, in which you&#8217;ll learn how to turn a sloppy codebase into a clean and effective one.</p>



<p>The payout comes in the third section, a single chapter featuring a list of heuristics and &#8220;smells&#8221; obtained during the case study creation. As a result, we have a knowledge base that outlines how we think about writing, reading, and cleaning a code.</p>



<p>Clean Code is a hard one. Don&#8217;t skip through it; fight your way through it. It is well worth your time.</p>



<p></p>



<p></p>



<h2 class="wp-block-heading" id="aioseo-conclusion">Conclusion</h2>



<p></p>



<p>While practice is key to developing practical skills, reading exercises your comprehension and analytical skills. After all, where else can you learn fundamentals, get inspiration and ideas to solve problems, and tap into the experience of fellow coders?</p>



<p>The six titles reviewed in this article can support your journey from beginner level to senior developer. Each book adds a penny to your piggy bank of knowledge and explores a multitude of concepts helping you to become a true professional.</p>



<p></p>



<p style="font-size:18px">Do you have any <strong>comments or ideas or any better </strong>suggestions to share?</p>



<p class="has-small-font-size"></p>



<p style="font-size:18px">Please sound off your comments below.</p>



<p class="has-medium-font-size"></p>



<p class="has-medium-font-size"><strong>Happy Coding </strong>!!</p>



<p></p>



<hr>



<p class=""></p>



<p class="has-background" style="background-color:#b6d9ac;font-size:18px"><br>Please <strong><em>bookmark </em></strong>this page and <em><strong>share </strong></em>it with your friends.                                                    Please <a href="https://www.thecodebuzz.com/subscription/" target="_blank" rel="noreferrer noopener"><em><mark style="background-color:rgba(0, 0, 0, 0)" class="has-inline-color has-luminous-vivid-orange-color"><strong>Subscribe</strong> </mark></em></a>to the blog to receive notifications on freshly published (2025) best practices and guidelines for software design and development.</p>




<br>



<hr>



<p class=""></p>



<p></p><p>The post <a href="https://thecodebuzz.com/the-java-bookshelf-6-must-read-guides/">The Java Bookshelf: 6 Must-Read Guides</a> first appeared on <a href="https://thecodebuzz.com">TheCodeBuzz</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://thecodebuzz.com/the-java-bookshelf-6-must-read-guides/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Java-Bulk Submit URLs to Google Search Console</title>
		<link>https://thecodebuzz.com/java-bulk-submit-urls-google-search-console-index-crawl/</link>
					<comments>https://thecodebuzz.com/java-bulk-submit-urls-google-search-console-index-crawl/#comments</comments>
		
		<dc:creator><![CDATA[admin]]></dc:creator>
		<pubDate>Wed, 02 Feb 2022 23:17:00 +0000</pubDate>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Wordpress]]></category>
		<guid isPermaLink="false">https://www.thecodebuzz.com/?p=20840</guid>

					<description><![CDATA[<p>Using Java to Bulk Submit URLs to Google Search Console Today in this article, we will learn how to perform Java-Bulk Submit URLs to Google Search Console. We will Java example to Bulk Submit URLs to Google Search Engine/Console for Indexing or Crawling purpose. We already learned how to set up the service account, project, [&#8230;]</p>
<p>The post <a href="https://thecodebuzz.com/java-bulk-submit-urls-google-search-console-index-crawl/">Java-Bulk Submit URLs to Google Search Console</a> first appeared on <a href="https://thecodebuzz.com">TheCodeBuzz</a>.</p>]]></description>
										<content:encoded><![CDATA[<h1 class="wp-block-heading">Using Java to Bulk Submit URLs to Google Search Console</h1>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="764" height="400" src="https://www.thecodebuzz.com/wp-content/uploads/2022/02/index-multiple-url-google-search-console-engine-using-JAVA.jpg" alt="Java-Bulk Submit URLs to Google Search Console" class="wp-image-20841" srcset="https://thecodebuzz.com/wp-content/uploads/2022/02/index-multiple-url-google-search-console-engine-using-JAVA.jpg 764w, https://thecodebuzz.com/wp-content/uploads/2022/02/index-multiple-url-google-search-console-engine-using-JAVA-300x157.jpg 300w" sizes="auto, (max-width: 764px) 100vw, 764px" /></figure>



<p>Today in this article,  we will learn how to perform Java-Bulk Submit URLs to Google Search Console. We will Java example to Bulk Submit URLs to Google Search Engine/Console for Indexing or Crawling purpose.</p>



<p></p>



<p>We already learned how to set up the service account, project, and other configurations so that we can leverage Google&#8217;s Indexing API before.</p>



<p>Today in this article, we will cover below aspects,</p>



<div class="wp-block-aioseo-table-of-contents"><ul><li><a href="#aioseo-step1-define-the-scope-and-endpoint">Step1- Define the scope and endpoint</a></li><li><a href="#aioseo-step2-include-the-service-account-access-token">Step2 &#8211; Include the service account access token</a></li><li><a href="#aioseo-step3-define-the-body-of-the-request-and-invoke-api">Step3 &#8211; Define the body of the request and invoke API</a></li></ul></div>



<p>If you have not performed mandatory prerequisites, please follow the below article for more details,</p>



<ul class="has-medium-font-size wp-block-list"><li><a href="https://www.thecodebuzz.com/how-to-bulk-submit-website-urls-index-google-search-engine-console-wordpress-crawling/" target="_blank" rel="noreferrer noopener" title="Configuration to setup multiple URLs submit to Google Search Console "><em>Configuration to setup multiple URLs submit to Google Search Console </em></a></li></ul>



<p></p>



<p></p>



<p>You may find the need to submit the URLs due to many reasons like article update due to new data or upgrade or article enhancement, etc. In such scenarios, it is always difficult to perform indexing manually.</p>



<p></p>



<p>We shall be using below endpoints required for publishing the URLs,</p>



<p></p>



<h2 class="wp-block-heading" id="aioseo-step1-define-the-scope-and-endpoint">Step1- Define the scope and endpoint </h2>



<p></p>



<blockquote class="wp-block-quote is-layout-flow wp-block-quote-is-layout-flow"><p><strong>SCOPES</strong> = [ &#8220;<a href="https://www.googleapis.com/auth/indexing&quot;" target="_blank" rel="noreferrer noopener"><em><strong>https://www.googleapis.com/auth/indexing</strong>&#8220;</em></a> ]</p><p><strong>ENDPOINT</strong> = &#8220;<em><strong>https://indexing.googleapis.com/v3/urlNotifications:publish</strong></em>&#8220;</p></blockquote>



<p></p>



<p>In your <strong><em>Java code </em></strong>please define the scopes and endpoint as below,</p>



<p></p>



<pre class="wp-block-preformatted has-medium-font-size">String scopes = "https://www.googleapis.com/auth/indexing";
String endPoint = "https://indexing.googleapis.com/v3/urlNotifications:publish";</pre>



<p></p>



<h2 class="wp-block-heading" id="aioseo-step2-include-the-service-account-access-token">Step2 &#8211; Include the&nbsp;service account access token</h2>



<p></p>



<p>Please include the service account access token in your code. In the last article, we generated a service account token <em><strong>thecodebuzz-da659b2b8b0d.json </strong></em>which is the private key that you use to authenticate the service account using OAuth2.</p>



<p></p>



<p>For more details :  </p>



<p class="has-medium-font-size"><li><a href="https://www.thecodebuzz.com/how-to-bulk-submit-website-urls-index-google-search-engine-console-wordpress-crawling/" target="_blank" rel="noreferrer noopener" title="Configuration to setup multiple URLs submit to Google Search Console "><em>Create Service account JSON for Google Indexing API </em></a></li> </p>



<p></p>



<h2 class="wp-block-heading" id="aioseo-step3-define-the-body-of-the-request-and-invoke-api">Step3 &#8211; Define the body of the request&nbsp;and invoke API</h2>



<p></p>



<p>Below is a sample Java code that can be used to send Bulk URLs to Indexing API </p>



<p></p>


<div class="wp-block-syntaxhighlighter-code "><pre class="brush: java; title: ; notranslate">
JsonFactory jsonFactory = new JacksonFactory();

// thecodebuzz-da659b2b8b0d.json is the private key that you created for your service account.
InputStream in = IOUtils.toInputStream(&quot;thecodebuzz-da659b2b8b0d.json&quot;);

GoogleCredential credentials =
  GoogleCredential.fromStream(in, this.httpTransport, jsonFactory).createScoped(Collections.singleton(scopes));

GenericUrl genericUrl = new GenericUrl(endPoint);
HttpRequestFactory requestFactory = this.httpTransport.createRequestFactory();

// Define all URLs to be submitted to API

String content = &quot;{&quot;
  + &quot;\&quot;url\&quot;: \&quot;http://your url .com\&quot;,&quot;
  + &quot;\&quot;type\&quot;: \&quot;URL_UPDATED\&quot;,&quot;
  + &quot;}&quot;;


HttpRequest request =
  requestFactory.buildPostRequest(genericUrl, ByteArrayContent.fromString(&quot;application/json&quot;, content));

credentials.initialize(request);
HttpResponse response = request.execute();
int statusCode = response.getStatusCode();



</pre></div>


<p></p>



<ul class="wp-block-list"><li>In the above code content is defined to contain the URL to be submitted. </li></ul>



<ul class="wp-block-list"><li>We have to define request format as &#8220;application/json&#8221;</li></ul>



<ul class="wp-block-list"><li>getStatusCode lets you verify the status code after executing the API</li><li></li></ul>



<p></p>



<p>Once successfully submitted the URLs for indexing, you can see the status code as 200 for the request.</p>



<p></p>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="526" src="https://www.thecodebuzz.com/wp-content/uploads/2022/01/script-to-bulk-submit-URLs-to-Google-indexing-engine-success-1024x526.jpg" alt="JAVA for Bulk Submit URLs to Google indexing,index url google using script , index url google search engine seo,submit to google for indexing,add to google index, google add url to index, google to crawl and index your url, submit url for indexing, bulk url indexer, submit url for indexing, google add website to index , google indexing api-python, bulk request indexing google, google submit url for indexing, google submit page for indexing, google console index" class="wp-image-19988" srcset="https://thecodebuzz.com/wp-content/uploads/2022/01/script-to-bulk-submit-URLs-to-Google-indexing-engine-success-1024x526.jpg 1024w, https://thecodebuzz.com/wp-content/uploads/2022/01/script-to-bulk-submit-URLs-to-Google-indexing-engine-success-300x154.jpg 300w, https://thecodebuzz.com/wp-content/uploads/2022/01/script-to-bulk-submit-URLs-to-Google-indexing-engine-success-768x394.jpg 768w, https://thecodebuzz.com/wp-content/uploads/2022/01/script-to-bulk-submit-URLs-to-Google-indexing-engine-success-1536x789.jpg 1536w, https://thecodebuzz.com/wp-content/uploads/2022/01/script-to-bulk-submit-URLs-to-Google-indexing-engine-success-785x403.jpg 785w, https://thecodebuzz.com/wp-content/uploads/2022/01/script-to-bulk-submit-URLs-to-Google-indexing-engine-success.jpg 1817w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<p></p>



<p><strong><em>References </em></strong>:</p>



<p></p>



<p>Please follow the below article for more details on prerequisites,</p>



<p></p>



<ul class="has-medium-font-size wp-block-list"><li><a href="https://www.thecodebuzz.com/how-to-bulk-submit-website-urls-index-google-search-engine-console-wordpress-crawling/" target="_blank" rel="noreferrer noopener" title="Configuration to setup multiple URLs submit to Google Search Console "><em>Configuration to setup multiple URLs submit to Google Search Console</em></a></li></ul>



<ul class="has-medium-font-size wp-block-list"><li><a href="https://www.thecodebuzz.com/python-script-bulk-submit-urls-to-google-search-console-indexing-crawling/" target="_blank" rel="noreferrer noopener"><em>Using Python for indexing/Crawling the URL </em></a></li></ul>



<p></p>



<p></p>



<p style="font-size:18px">Do you have any <strong>comments or ideas or any better </strong>suggestions to share?</p>



<p class="has-small-font-size"></p>



<p style="font-size:18px">Please sound off your comments below.</p>



<p class="has-medium-font-size"></p>



<p class="has-medium-font-size"><strong>Happy Coding </strong>!!</p>



<p></p>



<hr>



<p class=""></p>



<p class="has-background" style="background-color:#b6d9ac;font-size:18px"><br>Please <strong><em>bookmark </em></strong>this page and <em><strong>share </strong></em>it with your friends.                                                    Please <a href="https://www.thecodebuzz.com/subscription/" target="_blank" rel="noreferrer noopener"><em><mark style="background-color:rgba(0, 0, 0, 0)" class="has-inline-color has-luminous-vivid-orange-color"><strong>Subscribe</strong> </mark></em></a>to the blog to receive notifications on freshly published (2025) best practices and guidelines for software design and development.</p>




<br>



<hr>



<p class=""></p>



<p></p><p>The post <a href="https://thecodebuzz.com/java-bulk-submit-urls-google-search-console-index-crawl/">Java-Bulk Submit URLs to Google Search Console</a> first appeared on <a href="https://thecodebuzz.com">TheCodeBuzz</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://thecodebuzz.com/java-bulk-submit-urls-google-search-console-index-crawl/feed/</wfw:commentRss>
			<slash:comments>2</slash:comments>
		
		
			</item>
	</channel>
</rss>
