RegisterSensor and InsertObservation Services

Dec 22, 2009 at 7:55 PM

Hi.  Impressive amount of work.  I want to move from the 52North SOS implementation to something different (i.e. better performing), and i found your site and downloaded the code.  I'm not very familiar with WCF and the 3.5 framework.  But, I couldn't find a reference to the RegisterSensor and InsertObservation services in the web.config file, but I did find corresponding classes.  Are those services available, or am I missing something?

Thanks,

Dean

Coordinator
Dec 23, 2009 at 6:20 PM

Due to other projects we haven't had time to actively maintain this project... We hope to get back to it after the holidays.

That being said, the serialization classes are already created.  We wanted to implement the whole library first, but the actual service implementation was not done.  We tried to implement all required methods first as an example, and then move to everything else.

Another assumption was that each service has to implement those methods in context to the application it's being used for.

Please let me know if you have any problems or questions and we'll try to help out as time allows.

The project is not 100% completed, but can perform the basic required functions.

Thanks,
Oleg

 

Jan 12, 2010 at 8:23 PM

Oleg,

Hi, I'm working with Dean.  I downloaded both the OGC_WebClient_1.2_Source and OGC_WebService_1.2_Source.

I am having difficulty getting the client example to talk to the service.

When I run the client, I get html content returned instead of the expected xml.

The html content appears to be the asp.net page in which the service is being hosted.

Is there some configuration step that I'm missing.  I would appreciate it if you could point me in the right direction.

Thanks,

Scott

Jan 13, 2010 at 6:53 PM

Oleg,

Here's some more information regarding the issue.

The GetCapabilities() method is invoked on the SOSClient.

In the SweClient.GetResponse(), I should see xml data returned representing the Renci.Data.Interop.OpenGIS.Sos_10.Capabilities object.  Right?

Instead, I'm getting the contents of the asp.net page in which the Swe.svc is hosted.

Hopefully, this helps to pinpoint the problem.

 

Coordinator
Jan 13, 2010 at 7:12 PM
Hi Scott,

I just run the example I have on my local machine and I got a correct response.

It there any way that you can capture the response you getting and send it to me?

My guess its some ASP.NET error may be.

Thanks,
Oleg

On Wed, Jan 13, 2010 at 2:54 PM, ScottSuppan <notifications@codeplex.com> wrote:

From: ScottSuppan

Oleg,

Here's some more information regarding the issue.

The GetCapabilities() method is invoked on the SOSClient.

In the SweClient.GetResponse(), I should see xml data returned representing the Renci.Data.Interop.OpenGIS.Sos_10.Capabilities object.  Right?

Instead, I'm getting the contents of the asp.net page in which the Swe.svc is hosted.

Hopefully, this helps to pinpoint the problem.

 

Read the full discussion online.

To add a post to this discussion, reply to this email (ogc@discussions.codeplex.com)

To start a new discussion for this project, email ogc@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe or change your settings on codePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at codeplex.com


Jan 13, 2010 at 7:53 PM

Oleg,

Sure, here’s the response I captured via Visual Studio 2008.

<HTML><HEAD><link rel=\"alternate\" type=\"text/xml\" href=\"http://localhost:5786/Swe.svc?disco\"/><STYLE type=\"text/css\">#content{ FONT-SIZE: 0.7em; PADDING-BOTTOM: 2em; MARGIN-LEFT: 30px}BODY{MARGIN-TOP: 0px; MARGIN-LEFT: 0px; COLOR: #000000; FONT-FAMILY: Verdana; BACKGROUND-COLOR: white}P{MARGIN-TOP: 0px; MARGIN-BOTTOM: 12px; COLOR: #000000; FONT-FAMILY: Verdana}PRE{BORDER-RIGHT: #f0f0e0 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #f0f0e0 1px solid; MARGIN-TOP: -5px; PADDING-LEFT: 5px; FONT-SIZE: 1.2em; PADDING-BOTTOM: 5px; BORDER-LEFT: #f0f0e0 1px solid; PADDING-TOP: 5px; BORDER-BOTTOM: #f0f0e0 1px solid; FONT-FAMILY: Courier New; BACKGROUND-COLOR: #e5e5cc}.heading1{MARGIN-TOP: 0px; PADDING-LEFT: 15px; FONT-WEIGHT: normal; FONT-SIZE: 26px; MARGIN-BOTTOM: 0px; PADDING-BOTTOM: 3px; MARGIN-LEFT: -30px; WIDTH: 100%; COLOR: #ffffff; PADDING-TOP: 10px; FONT-FAMILY: Tahoma; BACKGROUND-COLOR: #003366}.intro{MARGIN-LEFT: -15px}</STYLE><TITLE>Swe Service</TITLE></HEAD><BODY><DIV id=\"content\"><P class=\"heading1\">Swe Service</P><BR/><P class=\"intro\">You have created a service.<P class='intro'>To test this service, you will need to create a client and use it to call the service. You can do this using the svcutil.exe tool from the command line with the following syntax:</P> <BR/><PRE>svcutil.exe <A HREF=\"http://localhost:5786/Swe.svc?wsdl\">http://localhost:5786/Swe.svc?wsdl</A></PRE></P><P class=\"intro\"/>This will generate a configuration file and a code file that contains the client class. Add the two files to your client application and use the generated client class to call the Service. For example:<BR/><P class='intro'><B>C#</B></P><PRE><font color=\"blue\">class </font><font color=\"teal\">Test\n</font>{\n<font color=\"blue\">    static void </font>Main()\n    {\n        <font color=\"teal\">SweClient</font> client = <font color=\"blue\">new </font><font color=\"teal\">SweClient</font>();\n\n<font color=\"green\">        // Use the 'client' variable to call operations on the service.\n\n</font><font color=\"green\">        // Always close the client.\n</font>        client.Close();\n    }\n}\n</PRE><BR/><P class='intro'><B>Visual Basic</B></P><PRE><font color=\"blue\">Class </font><font color=\"teal\">Test\n</font><font color=\"blue\">    Shared Sub </font>Main()\n<font color=\"blue\">        Dim </font>client As <font color=\"teal\">SweClient</font> = <font color=\"blue\">New </font><font color=\"teal\">SweClient</font>()\n<font color=\"green\">        ' Use the 'client' variable to call operations on the service.\n\n</font><font color=\"green\">        ' Always close the client.\n</font>        client.Close()\n<font color=\"blue\">    End Sub\n</font><font color=\"blue\">End Class</font></PRE></DIV></BODY></HTML>

 

