Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Test and Performance Tools Platform (TPTP) » Extending TPTP, Tutorial Error
Extending TPTP, Tutorial Error [message #84087] Mon, 25 September 2006 11:59 Go to next message
Eclipse User
Originally posted by: bruno.a.mateus.criticalsoftware.com

Hi all,

I'm trying to extend TPTP, simply to read a log file and display it in a
more friendly way on Eclipse IDE.

I followed the Introduction to the Generic Log Adaptar tutorial
( http://www.eclipse.org/tptp/home/documents/tutorials/gla/GLA _Intro/GLA_Intro.viewlet/GLA_Intro_viewlet_swf.html)
and when I run the example project I get an error.

First of all, to avoid using some deprecated classes I updated the source
code example. Bellow is the updated version:

package myLogParser;

import org.eclipse.hyades.logging.parsers.importer.ParserWrapper;

public class MyParserExtension extends ParserWrapper {
public MyParserExtension(){
super();
currentPlugin="myLogParser";
}
}

When I run the project, to create a deployable log parser, a new eclipse
application starts as expected. When I import the log file, in the new
eclipse application, the process takes some time and then gives an
internal error.

org.eclipse.hyades.logging.parsers.LogParserException: IWAT0412E Errors
occurred parsing the log file C:\Documents and
Settings\bamateus\Desktop\sample.log.
at
org.eclipse.hyades.logging.parsers.importer.ParserWrapper.pa rse(ParserWrapper.java:144)
at
org.eclipse.tptp.monitoring.logui.internal.wizards.LocalLogP arserLoader.startParsing(LocalLogParserLoader.java:87)
at
org.eclipse.tptp.monitoring.logui.internal.wizards.ImportLog Wizard$LocalLogImportJob.runOnLocalHost(ImportLogWizard.java :1183)ImportWizard
agentProxy=org.eclipse.hyades.models.hierarchy.impl.TRCAgentProxyImpl@118a770
(name: Sample Rules Log Parser for MyApp C:\Documents and
Settings\bamateus\Desktop\sample.log, type: Logging, runtimeId: null,
startTime: 0.0, stopTime: 0.0, collectionMode: HEAP_STATISTICS_ONLY,
active: false, attached: false, collectionData: false, monitored: false,
profileFile: null, deltaTime: 0.0)/0

at
org.eclipse.tptp.monitoring.logui.internal.wizards.ImportLog Wizard$LocalLogImportJob.run(ImportLogWizard.java:1171)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:76)


The following message appears on the main eclipse application:

org.eclipse.hyades.logging.parsers.LogParserException: IWAT0412E Errors
occurred parsing the log file C:\Documents and
Settings\bamateus\Desktop\sample.log.
at
org.eclipse.hyades.logging.parsers.importer.ParserWrapper.pa rse(ParserWrapper.java:144)
at
org.eclipse.tptp.monitoring.logui.internal.wizards.LocalLogP arserLoader.startParsing(LocalLogParserLoader.java:87)
at
org.eclipse.tptp.monitoring.logui.internal.wizards.ImportLog Wizard$LocalLogImportJob.runOnLocalHost(ImportLogWizard.java :1183)ImportWizard
agentProxy=org.eclipse.hyades.models.hierarchy.impl.TRCAgentProxyImpl@118a770
(name: Sample Rules Log Parser for MyApp C:\Documents and
Settings\bamateus\Desktop\sample.log, type: Logging, runtimeId: null,
startTime: 0.0, stopTime: 0.0, collectionMode: HEAP_STATISTICS_ONLY,
active: false, attached: false, collectionData: false, monitored: false,
profileFile: null, deltaTime: 0.0)/0

at
org.eclipse.tptp.monitoring.logui.internal.wizards.ImportLog Wizard$LocalLogImportJob.run(ImportLogWizard.java:1171)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:76)

This also happens if I use the original example code, with the deprecated
classes.

I'm currently using Eclipse 3.1.2 with TPTP 4.1.0.1 and all the
requirements.

Anyone has idea of what's happening?

Sorry for this long message, best regards,

Bruno Mateus
Re: Extending TPTP, Tutorial Error [message #84228 is a reply to message #84087] Tue, 26 September 2006 14:57 Go to previous messageGo to next message
Eclipse User
Originally posted by: bruno.a.mateus.criticalsoftware.com

Hi all,

I know that my previous message was to long so I just would like to know
if someone was able to test Generic Log Adaptar tutorial example,
available on
http://www.eclipse.org/tptp/home/documents/tutorials/gla/GLA _Intro/GLA_Intro.viewlet/GLA_Intro_viewlet_swf.html
with Eclipse 3.1.2 with TPTP 4.1.0.1.

Regards,

Bruno Mateus
Re: Extending TPTP, Tutorial Error [message #84243 is a reply to message #84087] Tue, 26 September 2006 15:24 Go to previous message
Eclipse User
Originally posted by: cindyjin.ca.ibm.com

Hi Bruno:

There is a bug https://bugs.eclipse.org/bugs/show_bug.cgi?id=112590
opened to update the GLA demo. You can update the regex.adapter for the
myLogParser. The adapter I used is as following, I just ran it with
eclipse3.1.2 and TPTP4.1.0.1. It works fine. Hope this can help you.

Cindy

<?xml version="1.0" encoding="ASCII"?>
<adapter:Adapter
xmlns:adapter="http://www.eclipse.org/hyades/schema/Adapter.xsd"
xmlns:cc=" http://www.eclipse.org/hyades/schema/ComponentConfiguration. xsd"
xmlns:ex="http://www.eclipse.org/hyades/schema/Extractor.xsd"
xmlns:fmt="http://www.eclipse.org/hyades/schema/Formatter.xsd"
xmlns:hga="http://www.eclipse.org/hyades/schema/Context.xsd"
xmlns:op="http://www.eclipse.org/hyades/schema/Outputter.xsd"
xmlns:parser="http://www.eclipse.org/hyades/schema/Parser.xsd"
xmlns:pu="http://www.eclipse.org/hyades/schema/ProcessUnit.xsd"
xmlns:sensor="http://www.eclipse.org/hyades/schema/Sensor.xsd">
<hga:Contexts>
<hga:Context description="Context Instance for the current
component"
executableClass="org.eclipse.hyades.logging.adapter.impl.BasicContext "
implementationCreationDate="2003-10-07T12:00:00.0"
implementationVersion="1.0.0" loggingLevel="60" name="Basic Context
Implementation" role="context" roleCreationDate="2003-10-07T12:00:00.0"
roleVersion="1.0.0" uniqueID="N35B6D910F8511D88000A31D7605087A">
<hga:Component description="Operating System file sensor"
executableClass=" org.eclipse.hyades.logging.adapter.sensors.SingleOSFileSenso r "
implementationCreationDate="2003-10-07T12:00:00.0"
implementationVersion="1.0.0" loggingLevel="40" name="OS File Sensor"
role="sensor" roleCreationDate="2003-10-07T12:00:00.0" roleVersion="1.0"
uniqueID="N3604F900F8511D88000A31D7605087A"/>
<hga:Component description="This extractor uses regular
expression patterns to identify record delimiters"
executableClass=" org.eclipse.hyades.logging.adapter.extractors.RegularExpress ionExtractor "
implementationCreationDate="2003-10-07T12:00:00.0"
implementationVersion="1.0.0" loggingLevel="60" name="Regular Expression
Extractor" role="messageExtractor"
roleCreationDate="2003-10-07T12:00:00.0" roleVersion="1.0.0"
uniqueID="N36299800F8511D88000A31D7605087A"/>
<hga:Component description="Regular expression parser"
executableClass="org.eclipse.hyades.logging.adapter.parsers.Parser "
implementationCreationDate="2003-10-07T12:00:00.0"
implementationVersion="1.0.0" loggingLevel="60" name="Generic Parser"
role="parser" roleCreationDate="2003-10-07T12:00:00.0"
roleVersion="1.0.0" uniqueID="N3650A800F8511D88000A31D7605087A"/>
<hga:Component description="CBE Formatter"
executableClass="org.eclipse.hyades.logging.adapter.formatters.CBEFormatter "
implementationCreationDate="2003-10-07T12:00:00.0"
implementationVersion="1.0.0" loggingLevel="60" name="CBE Formatter"
role="formatter" roleCreationDate="2003-10-07T12:00:00.0"
roleVersion="1.0.0" uniqueID="N36C36700F8511D88000A31D7605087A"/>
<hga:Component description="Logging agent outputter"
executableClass=" org.eclipse.hyades.logging.parsers.adapter.outputters.LogImp ortOutputter "
implementationCreationDate="2003-10-07T12:00:00.0"
implementationVersion="1.0.0" implementationVersionDescription=""
loggingLevel="60" name="Logging Agent Outputter" role="outputter"
roleCreationDate="2003-10-07T12:00:00.0" roleVersion="1.0.0"
uniqueID="N36E80600F8511D88000A31D7605087A"/>
</hga:Context>
</hga:Contexts>
<cc:Configuration description="The component level configurations for
this adapter" uniqueID="N35B6D900F8511D88000A31D7605087A">
<cc:ContextInstance continuousOperation="false"
description="Context Instance for the current component"
maximumIdleTime="500000" pauseInterval="10"
uniqueID="N35B6D910F8511D88000A31D7605087A">
<cc:Sensor description="A single file sensor"
uniqueID="N3604F900F8511D88000A31D7605087A" maximumBlocking="5"
type="SingleFileSensor">
<pu:Property propertyName="directory" propertyValue="c:\Temp"/>
<pu:Property propertyName="fileName" propertyValue="sample.log"/>
<sensor:SingleFileSensor directory="c:\Temp"
fileName="sample.log"/>
</cc:Sensor>
<ex:Extractor containsLineBreaks="false" description="This
extractor uses regular expression patterns to identify record
delimiters" endPattern="$" includeEndPattern="false"
includeStartPattern="true" lineBreakSymbol="" replaceLineBreaks="false"
startPattern="^" uniqueID="N36299800F8511D88000A31D7605087A"/>
<cc:Parser designationToken=":" separatorToken="[ ]{2}"
uniqueID="N3650A800F8511D88000A31D7605087A">
<parser:RuleElement index="N3650A810F8511D88000A31D7605087A"
name="CommonBaseEvent">
<parser:RuleElement index="N8CA7C54002A11D88000C6FD28070181"
name="sourceComponentId">
<parser:RuleAttribute
index="ND66C0C1002A11D88000C6FD28070181" name="component"
usePreviousMatchSubstitutionAsDefault="false">
<SubstitutionRule substitute="HTTP Server"/>
</parser:RuleAttribute>
<parser:RuleAttribute
index="N77CD869002A11D88000C6FD28070181" name="subComponent"
usePreviousMatchSubstitutionAsDefault="false">
<SubstitutionRule substitute="Unknown"/>
</parser:RuleAttribute>
<parser:RuleAttribute
index="N12069D2002A11D88000C6FD28070181" name="componentIdType"
usePreviousMatchSubstitutionAsDefault="false">
<SubstitutionRule substitute="ProductName"/>
</parser:RuleAttribute>
<parser:RuleAttribute
index="N3AB0CD6010F11D88000873B061CB0B3" name="location"
usePreviousMatchSubstitutionAsDefault="false">
<SubstitutionRule substitute="" useBuiltInFunction="true"/>
</parser:RuleAttribute>
<parser:RuleAttribute
index="NCD2CCD7010F11D88000873B061CB0B3" name="locationType"
usePreviousMatchSubstitutionAsDefault="false">
<SubstitutionRule substitute="" useBuiltInFunction="true"/>
</parser:RuleAttribute>
<parser:RuleAttribute
index="NDE661030DAB11D88000930FA6625271" name="componentType"
usePreviousMatchSubstitutionAsDefault="false">
<SubstitutionRule substitute="HTTPServer"
useBuiltInFunction="false"/>
</parser:RuleAttribute>
</parser:RuleElement>
<parser:RuleElement index="N8273E56002C11D88000C6FD28070181"
name="situation">
<parser:RuleElement
index="NA8AA990002E11D88000C6FD28070181" name="situationType">
<parser:RuleElement
index="NF8AFFE9002F11D88000C6FD28070181" name="RequestSituation">
<parser:RuleAttribute
index="N2815562002F11D88000C6FD28070181" name="successDisposition"
usePreviousMatchSubstitutionAsDefault="false">
<SubstitutionRule match="" positions=""
substitute="SUCCESSFUL"/>
</parser:RuleAttribute>
<parser:RuleAttribute
index="N30BA5C1002F11D88000C6FD28070181" name="situationQualifier"
usePreviousMatchSubstitutionAsDefault="false">
<SubstitutionRule match="" positions=""
substitute="REQUEST INITIATED"/>
</parser:RuleAttribute>
<parser:RuleAttribute
index="NCCBFC40002F11D88000C6FD28070181" name="reasoningScope"
usePreviousMatchSubstitutionAsDefault="false">
<SubstitutionRule match="" positions=""
substitute="EXTERNAL"/>
</parser:RuleAttribute>
</parser:RuleElement>
<parser:RuleElement
index="N224169A084711D8800091856AF4A65C" name="ReportSituation">
<parser:RuleAttribute
index="N224169B084711D8800091856AF4A65C" name="reasoningScope"
usePreviousMatchSubstitutionAsDefault="false">
<SubstitutionRule substitute="INTERNAL"
useBuiltInFunction="false"/>
</parser:RuleAttribute>
<parser:RuleAttribute
index="N224169C084711D8800091856AF4A65C" name="reportCategory"
usePreviousMatchSubstitutionAsDefault="false">
<SubstitutionRule substitute="LOG"
useBuiltInFunction="false"/>
</parser:RuleAttribute>
</parser:RuleElement>
</parser:RuleElement>
<parser:RuleAttribute
index="ND4A1091002F11D88000C6FD28070181" name="categoryName"
usePreviousMatchSubstitutionAsDefault="false">
<SubstitutionRule match="" positions=""
substitute="RequestSituation"/>
<SubstitutionRule substitute="ReportSituation"
useBuiltInFunction="false"/>
</parser:RuleAttribute>
</parser:RuleElement>
<parser:RuleAttribute
index="N3650A820F8511D88000A31D7605087A" name="creationTime"
usePreviousMatchSubstitutionAsDefault="true">
<SubstitutionRule match="^&lt;(.*)>.*" substitute="$1"
timeFormat="MMMM dd, yyyy hh:mm:ss z" useBuiltInFunction="false"/>
</parser:RuleAttribute>
<parser:RuleAttribute
index="N024368D002B11D88000C6FD28070181" name="msg"
usePreviousMatchSubstitutionAsDefault="false">
<SubstitutionRule match="^(\w+)-(.*)"
positions="$h('message')" substitute="$2"/>
</parser:RuleAttribute>
<parser:RuleAttribute
index="N230EBD1002C11D88000C6FD28070181" name="severity"
usePreviousMatchSubstitutionAsDefault="false">
<SubstitutionRule match="1" positions="$h('severity')"
substitute="60" useBuiltInFunction="false"/>
<SubstitutionRule match="2" positions="$h('severity')"
substitute="40" useBuiltInFunction="false"/>
<SubstitutionRule substitute="10" useBuiltInFunction="false"/>
</parser:RuleAttribute>
</parser:RuleElement>
</cc:Parser>
<fmt:Formatter description="CBE Formatter"
uniqueID="N36C36700F8511D88000A31D7605087A"/>
<cc:Outputter description="Default Logging Agent"
uniqueID="N36E80600F8511D88000A31D7605087A" type="LoggingAgentOutputter">
<pu:Property propertyName="agentName" propertyValue="Sample Log
logging agent"/>
<op:LoggingAgentOutputterType agentName="Sample Log logging
agent"/>
</cc:Outputter>
</cc:ContextInstance>
</cc:Configuration>
</adapter:Adapter>


Bruno Mateus wrote:
> Hi all,
>
> I'm trying to extend TPTP, simply to read a log file and display it in a
> more friendly way on Eclipse IDE.
>
> I followed the Introduction to the Generic Log Adaptar tutorial
> ( http://www.eclipse.org/tptp/home/documents/tutorials/gla/GLA _Intro/GLA_Intro.viewlet/GLA_Intro_viewlet_swf.html)
> and when I run the example project I get an error.
>
> First of all, to avoid using some deprecated classes I updated the
> source code example. Bellow is the updated version:
>
> package myLogParser;
>
> import org.eclipse.hyades.logging.parsers.importer.ParserWrapper;
>
> public class MyParserExtension extends ParserWrapper {
> public MyParserExtension(){
> super();
> currentPlugin="myLogParser";
> }
> }
>
> When I run the project, to create a deployable log parser, a new eclipse
> application starts as expected. When I import the log file, in the new
> eclipse application, the process takes some time and then gives an
> internal error.
> org.eclipse.hyades.logging.parsers.LogParserException: IWAT0412E Errors
> occurred parsing the log file C:\Documents and
> Settings\bamateus\Desktop\sample.log.
> at
> org.eclipse.hyades.logging.parsers.importer.ParserWrapper.pa rse(ParserWrapper.java:144)
>
> at
> org.eclipse.tptp.monitoring.logui.internal.wizards.LocalLogP arserLoader.startParsing(LocalLogParserLoader.java:87)
>
> at
> org.eclipse.tptp.monitoring.logui.internal.wizards.ImportLog Wizard$LocalLogImportJob.runOnLocalHost(ImportLogWizard.java :1183)ImportWizard
> agentProxy=org.eclipse.hyades.models.hierarchy.impl.TRCAgentProxyImpl@118a770
> (name: Sample Rules Log Parser for MyApp C:\Documents and
> Settings\bamateus\Desktop\sample.log, type: Logging, runtimeId: null,
> startTime: 0.0, stopTime: 0.0, collectionMode: HEAP_STATISTICS_ONLY,
> active: false, attached: false, collectionData: false, monitored: false,
> profileFile: null, deltaTime: 0.0)/0
>
> at
> org.eclipse.tptp.monitoring.logui.internal.wizards.ImportLog Wizard$LocalLogImportJob.run(ImportLogWizard.java:1171)
>
> at org.eclipse.core.internal.jobs.Worker.run(Worker.java:76)
>
>
> The following message appears on the main eclipse application:
>
> org.eclipse.hyades.logging.parsers.LogParserException: IWAT0412E Errors
> occurred parsing the log file C:\Documents and
> Settings\bamateus\Desktop\sample.log.
> at
> org.eclipse.hyades.logging.parsers.importer.ParserWrapper.pa rse(ParserWrapper.java:144)
>
> at
> org.eclipse.tptp.monitoring.logui.internal.wizards.LocalLogP arserLoader.startParsing(LocalLogParserLoader.java:87)
>
> at
> org.eclipse.tptp.monitoring.logui.internal.wizards.ImportLog Wizard$LocalLogImportJob.runOnLocalHost(ImportLogWizard.java :1183)ImportWizard
> agentProxy=org.eclipse.hyades.models.hierarchy.impl.TRCAgentProxyImpl@118a770
> (name: Sample Rules Log Parser for MyApp C:\Documents and
> Settings\bamateus\Desktop\sample.log, type: Logging, runtimeId: null,
> startTime: 0.0, stopTime: 0.0, collectionMode: HEAP_STATISTICS_ONLY,
> active: false, attached: false, collectionData: false, monitored: false,
> profileFile: null, deltaTime: 0.0)/0
>
> at
> org.eclipse.tptp.monitoring.logui.internal.wizards.ImportLog Wizard$LocalLogImportJob.run(ImportLogWizard.java:1171)
>
> at org.eclipse.core.internal.jobs.Worker.run(Worker.java:76)
>
> This also happens if I use the original example code, with the
> deprecated classes.
>
> I'm currently using Eclipse 3.1.2 with TPTP 4.1.0.1 and all the
> requirements.
>
> Anyone has idea of what's happening?
>
> Sorry for this long message, best regards,
>
> Bruno Mateus
>
>
Previous Topic:PerfMonAgent -v does not produce output anymore
Next Topic:AGR and Debug Launch Configuration
Goto Forum:
  


Current Time: Wed Sep 03 00:07:07 GMT 2014

Powered by FUDForum. Page generated in 0.11320 seconds