Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [udig-devel] problem with configuration of log4j

Hi,

Thanks for your help.

I did the same steps described in the custom app tutorial, but I have one exception when i want to export my product :

Unable to find feature "org.eclipse.rcp" with version in range [3.7.0.v20110216-9DB5Fm1FpBGy_AaVz-mFamgY,3.7.0.v20110216-9DB5Fm1FpBGy_AaVz-mFamgY].

In the dependencies tab i put this :
org.eclipse.rcp (3.7.0.v20110216-9DB5Fm1FpBGy_AaVz-mFamgY)
net.refractions.udig.base ...

I tried to delete the version but i had the same problem

thank you

2012/1/12 Jody Garnett <jody.garnett@xxxxxxxxx>
Have a read through the custom app tutorial!

You can define your product to export two ways:
1) as a list of features (where the features are the same thing that is published to an update site; basically a group of plugins that contribute one "idea" to your product). This is the one I recommend.

2) As a list of plugins. This is the one everyone else recommends (at least when they are starting out).

Can you try the Custom App tutorial and let me know if you have any questions?

-- 
Jody Garnett
Sent with Sparrow

On Thursday, 12 January 2012 at 7:59 PM, ilyass ahrazem wrote:

Hi,
I have developed a RCP Eclipse application that uses sdk udig. Now i want to export it to have an executable. 
I developed 7 bundles (plug-ins). It is possible to make an executable with more than one plug-in ?, how i can do it ?

thanks for help

2011/11/25 Jody Garnett <jody.garnett@xxxxxxxxx>
Good afternoon:
I am developping a plugin which moves a point into a map.
the coordinates of the point are provide by a simulator.
Sounds fun. 
What i want to do is to detect if my point is displayed in the map or not, if not, i must center the map. I dont know how i can do that. It is possible to get the status of the glasspane associed to my point ? (visible, enable ...)
You can listen to the viewport model to detect any changes in its bounds (i.e. the area of the wold it is displaying). You can also issue a command the viewport to cause it to display the area of the screen you wish. The seagulls code provides something similar where the simulation of seagulls moves points around the screen; and you can ask the viewport to track one of them and move the map to follow the action.
I am using udig sdk 1.2.2, eclipse 3.7, jdk 1.6
I have an other problem with org.apache.log4j. I declare a property file log4j.properties :
#Loggers
log4j.rootLogger=DEBUG,stdout

log4j.logger.com.orange.ots.carfleetmanagement.core=DEBUG,corelogging
log4j.additivity.com.orange.ots.carfleetmanagement.core=true


# Console
log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.conversionPattern=%d [%t] %-5p %c - %m%n

# log carfleet

log4j.appender.corelogging=org.apache.log4j.ConsoleAppender
log4j.appender.corelogging.File=log/core.log
log4j.appender.corelogging.MaxFileSize=500KB
log4j.appender.corelogging.MaxBackupIndex=4
log4j.appender.corelogging.layout=org.apache.log4j.PatternLayout
log4j.appender.corelogging.layout.conversionPattern=%d [%t] %-5p %c - %m%n
log4j.appender.corelogging.append=false

This file must be used by all my plugins. I put it in the runtime location and i declare in my executable argument -Dlog4j.configuration = "path of file"
and it seems not working
I have not tried working with a custom configuration file yet myself; just letting it auto generate for me. I know that when you include a file in a plugin you have to be sure to check it in the build.xml file or it will not be wrapped up when you release your application. You may wish to look on the internet for a tutorial on eclipse  / log4g integration for an example.
I have to warnings when i run my application :
log4j:WARN No appenders could be found for logger (com.orange.ots.carfleetmanagement.core.Activator).
log4j:WARN Please initialize the log4j system properly.

I think the problem is the location of the properties file.
You may wish to set up something in your activator to configure the log4j system by hand; just so you can confirm it is working - and then go back to looking into how to pass it the property file.

You may even be able to use your activator to look up the property file in the configuration directory (which will change as it runs for each user on a system) and pass it over to log4j.

We do something similar to look up an epsg.properties file in the net.refractions.udig.libs plugin; as the geotools library has a similar need to be configured prior to use.

Jody

_______________________________________________
User-friendly Desktop Internet GIS (uDig)
http://udig.refractions.net
http://lists.refractions.net/mailman/listinfo/udig-devel


_______________________________________________
User-friendly Desktop Internet GIS (uDig)


_______________________________________________
User-friendly Desktop Internet GIS (uDig)
http://udig.refractions.net
http://lists.refractions.net/mailman/listinfo/udig-devel



Back to the top