[KYUUBI #5991] Error on reading Atlas properties composed of multi values
# 🔍 Description ## Issue References 🔗 This pull request fixes # ## Describe Your Solution 🔧 Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change. ## Types of changes 🔖 - [x] Bugfix (non-breaking change which fixes an issue) - [ ] New feature (non-breaking change which adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to change) ## Test Plan 🧪 #### Behavior Without This Pull Request ⚰️ #### Behavior With This Pull Request 🎉 #### Related Unit Tests --- # Checklist 📝 - [ ] This patch was not authored or co-authored using [Generative Tooling](https://www.apache.org/legal/generative-tooling.html) **Be nice. Be informative.** Closes #5993 from SwordyZhao/fix-issues-5991. Closes #5991 827007d06 [swordy_zhao] run dev/reformat fix code style. 600363dd9 [swordy_zhao] delete scala.List,Convert a java.List to scala.List 7b000e94a [swordy_zhao] fix 5991--kyuubi failed to read atlas.rest.address 5de05764e [swordy_zhao] fix 5991--kyuubi failed to read atlas.rest.address Authored-by: swordy_zhao <swordy_work@163.com> Signed-off-by: Cheng Pan <chengpan@apache.org>
This commit is contained in:
parent
5ef4390b23
commit
97f7987689
@ -17,6 +17,10 @@
|
||||
|
||||
package org.apache.kyuubi.plugin.lineage.dispatcher.atlas
|
||||
|
||||
import java.util
|
||||
|
||||
import scala.collection.JavaConverters._
|
||||
|
||||
import org.apache.atlas.ApplicationProperties
|
||||
import org.apache.commons.configuration.Configuration
|
||||
import org.apache.spark.kyuubi.lineage.SparkContextHelper
|
||||
@ -26,7 +30,7 @@ class AtlasClientConf(configuration: Configuration) {
|
||||
def get(entry: ConfigEntry): String = {
|
||||
configuration.getProperty(entry.key) match {
|
||||
case s: String => s
|
||||
case l: List[_] => l.mkString(",")
|
||||
case jl: util.List[_] => jl.asScala.mkString(",")
|
||||
case o if o != null => o.toString
|
||||
case _ => entry.defaultValue
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user