September 26, 2008

Developing with Mapguide Enterprise / Open Source in a shared server environment

Filed under: Mapguide — Tags: — Darrin Maidlow @ 7:41 pm

I have enough junk running on my development machine.  In an effort to try and keep my workstation speedy – I don’t install any unnecessary services (Oracle server, Mapguide Server etc) on this machine.  In a larger development environment, running multiple servers on local development machines has a few other less than desirable results.  For example licensing issues and costs could increase, data management can become more complex, and just managing the extra services on N machines could cause a lot more work for your already overworked IT guy.

So instead I have centralized my server resources into a nice VM setup running on my beefy Dell server.  Now, regardless of which machine I use to develop I can still access the same data sets.  This is especially nice when traveling.  Specifically Mapguide Server and web tier are installed on my development web server.  When coding, I will either use my local IIS or the built in Visual Studio web server.  This poses one problem when working with Mapguide.  Referencing the web tier on the shared server from another web server will result in (XSS) errors.  Basically, javascript on one web server cannot access javascript code on another web server, which under most circumstances is a good thing.  When trying to develop using the Mapguide Web API on a central Mapguide server this poses a problem as the web tier API is wholly contained within the virtual directory on another server.  Gotta love when ‘security’ jumps up bites us in the behind.

The simple solution to this problem is to install the Mapguide web tier on every development machine.  This will require that each development machine have a web server installed, but chances are that is already the case.  When installing the web tier be sure to have the IP address of the Mapguide server handy as it will needed during the install.  Once the web tier is running locally, reference the local web tier in your URLs and the cross site scripting vulnerabilities go away!  If you’re running the 64 Bit version of Vista on your development machine, check out my post installing the

Technorati Tags:

September 25, 2008

Mapguide 6.5 Server – Missing the Autodesk Spatial Data Provider for Oracle Spatial

Filed under: Uncategorized — Tags: — Darrin Maidlow @ 7:41 am

Over the years, this problem has sporadically appeared (probably once or twice a year).  In the Mapguide 6.5 server admin when creating a new data source the Autodesk Spatial Data Provider for Oracle Spatial doesn’t appear as an option.  Every time this comes up I end up wracking my brain to remember what the solution is.  I know I’ve dealt with this many times – but I cannot remember the details.  Usually it’s occurring on a customer’s production server which is not a place I like to mess around.  This time, it was my development server – let the messing around begin!

In a nutshell this is a result of installing Mapguide server before the Oracle client is installed on the server.  The solution is to do a repair install of Mapguide Server (or a re-install if you prefer) once the Oracle client is installed.  Hopefully next year when this comes up again – writing this down will help me remember.  Worst case Google might pick this up and I’ll find my own post when I search for it…

Technorati Tags: ,

September 3, 2008

System.Runtime.InteropServices.ComException Loading ASP.NET Web Application in Visual Studio 2008

Filed under: General — Tags: , — Darrin Maidlow @ 11:04 pm

Another day, another fun error message.  Thanks to all the fun I’ve been having with – I’ve given up and created a new virtual machine with XP Pro to run Visual Studio in.   So I grab the latest revision from source control and load the solution in Visual Studio.  Boom.  Sytem.Runtime.InteropServices.ComException.  That’s it. No more details.  This is one of those errors where it could be just about anything.  A gives way too many results.

So I’m going to add one more search result on this error message.  After much muckery – I’ve resolved my instance of the problem.  The background is simple.  I have an ASP.NET web application with a few DLL projects and a deployment project.  As stated, I’ve created a new install of Windows XP.  First ensure that you have the add-on installed.  That can also cause this error (in some cases).

The key thing in this case was the lack of IIS on the machine.  On my primary development machine (the one where Oracle is a massive pain) I do have IIS installed, and the last time I ran this project from that machine – Oracle was working OK with the data access hack.  But apparently something has changed on that box and now I’m getting the evil "Oracle client and networking components were not found." error.  So I gave up.

First obvious work around is to install IIS.  I’m sick of messing around today, and just want to work.  So the quicker solution is to enable the built in development web server.  This can be accomplished by right clicking the unloaded project in the Visual Studio solution explorer and choosing "Edit <projectname.whateverlanguateyouuseproj>".  This will bring up the XML view of the project.  Find the ProjectExtensions section of the config and change UseIIS to be False.  Setting this up could also prevent problems when you have a larger, or more dynamic team accessing the project.

   1: <ProjectExtensions>
   2:     <VisualStudio>
   3:       <FlavorProperties GUID="{349c5851-65df-11da-9384-00065b846f21}">
   4:         <WebProjectProperties>
   5:           <UseIIS>False</UseIIS>
   6:           <AutoAssignPort>False</AutoAssignPort>
   7:           <DevelopmentServerPort>4088</DevelopmentServerPort>
   8:           <DevelopmentServerVPath>/webrade</DevelopmentServerVPath>
   9:           <IISUrl>http://localhost/WebRADE32</IISUrl>
  10:           <NTLMAuthentication>False</NTLMAuthentication>
  11:           <UseCustomServer>False</UseCustomServer>
  12:           <CustomServerUrl>
  13:           </CustomServerUrl>
  14:           <SaveServerSettingsInUserFile>False</SaveServerSettingsInUserFile>
  15:         </WebProjectProperties>
  16:       </FlavorProperties>
  17:     </VisualStudio>
  18:   </ProjectExtensions>

 

Reload the project, and it should load now.

P.S. Oracle, please please please release something for Vista x64 and ODAC/ODP.  Even an alpha.  I promise I will test on an x86 machine before I release..

Technorati Tags: ,

Powered by WordPress

Switch to our mobile site