3 Replies Latest reply on Mar 17, 2013 3:55 AM by user12301120

    Error After custom javahost program running.

      Hi all.

      We developed a javahost program which's running after ibot.

      It's role is downloading a attached pdf or mht file to local directory.

      we register it a ibot >> Advanced >>Add Action >> Custom Java Program.

      It works when a attached file size is small. (only contains text)

      but it fail when attached file is big(it contains multi contents including charts).

      below is our environment.

      thanks in advance.
      Server version : Linux,

      javahost config file
      <!-- Enabled the feature or not, by default feature is not enabled. -->

      <!-- Required field, default location for user to put their Java extension, utility jar files. -->

      <!-- Default temp file location for Scheduler RPC calls, by default is at system temp directory -->
      <!-- <DefaultTempFilePath/> -->

      <!-- Default purging period for Scheduler RPC calls to clean up failed jobs, by default is 300 seconds -->
      <!-- <DefaultPurgingPeriod/> -->

      custom java program
      public class LocalFileSave implements SchedulerJavaExtension{

      public void run(SchedulerJobInfo jobInfo) throws SchedulerJobException {
      String today = this.getToday();
      String filePrefix = jobInfo.parameter(0);
      String fileExt = jobInfo.parameter(1);
      String dir = "/oracle/BIEE/OracleBI/oc4j_bi/j2ee/home/default-web-app/ibot_stx/";
      String fileName = dir + filePrefix+"_"+today+"."+fileExt;

      System.out.println("JobID is:" + jobInfo.jobID());
      System.out.println("Instance ID is:" + jobInfo.instanceID());
      System.out.println("JobInfo to string is:" + jobInfo.toString());
      System.out.println("FileName:" + fileName);
      FileInputStream fileInputStr = new FileInputStream(jobInfo.getResultSetFile());
      DeliveryManager delMan = new DeliveryManager();
      DeliveryRequest delReq = delMan.createRequest(DeliveryManager.TYPE_LOCAL);
      delReq.addProperty(LocalPropertyDefinitions.LOCAL_DESTINATION, fileName);
      catch(Exception ex)
      throw new SchedulerJobException(1, 1, ex.getMessage());
      System.out.println("================ END ==================");

      public void cancel() {

      public String getToday(){

      Date todaysDate = new java.util.Date();
      SimpleDateFormat formatter = new SimpleDateFormat("yyyyMMdd");

      String formattedDate = formatter.format(todaysDate);
      return formattedDate;

      2010. 10. 27 오후 5:50:39 MessageProcessorImpl processMessage
      경고: Unexpected exception. Connection will be closed
      at com.siebel.analytics.web.sawconnect.sawprotocol.SAWProtocol.readInt(SAWProtocol.java:167)
      at com.siebel.analytics.javahost.MessageProcessorImpl.processMessage(MessageProcessorImpl.java:133)
      at com.siebel.analytics.javahost.Listener$Job.run(Listener.java:223)
      at com.siebel.analytics.javahost.standalone.SAJobManagerImpl.threadMain(SAJobManagerImpl.java:205)
      at com.siebel.analytics.javahost.standalone.SAJobManagerImpl$1.run(SAJobManagerImpl.java:153)
      at java.lang.Thread.run(Thread.java:595)

      Edited by: vingorius on 2010. 10. 27 오전 1:51

      Edited by: vingorius on 2010. 10. 27 오전 1:52