[mapguide-commits] r8446 - in trunk/Tools/Maestro: . MaestroAPITestRunner MaestroAPITests OSGeo.MapGuide.MaestroAPI.Http
svn_mapguide at osgeo.org
svn_mapguide at osgeo.org
Thu Nov 13 23:09:51 PST 2014
Author: jng
Date: 2014-11-13 23:09:50 -0800 (Thu, 13 Nov 2014)
New Revision: 8446
Removed:
trunk/Tools/Maestro/Maestro.AddIn.GeoRest/
Modified:
trunk/Tools/Maestro/MaestroAPITestRunner/TestMaestroAPI.LocalNative.xml
trunk/Tools/Maestro/MaestroAPITestRunner/TestMaestroAPI.xml
trunk/Tools/Maestro/MaestroAPITests/MaestroAPITests.csproj
trunk/Tools/Maestro/MaestroAPITests/TestControl.cs
trunk/Tools/Maestro/OSGeo.MapGuide.MaestroAPI.Http/HttpCapabilities.cs
trunk/Tools/Maestro/OSGeo.MapGuide.MaestroAPI.Http/HttpServerConnection.cs
trunk/Tools/Maestro/OSGeo.MapGuide.MaestroAPI.Http/OSGeo.MapGuide.MaestroAPI.Http.csproj
Log:
#2502: Remove GeoREST support
Modified: trunk/Tools/Maestro/MaestroAPITestRunner/TestMaestroAPI.LocalNative.xml
===================================================================
--- trunk/Tools/Maestro/MaestroAPITestRunner/TestMaestroAPI.LocalNative.xml 2014-11-14 06:45:40 UTC (rev 8445)
+++ trunk/Tools/Maestro/MaestroAPITestRunner/TestMaestroAPI.LocalNative.xml 2014-11-14 07:09:50 UTC (rev 8446)
@@ -37,14 +37,6 @@
The password for the MapGuide user account for running the HTTP provider tests under
-->
<HttpPassword>admin</HttpPassword>
- <!--
- The URL for the GeoREST endpoint for running the HTTP provider tests with GeoREST support
- -->
- <GeoRestUrl>http://localhost:99/</GeoRestUrl>
- <!--
- The path to the GeoREST test configuration file, needed by this GeoREST test suite
- -->
- <GeoRestConfig>UserTestData\GeoRestConfig.xml</GeoRestConfig>
</TestSettings>
<TestControl>
<!-- Core API -->
@@ -69,7 +61,5 @@
<IgnoreLocalNativeRuntimeMapTests>false</IgnoreLocalNativeRuntimeMapTests>
<IgnoreLocalNativePerformanceTests>false</IgnoreLocalNativePerformanceTests>
<IgnoreLocalNativeFeatureTests>false</IgnoreLocalNativeFeatureTests>
- <!-- GeoREST disabled because not every MapGuide installation has it installed -->
- <IgnoreGeoRestTests>true</IgnoreGeoRestTests>
</TestControl>
</TestConfiguration>
\ No newline at end of file
Modified: trunk/Tools/Maestro/MaestroAPITestRunner/TestMaestroAPI.xml
===================================================================
--- trunk/Tools/Maestro/MaestroAPITestRunner/TestMaestroAPI.xml 2014-11-14 06:45:40 UTC (rev 8445)
+++ trunk/Tools/Maestro/MaestroAPITestRunner/TestMaestroAPI.xml 2014-11-14 07:09:50 UTC (rev 8446)
@@ -36,14 +36,6 @@
The password for the MapGuide user account for running the HTTP provider tests under
-->
<HttpPassword>admin</HttpPassword>
- <!--
- The URL for the GeoREST endpoint for running the HTTP provider tests with GeoREST support
- -->
- <GeoRestUrl>http://localhost:99/</GeoRestUrl>
- <!--
- The path to the GeoREST test configuration file, needed by this GeoREST test suite
- -->
- <GeoRestConfig>UserTestData\GeoRestConfig.xml</GeoRestConfig>
</TestSettings>
<TestControl>
<!-- Core API -->
@@ -72,7 +64,5 @@
<IgnoreLocalNativeRuntimeMapTests>true</IgnoreLocalNativeRuntimeMapTests>
<IgnoreLocalNativePerformanceTests>true</IgnoreLocalNativePerformanceTests>
<IgnoreLocalNativeFeatureTests>true</IgnoreLocalNativeFeatureTests>
- <!-- GeoREST disabled because not every MapGuide installation has it installed -->
- <IgnoreGeoRestTests>true</IgnoreGeoRestTests>
</TestControl>
</TestConfiguration>
\ No newline at end of file
Modified: trunk/Tools/Maestro/MaestroAPITests/MaestroAPITests.csproj
===================================================================
--- trunk/Tools/Maestro/MaestroAPITests/MaestroAPITests.csproj 2014-11-14 06:45:40 UTC (rev 8445)
+++ trunk/Tools/Maestro/MaestroAPITests/MaestroAPITests.csproj 2014-11-14 07:09:50 UTC (rev 8446)
@@ -84,7 +84,6 @@
<Compile Include="ConnectionTestBase.cs" />
<Compile Include="ExpressionTests.cs" />
<Compile Include="FeatureReaderTests.cs" />
- <Compile Include="GeoRestTests.cs" />
<Compile Include="HttpConnectionTests.cs" />
<Compile Include="HttpSiteTests.cs" />
<Compile Include="LocalConnectionTests.cs" />
@@ -568,9 +567,6 @@
<Content Include="UserTestData\TestDuplicateLayerIds.xml">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
- <Content Include="UserTestData\GeoRestConfig.xml">
- <CopyToOutputDirectory>Always</CopyToOutputDirectory>
- </Content>
<Content Include="UserTestData\NASA_WMS_config_doc.xml">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
Modified: trunk/Tools/Maestro/MaestroAPITests/TestControl.cs
===================================================================
--- trunk/Tools/Maestro/MaestroAPITests/TestControl.cs 2014-11-14 06:45:40 UTC (rev 8445)
+++ trunk/Tools/Maestro/MaestroAPITests/TestControl.cs 2014-11-14 07:09:50 UTC (rev 8446)
@@ -38,9 +38,6 @@
public static string HttpUsername = "Administrator";
public static string HttpPassword = "admin";
- public static string GeoRestUrl = "http://localhost:99/";
- public static string GeoRestConfig = "UserTestData\\GeoRestConfig.xml";
-
public static void Initialize(string initFile)
{
if (File.Exists(initFile))
@@ -65,10 +62,6 @@
TestEnvironment.HttpUsername = settings["HttpUsername"].InnerText;
if (settings["HttpPassword"] != null)
TestEnvironment.HttpPassword = settings["HttpPassword"].InnerText;
- if (settings["GeoRestUrl"] != null)
- TestEnvironment.GeoRestUrl = settings["GeoRestUrl"].InnerText;
- if (settings["GeoRestConfig"] != null)
- TestEnvironment.GeoRestConfig = settings["GeoRestConfig"].InnerText;
}
var control = doc.SelectSingleNode("//TestConfiguration/TestControl");
if (control != null)
@@ -99,8 +92,6 @@
TestControl.IgnoreLocalNativePerformanceTests = control["IgnoreLocalNativePerformanceTests"].InnerText == "true";
if (control["IgnoreLocalNativeFeatureTests"] != null)
TestControl.IgnoreLocalNativeFeatureTests = control["IgnoreLocalNativeFeatureTests"].InnerText == "true";
- if (control["IgnoreGeoRestTests"] != null)
- TestControl.IgnoreGeoRestTests = control["IgnoreGeoRestTests"].InnerText == "true";
if (control["IgnoreLocalFeatureTests"] != null)
TestControl.IgnoreLocalFeatureTests = control["IgnoreLocalFeatureTests"].InnerText == "true";
if (control["IgnoreSchemaTests"] != null)
@@ -125,8 +116,6 @@
Console.WriteLine("HttpUrl = {0}", TestEnvironment.HttpUrl);
Console.WriteLine("HttpUsername = {0}", TestEnvironment.HttpUsername);
Console.WriteLine("HttpPassword = {0}", TestEnvironment.HttpPassword);
- Console.WriteLine("GeoRestUrl = {0}", TestEnvironment.GeoRestUrl);
- Console.WriteLine("GeoRestConfig = {0}", TestEnvironment.GeoRestConfig);
Console.WriteLine("********************** Test Control **************************");
Console.WriteLine("IgnoreConfigurationTests = {0}", TestControl.IgnoreConfigurationTests);
Console.WriteLine("IgnoreCapabilityTests = {0}", TestControl.IgnoreCapabilityTests);
@@ -141,7 +130,6 @@
Console.WriteLine("IgnoreLocalNativeRuntimeMapTests = {0}", TestControl.IgnoreLocalNativeRuntimeMapTests);
Console.WriteLine("IgnoreLocalNativePerformanceTests = {0}", TestControl.IgnoreLocalNativePerformanceTests);
Console.WriteLine("IgnoreLocalNativeFeatureTests = {0}", TestControl.IgnoreLocalNativeFeatureTests);
- Console.WriteLine("IgnoreGeoRestTests = {0}", TestControl.IgnoreGeoRestTests);
Console.WriteLine("IgnoreLocalFeatureTests = {0}", TestControl.IgnoreLocalFeatureTests);
Console.WriteLine("IgnoreSchemaTests = {0}", TestControl.IgnoreSchemaTests);
Console.WriteLine("IgnoreSerializationTests = {0}", TestControl.IgnoreSerializationTests);
@@ -165,7 +153,6 @@
public static bool IgnoreLocalNativeRuntimeMapTests = true;
public static bool IgnoreLocalNativePerformanceTests = true;
public static bool IgnoreLocalNativeFeatureTests = true;
- public static bool IgnoreGeoRestTests = true;
public static bool IgnoreLocalFeatureTests = false;
public static bool IgnoreSchemaTests = false;
public static bool IgnoreSerializationTests = false;
@@ -188,16 +175,6 @@
return ConnectionProviderRegistry.CreateConnection("Maestro.Local", "ConfigFile", TestEnvironment.LocalConfigFile);
}
- public static IServerConnection CreateTestHttpConnectionWithGeoRest()
- {
- return ConnectionProviderRegistry.CreateConnection("Maestro.Http",
- "Url", TestEnvironment.HttpUrl,
- "Username", TestEnvironment.HttpUsername,
- "Password", TestEnvironment.HttpPassword,
- "GeoRestUrl", TestEnvironment.GeoRestUrl,
- "GeoRestConfigPath", TestEnvironment.GeoRestConfig);
- }
-
public static IServerConnection CreateTestHttpConnection()
{
return ConnectionProviderRegistry.CreateConnection("Maestro.Http",
Modified: trunk/Tools/Maestro/OSGeo.MapGuide.MaestroAPI.Http/HttpCapabilities.cs
===================================================================
--- trunk/Tools/Maestro/OSGeo.MapGuide.MaestroAPI.Http/HttpCapabilities.cs 2014-11-14 06:45:40 UTC (rev 8445)
+++ trunk/Tools/Maestro/OSGeo.MapGuide.MaestroAPI.Http/HttpCapabilities.cs 2014-11-14 07:09:50 UTC (rev 8446)
@@ -42,30 +42,16 @@
get
{
List<int> cmds = new List<int>();
- var gconn = _implConn.GeoRestConnection;
- if (gconn != null && gconn.Configuration.FeatureSources.Count > 0)
+ //TODO: Work out what this can/can't do
+ cmds.Add((int)CommandType.GetResourceContents);
+ cmds.Add((int)CommandType.GetFdoCacheInfo);
+
+ //Create/Describe Runtime Map available with 2.6
+ if (_implConn.SiteVersion >= new Version(2, 6))
{
- cmds.Add((int)CommandType.GetResourceContents);
- cmds.Add((int)CommandType.GetFdoCacheInfo);
- //GeoREST allows us to support these
- //(int)CommandType.DeleteFeatures,
- cmds.Add((int)CommandType.InsertFeature);
- //(int)CommandType.UpdateFeatures
+ cmds.Add((int)CommandType.CreateRuntimeMap);
+ cmds.Add((int)CommandType.DescribeRuntimeMap);
}
- else
- {
- //TODO: Work out what this can/can't do
- cmds.Add((int)CommandType.GetResourceContents);
- cmds.Add((int)CommandType.GetFdoCacheInfo);
-
- //Create/Describe Runtime Map available with 2.6
- if (_implConn.SiteVersion >= new Version(2, 6))
- {
- cmds.Add((int)CommandType.CreateRuntimeMap);
- cmds.Add((int)CommandType.DescribeRuntimeMap);
- }
- }
-
return cmds.ToArray();
}
}
Modified: trunk/Tools/Maestro/OSGeo.MapGuide.MaestroAPI.Http/HttpServerConnection.cs
===================================================================
--- trunk/Tools/Maestro/OSGeo.MapGuide.MaestroAPI.Http/HttpServerConnection.cs 2014-11-14 06:45:40 UTC (rev 8445)
+++ trunk/Tools/Maestro/OSGeo.MapGuide.MaestroAPI.Http/HttpServerConnection.cs 2014-11-14 07:09:50 UTC (rev 8446)
@@ -88,26 +88,10 @@
nvc[PARAM_URL] = this.BaseURL;
nvc[CommandLineArguments.Provider] = this.ProviderName;
nvc[CommandLineArguments.Session] = this.SessionID;
- nvc[PARAM_GEORESTURL] = this.GeoRestUrl;
- nvc[PARAM_GEORESTCONF] = this.GeoRestConfigPath;
return nvc;
}
}
- private GeoRestConnection _geoRestConn;
-
- internal GeoRestConnection GeoRestConnection { get { return _geoRestConn; } }
-
- public string GeoRestUrl
- {
- get { return (_geoRestConn == null) ? string.Empty : _geoRestConn.Url; }
- }
-
- public string GeoRestConfigPath
- {
- get { return (_geoRestConn == null) ? string.Empty : _geoRestConn.ConfigPath; }
- }
-
public override string ProviderName
{
get { return "Maestro.Http"; }
@@ -135,18 +119,11 @@
public const string PARAM_USERNAME = "Username";
public const string PARAM_PASSWORD = "Password";
- public const string PARAM_GEORESTURL = "GeoRestUrl";
- public const string PARAM_GEORESTCONF = "GeoRestConfigPath";
-
private ICredentials _cred;
- private void InitConnection(Uri hosturl, string sessionid, string locale, bool allowUntestedVersion, string geoRestUrl, string geoRestConfigPath)
+ private void InitConnection(Uri hosturl, string sessionid, string locale, bool allowUntestedVersion)
{
DisableAutoSessionRecovery();
- if (!string.IsNullOrEmpty(geoRestUrl))
- {
- _geoRestConn = new GeoRestConnection(geoRestUrl, geoRestConfigPath);
- }
m_reqBuilder = new RequestBuilder(hosturl, locale, sessionid, true);
string req = m_reqBuilder.GetSiteVersion();
@@ -188,13 +165,8 @@
}
}
- private void InitConnection(Uri hosturl, string username, string password, string locale, bool allowUntestedVersion, string geoRestUrl, string geoRestConfigPath)
+ private void InitConnection(Uri hosturl, string username, string password, string locale, bool allowUntestedVersion)
{
- if (!string.IsNullOrEmpty(geoRestUrl))
- {
- _geoRestConn = new GeoRestConnection(geoRestUrl, geoRestConfigPath);
- }
-
m_reqBuilder = new RequestBuilder(hosturl, locale);
mAnonymousUser = (username == "Anonymous");
@@ -230,24 +202,16 @@
string locale = null;
bool allowUntestedVersion = true;
- string geoRestUrl = null;
- string geoRestConfig = null;
-
if (initParams[PARAM_LOCALE] != null)
locale = initParams[PARAM_LOCALE];
if (initParams[PARAM_UNTESTED] != null)
bool.TryParse(initParams[PARAM_UNTESTED], out allowUntestedVersion);
- if (initParams[PARAM_GEORESTURL] != null)
- geoRestUrl = initParams[PARAM_GEORESTURL];
- if (initParams[PARAM_GEORESTCONF] != null)
- geoRestConfig = initParams[PARAM_GEORESTCONF];
-
if (initParams[PARAM_SESSION] != null)
{
string sessionid = initParams[PARAM_SESSION];
- InitConnection(new Uri(initParams[PARAM_URL]), sessionid, locale, allowUntestedVersion, geoRestUrl, geoRestConfig);
+ InitConnection(new Uri(initParams[PARAM_URL]), sessionid, locale, allowUntestedVersion);
}
else //Assuming username/password combination
{
@@ -255,20 +219,20 @@
if (initParams[PARAM_USERNAME] == null)
throw new ArgumentException("Missing required connection parameter: " + PARAM_USERNAME);
- InitConnection(new Uri(initParams[PARAM_URL]), initParams[PARAM_USERNAME], pwd, locale, allowUntestedVersion, geoRestUrl, geoRestConfig);
+ InitConnection(new Uri(initParams[PARAM_URL]), initParams[PARAM_USERNAME], pwd, locale, allowUntestedVersion);
}
}
internal HttpServerConnection(Uri hosturl, string sessionid, string locale, bool allowUntestedVersion)
: this()
{
- InitConnection(hosturl, sessionid, locale, allowUntestedVersion, null, null);
+ InitConnection(hosturl, sessionid, locale, allowUntestedVersion);
}
internal HttpServerConnection(Uri hosturl, string username, string password, string locale, bool allowUntestedVersion)
: this()
{
- InitConnection(hosturl, username, password, locale, allowUntestedVersion, null, null);
+ InitConnection(hosturl, username, password, locale, allowUntestedVersion);
}
public override string SessionID
@@ -2012,9 +1976,7 @@
public override ICommand CreateCommand(int cmdType)
{
CommandType ct = (CommandType)cmdType;
- if (ct == CommandType.InsertFeature)
- return new GeoRestInsertFeatures(this);
- else if (ct == CommandType.GetResourceContents)
+ if (ct == CommandType.GetResourceContents)
return new HttpGetResourceContents(this);
else if (ct == CommandType.GetFdoCacheInfo)
return new HttpGetFdoCacheInfo(this);
Modified: trunk/Tools/Maestro/OSGeo.MapGuide.MaestroAPI.Http/OSGeo.MapGuide.MaestroAPI.Http.csproj
===================================================================
--- trunk/Tools/Maestro/OSGeo.MapGuide.MaestroAPI.Http/OSGeo.MapGuide.MaestroAPI.Http.csproj 2014-11-14 06:45:40 UTC (rev 8445)
+++ trunk/Tools/Maestro/OSGeo.MapGuide.MaestroAPI.Http/OSGeo.MapGuide.MaestroAPI.Http.csproj 2014-11-14 07:09:50 UTC (rev 8446)
@@ -74,11 +74,9 @@
<Compile Include="..\Properties\SignedAssemblyInfo.cs">
<Link>SignedAssemblyInfo.cs</Link>
</Compile>
- <Compile Include="Commands\GeoRestCommands.cs" />
<Compile Include="Commands\HttpCreateRuntimeMap.cs" />
<Compile Include="Commands\HttpDescribeRuntimeMap.cs" />
<Compile Include="Commands\HttpGetFdoCacheInfo.cs" />
- <Compile Include="GeoRestConnection.cs" />
<Compile Include="HttpCapabilities.cs" />
<Compile Include="HttpCoordinateSystem.cs" />
<Compile Include="HttpCoordinateSystemCatalog.cs" />
More information about the mapguide-commits
mailing list