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

LmRuntimeException on execution of edited link-move xml-extractor #184

Open
MProtasevich opened this issue Sep 18, 2020 · 2 comments
Open

Comments

@MProtasevich
Copy link

In our case, we deploy link-move xml extractors separately from main app, which uses LmRuntime to start jobs.

If we redeploy link-move extractors or edit the extractor (xml-file), which is going to be used in next execution, without restarting the application, exception will be thrown

com.nhl.link.move.LmRuntimeException: Multiple values are present for property: extractor.jdbc.sqltemplate
	at com.nhl.link.move.extractor.model.MutableExtractorModel.getPropertyValue(MutableExtractorModel.java:55)
	at com.nhl.link.move.extractor.model.MutableExtractorModel.getProperties(MutableExtractorModel.java:37)
	at com.nhl.link.move.extractor.model.ContainerAwareExtractorModel.getProperties(ContainerAwareExtractorModel.java:49)
	at com.nhl.linkmove.extensions.extension.DefaultExtensionFactory.getExtensions(DefaultExtensionFactory.java:50)
	at com.nhl.linkmove.extensions.DefaultSyncProcessorService.processor(DefaultSyncProcessorService.java:40)

Steps to reproduce:

  1. LinkMove extractors located outside of the jar (somewhere in file system)
  2. Start application which schedules jobs for execution (via cron, for instance)
  3. Wait for any job to finish it's work
  4. Edit xml-extractor of a job, which has been run previously
  5. Wait until next execution
  6. Exception is thrown
@andrus
Copy link
Contributor

andrus commented Oct 4, 2020

Need help reproducing this. I just created a test that changes the extractor and reruns the task. Everything seems to work correctly. Could there be an error in the XML syntax?

@MProtasevich
Copy link
Author

Could there be an error in the XML syntax?

No, that issue occurs even if I add a whitespace under <extractor.jdbc.sqltemplate> tag. No matter, if it's added inside CDATA block out of it.

The only difference between your test and the task we've implemented is that we create new LmTask between job invocations, but in your tests you use only one instance. Maybe that's the point.

P. S. And we use TimestampToken as well

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

No branches or pull requests

2 participants