Jetspeed preferences or the Portal api preferences are getting on my nerves. I am specifying preferences in the psml file. When I debug I get calls to two separate FragmentImpl.getPreferences methods.
The first is a call to the FragmentImpl in package,
org.apache.jetspeed.om.page.psml
Which is related to the portlet itself.
The second is a call to the FragmentImpl in package,
org.apache.jetspeed.om.page.impl
Which is related to layouts.
The fist call populates a o.a.j.om.preference.impl.FragmentPortletPreferenceSet from o.a.j.om.page.ContentFragmentImpl. Then pluto eats the preference and I never see it in my portlet.
Everything Java Apache Geospatial Open Source. Hello Shinning Stars!!! Vincent Massol, Raphael Luta, Santiago Gala, Carsten Z.
Tuesday, April 11, 2006
Monday, April 03, 2006
Caused by: java.lang.IllegalArgumentException: Illegal pattern character 'x'
Hmm, this is the second time I got this exception using Andromda. It is caused by an invalid character in my @andromda.presentation.view.field.format tagged value. Dates can not use the 'maxlength 10' value 'strict dd/MM/yyyy' is better validation rule.
Hmm, this is the second time I got this exception using Andromda. It is caused by an invalid character in my @andromda.presentation.view.field.format tagged value. Dates can not use the 'maxlength 10' value 'strict dd/MM/yyyy' is better validation rule.
Sunday, January 29, 2006
Geronimo is a truly modular application server. It can be build to run any particular war or ear with only the components that it needs. If your application is not running jms then build geronimo without activemq. If it is not using ejb then build it without openejb. This allows for a leaner faster application server, customized to run only the components that are needed.
Wednesday, January 25, 2006
Geronimo blogging is back, Andromda, MapServer, and Jetspeed news will follow. This is a list of some important modules built during the 'maven new' compile.
Geronimo :: Kernel
Geronimo :: Common
Geronimo :: Util
Geronimo :: System
Geronimo :: Deployment
Geronimo :: Core
Geronimo :: Management API
The first interesting thing to look at apart from the architecture which includes Kernel and Core, is the Management API. This programming interface allows you to control all GBeans installed in the system.
Geronimo :: J2EE
Geronimo :: J2EE Schema
Geronimo :: Service :: Builder
Geronimo :: Maven Dependency Plugin
Geronimo :: Security
Then checkout Security. All the standards are here JAAS and JACC.
Geronimo :: Web Services
Geronimo :: Axis
Geronimo :: Mail
Geronimo :: Deploy :: Common Config
Geronimo :: Test :: DDBeans
Geronimo :: Naming
Geronimo :: Security :: Builder
Geronimo :: J2EE
Geronimo :: Naming :: Builder
Geronimo :: Web :: Builder
Geronimo :: Transaction
Geronimo :: Connector
Geronimo :: Tomcat
Geronimo :: Connector :: Builder
Geronimo :: Axis :: Builder
Geronimo :: Tomcat :: Builder
Geronimo :: Derby
Geronimo :: Jetty
Geronimo :: Timer
Geronimo :: Client
Geronimo :: Client Builder
Geronimo :: Scripts
Geronimo :: Session
Geronimo :: Deploy :: JSR-88
Geronimo :: Jetty :: Builder
Geronimo :: Activation
Geronimo :: Configuration Converter
Geronimo :: Console Web
Geronimo :: JMX Remoting
Geronimo :: Installer Support
Geronimo :: JavaMail Transport
Geronimo :: Deploy :: CLI Tool
Geronimo :: Directory
Geronimo :: Installer Processing
Geronimo :: Deploy :: Hot Deployer
Geronimo :: Maven Deployment Plugin
Geronimo :: Maven Assembly Plugin
Geronimo :: IZPack Installer Build Plugin
Geronimo :: Maven Packaging Plugin
Geronimo :: Kernel
Geronimo :: Common
Geronimo :: Util
Geronimo :: System
Geronimo :: Deployment
Geronimo :: Core
Geronimo :: Management API
The first interesting thing to look at apart from the architecture which includes Kernel and Core, is the Management API. This programming interface allows you to control all GBeans installed in the system.
Geronimo :: J2EE
Geronimo :: J2EE Schema
Geronimo :: Service :: Builder
Geronimo :: Maven Dependency Plugin
Geronimo :: Security
Then checkout Security. All the standards are here JAAS and JACC.
Geronimo :: Web Services
Geronimo :: Axis
Geronimo :: Mail
Geronimo :: Deploy :: Common Config
Geronimo :: Test :: DDBeans
Geronimo :: Naming
Geronimo :: Security :: Builder
Geronimo :: J2EE
Geronimo :: Naming :: Builder
Geronimo :: Web :: Builder
Geronimo :: Transaction
Geronimo :: Connector
Geronimo :: Tomcat
Geronimo :: Connector :: Builder
Geronimo :: Axis :: Builder
Geronimo :: Tomcat :: Builder
Geronimo :: Derby
Geronimo :: Jetty
Geronimo :: Timer
Geronimo :: Client
Geronimo :: Client Builder
Geronimo :: Scripts
Geronimo :: Session
Geronimo :: Deploy :: JSR-88
Geronimo :: Jetty :: Builder
Geronimo :: Activation
Geronimo :: Configuration Converter
Geronimo :: Console Web
Geronimo :: JMX Remoting
Geronimo :: Installer Support
Geronimo :: JavaMail Transport
Geronimo :: Deploy :: CLI Tool
Geronimo :: Directory
Geronimo :: Installer Processing
Geronimo :: Deploy :: Hot Deployer
Geronimo :: Maven Deployment Plugin
Geronimo :: Maven Assembly Plugin
Geronimo :: IZPack Installer Build Plugin
Geronimo :: Maven Packaging Plugin
Tuesday, December 06, 2005
Thursday, December 01, 2005
I've been studying the data access methods used by MapServer and in theory any ODBC connection can be used to obtain data from a relational database. That's probably what we want. Afterwords all we need is a nifty car icon to indicate the direction that the car is travelling (the direction part may be tricky). MapServer uses SYMBOLS to label geo features using an icon image.
MapServer supports four categories of data access. The first is the basic file method. It can access files of type shape, arcinfo, mapinfo, us census tiger, csv, etc. These are read only methods of accessing data. Other sources could update these files and MapServer would get the updates. This wouldn't be a good idea because there could be a io conflict.
ODBC can be used to access relational databases (SQL Server, Oracle, MySQL, and company)
The third category of data access is not applicable to our work. MapServer can access data provided by a Spatial database engine like ArcSDE, Oracle Spatial, or PostGIS. These solutions provide spatial indexing and special geographic types. I think this is out of our scope. It would take longer to set up, it is more complex to install. I would suggest exploring this option if you expect to address larger clients.
The last thing that I want to tell you about is MapScript. MapServer exposes their application programing interface so that hackers and integraters can do custom things with MapServer in the language of their choice (Java,PHP,Perl,Ruby). We are not using it but It can be used to create maps and plot data, as well as query data. I will deliver you an example that I found on the net.
And lastly, I looked at your database and the GPSActive table looks like it could be plotted on the Map using the ODBC solution. There were duplicates in the table but they had the same latitude and longitude. MapServer will plot all data from the table. If we want to get fancy and label each car with their own icon we will have to read the database using PHP and plot using MapScript. Give me some more thoughts on what you need.
MapServer supports four categories of data access. The first is the basic file method. It can access files of type shape, arcinfo, mapinfo, us census tiger, csv, etc. These are read only methods of accessing data. Other sources could update these files and MapServer would get the updates. This wouldn't be a good idea because there could be a io conflict.
ODBC can be used to access relational databases (SQL Server, Oracle, MySQL, and company)
The third category of data access is not applicable to our work. MapServer can access data provided by a Spatial database engine like ArcSDE, Oracle Spatial, or PostGIS. These solutions provide spatial indexing and special geographic types. I think this is out of our scope. It would take longer to set up, it is more complex to install. I would suggest exploring this option if you expect to address larger clients.
The last thing that I want to tell you about is MapScript. MapServer exposes their application programing interface so that hackers and integraters can do custom things with MapServer in the language of their choice (Java,PHP,Perl,Ruby). We are not using it but It can be used to create maps and plot data, as well as query data. I will deliver you an example that I found on the net.
And lastly, I looked at your database and the GPSActive table looks like it could be plotted on the Map using the ODBC solution. There were duplicates in the table but they had the same latitude and longitude. MapServer will plot all data from the table. If we want to get fancy and label each car with their own icon we will have to read the database using PHP and plot using MapScript. Give me some more thoughts on what you need.
Here is a simple script that I found using ms4w from maptools.org. It helped me get a grasp on MapScript PHP for MapServer.
<?php
/*
Application: QuickMap
Purpose: Use this file to test mapfiles
Authors: Bill Bronsema (bbronsema@dmsolutions.ca)
Philip Donaghy (philip.donaghy@gmail.com)
Copyright: 2005, DM Solutions Group Inc.
Instructions: - modify the MAPFILE path and the name of the phpmapscript
MODULE (lines 16 & 17)
- in a web browser goto http://127.0.0.1/quickmap.php
- an image of your data should be displayed in your browser, or
a MapServer error
*/
// define variables
define( "MAPFILE", "map/MorganCo.map" );
define( "MODULE", "php_mapscript_44.dll" );
// load the mapscript module
if (!extension_loaded("MapScript")) dl(MODULE);
// open map
//$oMap = ms_newMapObj( MAPFILE, dirname( MAPFILE ) );
$oMap = ms_newMapObj( MAPFILE );
// set projection
//$oMap->setProjection("init=epsg:42304");
// set size
$oMap->setsize(1200, 700);
// set image format
$oMap->selectoutputformat("png");
// draw map
$oImage = $oMap->draw();
// set header
header("Content-type: image/png");
// output map
$url = $oImage->saveImage("");
?>
<?php
/*
Application: QuickMap
Purpose: Use this file to test mapfiles
Authors: Bill Bronsema (bbronsema@dmsolutions.ca)
Philip Donaghy (philip.donaghy@gmail.com)
Copyright: 2005, DM Solutions Group Inc.
Instructions: - modify the MAPFILE path and the name of the phpmapscript
MODULE (lines 16 & 17)
- in a web browser goto http://127.0.0.1/quickmap.php
- an image of your data should be displayed in your browser, or
a MapServer error
*/
// define variables
define( "MAPFILE", "map/MorganCo.map" );
define( "MODULE", "php_mapscript_44.dll" );
// load the mapscript module
if (!extension_loaded("MapScript")) dl(MODULE);
// open map
//$oMap = ms_newMapObj( MAPFILE, dirname( MAPFILE ) );
$oMap = ms_newMapObj( MAPFILE );
// set projection
//$oMap->setProjection("init=epsg:42304");
// set size
$oMap->setsize(1200, 700);
// set image format
$oMap->selectoutputformat("png");
// draw map
$oImage = $oMap->draw();
// set header
header("Content-type: image/png");
// output map
$url = $oImage->saveImage("");
?>
Monday, November 14, 2005
I'm thinking about Jetspeed documentation. Correct me if I'm wrong, it sucks, so what can be done about it. Here are things that can be done by Users, Developers, and Administrators.
User can CustomizeTheLayout, CustomizeTheStyle, CustomizeTemplates, CreatePages, CreateFolders, CreateSeparators, and CreateLinks.
Developers can WritePortlets, ConfigurePortlets, WriteLayouts, WriteStyles, as well as anything a user can do.
Administrators can InstallJetspeed, OptimizeJetspeed, ClusterJetspeed, CreateUsers, CreateGroups, and CreateRoles. As well as anything a user or developer can do. They are extremely lazy people who often say "That's the developers job".
User can CustomizeTheLayout, CustomizeTheStyle, CustomizeTemplates, CreatePages, CreateFolders, CreateSeparators, and CreateLinks.
Developers can WritePortlets, ConfigurePortlets, WriteLayouts, WriteStyles, as well as anything a user can do.
Administrators can InstallJetspeed, OptimizeJetspeed, ClusterJetspeed, CreateUsers, CreateGroups, and CreateRoles. As well as anything a user or developer can do. They are extremely lazy people who often say "That's the developers job".
[#JS2-188] Implement the LDAP - ASF JIRA summarizes the development of LDAP authentication and authorization.
Another important feature of Jetspeed is its ability to integrate with Apache Derby.
Another important feature of Jetspeed is its ability to integrate with Apache Derby.
The Jetspeed issue tracker, Browse Project - ASF JIRA, provides quick access to outstanding, resolved, added, updated, and important bugs.
The most significant recently added to jetspeed are translations, portlet api compliance, statistics and page manager implementations.
The most significant recently added to jetspeed are translations, portlet api compliance, statistics and page manager implementations.
Sunday, November 13, 2005
Installing wifi card on my toshiba 1800-100 with suse 10.0 and ndiswrapper. The card is a Belkin 54g "High-Speed Mode Wireless G Notebook Network Card" model number is f5d7011. The ndiswrapper package version 1.5 requires the kernel sources and gcc which were not installed by default by suse 10.0.
Just follow the ndiswrapper guide and it should work.
Just follow the ndiswrapper guide and it should work.
Wednesday, November 09, 2005
A MapServer portlet requires the following elements:
MapServer is a C program therfore you must obtain the proper version for your target operating system. Linux and Unix users will find that downloading the source and compiling it is the simplest alternative. Listed here are links to MapServer source and its required dependencies. Build each of these packages using the ./configure, make, and sudo make install commands. Building MapServer will tell you which dependencies are missing on your system.
MapServer-4.6.1 source code
GD-2.0.33 source code
Freetype-2.1.10 source code
Jpeg-6b source code
Png-1.2.8 source code
Windows users can use the ms4w package provided by maptools.org.
Mac OS users will find help here.
Geographic Data
The MapServer demo includes some sample geographic data.
MapServer Configuration
MapServer is configured using a MapFile. The demo configuration file is itasca.map.
Apache Portal Bridge for MapServer
A contribution to the Apache Portal Bridges project yeilded a component capable of executing the MapServer program. This bridge uses the portlet initalization parameters to determine the inital map. MapScript for Java is on the roadmap.
Jetspeed Configuration
A simple modification to any existing portlet.xml is enough to deploy a new MapServer map. See the attachment in the Jira issue.
- MapServer Software
- Geographic Data
- MapServer Configuration
- Apache Portlet Bridge for MapServer
- Jetspeed Configuration
MapServer is a C program therfore you must obtain the proper version for your target operating system. Linux and Unix users will find that downloading the source and compiling it is the simplest alternative. Listed here are links to MapServer source and its required dependencies. Build each of these packages using the ./configure, make, and sudo make install commands. Building MapServer will tell you which dependencies are missing on your system.
MapServer-4.6.1 source code
GD-2.0.33 source code
Freetype-2.1.10 source code
Jpeg-6b source code
Png-1.2.8 source code
Windows users can use the ms4w package provided by maptools.org.
Mac OS users will find help here.
Geographic Data
The MapServer demo includes some sample geographic data.
MapServer Configuration
MapServer is configured using a MapFile. The demo configuration file is itasca.map.
Apache Portal Bridge for MapServer
A contribution to the Apache Portal Bridges project yeilded a component capable of executing the MapServer program. This bridge uses the portlet initalization parameters to determine the inital map. MapScript for Java is on the roadmap.
Jetspeed Configuration
A simple modification to any existing portlet.xml is enough to deploy a new MapServer map. See the attachment in the Jira issue.
Thursday, November 03, 2005
Tuesday, October 25, 2005
I am going to write a MapServer portlet. The mapserv cgi script can be used on the command line like this.
The parameter program will be replaced by a servlet mapping. Therefore all request to the url, /browse/map, will be redirected to the mapserver.
The template will have all
A MapServerPortlet class will implement the doView method and encapsulate the mapserv binary execution. The portlet requires the following settings, the location of the mapserv binary, the location of the map file, the initial layer to display, the template to use, the absolute uri to the servlet mapping, the temporary image directory, the temporary image uri, the zoom mode, the zoom value.
A Jetspeed bridge is required. It is based on the Perl bridge which was too busy for the mapserver needs, so I just adapted it to the simplicity of mapserver.
./mapserv QUERY_STRING="layer=Citylimits&layer=Citywards&zoomdir=1&zoomsize=2&map=%2Fms4w%2FApache%2Fhtdocs%2Fmap%2FMorganCo.map&program=%2Fcgi-bin%2Fmapserv&root=%2Fmap&map_web_imagepath=%2Ftmp%2F&map_web_imageurl=%2Fmap%2Ftmp%2F&map_web_template=map.html"
The parameter program will be replaced by a servlet mapping. Therefore all request to the url, /browse/map, will be redirected to the mapserver.
The template will have all
htmland
bodytags removed so that it is an html page fragment.
A MapServerPortlet class will implement the doView method and encapsulate the mapserv binary execution. The portlet requires the following settings, the location of the mapserv binary, the location of the map file, the initial layer to display, the template to use, the absolute uri to the servlet mapping, the temporary image directory, the temporary image uri, the zoom mode, the zoom value.
A Jetspeed bridge is required. It is based on the Perl bridge which was too busy for the mapserver needs, so I just adapted it to the simplicity of mapserver.
MapServer 4.6 requests can probably be broken down into the following steps. Here the common name is presented along with its corresponding code fragment and/or the name of the source file.
- Create a mapserver object using mapserv.c.loadParams and mapserv.c.loadMap
- Parse parameters mapserv.c.loadForm
- Determine the mode. One of three are know to me, browse,query, and nquery. This is determined by the msObj.Mode property. Most of this logic is in mapserv.c.main.
- Extent, scale, and query files are evaluated using mapserv.c.setExtent mapserv.c.checkWebScale and mapserv.c.msLoadQuery
- Images are generated using maptemplate.c.msGenerateImages
- Map is drawn using mapdraw.c.msDrawMap
- Map is drawn using mapdraw.c.msDrawQueryMap
- Legend is drawn using maplegend.c.msDrawLegend
- Scalebar is drawn using mapscale.c.msDrawScalebar
- Reference map is drawn using mapraster.c.msDrawReferenceMap
- Two maps on one page.
Sunday, October 23, 2005
Implicit versus explicit application development. Creating a application that relies on implicit configuration or rules is a bad idea. I came across a struts configuration in Jetspeed that made me think of this subject. A $M$P pattern indicated that pages exist with the /module/path. Although this case is not an implicit declaration programming with out explicitly declaring classes, configuration, or properties will only create confusion and hard to debug applications.
Subscribe to:
Posts (Atom)
