888-898-3404

ROK Blog

ArcIMS Tomcat on Windows 2003 - Redirector Issue

Jason Harris - Thursday, July 14, 2005

Hey there everyone. If you are like me, you have at one time or another in the past struggled with getting Tomcat to work on your IIs based machine. Just the other day, I struggled with an install, only to give up in frustration.

The specs were: Windows Server 2003 standard Tomcat 5.028 ArcIMS 9.1

No matter what I did I couldn't get this thing to redirect to IIs. Port 8080 worked like a champ, so I knew Tomcat itself was ok. There is just something funky with iis6 I suppose. Anyway, a coworker of mine, Big LU took over the install, and late last night, he was able to get it going. He used the attached guide to help him through the install. I wish I knew where this guide came from so that we could give them proper credit, but I just don't know.

So, if you are one of those folks currently struggling with the Tomcat redirector issue, check out this guide: Click the download link below.


Jason Harris

ArcIMS 9.1 Issues - Follow up

Jason Harris - Friday, July 01, 2005

As many of you have read in the posting previous to this one, I have been doing a lot more direct connections to ArcSDE from ArcIMS. We'll I've been having a bit of trouble with a few things, but no big deal....However I did discover a few new things about ArcIMS 9.1.

I read about a new parameter for connection to ArcSDE on the ArcIMS whats new page:

"For Image and Feature services that use ArcSDE data, a new feature parameter defines the time interval between attempts to reconnect to ArcSDE when the SDE server becomes unavailable."

wOOt! Sounds great to me, so I go looking for it. Looks like its located in the %arcims install dir%\server\etc\aimssdeio.cfg. Open up that file and look at the new parameter connectioncheckinterval="300". First thing that came to mind for me was this is could be why it was taking my mapservices so freaking long to refresh (see this post for more info). I don't know that for sure, but I'm guessing that it is, so I immediately lowered that number to 20. I'll let you know what happens.

The next thing I noticed was a new log file getting created in that same etc directory called sdedc_SQL Server.log. Of course I check it out, because I am all about log files. Its a great start to just have a log file specifically for direct connections, but this didn't really contain a whole lot of useful information.

IDBInitialize::Initialize Failed CAN'T OPEN INSTANCE: sde:sqlserver. Spatial Engine Connection Failed (-9).

Yeah, I already know that. Thanks for nuttin. But, I applaud ESRI for recognizing the need for that log file, and I hope that with future releases, we'll get some more info. By the way, I left encrypted="true" in my sdeworkspace - and thats what threw the error above.


Jason Harris

ArcSDE Based ArcIMS Service Errors - Direct Connect Solution

Jason Harris - Tuesday, June 21, 2005

Howdy Folks....I had a lot of trouble with an app of mine last week. It took me a while to pin this one down. I hadn't seen any info posted anywhere on this before, so here we go...

Here is the info...

SDE 9 with sp3 SQL Server 2k IMS 9 with sp3 ServletExec 5 Jre 1.4.2 TCP keepalive is set to True on the Arcsde box

I have this application that will work fine for a few hours, and then bam, it will start throwing errors. Looking through the ArcIMS logs, I get:

[Jun 14, 2005 10:20:00 AM][3468 4000 ERROR] [ERR2407] (SDE error code -10 ) SE_stream_query : Network I/O error

I get the above most of the time, but depending on what I'm doing the application at the time (query, map request, etc), I may get the one of the following:

[Jun 14, 2005 7:38:47 AM][3500 3684 ERROR] [ERR2402] Field #SHAPE# not found.

[Jun 13, 2005 8:11:52 PM][3236 4044 ERROR] [ERR2407] (SDE error code -38 ) SE_stream_execute : Attribute column not found

[Jun 13, 2005 7:58:24 PM][3236 4068 ERROR] [ERR2407] (SDE error code -10 ) SE_layer_get_info : Network I/O error

The weird part is this...one REQUEST (image or query) will work one second, and the next it will fail with one of the above showing up in the errlog. It almost seems to alternate for a while between working and failing, then it will all seem to work fine for another hour, and then the problem shows up again for a while

My best guess is that this is a communication break between ArcIMS and SDE. After a lot of trial and error, we decided to try direct connect a try...Guess what? That did the trick! We have been error free for a week+ now.

