<?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>data lineage - Anjana Data</title>
	<atom:link href="https://anjanadata.com/en/tag/linaje-del-dato/feed/" rel="self" type="application/rss+xml" />
	<link>https://anjanadata.com/en</link>
	<description>Data Governance &amp; Analytics</description>
	<lastbuilddate>Fri, 04 Sep 2020 09:24:08 +0000</lastbuilddate>
	<language>en-GB</language>
	<sy:updateperiod>
	hourly	</sy:updateperiod>
	<sy:updatefrequency>
	1	</sy:updatefrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>

<image>
	<url>https://anjanadata.com/wp-content/uploads/2020/03/cropped-favicon_anjanadata-32x32.png</url>
	<title>data lineage - Anjana Data</title>
	<link>https://anjanadata.com/en</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>How to obtain a complete data lineage of Spark processes thanks to Anjana Data</title>
		<link>https://anjanadata.com/en/how-to-obtain-a-complete-data-lineage-of-spark-processes-thanks-to-anjana-data/</link>
					<comments>https://anjanadata.com/en/how-to-obtain-a-complete-data-lineage-of-spark-processes-thanks-to-anjana-data/#respond</comments>
		
		<dc:creator><![CDATA[Juan Sobrino]]></dc:creator>
		<pubdate>Fri, 04 Sep 2020 09:24:08 +0000</pubdate>
				<category><![CDATA[Gobierno del dato]]></category>
		<category><![CDATA[gobierno del dato]]></category>
		<category><![CDATA[linaje del dato]]></category>
		<guid ispermalink="false">https://anjanadata.com/?p=3484</guid>

					<description><![CDATA[Knowing the lineage of data is very important from a data governance point of view: Knowing how information flows throughout the organisation Understanding the data value chain and its processes Knowing the lifecycle of data assets and how [...]]]></description>
										<content:encoded><![CDATA[<h3><img fetchpriority="high" decoding="async" class="aligncenter wp-image-3492 size-full" src="https://anjanadata.com/wp-content/uploads/2020/09/linaje-de-datos-1.png" alt="" width="1024" height="512" srcset="https://anjanadata.com/wp-content/uploads/2020/09/linaje-de-datos-1.png 1024w, https://anjanadata.com/wp-content/uploads/2020/09/linaje-de-datos-1-300x150.png 300w, https://anjanadata.com/wp-content/uploads/2020/09/linaje-de-datos-1-768x384.png 768w" sizes="(max-width: 1024px) 100vw, 1024px" /></h3>
<p>&nbsp;</p>
<p><span style="font-weight: 400;">Knowing the lineage of data is very important from a data governance perspective in order to:</span></p>
<ul>
<li style="font-weight: 400;"><span style="font-weight: 400;">Knowing how information flows throughout the organisation</span></li>
<li style="font-weight: 400;"><span style="font-weight: 400;">Understanding the data value chain and its processes</span></li>
<li style="font-weight: 400;"><span style="font-weight: 400;">Understanding the lifecycle of data assets and how they are being generated</span></li>
<li style="font-weight: 400;"><span style="font-weight: 400;">Visualise dependencies between data assets and processes to manage the potential impacts generated by changes and modifications.</span></li>
<li style="font-weight: 400;"><span style="font-weight: 400;">Facilitate the search for process errors, quality issues, service degradation, etc.</span></li>
</ul>
<p><span style="font-weight: 400;">The <strong>data lineage</strong> It comes in many forms, and perhaps one of the best known is the technical lineage. That is, knowing, from a technical point of view, how data moves from one place to another through the processes that are executed on it, either automatically or manually.</span></p>
<p><span style="font-weight: 400;">However, it should be noted that, even though this is technical lineage, this information must be useful for data governance. Thus, for lineage information to be valuable, it must be interpretable, and in the vast majority of cases, a string of activity logs spewed out by a machine is of little use. That is why it is most common for technical lineage to have to be captured, interpreted, and translated in order to be of any use.</span></p>
<h3><b>Obtaining the lineage</b></h3>
<p><span style="font-weight: 400;">In this context, in order to obtain the technical lineage of the processes that move data from one site to another, we can rely on several techniques:</span></p>
<ul>
<li style="font-weight: 400;"><span style="font-weight: 400;">Extract lineage through the identification or inference of relationships between objects, which are declared in the form of metadata: This is typically the case with ETLs that operate with parameters and define all the processes to be executed by metadata.</span></li>
<li style="font-weight: 400;"><span style="font-weight: 400;">Extracting lineage through source code parsing: This is no easy task, and its complexity depends greatly on both the programming language (SQL is not the same as Java) and the programmer who wrote the code (depending on the functions, methods, or variables used). Given that we are entering murky waters here and could encounter anything, the only certainty is that the guarantee that can be offered in these situations is usually very low and, in the vast majority of cases, a significant gap must be assumed.</span></li>
<li style="font-weight: 400;"><span style="font-weight: 400;">Extracting lineage from the recovery and interpretation of audit logs: This is what we at Anjana Data call dynamic lineage, and in many cases it is the only way to obtain the most complete trace possible, even though you will only be able to capture what is executed. To implement this, you need to carry out native integration with data platforms and technologies to understand how logs work, know where and how to retrieve them, and finally be able to interpret the captured information, which usually has to be translated to be valuable.</span></li>
</ul>
<p><span style="font-weight: 400;">Furthermore, given the variability of languages, platforms, technologies, etc., the spectrum we encounter becomes too broad to cover completely. That is why, when we talk about lineage, we usually have to seek compromises and apply Pareto's Law, especially in certain specific scenarios.</span></p>
<h3><b>Spark and the data lineage</b></h3>
<p><span style="font-weight: 400;">As we have already seen, not all data processing technologies make it easy for us to obtain the internal lineage of their processes, and among all of them, Spark is one of the most complex.</span></p>
<p><span style="font-weight: 400;">Spark is an open-source distributed processing technology that offers greater use of the possibilities of distributed data clusters. As it is an open-source project, different distributions are available from various technology providers, such as:, <a href="https://es.cloudera.com/">Cloudera</a>, AWS EMR, GCP DataProc, or <a href="https://databricks.com/">Databricks</a>, the most famous of these, which is also offered natively by <a href="https://www.microsoft.com/es-es">Microsoft</a> in your Azure cloud.</span></p>
<p><span style="font-weight: 400;">One of Spark's most distinctive features is that it does not have its own storage, but rather uses the memory of the machines that make up the cluster where it runs and is capable of retrieving data from different types of storage, such as HDFS.</span><span style="font-weight: 400;">, S3, Cloud Storage, Blob Storage, etc., or streaming systems such as Kafka.</span></p>
<p><span style="font-weight: 400;">In this regard, Spark distributes tasks across the different nodes of the cluster during execution, using the memory and processors of the different machines. That is why, by its very definition, it seems difficult to obtain a complete trace of the processes executed that move or transform data. Furthermore, this is not something that is completely and natively resolved in any of the current implementations of Spark, as they are all designed and optimised for data processing and not for data governance.</span></p>
<p><span style="font-weight: 400;">When we talk about data governance and Spark appears in the picture as the technology involved, the vast majority of professionals throw up their hands in horror or assume there is a significant gap. Certainly, activating low-level log capture can provide us with a lot of information about processes, but it also penalises performance, so a compromise solution must be found.</span></p>
<h3><b>Obtaining Spark lineage with Anjana Data</b></h3>
<p><span style="font-weight: 400;">As we have seen, obtaining the trace of Spark processes is not an easy task, mainly for the following reasons:</span></p>
<ul>
<li style="font-weight: 400;"><span style="font-weight: 400;">Since it does not have its own storage, the metadata that can be obtained from Spark processes at rest is null. When not running, the most we can obtain is the metadata of the datasets that may participate in those processes as inputs or outputs, but we cannot know anything about what happens in between or how the output data is generated from the input data.</span></li>
<li style="font-weight: 400;"><span style="font-weight: 400;">The way Spark encodes the processing of datasets, whether in an RDD or a Spark Dataset, can be written in several languages (Scala, Java, Python) and operations can be masked according to the encoding. Therefore, parsing source code to obtain traces is not a viable option when it comes to Spark.</span></li>
<li style="font-weight: 400;"><span style="font-weight: 400;">The information that can be obtained from the execution logs is never complete or interpretable and depends largely on both the Spark distribution and the audit configuration. In many cases, the most that can be obtained is the input-output ratio at a rough level, or, on other occasions, the amount of logs to be interpreted will be unmanageable.</span></li>
</ul>
<p><span style="font-weight: 400;">However, thanks to Anjana Data's approach and implementation, you can get a very reliable picture at a granular level (field level and applied functions) that no other solution on the market is able to offer. How? We can't tell you everything, but we can give you a few brief glimpses. <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f642.png" alt="🙂" class="wp-smiley" style="height: 1em; max-height: 1em;" /></span></p>
<p><span style="font-weight: 400;">Essentially, what Anjana Data does is apply a combination of the three techniques mentioned above, intercepting each of the processes just before they are executed.</span></p>
<p><span style="font-weight: 400;">To execute processes, Spark creates an execution plan (DAG) before dividing the process into tasks that are launched in parallel. This is the only moment when all the information is available in a single point, just before it is distributed to all the elements responsible for its execution. By including a specific agent that is always invoked in each and every default execution, all this information can be captured and extracted with the required level of detail. Furthermore, all this can be done centrally and non-invasively, without the need for programmers to include anything in their processes.</span></p>
<p><span style="font-weight: 400;">Finally, all this information is processed and interpreted by one of the components of Anjana Data's architecture and then served to the solution's CORE, where it is cross-referenced with governed information to generate a lineage of valuable data that is made available to the end user.</span></p>
<p><span style="font-weight: 400;">Anjana Data can do this and much more... Want to find out more? </span></p>
<p><strong>Request a <a href="https://anjanadata.com/en/request-a-demo/">demonstration</a> and we'll tell you all about it!</strong></p>]]></content:encoded>
					
					<wfw:commentrss>https://anjanadata.com/en/how-to-obtain-a-complete-data-lineage-of-spark-processes-thanks-to-anjana-data/feed/</wfw:commentrss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>