class Azure::BaseManagement::SqlManagementHttpRequest
This class is used for communicating with the Management certificate authentication API endpoint
Attributes
uri[RW]
Public Class Methods
new(method, path, body = nil)
click to toggle source
Public: Creates the ManagementHttpRequest
method - Symbol. The HTTP method to use (:get, :post, :put, :del, etc…) path - URI. The URI of the HTTP endpoint to query body - IO or String
. The request body (optional)
Calls superclass method
Azure::BaseManagement::ManagementHttpRequest::new
# File lib/azure/base_management/sql_management_http_request.rb, line 27 def initialize(method, path, body = nil) if sql_endpoint? super(method, path, body) @headers['x-ms-version'] = '1.0' @uri = URI.parse(Azure.config.sql_database_management_endpoint + Azure.config.subscription_id + path) else path = "/services/sqlservers#{path}" super(method, path, body) end end
Private Instance Methods
sql_endpoint?()
click to toggle source
# File lib/azure/base_management/sql_management_http_request.rb, line 40 def sql_endpoint? Azure.config.sql_database_authentication_mode == :sql_server end