Skip to content

Commit

Permalink
[FOLLOWUP] Disable rest api authentication, remove auth filter
Browse files Browse the repository at this point in the history
  • Loading branch information
wForget committed Mar 18, 2024
1 parent fbf076b commit 9ade789
Showing 1 changed file with 2 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,14 @@

package org.apache.kyuubi.server

import java.util.EnumSet
import java.util.concurrent.{Future, TimeUnit}
import java.util.concurrent.atomic.{AtomicBoolean, AtomicInteger}
import javax.servlet.DispatcherType
import javax.ws.rs.WebApplicationException
import javax.ws.rs.core.Response.Status

import com.google.common.annotations.VisibleForTesting
import org.apache.hadoop.conf.Configuration
import org.eclipse.jetty.servlet.{ErrorPageErrorHandler, FilterHolder}
import org.eclipse.jetty.servlet.ErrorPageErrorHandler

import org.apache.kyuubi.{KyuubiException, Utils}
import org.apache.kyuubi.config.KyuubiConf
Expand Down Expand Up @@ -101,11 +99,9 @@ class KyuubiRestFrontendService(override val serverable: Serverable)

private def startInternal(): Unit = {
val contextHandler = ApiRootResource.getServletHandler(this)
val holder = new FilterHolder(new AuthenticationFilter(conf))
contextHandler.addFilter(holder, "/v1/*", EnumSet.allOf(classOf[DispatcherType]))
val authenticationFactory = new KyuubiHttpAuthenticationFactory(conf)
server.addHandler(contextHandler)

val authenticationFactory = new KyuubiHttpAuthenticationFactory(conf)
val proxyHandler = ApiRootResource.getEngineUIProxyHandler(this)
server.addHandler(authenticationFactory.httpHandlerWrapperFactory.wrapHandler(proxyHandler))

Expand Down

0 comments on commit 9ade789

Please sign in to comment.