File tree Expand file tree Collapse file tree 3 files changed +10
-6
lines changed
databricks-sdk-java/src/main/java/com/databricks/sdk/core Expand file tree Collapse file tree 3 files changed +10
-6
lines changed Original file line number Diff line number Diff line change 11# NEXT CHANGELOG
22
3- ## Release v0.68.0
3+ ## Release v0.67.1
44
55### New Features and Improvements
66
7+ * Add a new config attribute ` DATABRICKS_DISABLE_OAUTH_REFRESH_TOKEN ` to disable requesting
8+ refresh tokens by default (by adding the ` offline_access ` scope) in OAuth exchanges. This
9+ option does not remove the scope from the user provided scopes if present.
10+
711### Bug Fixes
812
913### Documentation
Original file line number Diff line number Diff line change @@ -176,9 +176,9 @@ public class DatabricksConfig {
176176 private Duration oauthBrowserAuthTimeout ;
177177
178178 /**
179- * Disable automatically adding the offline_access scope to the OAuth authentication
180- * request to request refresh tokens. Note that this does not remove the scope if it
181- * is explicitly provided by the user.
179+ * Disable automatically adding the offline_access scope to the OAuth authentication request to
180+ * request refresh tokens. Note that this does not remove the scope if it is explicitly provided
181+ * by the user.
182182 */
183183 @ ConfigAttribute (env = "DATABRICKS_DISABLE_OAUTH_REFRESH_TOKEN" )
184184 private Boolean disableOauthRefreshToken ;
Original file line number Diff line number Diff line change 77import java .nio .file .Path ;
88import java .util .ArrayList ;
99import java .util .HashSet ;
10+ import java .util .List ;
1011import java .util .Objects ;
1112import java .util .Optional ;
12- import java .util .List ;
1313import java .util .Set ;
1414import org .slf4j .Logger ;
1515import org .slf4j .LoggerFactory ;
@@ -110,7 +110,7 @@ protected List<String> getScopes(DatabricksConfig config) {
110110 // Get user-provided scopes and add required default scopes.
111111 Set <String > scopes = new HashSet <>(config .getScopes ());
112112 // Requesting a refresh token is most of the time the right thing to do to enable
113- // long-lived access to the API. However, some Identity Providers do not support
113+ // long-lived access to the API. However, some Identity Providers do not support
114114 // refresh tokens.
115115 if (!config .getDisableOauthRefreshToken ()) {
116116 scopes .add ("offline_access" );
You can’t perform that action at this time.
0 commit comments