Yicong-Huang commented on code in PR #7057:
URL: https://github.com/apache/texera/pull/7057#discussion_r3685604294
##########
amber/src/main/scala/org/apache/texera/web/ServletAwareConfigurator.scala:
##########
@@ -97,19 +90,11 @@ class ServletAwareConfigurator extends
ServerEndpointConfig.Configurator with La
val claims = jwtConsumer.process(token).getJwtClaims
config.getUserProperties.put(
classOf[User].getName,
- new User(
- claims.getClaimValue("userId").asInstanceOf[Long].toInt,
- claims.getSubject,
-
String.valueOf(claims.getClaimValue("email").asInstanceOf[String]),
- null,
- null,
- null,
- null,
- null,
- null,
- null,
- null
- )
+ new User().tap { user =>
+
user.setUid(claims.getClaimValue("userId").asInstanceOf[Long].toInt)
+ user.setName(claims.getSubject)
+
user.setEmail(claims.getClaimValue("email").asInstanceOf[String])
Review Comment:
nvm, this is for JWT, not for DB. we don't need a SQL script.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]