• labarai_banner

Sabis

Injin tsaftace bayanan Spark Streaming
(I) DStream da RDD
Kamar yadda muka sani, lissafin Spark Streaming yana dogara ne akan Spark Core, kuma ainihin Spark Core shine RDD, don haka Spark Streaming dole ne ya kasance yana da alaƙa da RDD shima.Koyaya, Spark Streaming baya barin masu amfani suyi amfani da RDD kai tsaye, amma abstracts saitin ra'ayoyin DStream, DStream da RDD alaƙa ce mai haɗa kai, zaku iya fahimtar ta azaman tsarin ado a Java, wato, DStream haɓaka RDD ne, amma Halin yayi kama da RDD.
DStream da RDD duka suna da sharuɗɗa da yawa.
(1) suna da ayyuka iri ɗaya na canji, kamar taswira, rageByKey, da sauransu, amma kuma wasu na musamman, kamar Window, mapWithStated, da sauransu.
(2) duk suna da Ayyukan Aiki, kamar foreachRDD, ƙidaya, da sauransu.
Samfurin shirye-shirye yana da daidaituwa.
(B) Gabatarwar DStream a cikin Spark Streaming
DStream ya ƙunshi azuzuwan da yawa.
(1) Azuzuwan tushen bayanai, kamar InputDStream, musamman kamar DirectKafkaInputStream, da sauransu.
(2) Azuzuwan juyi, yawanci MappedDStream, ShuffledDStream
(3) azuzuwan fitarwa, yawanci kamar ForEachDStream
Daga abin da ke sama, bayanan daga farkon (shigarwa) zuwa ƙarshe (fitarwa) ana yin su ta hanyar tsarin DStream, wanda ke nufin cewa mai amfani kullum ba zai iya samar da kai tsaye da sarrafa RDDs ba, wanda ke nufin cewa DStream yana da damar da wajibcin zama. alhakin tsarin rayuwa na RDDs.
A takaice dai, Spark Streaming yana datsaftacewa ta atomatikaiki.
(iii) Tsarin tsarar RDD a cikin Spark Streaming
Gudun rayuwar RDDs a cikin Spark Streaming yana da wahala kamar haka.
(1) A cikin InputDStream, ana canza bayanan da aka karɓa zuwa RDD, kamar DirectKafkaInputStream, wanda ke haifar da KafkaRDD.
(2) sannan ta hanyar MappedDStream da sauran canjin bayanai, wannan lokacin ana kiransa RDD kai tsaye daidai da hanyar taswira don juyawa.
(3) A cikin aikin aji na fitarwa, kawai lokacin da RDD ya fallasa, zaku iya barin mai amfani ya yi ma'ajin da ya dace, sauran lissafin, da sauran ayyuka.