Mapscript c# problems and apache2 scratches

Xavier Mauclaire xavier.mauclaire at GEOTER.FR
Mon Jun 26 12:09:00 EDT 2006


Hi Tamas

I've done a tool that allows, by clicking on the map, to select the polygon
in the postgis database. With this object loaded, i query other objects
using the querybyshape function. After i produce an htlm report.
If i click slowing in the map, no problem.
If i click on several objets quickly the problems occurs.
I don't know if  i would be enabled to reproduce the problem with a little
program. I'm going to work about this

The function source is : 

		private shapeObj localiser_parcelle(Double dX, Double dY,
out String zParcelleIdent){
			shapeObj pShape = null;
			zParcelleIdent = "";
			
			int liRes ; 

			try {
				// recupération de la layer des parcelle
				// celle dont le nom est
CONST_LAYERNAME_PARCELLE
				layerObj pLayerParcelle =
pMapQuery.getLayerByName(cConstantes.CONST_LAYERNAME_PARCELLE);
			
				if(pLayerParcelle != null){
					// creation du poitn de localisation
					pointObj pPoint = new pointObj(dX,
dY,0.0,0.0 );

					// on recherche la parcelle au point
cliqué
	
pLayerParcelle.queryByPoint(pMapQuery,pPoint,mapscript.MS_SINGLE,0);
					resultCacheObj pRes =
pLayerParcelle.getResults();
					
					try{
						resultCacheMemberObj
pResMember = null;

						if(pRes.numresults > 0) {
							//on zoom sur la
selection courante

	
pMapQuery.setExtent(pRes.bounds.minx,pRes.bounds.miny,pRes.bounds.maxx,pRes.
bounds.maxy);					
 
	
pLayerParcelle.open();
							try{
								//
récupération de la première parcelle
								pResMember =
pRes.getResult(0);
								pShape =
pLayerParcelle.getFeature(pResMember.shapeindex, pResMember.tileindex);
								if(pShape !=
null) {
							// récupération de
l'identifiant de la parcellle
	
Int32 liRang = -1;
									//
recherche rang champs
	
liRang = cRegInfos.SetLayerFieldRang(pLayerParcelle,
cRegInfo.CONST_IDPARCELLE);
	
zParcelleIdent = pShape.getValue(liRang);
								} //end if 
							}finally{
	
pLayerParcelle.close();
							} //e nd finally
						} //e nd if
					} finally {
						pRes.Dispose();
						pRes = null;
					} //e nd finally		
					pLayerParcelle.Dispose();
					pLayerParcelle = null;
				} else
					throw new Exception("Couche des
parcelles introuvable"); 
				
			
			} finally{
	

			} //end finally 


			return pShape;

	} //end fucntion


regards

-----------------------------------------
Xavier Mauclaire
Service informatique
GEOTER SAS
3, rue Jean Monnet
34830 Clapiers France
Tél.: +33 (0)4.67.59.18.11
Fax: +33 (0)4.67.59.18.24 
Email: xavier.mauclaire at geoter.fr
Web site: http://www.geoter.fr
-------------------------------------------------------

 

-----Message d'origine-----
De : Tamas Szekeres [mailto:szekerest at gmail.com] 
Envoyé : lundi 26 juin 2006 17:55
À : Xavier Mauclaire
Cc : MAPSERVER-USERS at lists.umn.edu
Objet : Re: Mapscript c# problems and apache2 scratches

Xavier,

Could you extract the problem as a sample application, like you have done
with the previous issue?
How did you make the test? How many requests should be made? Is the problem
deterministic of occurs randomly at different functions.

Tamas


2006/6/26, Xavier Mauclaire <xavier.mauclaire at geoter.fr>:
>
>
> HI
>
> New problem with the mapscript c# library.
> I'm doing a web site using, among others, querybyshape function. If 
> there are several requests using this function i scratches the server
>
>



More information about the mapserver-users mailing list