Here is a quick primer on Direct Connect for those who are unfamiliar. Direct connect is another way of connecting to ArcSDE. All of the ArcGIS clients now (since 8.2 I think?) ship with all the necessary libraries to connect to ArcSDE without going though ArcSDE. In other words, the work that ArcSDE traditionally performs can be 'sidesteped'. There are some finer points to it, but essentially, you just need to add an SDEHOME environment variable to point to the %arcims install directory%\ArcGIS\ArcIMS\Server and then change your ArcSDE AXL connection string to instance="sde:sqlserver:datasourcename" instead of instance="port:5151" (or whatever your port is).

So, moral of the story - if you are having ArcSDE - ArcIMS based connectivity issues, it never hurts to try direct connect!


Jason Harris

ArcIMS 9.1 Issues?

Jason Harris - Thursday, June 09, 2005

It may just be my inistall, not sure...But, I have had some weird issues with ArcIMS 9.1. Don't get me wrong, I am a huge fan of v9. Almost 100% stable and far fewer issues (mainly that nastiness of aimserver.exe's restarting themselves without recycling and 'loosing' their connection to SDE pre version 9)

But, here are 2 things that I have noticed.

* The map services appear to take much longer to 'refresh' themselves. I'm a keen watcher of those aimserver.exe's after you refresh the 3 services (monitor, tasker, app server). I know just how much memory they take and how much cpu time they take to complete a refresh. I don't know, this could be caused by somthing with ArcSDE 9.1 as 90% of my map services are ArcSDE based. * A simple buffering that has been working in production for almost 3 years suddenly began to fail. The error I was getting in the ArcIMS logs was a arcsde stream error 'Field Not Found' which I thought was extra bizarre. Whats even weirder is that fact that refreshing the 3 services (monitor, tasker, app server) fixed the issue.

All that being said, I'm not ready to blame ArcIMS for it yet. There are other things that could have casued these issues I suppose. So, these are just some quick observations after having 9.1 installed for a week or so. I plan to keep a close eye on it and I'll let ya'll know what I find.


Jason Harris

Mapdex is to ArcIMS what Google is to Websites

Jason Harris - Wednesday, May 18, 2005

You guys have to check this out. This site was done by a fellow Coldfusion programmer Jeremy Bartley. He'll be presenting it at this years ESRI User Conference. Here is the abstract. If you are going this year, I would highly recommend you check it out.

Do you want to find and use over 1,300 Landsat scenes? 3,500 ortho layers? 6,500 parcel layers? 18,000 road layers? All publicly accessible over the Internet as a map service? If so, then you need Mapdex. Mapdex is an index of publicly available ArcIMS services comprising 1,400 servers, serving 24,500 map services, containing over 400,000 GIS Layers, covering more than 3,250,000 columns! Mapdex is built on the Google premise. If you are publishing geospatial data, then Mapdex will harvest that information and share it to the broader international community. Mapdex is built with the Google Web Service API, ESRI ArcIMS, Oracle XMLDB, and ColdFusion MX. Using Mapdex will allow you to locate and use spatial information from all over the world. Mapdex also allows you to map multiple map services simultaneously from within one Web-based application.

Take your geoportal to the next step at http://www.mapdex.org

Jason Harris

Using ArcIMS Antialiasing In Layer Renderers

Jason Harris - Tuesday, May 10, 2005

For the longest time, I didnt really even realize that you could use antialiasing='true' in your layer renderers. Of course, I had always used this when doing any type of labeling, but never in layer renderers. It works exceptionally well in some cases and not much of a difference in others. Using it looks very nice when doing line features, such as streets.

This is the typical way that I render my street layers and it looks so much better when using antialiasing:


<GROUPRENDERER>
<SIMPLERENDERER>
<SIMPLELINESYMBOL width="4" antialiasing="true" captype="round" color="192,126,61" />
</SIMPLERENDERER>
<SIMPLERENDERER>
<SIMPLELINESYMBOL width="2" antialiasing="true" captype="round" color="255,255,255" />
</SIMPLERENDERER>
</GROUPRENDERER>


Jason Harris

ArcIMS Administrator Problems

Jason Harris - Friday, April 29, 2005

We were just doing a remote ArcIMS install for a client and ran into something that I have not seen before. This was probably the 300th install (seriously) that I had done and this was the first instance of this issue that I have ever seen.

What was happening was this: Fresh install (CFMX using JRUN on Win 2003), diagnostics all OK. Then when we tried to start the administrator, the usual first time prompt for user name and desired password appears, which is all normal. After inputing that information, the admin would just hang. Nada.

So, it seems for some very bizarre reason, ArcIMS was not able to create the initial AimsAdmPw file in %install dir%\AppServer. So, after copying an existing AimsAdmPw file over to the new installation, everything worked as expected. Only rub: you'll need an existing file for this solution to work.


Jason Harris

