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

Compare with Current View Page History

« Previous Version 2 Next »

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

 

 

 

1. 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.
2. The main hook for the sqoop server to start is this entry in the web.xml. Tomcat invokes it callbacks as it bootups and we use the 

contextInitialized callback to initialize all the related code.

 <!-- Listeners -->

  <listener>

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

  </listener>

3. SqoopServer.initialize() is the main entry point.

4. 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.

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

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