{"id":13763,"date":"2022-09-27T12:14:50","date_gmt":"2022-09-27T19:14:50","guid":{"rendered":"https:\/\/www.couchbase.com\/blog\/?p=13763"},"modified":"2024-05-08T06:23:23","modified_gmt":"2024-05-08T13:23:23","slug":"databricks-couchbase-spark-sql-quickstart","status":"publish","type":"post","link":"https:\/\/www.couchbase.com\/blog\/pt\/databricks-couchbase-spark-sql-quickstart\/","title":{"rendered":"In\u00edcio r\u00e1pido: Couchbase com Apache Spark na Databricks"},"content":{"rendered":"<p><span style=\"font-weight: 400\">O Couchbase \u00e9 o principal banco de dados de documentos NoSQL do mundo. Ele oferece desempenho, flexibilidade e escalabilidade inigual\u00e1veis na borda, no local e na nuvem. O Spark \u00e9 um dos ambientes de computa\u00e7\u00e3o em mem\u00f3ria mais populares. As duas plataformas podem ser combinadas para executar fun\u00e7\u00f5es incrivelmente r\u00e1pidas de consulta, engenharia de dados, ci\u00eancia de dados e aprendizado de m\u00e1quina.<\/span><\/p>\n<p><span style=\"font-weight: 400\">Neste QuickStart, eu o guiarei pelas etapas simples para configurar o Couchbase com o Databricks* e executar consultas de dados do Couchbase e consultas SQL do Spark.<\/span><\/p>\n<p><i><span style=\"font-weight: 400\">*Observa\u00e7\u00e3o: as etapas deste QuickStart foram validadas com o tempo de execu\u00e7\u00e3o do Databricks 10.4 LTS.<\/span><\/i><\/p>\n<h2><span style=\"font-weight: 400\">Configura\u00e7\u00e3o<\/span><\/h2>\n<h3><span style=\"font-weight: 400\">Pr\u00e9-requisitos<\/span><\/h3>\n<p><span style=\"font-weight: 400\">Para concluir este In\u00edcio R\u00e1pido, voc\u00ea precisar\u00e1 do seguinte:<\/span><\/p>\n<ul>\n<li style=\"list-style-type: none\">\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Um cluster do Couchbase e <em>amostra de viagem<\/em> bucket acess\u00edvel ao cluster do Databricks. Usei um cluster do Couchbase em uma m\u00e1quina AWS EC2.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">A<\/span>\u00a0<a href=\"https:\/\/databricks.com\/try-databricks?utm_medium=paid+search&amp;utm_source=google&amp;utm_campaign=14272820537&amp;utm_adgroup=133937946470&amp;utm_content=trial&amp;utm_offer=try-databricks&amp;utm_ad=564241575790&amp;utm_term=databricks%20login&amp;gclid=CjwKCAiAgvKQBhBbEiwAaPQw3JW8bFOKAc13o921CzNkQf0KwC39UQ_x8NZEBFiihDxpvNutxbSpNhoCjIQQAvD_BwE\" target=\"_blank\" rel=\"noopener\"><span style=\"font-weight: 400\">Conta da Databricks<\/span><\/a><span style=\"font-weight: 400\"> - Est\u00e3o dispon\u00edveis avalia\u00e7\u00f5es gratuitas que exigem uma conta do AWS, Azure ou GCP.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">O Couchbase <em>conector de fa\u00edsca<\/em> biblioteca, vers\u00e3o 3.2.2 - dispon\u00edvel via<\/span>\u00a0<a href=\"https:\/\/mvnrepository.com\/artifact\/com.couchbase.client\/spark-connector\" target=\"_blank\" rel=\"noopener\"><span style=\"font-weight: 400\">Maven<\/span><\/a><span style=\"font-weight: 400\">:\u00a0<\/span>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Na tela de cria\u00e7\u00e3o do cluster, na se\u00e7\u00e3o <strong>Bibliotecas<\/strong> guia.  Selecione <strong>Instalar<\/strong> new e procure o pacote no Maven Central.  Veja o exemplo abaixo:<\/span><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-13764\" src=\"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/2022\/09\/image1-1024x356.png\" alt=\"\" width=\"900\" height=\"313\" srcset=\"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/image1-1024x356.png 1024w, https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/image1-300x104.png 300w, https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/image1-768x267.png 768w, https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/image1-1536x533.png 1536w, https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/image1-1320x458.png 1320w, https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/image1.png 1768w\" sizes=\"auto, (max-width: 900px) 100vw, 900px\" \/><\/p>\n<ul>\n<li style=\"list-style-type: none\">\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">O <strong>Instalar<\/strong> a configura\u00e7\u00e3o da biblioteca ser\u00e1 configurada como no exemplo abaixo:<\/span><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p><span style=\"font-weight: 400\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-13767\" src=\"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/2022\/09\/image4-1024x562.png\" alt=\"\" width=\"900\" height=\"494\" srcset=\"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/image4-1024x562.png 1024w, https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/image4-300x165.png 300w, https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/image4-768x421.png 768w, https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/image4.png 1192w\" sizes=\"auto, (max-width: 900px) 100vw, 900px\" \/><br \/>\n<\/span><\/p>\n<h3><span style=\"font-weight: 400\">Configura\u00e7\u00e3o<\/span><\/h3>\n<p><span style=\"font-weight: 400\">Antes de come\u00e7armos, precisamos configurar os seguintes par\u00e2metros no cluster do Databricks<\/span> <span style=\"font-weight: 400\"><strong>op\u00e7\u00f5es avan\u00e7adas<\/strong> Configura\u00e7\u00e3o do Spark. Isso pode ser feito<\/span> <span style=\"font-weight: 400\">ao criar um cluster (veja a impress\u00e3o de tela abaixo):<\/span><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-13765\" src=\"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/2022\/09\/image2.png\" alt=\"\" width=\"337\" height=\"172\" srcset=\"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/image2.png 337w, https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/image2-300x153.png 300w\" sizes=\"auto, (max-width: 337px) 100vw, 337px\" \/><\/p>\n<p><span style=\"font-weight: 400\">Voc\u00ea pode copiar e colar as configura\u00e7\u00f5es abaixo e substituir os par\u00e2metros em <em>&lt;&gt;<\/em> com os valores de seu cluster do Couchbase na vari\u00e1vel <\/span><span style=\"font-weight: 400\"><strong>op\u00e7\u00f5es avan\u00e7adas<\/strong> Configura\u00e7\u00e3o do Spark<\/span><span style=\"font-weight: 400\">:\u00a0<\/span><\/p>\n<pre class=\"lang:default decode:true\">\u00a0 spark.couchbase.password &lt;password&gt;\r\n\u00a0 spark.couchbase.implicitBucket &lt;travel-sample&gt;\r\n\u00a0 spark.couchbase.connectionString &lt;hostname&gt;\r\n\u00a0 spark.couchbase.username &lt;username&gt;\r\n\u00a0 spark.databricks.delta.preview.enabled true<\/pre>\n<p><span style=\"font-weight: 400\">Primeiro, vamos executar as importa\u00e7\u00f5es necess\u00e1rias. Copie o c\u00f3digo de amostra abaixo em um notebook em branco anexado a um cluster com a configura\u00e7\u00e3o acima<\/span><\/p>\n<pre class=\"lang:default decode:true\">  import com.couchbase.spark._\r\n\u00a0 import org.apache.spark.sql._\r\n\u00a0 import com.couchbase.client.scala.json.JsonObject\r\n\u00a0 import com.couchbase.spark.kv.Get\r\n\u00a0 import com.couchbase.client.scala.kv.MutateInSpec\r\n\u00a0 import com.couchbase.spark.kv.MutateIn\r\n\u00a0 import com.couchbase.client.scala.kv.LookupInSpec\r\n\u00a0 import com.couchbase.spark.kv.LookupIn\r\n\u00a0 import com.couchbase.client.scala.query.QueryOptions\r\n  import com.couchbase.spark.query.QueryOptions\r\n  import com.couchbase.client.scala.analytics.AnalyticsOptions<\/pre>\n<p><span style=\"font-weight: 400\">Agora, vamos obter alguns documentos por chaves do Couchbase <em>amostra de viagem<\/em> usando o c\u00f3digo abaixo:<\/span><\/p>\n<pre class=\"lang:default decode:true\"> sc\r\n\u00a0 .couchbaseGet(Seq(Get(\"airline_10\"), Get(\"airline_10642\")))\r\n\u00a0 .collect()\r\n\u00a0 .foreach(result =&gt; println(result.contentAs[JsonObject]))<\/pre>\n<p>\u00d3timo, nos conectamos ao cluster e retornamos nosso primeiro RDD (Resilient Distributed Dataset).<\/p>\n<p><span style=\"font-weight: 400\">Podemos consultar os dados usando o SQL++ (linguagem de consulta do Couchbase baseada em SQL).  Execute o c\u00f3digo abaixo como um exemplo:<\/span><\/p>\n<pre class=\"lang:default decode:true\"> sc\r\n\u00a0 .couchbaseQuery[JsonObject](\"select country, count(*) as count from `travel-sample` where type = 'airport' group by country order by count desc\")\r\n\u00a0 .collect()\r\n\u00a0 .foreach(println)<\/pre>\n<h2><span style=\"font-weight: 400\">Consulta ao servi\u00e7o de an\u00e1lise<\/span><\/h2>\n<p><span style=\"font-weight: 400\">O Couchbase tamb\u00e9m oferece um servi\u00e7o de an\u00e1lise para an\u00e1lise operacional e an\u00e1lise em tempo real. Abaixo est\u00e1 um exemplo de uma consulta de an\u00e1lise:<\/span><\/p>\n<pre class=\"lang:default decode:true\">val query = \"SELECT ht.city,ht.state,COUNT(*) AS num_hotels FROM `travel-sample`.inventory.hotel ht GROUP BY ht.city,ht.state HAVING COUNT(*) &gt; 30\"\r\nsc.couchbaseAnalyticsQuery[JsonObject](query).collect().foreach(println)<\/pre>\n<h2><span style=\"font-weight: 400\">Agora, vamos ver um pouco de Spark SQL<\/span><\/h2>\n<p><span style=\"font-weight: 400\">Use o c\u00f3digo abaixo para criar exibi\u00e7\u00f5es tempor\u00e1rias para <em>companhias a\u00e9reas<\/em> e <em>aeroportos<\/em> DataFrames:<\/span><\/p>\n<pre class=\"lang:default decode:true\">val airlines = spark.read.format(\"couchbase.query\")\r\n\u00a0 .option(QueryOptions.Filter, \"type = 'airline'\")\r\n\u00a0 .load()\r\nairlines.createOrReplaceTempView(\"airlines\")\r\n\u00a0\r\nval airports = spark.read.format(\"couchbase.query\")\r\n\u00a0 .option(QueryOptions.Filter, \"type = 'airport'\")\r\n\u00a0 .load()\r\nairports.createOrReplaceTempView(\"airports\")<\/pre>\n<p><span style=\"font-weight: 400\">Agora podemos executar consultas Spark SQL nas exibi\u00e7\u00f5es, por exemplo:<\/span><\/p>\n<p><span style=\"font-weight: 400\">Obter as companhias a\u00e9reas em ordem crescente:<\/span><\/p>\n<pre class=\"nums:false lang:default decode:true\">%sql select * from airlines order by name asc limit 10<\/pre>\n<p><span style=\"font-weight: 400\">Obtenha as companhias a\u00e9reas agrupadas por pa\u00eds:<\/span><\/p>\n<pre class=\"nums:false lang:default decode:true\">%sql select country, count(*) from airlines group by country;<\/pre>\n<p><span style=\"font-weight: 400\">E, por fim, vamos visualizar os aeroportos por pa\u00eds usando um <\/span><a href=\"https:\/\/docs.couchbase.com\/server\/current\/guides\/create-user-defined-function.html\" target=\"_blank\" rel=\"noopener\"><span style=\"font-weight: 400\">UDF<\/span><\/a><span style=\"font-weight: 400\"> (Fun\u00e7\u00e3o definida pelo usu\u00e1rio) junto com o recurso de mapeamento do Databricks.  Crie a UDF usando o SQL++ abaixo:<\/span><\/p>\n<pre class=\"lang:default decode:true\">val countrymap = (s: String) =&gt; {\r\n s match {\r\n  case \"France\" =&gt; \"FRA\"\r\n  case \"United States\" =&gt; \"USA\"\r\n  case \"United Kingdom\" =&gt; \"GBR\"\r\n }\r\n}\r\nspark.udf.register(\"countrymap\", countrymap)<\/pre>\n<p><span style=\"font-weight: 400\">Selecione as contagens de aeroportos por pa\u00eds e visualize os resultados:<\/span><\/p>\n<pre class=\"nums:false lang:default decode:true\">%sql select countrymap(country), count(*) from airports group by country;<\/pre>\n<p><span style=\"font-weight: 400\">Ap\u00f3s concluir este In\u00edcio R\u00e1pido, seu resultado dever\u00e1 ser semelhante \u00e0 visualiza\u00e7\u00e3o abaixo:<\/span><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-13766\" src=\"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/2022\/09\/image3.png\" alt=\"\" width=\"469\" height=\"191\" srcset=\"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/image3.png 469w, https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/image3-300x122.png 300w\" sizes=\"auto, (max-width: 469px) 100vw, 469px\" \/><\/p>\n<h2><span style=\"font-weight: 400\">O que realizamos<\/span><\/h2>\n<p><span style=\"font-weight: 400\">Neste QuickStart, descrevi como utilizar o Couchbase spark-connector com o Databricks para criar RDDs, executar consultas SQL do Couchbase e do Spark, criar um UDF e utilizar o recurso de mapeamento do Databricks para visualizar os resultados. Essas etapas demonstram o processo usado para acessar, analisar e visualizar dados em um cluster do Couchbase a partir de uma interface de notebook do Databricks.<\/span><\/p>\n<h2><span style=\"font-weight: 400\">Pr\u00f3ximas etapas<\/span><\/h2>\n<p><span style=\"font-weight: 400\">Saiba mais sobre<\/span><a href=\"https:\/\/www.couchbase.com\/blog\/pt\/products\/capella\/\" target=\"_blank\" rel=\"noopener\"> <span style=\"font-weight: 400\">Couchbase Capella<\/span><\/a><span style=\"font-weight: 400\">:<\/span><\/p>\n<ul>\n<li style=\"list-style-type: none\">\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Fa\u00e7a um test drive com a Capella inscrevendo-se para um<\/span><a href=\"https:\/\/cloud.couchbase.com\/?href=Playground\" target=\"_blank\" rel=\"noopener\"> <span style=\"font-weight: 400\">teste gratuito de 30 dias<\/span><\/a><span style=\"font-weight: 400\">.<\/span><\/li>\n<li style=\"font-weight: 400\"><a href=\"https:\/\/cloud.couchbase.com\/sign-up\" target=\"_blank\" rel=\"noopener\"><span style=\"font-weight: 400\">Conecte seu cluster de teste ao Playground<\/span><\/a> <span style=\"font-weight: 400\">ou conecte um projeto para test\u00e1-lo por si mesmo.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Visite o<\/span><a href=\"https:\/\/www.couchbase.com\/blog\/pt\/developers\/\" target=\"_blank\" rel=\"noopener\"> <span style=\"font-weight: 400\">Portal do desenvolvedor do Couchbase<\/span><\/a> <span style=\"font-weight: 400\">que toneladas de<\/span><a href=\"https:\/\/developer.couchbase.com\/tutorials\" target=\"_blank\" rel=\"noopener\"> <span style=\"font-weight: 400\">tutoriais\/guias de in\u00edcio r\u00e1pido<\/span><\/a> <span style=\"font-weight: 400\">e caminhos de aprendizagem para ajud\u00e1-lo a come\u00e7ar!<\/span><\/li>\n<li style=\"font-weight: 400\"><a href=\"https:\/\/docs.couchbase.com\/home\/sdk.html\" target=\"_blank\" rel=\"noopener\"><span style=\"font-weight: 400\">Consulte a documenta\u00e7\u00e3o<\/span><\/a> <span style=\"font-weight: 400\">para saber mais sobre os SDKs do Couchbase.<\/span><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<ul>\n<li style=\"list-style-type: none\"><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400\">Obrigado por ler esta postagem! Se tiver alguma d\u00favida ou coment\u00e1rio, entre em contato conosco no<\/span>\u00a0<a href=\"https:\/\/www.couchbase.com\/blog\/pt\/forums\/\" target=\"_blank\" rel=\"noopener\"><span style=\"font-weight: 400\">Couchbase<\/span><\/a> <span style=\"font-weight: 400\">F\u00f3runs!<\/span><\/p>\n<p>&nbsp;<\/p>\n<p><span style=\"font-weight: 400\">\u00a0<\/span><\/p>\n<p><span style=\"font-weight: 400\">\u00a0<\/span><\/p>\n<p><span style=\"font-weight: 400\">\u00a0<\/span><\/p>\n<p><span style=\"font-weight: 400\">\u00a0<\/span><\/p>\n<p><span style=\"font-weight: 400\">\u00a0<\/span><\/p>\n<p><span style=\"font-weight: 400\">\u00a0<\/span><\/p>\n<p><span style=\"font-weight: 400\">\u00a0<\/span><\/p>\n<p><span style=\"font-weight: 400\">\u00a0<\/span><\/p>\n<p><span style=\"font-weight: 400\">\u00a0<\/span><\/p>\n<p>&nbsp;<\/p>","protected":false},"excerpt":{"rendered":"<p>Couchbase is the world\u2019s leading NoSQL document database. It offers unmatched performance, flexibility and scalability on the edge, on-premise and in the cloud. Spark is one of the most popular in-memory computing environments. The two platforms can be combined to [&hellip;]<\/p>","protected":false},"author":70772,"featured_media":13769,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"inline_featured_image":false,"footnotes":""},"categories":[2242,2225,1818,1812,2201],"tags":[9719,1610],"ppma_author":[9208],"class_list":["post-13763","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-connectors","category-cloud","category-java","category-n1ql-query","category-tools-sdks","tag-databricks","tag-spark"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v26.4 (Yoast SEO v26.4) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>QuickStart: Couchbase with Apache Spark on Databricks<\/title>\n<meta name=\"description\" content=\"Get started quickly with Apache Spark SQL and more using the Couchbase provider on the Databricks platform.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.couchbase.com\/blog\/pt\/databricks-couchbase-spark-sql-quickstart\/\" \/>\n<meta property=\"og:locale\" content=\"pt_BR\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"QuickStart: Couchbase with Apache Spark on Databricks\" \/>\n<meta property=\"og:description\" content=\"Get started quickly with Apache Spark SQL and more using the Couchbase provider on the Databricks platform.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.couchbase.com\/blog\/pt\/databricks-couchbase-spark-sql-quickstart\/\" \/>\n<meta property=\"og:site_name\" content=\"The Couchbase Blog\" \/>\n<meta property=\"article:published_time\" content=\"2022-09-27T19:14:50+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-05-08T13:23:23+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/2022\/09\/databricks-couchbase-spark-sql-scaled.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"2560\" \/>\n\t<meta property=\"og:image:height\" content=\"1610\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Rick Jacobs\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Rick Jacobs\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 minutos\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/\"},\"author\":{\"name\":\"Rick Jacobs\",\"@id\":\"https:\/\/www.couchbase.com\/blog\/#\/schema\/person\/ecb4001e1e4b88a5c44d20c7bf39fcd3\"},\"headline\":\"QuickStart: Couchbase with Apache Spark on Databricks\",\"datePublished\":\"2022-09-27T19:14:50+00:00\",\"dateModified\":\"2024-05-08T13:23:23+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/\"},\"wordCount\":593,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/www.couchbase.com\/blog\/#organization\"},\"image\":{\"@id\":\"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/databricks-couchbase-spark-sql-scaled.jpg\",\"keywords\":[\"databricks\",\"spark\"],\"articleSection\":[\"Connectors\",\"Couchbase Capella\",\"Java\",\"SQL++ \/ N1QL Query\",\"Tools &amp; SDKs\"],\"inLanguage\":\"pt-BR\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/\",\"url\":\"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/\",\"name\":\"QuickStart: Couchbase with Apache Spark on Databricks\",\"isPartOf\":{\"@id\":\"https:\/\/www.couchbase.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/databricks-couchbase-spark-sql-scaled.jpg\",\"datePublished\":\"2022-09-27T19:14:50+00:00\",\"dateModified\":\"2024-05-08T13:23:23+00:00\",\"description\":\"Get started quickly with Apache Spark SQL and more using the Couchbase provider on the Databricks platform.\",\"breadcrumb\":{\"@id\":\"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/#breadcrumb\"},\"inLanguage\":\"pt-BR\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"pt-BR\",\"@id\":\"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/#primaryimage\",\"url\":\"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/databricks-couchbase-spark-sql-scaled.jpg\",\"contentUrl\":\"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/databricks-couchbase-spark-sql-scaled.jpg\",\"width\":2560,\"height\":1610,\"caption\":\"an overview of retrieval augmentation generation\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.couchbase.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"QuickStart: Couchbase with Apache Spark on Databricks\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.couchbase.com\/blog\/#website\",\"url\":\"https:\/\/www.couchbase.com\/blog\/\",\"name\":\"The Couchbase Blog\",\"description\":\"Couchbase, the NoSQL Database\",\"publisher\":{\"@id\":\"https:\/\/www.couchbase.com\/blog\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.couchbase.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"pt-BR\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/www.couchbase.com\/blog\/#organization\",\"name\":\"The Couchbase Blog\",\"url\":\"https:\/\/www.couchbase.com\/blog\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"pt-BR\",\"@id\":\"https:\/\/www.couchbase.com\/blog\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/2023\/04\/admin-logo.png\",\"contentUrl\":\"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/2023\/04\/admin-logo.png\",\"width\":218,\"height\":34,\"caption\":\"The Couchbase Blog\"},\"image\":{\"@id\":\"https:\/\/www.couchbase.com\/blog\/#\/schema\/logo\/image\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.couchbase.com\/blog\/#\/schema\/person\/ecb4001e1e4b88a5c44d20c7bf39fcd3\",\"name\":\"Rick Jacobs\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"pt-BR\",\"@id\":\"https:\/\/www.couchbase.com\/blog\/#\/schema\/person\/image\/398e492dda1c41103d3dfa60dfd80cfe\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/4df9d5daa89732e9e520a2ded9e366daf2b32b5aea74313c561073fbc3784be9?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/4df9d5daa89732e9e520a2ded9e366daf2b32b5aea74313c561073fbc3784be9?s=96&d=mm&r=g\",\"caption\":\"Rick Jacobs\"},\"description\":\"Rick Jacobs is the Technical Product Marketing Manager at Couchbase. His varied background includes experience at many of the world\u2019s leading organizations such as Computer Sciences Corporation, IBM, Cloudera etc. He comes with over 15 years of general technology experience garnered from serving in development, consulting, data science, sales engineering and technical marketing roles. He holds several academic degrees including an MS in Computational Science from George Mason University.\",\"url\":\"https:\/\/www.couchbase.com\/blog\/pt\/author\/rick\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"In\u00edcio r\u00e1pido: Couchbase com Apache Spark na Databricks","description":"Comece a usar rapidamente o Apache Spark SQL e muito mais usando o provedor Couchbase na plataforma Databricks.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.couchbase.com\/blog\/pt\/databricks-couchbase-spark-sql-quickstart\/","og_locale":"pt_BR","og_type":"article","og_title":"QuickStart: Couchbase with Apache Spark on Databricks","og_description":"Get started quickly with Apache Spark SQL and more using the Couchbase provider on the Databricks platform.","og_url":"https:\/\/www.couchbase.com\/blog\/pt\/databricks-couchbase-spark-sql-quickstart\/","og_site_name":"The Couchbase Blog","article_published_time":"2022-09-27T19:14:50+00:00","article_modified_time":"2024-05-08T13:23:23+00:00","og_image":[{"width":2560,"height":1610,"url":"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/2022\/09\/databricks-couchbase-spark-sql-scaled.jpg","type":"image\/jpeg"}],"author":"Rick Jacobs","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Rick Jacobs","Est. reading time":"4 minutos"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/#article","isPartOf":{"@id":"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/"},"author":{"name":"Rick Jacobs","@id":"https:\/\/www.couchbase.com\/blog\/#\/schema\/person\/ecb4001e1e4b88a5c44d20c7bf39fcd3"},"headline":"QuickStart: Couchbase with Apache Spark on Databricks","datePublished":"2022-09-27T19:14:50+00:00","dateModified":"2024-05-08T13:23:23+00:00","mainEntityOfPage":{"@id":"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/"},"wordCount":593,"commentCount":0,"publisher":{"@id":"https:\/\/www.couchbase.com\/blog\/#organization"},"image":{"@id":"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/#primaryimage"},"thumbnailUrl":"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/databricks-couchbase-spark-sql-scaled.jpg","keywords":["databricks","spark"],"articleSection":["Connectors","Couchbase Capella","Java","SQL++ \/ N1QL Query","Tools &amp; SDKs"],"inLanguage":"pt-BR","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/","url":"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/","name":"In\u00edcio r\u00e1pido: Couchbase com Apache Spark na Databricks","isPartOf":{"@id":"https:\/\/www.couchbase.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/#primaryimage"},"image":{"@id":"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/#primaryimage"},"thumbnailUrl":"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/databricks-couchbase-spark-sql-scaled.jpg","datePublished":"2022-09-27T19:14:50+00:00","dateModified":"2024-05-08T13:23:23+00:00","description":"Comece a usar rapidamente o Apache Spark SQL e muito mais usando o provedor Couchbase na plataforma Databricks.","breadcrumb":{"@id":"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/#breadcrumb"},"inLanguage":"pt-BR","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/"]}]},{"@type":"ImageObject","inLanguage":"pt-BR","@id":"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/#primaryimage","url":"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/databricks-couchbase-spark-sql-scaled.jpg","contentUrl":"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/1\/2022\/09\/databricks-couchbase-spark-sql-scaled.jpg","width":2560,"height":1610,"caption":"an overview of retrieval augmentation generation"},{"@type":"BreadcrumbList","@id":"https:\/\/www.couchbase.com\/blog\/databricks-couchbase-spark-sql-quickstart\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.couchbase.com\/blog\/"},{"@type":"ListItem","position":2,"name":"QuickStart: Couchbase with Apache Spark on Databricks"}]},{"@type":"WebSite","@id":"https:\/\/www.couchbase.com\/blog\/#website","url":"https:\/\/www.couchbase.com\/blog\/","name":"Blog do Couchbase","description":"Couchbase, o banco de dados NoSQL","publisher":{"@id":"https:\/\/www.couchbase.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.couchbase.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"pt-BR"},{"@type":"Organization","@id":"https:\/\/www.couchbase.com\/blog\/#organization","name":"Blog do Couchbase","url":"https:\/\/www.couchbase.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"pt-BR","@id":"https:\/\/www.couchbase.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/2023\/04\/admin-logo.png","contentUrl":"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/2023\/04\/admin-logo.png","width":218,"height":34,"caption":"The Couchbase Blog"},"image":{"@id":"https:\/\/www.couchbase.com\/blog\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/www.couchbase.com\/blog\/#\/schema\/person\/ecb4001e1e4b88a5c44d20c7bf39fcd3","name":"Rick Jacobs","image":{"@type":"ImageObject","inLanguage":"pt-BR","@id":"https:\/\/www.couchbase.com\/blog\/#\/schema\/person\/image\/398e492dda1c41103d3dfa60dfd80cfe","url":"https:\/\/secure.gravatar.com\/avatar\/4df9d5daa89732e9e520a2ded9e366daf2b32b5aea74313c561073fbc3784be9?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/4df9d5daa89732e9e520a2ded9e366daf2b32b5aea74313c561073fbc3784be9?s=96&d=mm&r=g","caption":"Rick Jacobs"},"description":"Rick Jacobs is the Technical Product Marketing Manager at Couchbase. His varied background includes experience at many of the world\u2019s leading organizations such as Computer Sciences Corporation, IBM, Cloudera etc. He comes with over 15 years of general technology experience garnered from serving in development, consulting, data science, sales engineering and technical marketing roles. He holds several academic degrees including an MS in Computational Science from George Mason University.","url":"https:\/\/www.couchbase.com\/blog\/pt\/author\/rick\/"}]}},"authors":[{"term_id":9208,"user_id":70772,"is_guest":0,"slug":"rick","display_name":"Rick Jacobs","avatar_url":"https:\/\/secure.gravatar.com\/avatar\/4df9d5daa89732e9e520a2ded9e366daf2b32b5aea74313c561073fbc3784be9?s=96&d=mm&r=g","author_category":"","last_name":"Jacobs","first_name":"Rick","job_title":"","user_url":"","description":"Rick Jacobs \u00e9 o gerente t\u00e9cnico de marketing de produtos da Couchbase.  Seu hist\u00f3rico variado inclui experi\u00eancia em muitas das principais organiza\u00e7\u00f5es do mundo, como Computer Sciences Corporation, IBM, Cloudera etc. Ele tem mais de 15 anos de experi\u00eancia em tecnologia geral, adquirida em fun\u00e7\u00f5es de desenvolvimento, consultoria, ci\u00eancia de dados, engenharia de vendas e marketing t\u00e9cnico.  Ele possui v\u00e1rios diplomas acad\u00eamicos, incluindo um mestrado em Ci\u00eancia da Computa\u00e7\u00e3o pela George Mason University."}],"_links":{"self":[{"href":"https:\/\/www.couchbase.com\/blog\/pt\/wp-json\/wp\/v2\/posts\/13763","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.couchbase.com\/blog\/pt\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.couchbase.com\/blog\/pt\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.couchbase.com\/blog\/pt\/wp-json\/wp\/v2\/users\/70772"}],"replies":[{"embeddable":true,"href":"https:\/\/www.couchbase.com\/blog\/pt\/wp-json\/wp\/v2\/comments?post=13763"}],"version-history":[{"count":0,"href":"https:\/\/www.couchbase.com\/blog\/pt\/wp-json\/wp\/v2\/posts\/13763\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.couchbase.com\/blog\/pt\/wp-json\/wp\/v2\/media\/13769"}],"wp:attachment":[{"href":"https:\/\/www.couchbase.com\/blog\/pt\/wp-json\/wp\/v2\/media?parent=13763"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.couchbase.com\/blog\/pt\/wp-json\/wp\/v2\/categories?post=13763"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.couchbase.com\/blog\/pt\/wp-json\/wp\/v2\/tags?post=13763"},{"taxonomy":"author","embeddable":true,"href":"https:\/\/www.couchbase.com\/blog\/pt\/wp-json\/wp\/v2\/ppma_author?post=13763"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}