I have a simple WCF service project and a Silverlight project that queries the database through this service.
Is it possible to set the address (actually only the port number since I deploy on localhost) of the service, fixed?
Because everytime I rebuild the web service, it changes the address and I need to update also the ServiceReferences.ClientConfig file from Silverlight in order to update the reference.
You want to configure an ASP.NET project to consistently run on the same port within Visual Studio Development Server?
Right click on your ASP.NET project and select Properties
Choose the Web tab in the properties window (should be the third option)
Under the Servers section (the second section), you'll have a radio button check for Use Visual Studio Development Server, and then by default a subselection labelled Auto-assign Port. Simply change this subselection to Specific port, and then choose a port number.
Now your project will always run under the specified port on the Development Server, e.g. http://localhost:12345/MyService.svc and http://localhost:12345/Default.aspx.
Related
i have followed the https://grafana.com/docs/project/building_from_source/ and set up grafana in my local physical machine. Now am running it using yarn start and also starting grafana-server and it is working perfectly fine. Now i want to move it to Azure.
I am completely new to hosting procedures hence i would need some step by step instruction to host the created grafana over there in Azure
There is no managed service for graphana, you need to install it on a VM using an existing image or manually, you can find the image from the market place
here is a more detailed step, and it helps me out
https://github.com/MicrosoftDocs/azure-docs/blob/master/articles/azure-monitor/platform/grafana-plugin.md
Using the IP address of your server, open the Login page at HTTP://:3000 or the :3000 in your browser. While 3000 is the default port, note you might have selected a different port during setup. You should see a login page for the Grafana server you built.
we are working on a WPF application which we want to publish as a click once smart client application.
We are able to publish the application on local machine using Visual Studio 2012 and configured it in IIS.
Now we want to upload the published smart client installer to windows Azure Virtual Machine with Windows Server 2012 and IIS 8. We cannot upload the locally published components as the URL configuration in the manifest and deployment file is that of local server. We tried to edit the entries using text editor but once we do the editing the files become unused and it shows xml parsing error when we try to install from the location.
we tried to publish the application direct to the Virtual Machine but it shows an error as Front Page Extension is needed in IIS. We tried to find Front Page extension but couldn't find an version for IIS 8 in Windows Server 2012.
Can any one help us to publish the application in Azure Virtual Machine.
The problem you are having has nothing to do with Azure per se.
In the first case (of editing the XML files), you can do that but it's best to use MageUI to do the edit, because you can then re-sign the manifests. If you just edit the files, it messes up the security on them, and they will not work (as you have found). If you want to edit them with a text editor, you can do that, but then you must re-sign them (using mage); you can create a script to change the installation URL.
Or you can use MageUI. You need to do it in this order:
Open the application manifest in the versioned folder and then save it, re-signing it with your signing certificate.
Open the deployment manifest (yourapp.application) in the top deployment folder. Change the Start Folder to be the right Installation URL. Go to the "Application Reference" tab and re-select the application manifest in the versioned folder. (I know, it hasn't changed, but trust me, you have to do this.) Save this manifest and sign it with your signing certificate.
Copy the deployment manifest from the top folder to the versioned folder. It's always good to keep a copy, so you can go backwards a version if you need to.
NOW you can copy the files to your VM and they will work fine.
In the second case, the Front Page Extensions are required if you are using HTTP to publish the application, yet they are no longer available past about Windows Server 2008(?). So don't use HTTP. Use FTP. Set the publish file location using FTP, like ftp://myserver.mycompany.com/myfolder and set the Installation URL to the HTTP equivalent of it. Then publish it. It will put the files on your VM (assuming FTP is enabled on both sides), and the HTTP link should work.
By the way, you can also host your deployment in Azure blob storage. It is dirt cheap, and you can use something like Cerebrata Cloud Storage Studio or even write your own code to publish it (which I did). This article explains how to put the files out there, what the MIME types need to be, etc. If you do this, then it will work even if you need to replace your VM or redeploy it or the VM becomes unavailable for some reason.
here is a reference to Avkash Chauhan's blog post explaining in detail How to deploy ClickOnce Application using Windows Azure Storage in very simple steps?
http://blogs.msdn.com/b/avkashchauhan/archive/2011/05/09/how-to-deploy-clickonce-application-using-windows-azure-storage-in-very-simple-steps.aspx
He also gives an code example of a windows form (using Wpf) that he shows how to deploy on azure using one click deployment.
hope this helps
As an .xap file is added in the web project which runs at client side, then can anyone please explain how are we able to debug the silverlight client side code?
If you are running the web server built into Visual Studio then Visual Studio is both hosting the web server and running the web client. This means you are able to debug both the client and server side code.
If you are using IIS to serve the site then you are still running the web client within Visual Studio.
As long has you have the "Debuggers" option set on the web project you will be able to set break points and step through the code.
In the web project properties, under ‘web’ tab all way at the bottom, there is a group called ‘Debuggers’, make sure you have Silverlight check box is checked. By checking the Silverlight check box you will be able to debug the client side code.
WCF service is hosted in a website in the same solution as my WPF client.
Given that the development webserver often switches ports, I was wondering if there was an easy way to detect this so I don't have to keep hardcoding / updating my config?
The web project properties page contains option to specify an exact port on which the development server would run. Check the 'Web' property page.
I have a WCF REST service running on IIS on port 8000. I have implemented two GET methods in the service. I created another web application project to implement the UI for the GET's. This application is also hosted on the same IIS on port 8080.
The GET methods call a stored proc from a SQL server db, also hosted on the same machine as IIS (this is a prototype).
From my VS 2010 environment, I am able to display the results from the db on the UI (using GridView and ObjectDatasource as the GET methods from the referenced WCF project). However, when both projects are hosted on IIS on different ports, the UI shows the column headers but not the results. I have checked the connection string for the projects and dont see an issue there.
Any suggestions?
First, I know you say you have checked it, but make sure you check the connection strings in the actual IIS directories. If they have been edited, publishing your site may no overwrite them.
Filing that, you may wish to attach to the IIS process to see what is going on. See How to debug a deployed web site.