Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fact-tools_latest.jar: java.lang.Exception: Failed to determine class for node 'fact.datacorrection.DrsCalibration'! #80

Closed
kbruegge opened this issue Aug 19, 2015 · 15 comments

Comments

@kbruegge
Copy link
Member

Originally reported by: Dominik Neise (Bitbucket: dneise, GitHub: dneise)


Just got the fact-tools_latest.jar from here. And tried to use it as an event viewer at ISDC using this XML:

<container>
    <properties url="classpath:/default/settings.properties" />
    <property name="infile" value="file:/fact/raw/2015/07/21/20150721_056.fits.fz" />
    <property name="drsfile" value="file:/fact/raw/2015/07/21/20150721_042.drs.fits.gz" />
    <stream id="fact" class="fact.io.FitsStream"  url="${infile}"/>
    <process id="1" input="fact">
        <fact.datacorrection.DrsCalibration/>
        <fact.ShowViewer key="DataCalibrated"/>
    </process>
</container>

It did not work but threw this exception:

neise@isdc-nx00:~/fact-tools$ java -jar fact-tools_latest.jar viewer.xml
Aug 19 2015 12:56:45 [ERROR] stream.util.PropertiesHandler: Failed to read properties from url classpath:/default/settings.properties: Property event_param is not set.
Aug 19 2015 12:56:45 [INFO ] stream.runtime.ProcessContainer: XML created and preprocessed.
Aug 19 2015 12:56:45 [ERROR] stream.util.PropertiesHandler: Failed to read properties from url classpath:/default/settings.properties: Property event_param is not set.
Exception in thread "main" java.lang.Exception: Failed to determine class for node 'fact.datacorrection.DrsCalibration'!
        at stream.runtime.setup.factory.ObjectFactory.findClassForElement(ObjectFactory.java:361)
        at stream.runtime.setup.factory.ObjectFactory.create(ObjectFactory.java:220)
        at stream.runtime.setup.factory.DefaultProcessFactory.createProcessorAndRegisterServices(DefaultProcessFactory.java:300)
        at stream.runtime.setup.factory.DefaultProcessFactory.createNestedProcessors(DefaultProcessFactory.java:282)
        at stream.runtime.setup.factory.DefaultProcessFactory.createAndRegisterProcesses(DefaultProcessFactory.java:258)
        at stream.runtime.setup.handler.ProcessElementHandler.handleElement(ProcessElementHandler.java:98)
        at stream.runtime.ProcessContainer.init(ProcessContainer.java:515)
        at stream.runtime.ProcessContainer.<init>(ProcessContainer.java:399)
        at stream.runtime.ProcessContainer.<init>(ProcessContainer.java:253)
        at stream.run.main(run.java:159)
        at stream.run.main(run.java:147)

Please advice


@kbruegge
Copy link
Member Author

Original comment by Dominik Neise (Bitbucket: dneise, GitHub: dneise):


The XML file, I basically copied from fact-tools / examples / viewer_zfits.xml

@kbruegge
Copy link
Member Author

Original comment by Dominik Neise (Bitbucket: dneise, GitHub: dneise):


Ah .. this seems to be a user error. ... I am working on it...

@kbruegge
Copy link
Member Author

Original comment by Dominik Neise (Bitbucket: dneise, GitHub: dneise):


No ... I can't find out what's the matter here ... I give up....

@kbruegge
Copy link
Member Author

Original comment by ftemme (Bitbucket: ftemme, GitHub: ftemme):


It seems to be connected to issue #62. Something goes wrong with the reading of the properties file in the streams framework. As a workaround remove the reading of the properties file from your xml. You don't need it.

@kbruegge
Copy link
Member Author

Original comment by Dominik Neise (Bitbucket: dneise, GitHub: dneise):


Nope ... doesn't help ... it removes those 2 [ERROR] messages, but it still does not work

<container>
    <property name="infile"  value="file:/fact/raw/2015/07/21/20150721_056.fits.fz" />
    <property name="drsfile" value="file:/fact/raw/2015/07/21/20150721_042.drs.fits.gz" />

    <stream id="fact" class="fact.io.FitsStream"  url="${infile}"/>

    <process id="1" input="fact">
        <fact.datacorrection.DrsCalibration 
            url="$(drsfile)" 
            key="data" 
            outputKey="DataCalibrated"/>
        <fact.ShowViewer key="DataCalibrated"/>
    </process>
