You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Next »

This document details the internals of how the sqoop-server works.

This document is relevant to the release 1.99.5. Further changes can happen in future releases

Sqoop Tomcat Server

  • Sqoop-server uses tomcat web server, it is very bare bones.
  • The main entry point is the TomcatToolRunner, it bootstraps the tomcat and loads all the sqoop related classes into its class path.  It is invoked from the bash script .

    /sqoop.sh server start 
  • The main hook for the sqoop server to start is this entry in the web.xml. Tomcat invokes it callbacks as it bootstraps and we use the contextInitialized callback to initialize all the related code.

 

   <!-- Listeners -->
   <listener>
    <listener-class>org.apache.sqoop.server.ServerInitializer</listener-class>
  </listener>

 

Sqoop Server

 

SqoopServer.initialize() is the main entry point.

Sqoop Servlets

 

There are a bunch of servlets in web.xml : https://github.com/apache/sqoop/blob/sqoop2/server/src/main/webapp/WEB-INF/web.xml

They receive the requests and process it. Each Servlet has its corresponding handler class that handles the request for that servlet. It then internally calls the internal sqoop core/ common code.

Sqoop Request Handlers

 

They receive the requests and process it. Each Servlet has its corresponding handler class that handles the request for that servlet. It then internally calls the internal sqoop core/ common code.

All the rest APIs supported via the sqoop-server are documented here: http://sqoop.apache.org/docs/1.99.4/RESTAPI.html#id1

Sqoop Client

There is also the Sqoop-client that used to invoke the Sqoop-server methods via the jersey REST client, Recently it was switched to Hadoop-auth for adding Kerberos support that are documented herehttps://cwiki.apache.org/confluence/display/SQOOP/Security+Guide+On+Sqoop+2

  • No labels