You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@turbine.apache.org by pb...@wuerth-phoenix.com on 2002/05/28 15:57:00 UTC

RE: using the decoupled fulcrum services ? Follow up!!!!!!

"Selders, Bart" <ba...@ibanx.nl> said:

Gentlemen,

I also have problems to start a Fulcrum service, the scheduler.
Personally i do not think that it is a problem of logging.
We should ask the persons who have written fulcrum if they can give us an
HowTo   on how to start the services.

I use turbine(tdk 2.2) and i would like to use fulcrum scheduler.

Greetings

Fabio Daprile

> Uwe,
> 
> In order to get Fulcrum to log I had to do one of the following:
> 
> - Either create a log4j.properties file and put it in WEB-INF/classes
>   See log4j website for details on what to specify.
> 
> - Or alternatively (and easier for T2.2 users) log everything in one log
> file
>   To do that I use the following log settings in TR.properties:
> 
>    services.LoggingService.facilities=system,debug,security,logforj
>    services.LoggingService.default=logforj
>    services.LoggingService.loggingConfig=
> org.apache.turbine.services.logging.PropertiesLoggingConfig
> 
>    services.LoggingService.logforj.log4j.rootCategory = ALL, logforj
>    services.LoggingService.logforj.log4j.category.logforj = ALL, logforj
>    services.LoggingService.logforj.log4j.appender.logforj.file
> =${webappRoot}/logs/turbine.log
>    services.LoggingService.logforj.log4j.appender.logforj =
> org.apache.log4j.FileAppender
>    services.LoggingService.logforj.log4j.appender.logforj.layout =
> org.apache.log4j.PatternLayout
>  
> services.LoggingService.logforj.log4j.appender.logforj.layout.conversionPatt
> ern = [%d{ABSOLUTE} %-5p] %m%n
>    services.LoggingService.logforj.log4j.appender.logforj.append = false
>  
> services.LoggingService.logforj.className=org.apache.turbine.services.loggin
> g.Log4JavaLogger
>    services.LoggingService.logforj.level=ALL
> 
> Set the level to one of: ALL, DEBUG, INFO dependent on your need.
> 
> Success.
> 
> Bart
> 
> -----Original Message-----
> From: Schmidt, Uwe
> To: Turbine Users List
> Sent: 5/26/02 6:38 PM
> Subject: using the decoupled fulcrum services ?
> 
> Hi 
> 
> I have recently switched to turbine 2.2b1. To complete this I try to
> switch 
> from the integrated turbine services to the decoupled fulcrum services.
> As a first aproach I simply tried to replace the Localization-Service.
> It seems that the fulcrum services are not initialized at all.
> How can I use them. It seems that I have missed something.
> 
> This is the error message I get in the log file:
> 
> Error rendering Velocity template: screens/Index.vm: Invocation of
> method
> 'setLanguage' in  class de.gea.wiegand.teben.tools.Session threw
> exception
> class org.apache.fulcrum.InstantiationException : ServiceBroker: Unknown
> Service 'LocalizationService' requested
> 
> [Fri May 24 18:19:38 CEST 2002] -- ERROR -- Error rendering Velocity
> template: screens/Index.vm: Error rendering Velocity template:
> screens/Index.vm: Invocation of method 'setLanguage' in  class
> de.gea.wiegand.teben.tools.Session threw exception class
> org.apache.fulcrum.InstantiationException : ServiceBroker: Unknown
> Service
> 'LocalizationService' requested
> 
> The localization is activated in the fulcrum.properties file, but there
> are no fulcrum messages in the log file at all ....
> (I�ve already tried several combinations of the path to
> fulcrum.properties
> ;-(  )
> 
> Any ideas ?
> 
> thanks
> 
> Uwe
> 
> --
> To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> For additional commands, e-mail:
> <ma...@jakarta.apache.org>
> 
> 
> *************************************************************************
> The information contained in this communication is confidential and is
> intended solely for the use of the individual or entity to  whom it is
> addressed.You should not copy, disclose or distribute this communication 
> without the authority of iBanx bv. iBanx bv is neither liable for 
> the proper and complete transmission of the information has been maintained
> nor that the communication is free of viruses, interceptions or interference.
> 
> If you are not the intended recipient of this communication please return
> the communication to the sender and delete and destroy all copies.
> 
> --
> To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>
> 



-- 




--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: using the decoupled fulcrum services ? Follow up!!!!!!

Posted by Bart Selders <ba...@ibanx.nl>.
You need the logging to find out what is happening if things are not 
working as expected. Fulcrum did not log anything.

It works for me, both the LocalizationService as some own developed 
services. LocalizationService is (late) inited, only when used for first 
time, so you only see in your log file that the mapping is added.

My log file (using log4j with Turbine logging) shows:
[09:43:50,401 INFO ] loading component: name=fulcrum 
class=org.apache.fulcrum.Fulcrum 
config=/home/bselders/work/src/concedo-permit/target/webapps/concedo-permit/WEB-INF/conf/Fulcrum.properties
[09:43:50,401 DEBUG] attempting to load 'org.apache.fulcrum.Fulcrum' 
with the config file 
'/home/bselders/work/src/concedo-permit/target/webapps/concedo-permit/WEB-INF/conf/Fulcrum.properties'.
[09:43:50,490 INFO ] Added Mapping for Service: DatabaseService
[09:43:50,491 INFO ] Added Mapping for Service: PersistenceService
[09:43:50,491 INFO ] Added Mapping for Service: LocalizationService
[09:43:50,491 INFO ] Start Initializing service (early): DatabaseService
[09:43:50,521 INFO ] Start Initializing service (late): DatabaseService
[09:43:52,263 INFO ] Finished initializing all services!
[09:43:52,263 DEBUG] good news! org.apache.fulcrum.Fulcrum successfully 
configured and initialized
[09:43:52,263 INFO ] Turbine: init() Ready to Rumble!

Some other tips worthwile to consider:
I am accessing the service through the 
org.apache.fulcrum.localization.Localization class as documented in the 
docs at 
http://jakarta.apache.org/turbine/fulcrum/howto/localization-service.html

Did you comment out the 'old' LocalizationService from TR.properties?

I am also using the fulcrum-3.0-b2-dev.jar from 
http://jakarta.apache.org/turbine/jars.

Bart


pb00059@wuerth-phoenix.com wrote:
> "Selders, Bart" <ba...@ibanx.nl> said:
> 
> Gentlemen,
> 
> I also have problems to start a Fulcrum service, the scheduler.
> Personally i do not think that it is a problem of logging.
> We should ask the persons who have written fulcrum if they can give us an
> HowTo   on how to start the services.
> 
> I use turbine(tdk 2.2) and i would like to use fulcrum scheduler.
> 
> Greetings
> 
> Fabio Daprile
> 
> 
>>Uwe,
>>
>>In order to get Fulcrum to log I had to do one of the following:
>>
>>- Either create a log4j.properties file and put it in WEB-INF/classes
>>  See log4j website for details on what to specify.
>>
>>- Or alternatively (and easier for T2.2 users) log everything in one log
>>file
>>  To do that I use the following log settings in TR.properties:
>>
>>   services.LoggingService.facilities=system,debug,security,logforj
>>   services.LoggingService.default=logforj
>>   services.LoggingService.loggingConfig=
>>org.apache.turbine.services.logging.PropertiesLoggingConfig
>>
>>   services.LoggingService.logforj.log4j.rootCategory = ALL, logforj
>>   services.LoggingService.logforj.log4j.category.logforj = ALL, logforj
>>   services.LoggingService.logforj.log4j.appender.logforj.file
>>=${webappRoot}/logs/turbine.log
>>   services.LoggingService.logforj.log4j.appender.logforj =
>>org.apache.log4j.FileAppender
>>   services.LoggingService.logforj.log4j.appender.logforj.layout =
>>org.apache.log4j.PatternLayout
>> 
>>services.LoggingService.logforj.log4j.appender.logforj.layout.conversionPatt
>>ern = [%d{ABSOLUTE} %-5p] %m%n
>>   services.LoggingService.logforj.log4j.appender.logforj.append = false
>> 
>>services.LoggingService.logforj.className=org.apache.turbine.services.loggin
>>g.Log4JavaLogger
>>   services.LoggingService.logforj.level=ALL
>>
>>Set the level to one of: ALL, DEBUG, INFO dependent on your need.
>>
>>Success.
>>
>>Bart
>>
>>-----Original Message-----
>>From: Schmidt, Uwe
>>To: Turbine Users List
>>Sent: 5/26/02 6:38 PM
>>Subject: using the decoupled fulcrum services ?
>>
>>Hi 
>>
>>I have recently switched to turbine 2.2b1. To complete this I try to
>>switch 
>>from the integrated turbine services to the decoupled fulcrum services.
>>As a first aproach I simply tried to replace the Localization-Service.
>>It seems that the fulcrum services are not initialized at all.
>>How can I use them. It seems that I have missed something.
>>
>>This is the error message I get in the log file:
>>
>>Error rendering Velocity template: screens/Index.vm: Invocation of
>>method
>>'setLanguage' in  class de.gea.wiegand.teben.tools.Session threw
>>exception
>>class org.apache.fulcrum.InstantiationException : ServiceBroker: Unknown
>>Service 'LocalizationService' requested
>>
>>[Fri May 24 18:19:38 CEST 2002] -- ERROR -- Error rendering Velocity
>>template: screens/Index.vm: Error rendering Velocity template:
>>screens/Index.vm: Invocation of method 'setLanguage' in  class
>>de.gea.wiegand.teben.tools.Session threw exception class
>>org.apache.fulcrum.InstantiationException : ServiceBroker: Unknown
>>Service
>>'LocalizationService' requested
>>
>>The localization is activated in the fulcrum.properties file, but there
>>are no fulcrum messages in the log file at all ....
>>(I´ve already tried several combinations of the path to
>>fulcrum.properties
>>;-(  )
>>
>>Any ideas ?
>>
>>thanks
>>
>>Uwe
>>
>>--
>>To unsubscribe, e-mail:
>><ma...@jakarta.apache.org>
>>For additional commands, e-mail:
>><ma...@jakarta.apache.org>
>>
>>
>>*************************************************************************
>>The information contained in this communication is confidential and is
>>intended solely for the use of the individual or entity to  whom it is
>>addressed.You should not copy, disclose or distribute this communication 
>>without the authority of iBanx bv. iBanx bv is neither liable for 
>>the proper and complete transmission of the information has been maintained
>>nor that the communication is free of viruses, interceptions or interference.
>>
>>If you are not the intended recipient of this communication please return
>>the communication to the sender and delete and destroy all copies.
>>
>>--
>>To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
>>For additional commands, e-mail: <ma...@jakarta.apache.org>
>>
> 
> 
> 





*************************************************************************
The information contained in this communication is confidential and is
intended solely for the use of the individual or entity to  whom it is
addressed.You should not copy, disclose or distribute this communication 
without the authority of iBanx bv. iBanx bv is neither liable for 
the proper and complete transmission of the information has been maintained
nor that the communication is free of viruses, interceptions or interference.

If you are not the intended recipient of this communication please return
the communication to the sender and delete and destroy all copies.

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>