</container>

@kbruegge
Copy link
Member Author

Original comment by Dominik Neise (Bitbucket: dneise, GitHub: dneise):


Result is:

neise@isdc-nx00:~/fact-tools$ java -jar fact-tools_latest.jar lala.xml 
Aug 19 2015 15:03:39 [INFO ] stream.runtime.ProcessContainer: XML created and preprocessed.
Exception in thread "main" java.lang.Exception: Failed to determine class for node 'fact.datacorrection.DrsCalibration'!
        at stream.runtime.setup.factory.ObjectFactory.findClassForElement(ObjectFactory.java:361)
        at stream.runtime.setup.factory.ObjectFactory.create(ObjectFactory.java:220)
        at stream.runtime.setup.factory.DefaultProcessFactory.createProcessorAndRegisterServices(DefaultProcessFactory.java:300)
        at stream.runtime.setup.factory.DefaultProcessFactory.createNestedProcessors(DefaultProcessFactory.java:282)
        at stream.runtime.setup.factory.DefaultProcessFactory.createAndRegisterProcesses(DefaultProcessFactory.java:258)
        at stream.runtime.setup.handler.ProcessElementHandler.handleElement(ProcessElementHandler.java:98)
        at stream.runtime.ProcessContainer.init(ProcessContainer.java:515)
        at stream.runtime.ProcessContainer.<init>(ProcessContainer.java:399)
        at stream.runtime.ProcessContainer.<init>(ProcessContainer.java:253)
        at stream.run.main(run.java:159)
        at stream.run.main(run.java:147)

@kbruegge
Copy link
Member Author

Original comment by Dominik Neise (Bitbucket: dneise, GitHub: dneise):


ah! I see my error.

@kbruegge
Copy link
Member Author

Original comment by Dominik Neise (Bitbucket: dneise, GitHub: dneise):


I fucked up the XML ... didn't see it in vi ... XML syntax highlighting sux.
But it still doesn't work... damn.

@kbruegge
Copy link
Member Author

Original comment by Maximilian Nöthe (Bitbucket: MaxNoe, GitHub: MaxNoe):


The version of the jar you linked is 0.6.29 so quite ancient.

@kbruegge
Copy link
Member Author

Original comment by ftemme (Bitbucket: ftemme, GitHub: ftemme):


I will remove the link from the website, as long as it is not working.

@kbruegge
Copy link
Member Author

Original comment by Dominik Neise (Bitbucket: dneise, GitHub: dneise):


Okay ... now I got it ... this XML works:

<container>
    <property name="infile"  value="file:/fact/raw/2015/07/21/20150721_056.fits.fz" />
    <property name="drsfile" value="file:/fact/raw/2015/07/21/20150721_042.drs.fits.gz" />

    <stream id="fact" class="fact.io.zfits.ZFitsStream"  url="${infile}"/>

    <process id="1" input="fact">
        <fact.datacorrection.DrsCalibration 
            url="${drsfile}" 
            key="Data" 
            outputKey="DataCalibrated"/>
        <fact.ShowViewer key="DataCalibrated"/>
    </process>
</container>

I wonder why you guys bother to keep anything inside the examples folder ... better delete it entirely instead of keeping outdated shit in there

@kbruegge
Copy link
Member Author

Original comment by Dominik Neise (Bitbucket: dneise, GitHub: dneise):


The version of the jar you linked is 0.6.29 so quite ancient.

I linked that? It was linked on the fact tools web site ... I merely quoted that shit

@kbruegge
Copy link
Member Author

Original comment by ftemme (Bitbucket: ftemme, GitHub: ftemme):


Sorry, it seems that the building of the latest jar file for direct downloading via the link on the webpage isn't working for some time. Therefore you downloaded a rather old version.
I removed the link from the webpage (will be removed in a few minutes when the build drone updates the webpage).

Could you check, when you checkout the master and build with mvn package (-Dmaven.test.skip=true for skipping the tests), if your process is working?

@kbruegge
Copy link
Member Author

Original comment by Dominik Neise (Bitbucket: dneise, GitHub: dneise):


Yes it works now ... after I found out again, how to skip the tests .... another 30 seconds of my life wasted.

@kbruegge
Copy link
Member Author

Original comment by Maximilian Nöthe (Bitbucket: MaxNoe, GitHub: MaxNoe):


fix examples/viewer_zfits.xml, close #80

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant