This page: http://docs.geotools.org/latest/developer/conventions/code/log.html

It contains explanation how to turn on logging for a module.
But it does not explain what module to use. I thought a module was a package. 
This is not always the case as you explained earlier. 
Maybe for developers of the packages it is clear, but not for package users.


Ron



________________________________
 From: Jody Garnett <[email protected]>
To: Ron Lindhoudt <[email protected]> 
Cc: "[email protected]" 
<[email protected]> 
Sent: Wednesday, March 27, 2013 6:21 AM
Subject: Re: [Geotools-gt2-users] How do I turn on FINE Logging for package 
org.geotools.data.oracle?
 

Can you tell me what documentation page you went looking in - and I can add it 
:-) 


-- 
Jody Garnett


On Monday, 25 March 2013 at 7:14 PM, Ron Lindhoudt wrote:
Jody,
>
>Thanks for your answer.
>
>I finally got it working with:
>org.geotools.jdbc.level=FINE
>org.geotools.jdbc.SQLDialect.level=FINE
>
>This does not work: org.geotools.jdbc.logging.level=FINE
>
>It is not clear from any documentation.
>
>
>Ron
>
>
>________________________________
> From: Jody Garnett <[email protected]>
>To: Ron Lindhoudt <[email protected]> 
>Cc: "[email protected]" 
><[email protected]> 
>Sent: Monday, March 25, 2013 7:40 AM
>Subject: Re: [Geotools-gt2-users] How do I turn on FINE Logging for package 
>org.geotools.data.oracle?
> 
>
>In reviewing the code I do not see a log of logging at that level.
>
>
>1. SQL generation is often handled by SQLDialect which provides:
>
>
>protected static final Logger LOGGER = Logging.getLogger(SQLDialect.class);
>
>
>So either of the OracleDialect implementations should use this. So your 
>logging.properties should reference "org.geotools.jdbc.SQLDialect"
>
>
>2. JDBCDataStore makes use of a logger created by its superclass:
>
>
>this.LOGGER = org.geotools.util.logging.Logging.getLogger( 
>getClass().getPackage().getName());
>
>
>This should result in "org.geotools.jdbc"
>
>
>3. For actually running the SQL .. it happens where it is needed. The most 
>useful is JDBCFeatureReader (however it is not logging the SQL used).
>
>
>    public JDBCFeatureReader( String sql, Connection cx, JDBCFeatureSource 
>featureSource, SimpleFeatureType featureType, Hints hints ) 
>        throws SQLException {
>        init( featureSource, featureType, hints );
>        
>        //create the result set
>        this.cx = cx;
>        st = cx.createStatement(ResultSet.TYPE_FORWARD_ONLY, 
>ResultSet.CONCUR_READ_ONLY);
>        st.setFetchSize(featureSource.getDataStore().getFetchSize());
>        
>        
>((BasicSQLDialect)featureSource.getDataStore().getSQLDialect()).onSelect(st, 
>cx, featureType);
>        rs = st.executeQuery(sql);
>    }
>
>
>This class is called from a number of locations such as 
>JDBCFeatureSource.getReaderInternalQuery() - 
>
>
>                   //build up a statement for the content
>                    String sql = getDataStore().selectSQL(querySchema, 
>preQuery);
>                    getDataStore().getLogger().fine(sql);
>        
>                    reader = new JDBCFeatureReader( sql, cx, this, 
>querySchema, query.getHints() );
>
>
>So this is your best bet, "org.geotools.jdbc" set to FINE 
>-- 
>Jody Garnett
>
>
>
>On Sunday, 24 March 2013 at 6:05 PM, Ron Lindhoudt wrote:
> 
>>Hey,
>> 
>>How can I turn on FINE logging to display the sql statements in package 
>>org.geotools.data.oracle?
>>I tried several thing in logging.properties but nothing helps.
>>I also want to show sql statements that are executed in FeatureLayer during 
>>StreamingRenderer.paint.
>> 
>>Thanks.
>> 
>>Ron
>> 
>>------------------------------------------------------------------------------
>>Everyone hates slow websites. So do we.
>>Make your web apps faster with AppDynamics
>>Download AppDynamics Lite for free today:
>>http://p.sf.net/sfu/appdyn_d2d_mar
>>_______________________________________________
>>GeoTools-GT2-Users mailing list
>>[email protected]
>>https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users 
>
>
>
> 
------------------------------------------------------------------------------
Own the Future-Intel&reg; Level Up Game Demo Contest 2013
Rise to greatness in Intel's independent game demo contest.
Compete for recognition, cash, and the chance to get your game 
on Steam. $5K grand prize plus 10 genre and skill prizes. 
Submit your demo by 6/6/13. http://p.sf.net/sfu/intel_levelupd2d
_______________________________________________
GeoTools-GT2-Users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users

Reply via email to