nhl / link-move

A model-driven dynamically-configurable framework to acquire data from external sources and save it to your database.
Apache License 2.0
35 stars 15 forks source link

Validation for CSV file import #144

Open nbrych opened 6 years ago

nbrych commented 6 years ago

Now it's totally unclear why import was failed:


java.lang.ArrayIndexOutOfBoundsException: 1
        at org.apache.commons.csv.CSVRecord.get(CSVRecord.java:81)
        at com.nhl.link.move.runtime.csv.CsvDataRow.get(CsvDataRow.java:25)
        at com.nhl.link.move.runtime.task.createorupdate.RowConverter.convert(RowConverter.java:44)
        at com.nhl.link.move.runtime.task.createorupdate.RowConverter.convert(RowConverter.java:31)
        at com.nhl.link.move.runtime.task.createorupdate.CreateOrUpdateSegmentProcessor.convertSrc(CreateOrUpdateSegmentProcessor.java:55)
        at com.nhl.link.move.runtime.task.createorupdate.CreateOrUpdateSegmentProcessor.process(CreateOrUpdateSegmentProcessor.java:46)
        at com.nhl.link.move.runtime.task.createorupdate.CreateOrUpdateTask$1.process(CreateOrUpdateTask.java:74)
        at com.nhl.link.move.batch.BatchRunner.run(BatchRunner.java:57)
        at com.nhl.link.move.runtime.task.createorupdate.CreateOrUpdateTask.run(CreateOrUpdateTask.java:60)
        at com.nhl.link.move.runtime.task.BaseTask.run(BaseTask.java:29)
        at ****
        at io.bootique.job.scheduler.execution.DefaultJobRegistry$1.run(DefaultJobRegistry.java:102)
        at io.bootique.job.scheduler.execution.Callback.runAndNotify(Callback.java:21)
        at io.bootique.job.scheduler.execution.SingleJob.run(SingleJob.java:38)
        at io.bootique.job.runnable.SimpleRunnableJobFactory.lambda$runnable$0(SimpleRunnableJobFactory.java:11)
        at io.bootique.job.lock.LocalLockHandler.lambda$lockingJob$0(LocalLockHandler.java:45)
        at io.bootique.job.runnable.ErrorHandlingRunnableJobFactory.lambda$runnable$0(ErrorHandlingRunnableJobFactory.java:26)
        at io.bootique.job.scheduler.DefaultScheduler.lambda$null$6(DefaultScheduler.java:171)
        at org.springframework.scheduling.support.DelegatingErrorHandlingRunnable.run(DelegatingErrorHandlingRunnable.java:54)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
        at java.lang.Thread.run(Thread.java:745)```