I got this value back from here [see responseData variable below]:

        private TResponse CreateResponse<TResponse>(HttpWebResponse webResponse)

        {

            StreamReader responseStream = new StreamReader(webResponse.GetResponseStream());

            string responseData = responseStream.ReadToEnd();

 

What happens next is that an exception is thrown when the code attempts to deserialize the xml [for obvious reasons :-) ]

           if (ser.CanDeserialize(XmlReader.Create(new StringReader(responseData))))

            {

                response = (TResponse)ser.Deserialize(new StringReader(responseData));

            }

            else if (this._exceptionSerializer.CanDeserialize(XmlReader.Create(new StringReader(responseData))))

            {

Coordinator
Jan 19, 2010 at 2:08 PM
sorry for late response,

Did you try to run the example as it is or did some modifications to the code?
If so can you attach the project and I can a look?

From error message it seems that it doesn't invoke correct method.

Oleg

On Wed, Jan 13, 2010 at 3:54 PM, ScottSuppan <notifications@codeplex.com> wrote:

From: ScottSuppan

Oleg,

Sure, here’s the response I captured via Visual Studio 2008.

<HTML><HEAD><link rel=\"alternate\" type=\"text/xml\" href=\"http://localhost:5786/Swe.svc?disco\"/><STYLE type=\"text/css\">#content{ FONT-SIZE: 0.7em; PADDING-BOTTOM: 2em; MARGIN-LEFT: 30px}BODY{MARGIN-TOP: 0px; MARGIN-LEFT: 0px; COLOR: #000000; FONT-FAMILY: Verdana; BACKGROUND-COLOR: white}P{MARGIN-TOP: 0px; MARGIN-BOTTOM: 12px; COLOR: #000000; FONT-FAMILY: Verdana}PRE{BORDER-RIGHT: #f0f0e0 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #f0f0e0 1px solid; MARGIN-TOP: -5px; PADDING-LEFT: 5px; FONT-SIZE: 1.2em; PADDING-BOTTOM: 5px; BORDER-LEFT: #f0f0e0 1px solid; PADDING-TOP: 5px; BORDER-BOTTOM: #f0f0e0 1px solid; FONT-FAMILY: Courier New; BACKGROUND-COLOR: #e5e5cc}.heading1{MARGIN-TOP: 0px; PADDING-LEFT: 15px; FONT-WEIGHT: normal; FONT-SIZE: 26px; MARGIN-BOTTOM: 0px; PADDING-BOTTOM: 3px; MARGIN-LEFT: -30px; WIDTH: 100%; COLOR: #ffffff; PADDING-TOP: 10px; FONT-FAMILY: Tahoma; BACKGROUND-COLOR: #003366}.intro{MARGIN-LEFT: -15px}</STYLE><TITLE>Swe Service</TITLE></HEAD><BODY>

Swe Service


You have created a service.

To test this service, you will need to create a client and use it to call the service. You can do this using the svcutil.exe tool from the command line with the following syntax:


svcutil.exe http://localhost:5786/Swe.svc?wsdl\">http://localhost:5786/Swe.svc?wsdl

This will generate a configuration file and a code file that contains the client class. Add the two files to your client application and use the generated client class to call the Service. For example:

C#

<font color=\"blue\">class </font><font color=\"teal\">Test\n</font>{\n<font color=\"blue\">    static void </font>Main()\n    {\n        <font color=\"teal\">SweClient</font> client = <font color=\"blue\">new </font><font color=\"teal\">SweClient</font>();\n\n<font color=\"green\">        // Use the 'client' variable to call operations on the service.\n\n</font><font color=\"green\">        // Always close the client.\n</font>        client.Close();\n    }\n}\n

Visual Basic

<font color=\"blue\">Class </font><font color=\"teal\">Test\n</font><font color=\"blue\">    Shared Sub </font>Main()\n<font color=\"blue\">        Dim </font>client As <font color=\"teal\">SweClient</font> = <font color=\"blue\">New </font><font color=\"teal\">SweClient</font>()\n<font color=\"green\">        ' Use the 'client' variable to call operations on the service.\n\n</font><font color=\"green\">        ' Always close the client.\n</font>        client.Close()\n<font color=\"blue\">    End Sub\n</font><font color=\"blue\">End Class</font>
</BODY></HTML>

 

I got this value back from here [see responseData variable below]:

        private TResponse CreateResponse<TResponse>(HttpWebResponse webResponse)

        {

            StreamReader responseStream = new StreamReader(webResponse.GetResponseStream());

            string responseData = responseStream.ReadToEnd();

 

What happens next is that an exception is thrown when the code attempts to deserialize the xml [for obvious reasons :-) ]

           if (ser.CanDeserialize(XmlReader.Create(new StringReader(responseData))))

            {

                response = (TResponse)ser.Deserialize(new StringReader(responseData));

            }

            else if (this._exceptionSerializer.CanDeserialize(XmlReader.Create(new StringReader(responseData))))

            {

Read the full discussion online.

To add a post to this discussion, reply to this email (ogc@discussions.codeplex.com)

To start a new discussion for this project, email ogc@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe or change your settings on codePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at codeplex.com


Jan 19, 2010 at 2:47 PM

Oleg (2 o 3),

From: olegkap [mailto:notifications@codeplex.com]
Sent: Tuesday, January 19, 2010 10:09 AM
To: Suppan, Scott J
Subject: Re: RegisterSensor and InsertObservation Services [ogc:78870]

From: olegkap

sorry for late response,

Did you try to run the example as it is or did some modifications to the code?
If so can you attach the project and I can a look?

From error message it seems that it doesn't invoke correct method.

Oleg

On Wed, Jan 13, 2010 at 3:54 PM, ScottSuppan <notifications@codeplex.com> wrote:

From: ScottSuppan

Oleg,

Sure, here’s the response I captured via Visual Studio 2008.

<HTML><HEAD><link rel=\"alternate\" type=\"text/xml\" href=\"http://localhost:5786/Swe.svc?disco\"/><STYLE type=\"text/css\">#content{ FONT-SIZE: 0.7em; PADDING-BOTTOM: 2em; MARGIN-LEFT: 30px}BODY{MARGIN-TOP: 0px; MARGIN-LEFT: 0px; COLOR: #000000; FONT-FAMILY: Verdana; BACKGROUND-COLOR: white}P{MARGIN-TOP: 0px; MARGIN-BOTTOM: 12px; COLOR: #000000; FONT-FAMILY: Verdana}PRE{BORDER-RIGHT: #f0f0e0 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #f0f0e0 1px solid; MARGIN-TOP: -5px; PADDING-LEFT: 5px; FONT-SIZE: 1.2em; PADDING-BOTTOM: 5px; BORDER-LEFT: #f0f0e0 1px solid; PADDING-TOP: 5px; BORDER-BOTTOM: #f0f0e0 1px solid; FONT-FAMILY: Courier New; BACKGROUND-COLOR: #e5e5cc}.heading1{MARGIN-TOP: 0px; PADDING-LEFT: 15px; FONT-WEIGHT: normal; FONT-SIZE: 26px; MARGIN-BOTTOM: 0px; PADDING-BOTTOM: 3px; MARGIN-LEFT: -30px; WIDTH: 100%; COLOR: #ffffff; PADDING-TOP: 10px; FONT-FAMILY: Tahoma; BACKGROUND-COLOR: #003366}.intro{MARGIN-LEFT: -15px}</STYLE><TITLE>Swe Service</TITLE></HEAD><BODY>

Swe Service

You have created a service.

To test this service, you will need to create a client and use it to call the service. You can do this using the svcutil.exe tool from the command line with the following syntax:

svcutil.exe http://localhost:5786/Swe.svc?wsdl\">http://localhost:5786/Swe.svc?wsdl

This will generate a configuration file and a code file that contains the client class. Add the two files to your client application and use the generated client class to call the Service. For example:

C#

<font color=\"blue\">class </font><font color=\"teal\">Test\n</font>{\n<font color=\"blue\">    static void </font>Main()\n    {\n        <font color=\"teal\">SweClient</font> client = <font color=\"blue\">new </font><font color=\"teal\">SweClient</font>();\n\n<font color=\"green\">        // Use the 'client' variable to call operations on the service.\n\n</font><font color=\"green\">        // Always close the client.\n</font>        client.Close();\n    }\n}\n

Visual Basic

<font color=\"blue\">Class </font><font color=\"teal\">Test\n</font><font color=\"blue\">    Shared Sub </font>Main()\n<font color=\"blue\">        Dim </font>client As <font color=\"teal\">SweClient</font> = <font color=\"blue\">New </font><font color=\"teal\">SweClient</font>()\n<font color=\"green\">        ' Use the 'client' variable to call operations on the service.\n\n</font><font color=\"green\">        ' Always close the client.\n</font>        client.Close()\n<font color=\"blue\">    End Sub\n</font><font color=\"blue\">End Class</font>

</BODY></HTML>

I got this value back from here [see responseData variable below]:

private TResponse CreateResponse<TResponse>(HttpWebResponse webResponse)

{

StreamReader responseStream = new StreamReader(webResponse.GetResponseStream());

string responseData = responseStream.ReadToEnd();

What happens next is that an exception is thrown when the code attempts to deserialize the xml [for obvious reasons :-) ]

if (ser.CanDeserialize(XmlReader.Create(new StringReader(responseData))))

{

response = (TResponse)ser.Deserialize(new StringReader(responseData));

}

else if (this._exceptionSerializer.CanDeserialize(XmlReader.Create(new StringReader(responseData))))

{

Read the full discussion online.

To add a post to this discussion, reply to this email (ogc@discussions.codeplex.com)

To start a new discussion for this project, email ogc@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe or change your settings on codePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at codeplex.com

Read the full discussion online.

To add a post to this discussion, reply to this email (ogc@discussions.codeplex.com)

To start a new discussion for this project, email ogc@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com

Jan 19, 2010 at 2:47 PM

Oleg (3 of 3),

From: olegkap [mailto:notifications@codeplex.com]
Sent: Tuesday, January 19, 2010 10:09 AM
To: Suppan, Scott J
Subject: Re: RegisterSensor and InsertObservation Services [ogc:78870]

From: olegkap

sorry for late response,

Did you try to run the example as it is or did some modifications to the code?
If so can you attach the project and I can a look?

From error message it seems that it doesn't invoke correct method.

Oleg

On Wed, Jan 13, 2010 at 3:54 PM, ScottSuppan <notifications@codeplex.com> wrote:

From: ScottSuppan

Oleg,

Sure, here’s the response I captured via Visual Studio 2008.

<HTML><HEAD><link rel=\"alternate\" type=\"text/xml\" href=\"http://localhost:5786/Swe.svc?disco\"/><STYLE type=\"text/css\">#content{ FONT-SIZE: 0.7em; PADDING-BOTTOM: 2em; MARGIN-LEFT: 30px}BODY{MARGIN-TOP: 0px; MARGIN-LEFT: 0px; COLOR: #000000; FONT-FAMILY: Verdana; BACKGROUND-COLOR: white}P{MARGIN-TOP: 0px; MARGIN-BOTTOM: 12px; COLOR: #000000; FONT-FAMILY: Verdana}PRE{BORDER-RIGHT: #f0f0e0 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #f0f0e0 1px solid; MARGIN-TOP: -5px; PADDING-LEFT: 5px; FONT-SIZE: 1.2em; PADDING-BOTTOM: 5px; BORDER-LEFT: #f0f0e0 1px solid; PADDING-TOP: 5px; BORDER-BOTTOM: #f0f0e0 1px solid; FONT-FAMILY: Courier New; BACKGROUND-COLOR: #e5e5cc}.heading1{MARGIN-TOP: 0px; PADDING-LEFT: 15px; FONT-WEIGHT: normal; FONT-SIZE: 26px; MARGIN-BOTTOM: 0px; PADDING-BOTTOM: 3px; MARGIN-LEFT: -30px; WIDTH: 100%; COLOR: #ffffff; PADDING-TOP: 10px; FONT-FAMILY: Tahoma; BACKGROUND-COLOR: #003366}.intro{MARGIN-LEFT: -15px}</STYLE><TITLE>Swe Service</TITLE></HEAD><BODY>

Swe Service

You have created a service.

To test this service, you will need to create a client and use it to call the service. You can do this using the svcutil.exe tool from the command line with the following syntax:

svcutil.exe http://localhost:5786/Swe.svc?wsdl\">http://localhost:5786/Swe.svc?wsdl

This will generate a configuration file and a code file that contains the client class. Add the two files to your client application and use the generated client class to call the Service. For example:

C#

<font color=\"blue\">class </font><font color=\"teal\">Test\n</font>{\n<font color=\"blue\">    static void </font>Main()\n    {\n        <font color=\"teal\">SweClient</font> client = <font color=\"blue\">new </font><font color=\"teal\">SweClient</font>();\n\n<font color=\"green\">        // Use the 'client' variable to call operations on the service.\n\n</font><font color=\"green\">        // Always close the client.\n</font>        client.Close();\n    }\n}\n

Visual Basic

<font color=\"blue\">Class </font><font color=\"teal\">Test\n</font><font color=\"blue\">    Shared Sub </font>Main()\n<font color=\"blue\">        Dim </font>client As <font color=\"teal\">SweClient</font> = <font color=\"blue\">New </font><font color=\"teal\">SweClient</font>()\n<font color=\"green\">        ' Use the 'client' variable to call operations on the service.\n\n</font><font color=\"green\">        ' Always close the client.\n</font>        client.Close()\n<font color=\"blue\">    End Sub\n</font><font color=\"blue\">End Class</font>

</BODY></HTML>

I got this value back from here [see responseData variable below]:

private TResponse CreateResponse<TResponse>(HttpWebResponse webResponse)

{

StreamReader responseStream = new StreamReader(webResponse.GetResponseStream());

string responseData = responseStream.ReadToEnd();

What happens next is that an exception is thrown when the code attempts to deserialize the xml [for obvious reasons :-) ]

if (ser.CanDeserialize(XmlReader.Create(new StringReader(responseData))))

{

response = (TResponse)ser.Deserialize(new StringReader(responseData));

}

else if (this._exceptionSerializer.CanDeserialize(XmlReader.Create(new StringReader(responseData))))

{

Read the full discussion online.

To add a post to this discussion, reply to this email (ogc@discussions.codeplex.com)

To start a new discussion for this project, email ogc@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe or change your settings on codePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at codeplex.com

Read the full discussion online.

To add a post to this discussion, reply to this email (ogc@discussions.codeplex.com)

To start a new discussion for this project, email ogc@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com

Jan 19, 2010 at 2:52 PM

Oleg (2 of 2),

Please remove the “.allow” at the end of the file.

From: olegkap [mailto:notifications@codeplex.com]
Sent: Tuesday, January 19, 2010 10:09 AM
To: Suppan, Scott J
Subject: Re: RegisterSensor and InsertObservation Services [ogc:78870]

From: olegkap

sorry for late response,

Did you try to run the example as it is or did some modifications to the code?
If so can you attach the project and I can a look?

From error message it seems that it doesn't invoke correct method.

Oleg

On Wed, Jan 13, 2010 at 3:54 PM, ScottSuppan <notifications@codeplex.com> wrote:

From: ScottSuppan

Oleg,

Sure, here’s the response I captured via Visual Studio 2008.

<HTML><HEAD><link rel=\"alternate\" type=\"text/xml\" href=\"http://localhost:5786/Swe.svc?disco\"/><STYLE type=\"text/css\">#content{ FONT-SIZE: 0.7em; PADDING-BOTTOM: 2em; MARGIN-LEFT: 30px}BODY{MARGIN-TOP: 0px; MARGIN-LEFT: 0px; COLOR: #000000; FONT-FAMILY: Verdana; BACKGROUND-COLOR: white}P{MARGIN-TOP: 0px; MARGIN-BOTTOM: 12px; COLOR: #000000; FONT-FAMILY: Verdana}PRE{BORDER-RIGHT: #f0f0e0 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #f0f0e0 1px solid; MARGIN-TOP: -5px; PADDING-LEFT: 5px; FONT-SIZE: 1.2em; PADDING-BOTTOM: 5px; BORDER-LEFT: #f0f0e0 1px solid; PADDING-TOP: 5px; BORDER-BOTTOM: #f0f0e0 1px solid; FONT-FAMILY: Courier New; BACKGROUND-COLOR: #e5e5cc}.heading1{MARGIN-TOP: 0px; PADDING-LEFT: 15px; FONT-WEIGHT: normal; FONT-SIZE: 26px; MARGIN-BOTTOM: 0px; PADDING-BOTTOM: 3px; MARGIN-LEFT: -30px; WIDTH: 100%; COLOR: #ffffff; PADDING-TOP: 10px; FONT-FAMILY: Tahoma; BACKGROUND-COLOR: #003366}.intro{MARGIN-LEFT: -15px}</STYLE><TITLE>Swe Service</TITLE></HEAD><BODY>

Swe Service

You have created a service.

To test this service, you will need to create a client and use it to call the service. You can do this using the svcutil.exe tool from the command line with the following syntax:

svcutil.exe http://localhost:5786/Swe.svc?wsdl\">http://localhost:5786/Swe.svc?wsdl

This will generate a configuration file and a code file that contains the client class. Add the two files to your client application and use the generated client class to call the Service. For example:

C#

<font color=\"blue\">class </font><font color=\"teal\">Test\n</font>{\n<font color=\"blue\">    static void </font>Main()\n    {\n        <font color=\"teal\">SweClient</font> client = <font color=\"blue\">new </font><font color=\"teal\">SweClient</font>();\n\n<font color=\"green\">        // Use the 'client' variable to call operations on the service.\n\n</font><font color=\"green\">        // Always close the client.\n</font>        client.Close();\n    }\n}\n

Visual Basic

<font color=\"blue\">Class </font><font color=\"teal\">Test\n</font><font color=\"blue\">    Shared Sub </font>Main()\n<font color=\"blue\">        Dim </font>client As <font color=\"teal\">SweClient</font> = <font color=\"blue\">New </font><font color=\"teal\">SweClient</font>()\n<font color=\"green\">        ' Use the 'client' variable to call operations on the service.\n\n</font><font color=\"green\">        ' Always close the client.\n</font>        client.Close()\n<font color=\"blue\">    End Sub\n</font><font color=\"blue\">End Class</font>

</BODY></HTML>

I got this value back from here [see responseData variable below]:

private TResponse CreateResponse<TResponse>(HttpWebResponse webResponse)

{

StreamReader responseStream = new StreamReader(webResponse.GetResponseStream());

string responseData = responseStream.ReadToEnd();

What happens next is that an exception is thrown when the code attempts to deserialize the xml [for obvious reasons :-) ]

if (ser.CanDeserialize(XmlReader.Create(new StringReader(responseData))))

{

response = (TResponse)ser.Deserialize(new StringReader(responseData));

}

else if (this._exceptionSerializer.CanDeserialize(XmlReader.Create(new StringReader(responseData))))

{

Read the full discussion online.

To add a post to this discussion, reply to this email (ogc@discussions.codeplex.com)

To start a new discussion for this project, email ogc@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe or change your settings on codePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at codeplex.com

Read the full discussion online.

To add a post to this discussion, reply to this email (ogc@discussions.codeplex.com)

To start a new discussion for this project, email ogc@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com

Jan 19, 2010 at 3:13 PM

Oleg (3 of 3),

Sorry about the confusion. It appears that the zip file is too big to be sent.

I will have to split it.

From: olegkap [mailto:notifications@codeplex.com]
Sent: Tuesday, January 19, 2010 10:09 AM
To: Suppan, Scott J
Subject: Re: RegisterSensor and InsertObservation Services [ogc:78870]

From: olegkap

sorry for late response,

Did you try to run the example as it is or did some modifications to the code?
If so can you attach the project and I can a look?

From error message it seems that it doesn't invoke correct method.

Oleg

On Wed, Jan 13, 2010 at 3:54 PM, ScottSuppan <notifications@codeplex.com> wrote:

From: ScottSuppan

Oleg,

Sure, here’s the response I captured via Visual Studio 2008.

<HTML><HEAD><link rel=\"alternate\" type=\"text/xml\" href=\"http://localhost:5786/Swe.svc?disco\"/><STYLE type=\"text/css\">#content{ FONT-SIZE: 0.7em; PADDING-BOTTOM: 2em; MARGIN-LEFT: 30px}BODY{MARGIN-TOP: 0px; MARGIN-LEFT: 0px; COLOR: #000000; FONT-FAMILY: Verdana; BACKGROUND-COLOR: white}P{MARGIN-TOP: 0px; MARGIN-BOTTOM: 12px; COLOR: #000000; FONT-FAMILY: Verdana}PRE{BORDER-RIGHT: #f0f0e0 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #f0f0e0 1px solid; MARGIN-TOP: -5px; PADDING-LEFT: 5px; FONT-SIZE: 1.2em; PADDING-BOTTOM: 5px; BORDER-LEFT: #f0f0e0 1px solid; PADDING-TOP: 5px; BORDER-BOTTOM: #f0f0e0 1px solid; FONT-FAMILY: Courier New; BACKGROUND-COLOR: #e5e5cc}.heading1{MARGIN-TOP: 0px; PADDING-LEFT: 15px; FONT-WEIGHT: normal; FONT-SIZE: 26px; MARGIN-BOTTOM: 0px; PADDING-BOTTOM: 3px; MARGIN-LEFT: -30px; WIDTH: 100%; COLOR: #ffffff; PADDING-TOP: 10px; FONT-FAMILY: Tahoma; BACKGROUND-COLOR: #003366}.intro{MARGIN-LEFT: -15px}</STYLE><TITLE>Swe Service</TITLE></HEAD><BODY>

Swe Service

You have created a service.

To test this service, you will need to create a client and use it to call the service. You can do this using the svcutil.exe tool from the command line with the following syntax:

svcutil.exe http://localhost:5786/Swe.svc?wsdl\">http://localhost:5786/Swe.svc?wsdl

This will generate a configuration file and a code file that contains the client class. Add the two files to your client application and use the generated client class to call the Service. For example:

C#

<font color=\"blue\">class </font><font color=\"teal\">Test\n</font>{\n<font color=\"blue\">    static void </font>Main()\n    {\n        <font color=\"teal\">SweClient</font> client = <font color=\"blue\">new </font><font color=\"teal\">SweClient</font>();\n\n<font color=\"green\">        // Use the 'client' variable to call operations on the service.\n\n</font><font color=\"green\">        // Always close the client.\n</font>        client.Close();\n    }\n}\n

Visual Basic

<font color=\"blue\">Class </font><font color=\"teal\">Test\n</font><font color=\"blue\">    Shared Sub </font>Main()\n<font color=\"blue\">        Dim </font>client As <font color=\"teal\">SweClient</font> = <font color=\"blue\">New </font><font color=\"teal\">SweClient</font>()\n<font color=\"green\">        ' Use the 'client' variable to call operations on the service.\n\n</font><font color=\"green\">        ' Always close the client.\n</font>        client.Close()\n<font color=\"blue\">    End Sub\n</font><font color=\"blue\">End Class</font>

</BODY></HTML>

I got this value back from here [see responseData variable below]:

private TResponse CreateResponse<TResponse>(HttpWebResponse webResponse)

{

StreamReader responseStream = new StreamReader(webResponse.GetResponseStream());

string responseData = responseStream.ReadToEnd();

What happens next is that an exception is thrown when the code attempts to deserialize the xml [for obvious reasons :-) ]

if (ser.CanDeserialize(XmlReader.Create(new StringReader(responseData))))

{

response = (TResponse)ser.Deserialize(new StringReader(responseData));

}

else if (this._exceptionSerializer.CanDeserialize(XmlReader.Create(new StringReader(responseData))))

{

Read the full discussion online.

To add a post to this discussion, reply to this email (ogc@discussions.codeplex.com)

To start a new discussion for this project, email ogc@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe or change your settings on codePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at codeplex.com

Read the full discussion online.

To add a post to this discussion, reply to this email (ogc@discussions.codeplex.com)

To start a new discussion for this project, email ogc@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com

Jan 19, 2010 at 3:13 PM

Oleg (1 of 1),

Please remove the “.allow” at the end of the file.

From: olegkap [mailto:notifications@codeplex.com]
Sent: Tuesday, January 19, 2010 10:09 AM
To: Suppan, Scott J
Subject: Re: RegisterSensor and InsertObservation Services [ogc:78870]

From: olegkap

sorry for late response,

Did you try to run the example as it is or did some modifications to the code?
If so can you attach the project and I can a look?

From error message it seems that it doesn't invoke correct method.

Oleg

On Wed, Jan 13, 2010 at 3:54 PM, ScottSuppan <notifications@codeplex.com> wrote:

From: ScottSuppan

Oleg,

Sure, here’s the response I captured via Visual Studio 2008.

<HTML><HEAD><link rel=\"alternate\" type=\"text/xml\" href=\"http://localhost:5786/Swe.svc?disco\"/><STYLE type=\"text/css\">#content{ FONT-SIZE: 0.7em; PADDING-BOTTOM: 2em; MARGIN-LEFT: 30px}BODY{MARGIN-TOP: 0px; MARGIN-LEFT: 0px; COLOR: #000000; FONT-FAMILY: Verdana; BACKGROUND-COLOR: white}P{MARGIN-TOP: 0px; MARGIN-BOTTOM: 12px; COLOR: #000000; FONT-FAMILY: Verdana}PRE{BORDER-RIGHT: #f0f0e0 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #f0f0e0 1px solid; MARGIN-TOP: -5px; PADDING-LEFT: 5px; FONT-SIZE: 1.2em; PADDING-BOTTOM: 5px; BORDER-LEFT: #f0f0e0 1px solid; PADDING-TOP: 5px; BORDER-BOTTOM: #f0f0e0 1px solid; FONT-FAMILY: Courier New; BACKGROUND-COLOR: #e5e5cc}.heading1{MARGIN-TOP: 0px; PADDING-LEFT: 15px; FONT-WEIGHT: normal; FONT-SIZE: 26px; MARGIN-BOTTOM: 0px; PADDING-BOTTOM: 3px; MARGIN-LEFT: -30px; WIDTH: 100%; COLOR: #ffffff; PADDING-TOP: 10px; FONT-FAMILY: Tahoma; BACKGROUND-COLOR: #003366}.intro{MARGIN-LEFT: -15px}</STYLE><TITLE>Swe Service</TITLE></HEAD><BODY>

Swe Service

You have created a service.

To test this service, you will need to create a client and use it to call the service. You can do this using the svcutil.exe tool from the command line with the following syntax:

svcutil.exe http://localhost:5786/Swe.svc?wsdl\">http://localhost:5786/Swe.svc?wsdl

This will generate a configuration file and a code file that contains the client class. Add the two files to your client application and use the generated client class to call the Service. For example:

C#

<font color=\"blue\">class </font><font color=\"teal\">Test\n</font>{\n<font color=\"blue\">    static void </font>Main()\n    {\n        <font color=\"teal\">SweClient</font> client = <font color=\"blue\">new </font><font color=\"teal\">SweClient</font>();\n\n<font color=\"green\">        // Use the 'client' variable to call operations on the service.\n\n</font><font color=\"green\">        // Always close the client.\n</font>        client.Close();\n    }\n}\n

Visual Basic

<font color=\"blue\">Class </font><font color=\"teal\">Test\n</font><font color=\"blue\">    Shared Sub </font>Main()\n<font color=\"blue\">        Dim </font>client As <font color=\"teal\">SweClient</font> = <font color=\"blue\">New </font><font color=\"teal\">SweClient</font>()\n<font color=\"green\">        ' Use the 'client' variable to call operations on the service.\n\n</font><font color=\"green\">        ' Always close the client.\n</font>        client.Close()\n<font color=\"blue\">    End Sub\n</font><font color=\"blue\">End Class</font>

</BODY></HTML>

I got this value back from here [see responseData variable below]:

private TResponse CreateResponse<TResponse>(HttpWebResponse webResponse)

{

StreamReader responseStream = new StreamReader(webResponse.GetResponseStream());

string responseData = responseStream.ReadToEnd();

What happens next is that an exception is thrown when the code attempts to deserialize the xml [for obvious reasons :-) ]

if (ser.CanDeserialize(XmlReader.Create(new StringReader(responseData))))

{

response = (TResponse)ser.Deserialize(new StringReader(responseData));

}

else if (this._exceptionSerializer.CanDeserialize(XmlReader.Create(new StringReader(responseData))))

{

Read the full discussion online.

To add a post to this discussion, reply to this email (ogc@discussions.codeplex.com)

To start a new discussion for this project, email ogc@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe or change your settings on codePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at codeplex.com

Read the full discussion online.

To add a post to this discussion, reply to this email (ogc@discussions.codeplex.com)

To start a new discussion for this project, email ogc@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com

Jan 19, 2010 at 3:13 PM

Oleg (3 of 3, part 2)

From: olegkap [mailto:notifications@codeplex.com]
Sent: Tuesday, January 19, 2010 10:09 AM
To: Suppan, Scott J
Subject: Re: RegisterSensor and InsertObservation Services [ogc:78870]

From: olegkap

sorry for late response,

Did you try to run the example as it is or did some modifications to the code?
If so can you attach the project and I can a look?

From error message it seems that it doesn't invoke correct method.

Oleg

On Wed, Jan 13, 2010 at 3:54 PM, ScottSuppan <notifications@codeplex.com> wrote:

From: ScottSuppan

Oleg,

Sure, here’s the response I captured via Visual Studio 2008.

<HTML><HEAD><link rel=\"alternate\" type=\"text/xml\" href=\"http://localhost:5786/Swe.svc?disco\"/><STYLE type=\"text/css\">#content{ FONT-SIZE: 0.7em; PADDING-BOTTOM: 2em; MARGIN-LEFT: 30px}BODY{MARGIN-TOP: 0px; MARGIN-LEFT: 0px; COLOR: #000000; FONT-FAMILY: Verdana; BACKGROUND-COLOR: white}P{MARGIN-TOP: 0px; MARGIN-BOTTOM: 12px; COLOR: #000000; FONT-FAMILY: Verdana}PRE{BORDER-RIGHT: #f0f0e0 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #f0f0e0 1px solid; MARGIN-TOP: -5px; PADDING-LEFT: 5px; FONT-SIZE: 1.2em; PADDING-BOTTOM: 5px; BORDER-LEFT: #f0f0e0 1px solid; PADDING-TOP: 5px; BORDER-BOTTOM: #f0f0e0 1px solid; FONT-FAMILY: Courier New; BACKGROUND-COLOR: #e5e5cc}.heading1{MARGIN-TOP: 0px; PADDING-LEFT: 15px; FONT-WEIGHT: normal; FONT-SIZE: 26px; MARGIN-BOTTOM: 0px; PADDING-BOTTOM: 3px; MARGIN-LEFT: -30px; WIDTH: 100%; COLOR: #ffffff; PADDING-TOP: 10px; FONT-FAMILY: Tahoma; BACKGROUND-COLOR: #003366}.intro{MARGIN-LEFT: -15px}</STYLE><TITLE>Swe Service</TITLE></HEAD><BODY>

Swe Service

You have created a service.

To test this service, you will need to create a client and use it to call the service. You can do this using the svcutil.exe tool from the command line with the following syntax:

svcutil.exe http://localhost:5786/Swe.svc?wsdl\">http://localhost:5786/Swe.svc?wsdl

This will generate a configuration file and a code file that contains the client class. Add the two files to your client application and use the generated client class to call the Service. For example:

C#

<font color=\"blue\">class </font><font color=\"teal\">Test\n</font>{\n<font color=\"blue\">    static void </font>Main()\n    {\n        <font color=\"teal\">SweClient</font> client = <font color=\"blue\">new </font><font color=\"teal\">SweClient</font>();\n\n<font color=\"green\">        // Use the 'client' variable to call operations on the service.\n\n</font><font color=\"green\">        // Always close the client.\n</font>        client.Close();\n    }\n}\n

Visual Basic

<font color=\"blue\">Class </font><font color=\"teal\">Test\n</font><font color=\"blue\">    Shared Sub </font>Main()\n<font color=\"blue\">        Dim </font>client As <font color=\"teal\">SweClient</font> = <font color=\"blue\">New </font><font color=\"teal\">SweClient</font>()\n<font color=\"green\">        ' Use the 'client' variable to call operations on the service.\n\n</font><font color=\"green\">        ' Always close the client.\n</font>        client.Close()\n<font color=\"blue\">    End Sub\n</font><font color=\"blue\">End Class</font>

</BODY></HTML>

I got this value back from here [see responseData variable below]:

private TResponse CreateResponse<TResponse>(HttpWebResponse webResponse)

{

StreamReader responseStream = new StreamReader(webResponse.GetResponseStream());

string responseData = responseStream.ReadToEnd();

What happens next is that an exception is thrown when the code attempts to deserialize the xml [for obvious reasons :-) ]

if (ser.CanDeserialize(XmlReader.Create(new StringReader(responseData))))

{

response = (TResponse)ser.Deserialize(new StringReader(responseData));

}

else if (this._exceptionSerializer.CanDeserialize(XmlReader.Create(new StringReader(responseData))))

{

Read the full discussion online.

To add a post to this discussion, reply to this email (ogc@discussions.codeplex.com)

To start a new discussion for this project, email ogc@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe or change your settings on codePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at codeplex.com

Read the full discussion online.

To add a post to this discussion, reply to this email (ogc@discussions.codeplex.com)

To start a new discussion for this project, email ogc@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com

Jan 19, 2010 at 3:56 PM

Oleg,

Sorry but it appears that the attachments didn't come through. :-(  I feel silly.

I can tell you what I did though.

I extracted the web service source and web client source.

I extracted the web service binary and then overlayed the contents of the webapp in web service with those files.

I extracted the latest database and then configured the web.config to acesss it via localhost and user/password combination.

That's really it.  I can't understand why the service comes back with HTML.  I realize that there's no data in the database.  However, I should get back an empty schema representation in xml.