Thanks Kevin is that I want to see, only two more things

1) Now I have this error message:

Unable to construct service com.pct.AjaxSIG.loggerContextFactory: Unable to convert type 'com.pct.commons.Helper.LoggerFactory' to a Java class, either as is, or in package com.pct.AjaxSIG


My hivemodule in the logs related is:

<service-point id="loggerContextFactory" interface="org.apache.tapestry.engine.state.StateObjectFactory"> <create-instance class="com.pct.commons.Helper.LoggerFactory,appName=SIG"/>
  </service-point>
  <contribution configuration-id="tapestry.state.ApplicationObjects">
    <state-object name="Logger" scope="application">
       <invoke-factory object="service:loggerContextFactory" />
    </state-object>
 </contribution>

and the .java is

public class LoggerFactory implements StateObjectFactory{
private String appName="TapApp";

   public Object createStateObject(){
       return LogFactory.getLog(appName);
   }

   public void setAppName(String appName) {
       this.appName = appName;
   }
}

appName is something that I wanna pass as a parameter (and the config file), that's because I put SIG in the hivemodule and in Tomcat screen logs don´t complaint for it when load hivemodule, with or without this on hivemodule the error appears.

2) In your link I don´t know if was a "copy paste" mistake in the service-point tag where the interface is the same class, in my case I have to put the StateObjectFactory as interface or Tap give another error message.

Thanks a lot for your help.

JQ

Kevin Menard escribió:
Jorge Quiroga wrote:
Then I have to write a service after all, so do you know which interface I have to use (or define) to put in the invoke factory and service tags?

See http://mail-archives.apache.org/mod_mbox/incubator-cayenne-user/200606.mbox/[EMAIL PROTECTED]

It's an example of something similar I did with a Cayenne DataContext. It illustrates using a StateObjectFactory to customize the creation of a "global" ASO.



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to