Skip to content

Commit

Permalink
remove the cosmos.permisssions properties and set the default connect…
Browse files Browse the repository at this point in the history
…ion mode to direct
  • Loading branch information
saragluna committed Feb 22, 2022
1 parent c8a7610 commit ce17d3e
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 19 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -78,10 +78,6 @@ public class AzureCosmosProperties extends AbstractAzureServiceConfigurationProp
* Whether to allow for reads to go to multiple regions configured on an account of Azure Cosmos DB service.
*/
private Boolean readRequestsFallbackEnabled;
/**
* Permission list which contains the resource tokens needed to access resources.
*/
private final List<CosmosPermissionProperties> permissions = new ArrayList<>();
/**
* Preferred regions for geo-replicated database accounts. For example, "East US" as the preferred region.
*/
Expand All @@ -97,7 +93,7 @@ public class AzureCosmosProperties extends AbstractAzureServiceConfigurationProp
/**
* Connection mode to be used by the client in the Azure Cosmos DB database service.
*/
private ConnectionMode connectionMode;
private ConnectionMode connectionMode = ConnectionMode.DIRECT;

@NestedConfigurationProperty
private final GatewayConnectionConfig gatewayConnection = new GatewayConnectionConfig();
Expand Down Expand Up @@ -201,10 +197,6 @@ public void setReadRequestsFallbackEnabled(Boolean readRequestsFallbackEnabled)
this.readRequestsFallbackEnabled = readRequestsFallbackEnabled;
}

public List<CosmosPermissionProperties> getPermissions() {
return permissions;
}

public List<String> getPreferredRegions() {
return preferredRegions;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,12 +75,6 @@ public interface CosmosClientProperties extends AzureProperties, KeyAware {
*/
Boolean getReadRequestsFallbackEnabled();

/**
* Get the cosmos client permission properties list.
* @return the cosmos client permission properties list.
*/
List<CosmosPermissionProperties> getPermissions();

/**
* Get the cosmos client preferred regions.
* @return the cosmos client preferred regions.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -135,10 +135,6 @@ public void setReadRequestsFallbackEnabled(Boolean readRequestsFallbackEnabled)
this.readRequestsFallbackEnabled = readRequestsFallbackEnabled;
}

public List<CosmosPermissionProperties> getPermissions() {
return permissions;
}

public List<String> getPreferredRegions() {
return preferredRegions;
}
Expand Down

0 comments on commit ce17d3e

Please sign in to comment.