|
30 | 30 | import org.apache.hadoop.util.JsonSerialization; |
31 | 31 | import org.apache.hadoop.util.Timer; |
32 | 32 |
|
33 | | -import static org.apache.hadoop.hdfs.client.HdfsClientConfigKeys.OAUTH_CLIENT_ID_KEY; |
34 | | -import static org.apache.hadoop.hdfs.client.HdfsClientConfigKeys.OAUTH_REFRESH_URL_KEY; |
35 | | -import static org.apache.hadoop.hdfs.web.oauth2.OAuth2Constants.ACCESS_TOKEN; |
36 | | -import static org.apache.hadoop.hdfs.web.oauth2.OAuth2Constants.CLIENT_CREDENTIALS; |
37 | | -import static org.apache.hadoop.hdfs.web.oauth2.OAuth2Constants.CLIENT_ID; |
38 | | -import static org.apache.hadoop.hdfs.web.oauth2.OAuth2Constants.CLIENT_SECRET; |
39 | | -import static org.apache.hadoop.hdfs.web.oauth2.OAuth2Constants.EXPIRES_IN; |
40 | | -import static org.apache.hadoop.hdfs.web.oauth2.OAuth2Constants.GRANT_TYPE; |
41 | | -import static org.apache.hadoop.hdfs.web.oauth2.Utils.notNull; |
42 | | - |
43 | 33 | import org.apache.http.HttpEntity; |
44 | 34 | import org.apache.http.HttpStatus; |
45 | 35 | import org.apache.http.client.config.RequestConfig; |
|
52 | 42 | import org.apache.http.impl.client.HttpClientBuilder; |
53 | 43 | import org.apache.http.message.BasicNameValuePair; |
54 | 44 |
|
| 45 | +import static org.apache.hadoop.hdfs.client.HdfsClientConfigKeys.OAUTH_CLIENT_ID_KEY; |
| 46 | +import static org.apache.hadoop.hdfs.client.HdfsClientConfigKeys.OAUTH_REFRESH_URL_KEY; |
| 47 | +import static org.apache.hadoop.hdfs.web.oauth2.OAuth2Constants.ACCESS_TOKEN; |
| 48 | +import static org.apache.hadoop.hdfs.web.oauth2.OAuth2Constants.CLIENT_CREDENTIALS; |
| 49 | +import static org.apache.hadoop.hdfs.web.oauth2.OAuth2Constants.CLIENT_ID; |
| 50 | +import static org.apache.hadoop.hdfs.web.oauth2.OAuth2Constants.CLIENT_SECRET; |
| 51 | +import static org.apache.hadoop.hdfs.web.oauth2.OAuth2Constants.EXPIRES_IN; |
| 52 | +import static org.apache.hadoop.hdfs.web.oauth2.OAuth2Constants.GRANT_TYPE; |
| 53 | +import static org.apache.hadoop.hdfs.web.oauth2.Utils.notNull; |
| 54 | + |
55 | 55 | /** |
56 | 56 | * Obtain an access token via the credential-based OAuth2 workflow. This |
57 | 57 | * abstract class requires only that implementations provide the credential, |
|
0 commit comments