Nice use of buffering and demographics

Jason Harris - Friday, April 29, 2005

This site that I did has been out there for a while, but I thought I would share it now becasue it does have some interesting geographical components to it. To be honest, the mapping portion is not all that impressive...it was done so that it the frontend was very very easy to understand and navigate for the less-than-average-user.

Its a site for Caldwell County, NC and its designed to give prospective business owners access to on the fly demographic data. It essentially buffers a property and returns the census block groups that are within that buffer. It then sums all the rows of data up and creates percentages, etc etc.

So it makes this very sharp report..but then what. Well, you can print it, save it, email it, etc. In fact, just about anything that you can create and output to the browser, you should be able to:

* store as url variables * insert into a db, text file, etc * recall them when requested by the user at a later date

Think about all those possibilities. Store user sessions, map extents, layer lists, renderering preferences, etc...

Site was written in Coldfusion with the Coldfusion ArcIMS Connector and the backend db was sql server and ArcSDE 8.3


Jason Harris

How To Draw A Circle or Buffer a Point

Jason Harris - Tuesday, April 26, 2005

eah, it sounds simple enough, but it can be a real pain if you don't know where to start.

Basically, drawing a circle is the same a buffering a point. But what if you don't have a point feature to buffer? What if you would like to buffer a users click instead? Ah, thats where this little code snippet will come in handy.

The basica idea is this:

* capture the users click * create the circle (or radius or whatever you want to call it) * 'draw' the cicle in an acetate layer * perform a spatial query with those same coords

This code is in Coldfusion, but it should be fairly easy to move this to any other languge.


<!--- create the circle --->


<cfset CurWidth = MaxX - MinX>
<cfset CurHeight = MaxY - MinY>
<cfset r = #RadiusDistance#>
<cfset h = #RadiusX#> <!--- user click --->
<cfset k = #Radiusy#> <!--- user click --->
<cfset numTo = 360>
<cfset lCoords = "">
<!--- steps by 12 to draw the circle; 1 would be more accurate, but take longer --->
<cfloop index="i" from=0 to=#numTo# step="12">
<cfset cirX = (cos(i * Pi()/180) * r) + h>
<cfset lCoords = ListAppend(lCoords, cirX)>
<cfset cirY = (sin(i * Pi()/180) * r) + k>
<cfset lCoords = ListAppend(lCoords, cirY)>
<cfset lCoords = ListAppend(#lCoords#, ";")>
</cfloop>

<cfset lCoords = ListChangeDelims(#lCoords#, " ")>
<cfset RadiusCoords = lCoords>

<Cfif LEN(RadiusCoords) neq 0>
<!--- Using this to close the polygon with the first coord in the list --->
<cfset LastCoord = #GetToken("#RadiusCoords#",1,";")#>
</CFIF>

<!--- here is the request you would send to the queryserver --->

<?xml version="1.0"?>
<ARCXML version="1.1">
<REQUEST>
<GET_FEATURES outputmode="newxml" geometry="false" envelope="true" compact="false" featurelimit="250">
<LAYER id="#Session.LayerID#"/>
<SPATIALQUERY featurelimit="250" searchorder="spatialfirst" subfields ="##SHAPE## objectid">
<SPATIALFILTER relation="Area_Intersection">
<POLYGON>
<RING>
<Cfloop list="#Radius#" index="Coord" delimiters=";">
<POINT x="#GetToken("#Coord#",1," ")#" y="#GetToken("#Coord#",2," ")#" />
</CFLOOP>

</RING>
</POLYGON>
</SPATIALFILTER>
</SPATIALQUERY>
</GET_FEATURES>
</REQUEST>
</ARCXML>

Jason Harris

Registered Sex Offender GIS Search Site

Jason Harris - Tuesday, April 26, 2005

Just completed a very, very simple site for Santa Rosa County, Florida. Its purpose is simple: Locate your property, and then locate any registered sex offenders within xxx distance of your property. I'm surprised that there aren't more 'GIS' based applications out there. I have a ton of text based address searches, but not too many that will let you perform a radius search. Anyway, here is is: http://maps.roktech.net/santarosa/sexualoffender/

Santa Rosa County took the 'simple' approach to their GIS sites. They felt that there was too much functionality packed into county gis applications, so instead they had us develop a suite of 8 applications (and ever growing) that focus on very simple, straightforward tasks, like school locator, zoning, etc. All of their sites are using Coldfusion 6.1, ArcIMS, ArcSDE, and SQL server.


Jason Harris

Recent Posts


Tags


Archive

All content © ROK / Website by Hazel Digital Media