-
Notifications
You must be signed in to change notification settings - Fork 145
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/cms backend #776
Feature/cms backend #776
Changes from 5 commits
3d624af
e140205
72c3d59
fcb08de
648cbde
26ce53c
64cf747
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<configuration > | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<configuration> | ||
<packageSources> | ||
<clear /> | ||
<add key="Nuget Preview" value="https://dotnet.myget.org/F/dotnet-core/api/v3/index.json" /> | ||
<add key="Nuget" value="https://www.nuget.org/api/v2" /> | ||
<add key="DataTools Nuget" value="./bin/nuget" /> | ||
<add key="DataTools Nuget" value="./bin/nuget" /> | ||
</packageSources> | ||
</configuration> |
Large diffs are not rendered by default.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,84 @@ | ||
// | ||
// Copyright (c) Microsoft. All rights reserved. | ||
// Licensed under the MIT license. See LICENSE file in the project root for full license information. | ||
// | ||
using Microsoft.SqlTools.ServiceLayer.Connection.Contracts; | ||
|
||
namespace Microsoft.SqlTools.ServiceLayer.Cms.Contracts | ||
{ | ||
/// <summary> | ||
/// Paramaters to create Top level Central Management Server | ||
/// </summary> | ||
public class CreateCentralManagementServerParams | ||
{ | ||
public string RegisteredServerName { get; set; } | ||
|
||
public string RegisterdServerDescription { get; set; } | ||
|
||
public ConnectParams ConnectParams { get; set; } | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. should this class derive from ConnectParams instead? |
||
} | ||
|
||
/// <summary> | ||
/// Parmaters to Add Registered Server to top level CMS | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. nit: There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ..note this same typo appears to have been copy\pasted a few times |
||
/// </summary> | ||
public class AddRegisteredServerParams | ||
{ | ||
public string RegisteredServerName { get; set; } | ||
|
||
public string RegisterdServerDescription { get; set; } | ||
|
||
public ConnectionDetails RegServerConnectionDetails { get; set; } | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. we should be consistent whether to use |
||
|
||
public string ParentOwnerUri { get; set; } | ||
|
||
public string RelativePath { get; set; } | ||
} | ||
|
||
/// <summary> | ||
/// Parmaters to Add Server Group to top level CMS | ||
/// </summary> | ||
public class AddServerGroupParams | ||
{ | ||
public string GroupName { get; set; } | ||
|
||
public string GroupDescription { get; set; } | ||
|
||
public string ParentOwnerUri { get; set; } | ||
|
||
public string RelativePath { get; set; } | ||
} | ||
|
||
/// <summary> | ||
/// Parmaters to Remove Server Group from CMS | ||
/// </summary> | ||
public class RemoveServerGroupParams | ||
{ | ||
public string GroupName { get; set; } | ||
|
||
public string ParentOwnerUri { get; set; } | ||
|
||
public string RelativePath { get; set; } | ||
} | ||
|
||
/// <summary> | ||
/// Paramaters to remove a Registered Server from CMS tree | ||
/// </summary> | ||
public class RemoveRegisteredServerParams | ||
{ | ||
public string RegisteredServerName { get; set; } | ||
|
||
public string ParentOwnerUri { get; set; } | ||
|
||
public string RelativePath { get; set; } | ||
} | ||
|
||
/// <summary> | ||
/// Paramaters to list a Registered Server from CMS tree | ||
/// </summary> | ||
public class ListRegisteredServerParams | ||
{ | ||
public string ParentOwnerUri { get; set; } | ||
|
||
public string RelativePath { get; set; } | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
// | ||
// Copyright (c) Microsoft. All rights reserved. | ||
// Licensed under the MIT license. See LICENSE file in the project root for full license information. | ||
// | ||
using Microsoft.SqlTools.Hosting.Protocol.Contracts; | ||
using Microsoft.SqlTools.ServiceLayer.Connection.Contracts; | ||
|
||
namespace Microsoft.SqlTools.ServiceLayer.Cms.Contracts | ||
{ | ||
|
||
public class CreateCentralManagementServerRequest | ||
{ | ||
public static readonly RequestType<CreateCentralManagementServerParams, ListRegisteredServersResult> Type = | ||
RequestType<CreateCentralManagementServerParams, ListRegisteredServersResult>.Create("cms/createCms"); | ||
} | ||
|
||
public class ListRegisteredServerRequest | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. should this be |
||
{ | ||
public static readonly RequestType<ListRegisteredServerParams, ListRegisteredServersResult> Type = | ||
RequestType<ListRegisteredServerParams, ListRegisteredServersResult>.Create("cms/listRegServers"); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'd write out RegisteredServers completely in the JSON-RPC method names. |
||
} | ||
|
||
public class AddRegisteredServerRequest | ||
{ | ||
public static readonly RequestType<AddRegisteredServerParams, bool> Type = | ||
RequestType<AddRegisteredServerParams, bool>.Create("cms/addRegServers"); | ||
} | ||
|
||
public class AddServerGroupRequest | ||
{ | ||
public static readonly RequestType<AddServerGroupParams, bool> Type = | ||
RequestType<AddServerGroupParams, bool>.Create("cms/addCmsServerGroup"); | ||
} | ||
|
||
public class RemoveServerGroupRequest | ||
{ | ||
public static readonly RequestType<RemoveServerGroupParams, bool> Type = | ||
RequestType<RemoveServerGroupParams, bool>.Create("cms/removeCmsServerGroup"); | ||
} | ||
|
||
public class RemoveRegisteredServerRequest | ||
{ | ||
public static readonly RequestType<RemoveRegisteredServerParams, bool> Type = | ||
RequestType<RemoveRegisteredServerParams, bool>.Create("cms/removeRegServers"); | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
// | ||
// Copyright (c) Microsoft. All rights reserved. | ||
// Licensed under the MIT license. See LICENSE file in the project root for full license information. | ||
// | ||
using Microsoft.SqlTools.ServiceLayer.Connection.Contracts; | ||
using System.Collections.Generic; | ||
|
||
namespace Microsoft.SqlTools.ServiceLayer.Cms.Contracts | ||
{ | ||
public class ListRegisteredServersResult | ||
{ | ||
public List<RegisteredServerResult> RegisteredServersList { get; set; } | ||
|
||
public List<RegisteredServerGroup> RegisteredServerGroups { get; set; } | ||
} | ||
|
||
public class RegisteredServerResult | ||
{ | ||
public string Name { get; set; } | ||
|
||
public string ServerName { get; set; } | ||
|
||
public string Description { get; set; } | ||
|
||
public string RelativePath { get; set; } | ||
|
||
public ConnectionDetails connectionDetails { get; set; } | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
} | ||
|
||
public class RegisteredServerGroup | ||
{ | ||
public string Name { get; set; } | ||
|
||
public string Description { get; set; } | ||
|
||
public string RelativePath { get; set; } | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
small typo: RegisteredServerDescription