Skip to content
Snippets Groups Projects
Commit 1d82c3c3 authored by Tor-Einar Skog's avatar Tor-Einar Skog
Browse files

Improved error messaging

parent 31336b9c
No related branches found
No related tags found
No related merge requests found
...@@ -496,7 +496,16 @@ public class ForecastBean { ...@@ -496,7 +496,16 @@ public class ForecastBean {
loginInfo.put("password",System.getProperty("no.bioforsk.vips.logic.CORE_BATCH_PASSWORD")); loginInfo.put("password",System.getProperty("no.bioforsk.vips.logic.CORE_BATCH_PASSWORD"));
request.setLoginInfo(loginInfo); request.setLoginInfo(loginInfo);
// We tell which client this is (the db Id in VIPSCoreManager) // We tell which client this is (the db Id in VIPSCoreManager)
request.setVipsCoreUserId(forecastConfiguration.getVipsLogicUserId().getVipsCoreUserIdWithFallback()); Integer VIPSCoreUserId = forecastConfiguration.getVipsLogicUserId().getVipsCoreUserIdWithFallback();
if(VIPSCoreUserId == null)
{
throw new PreprocessorException("No user id found for forecast #" + forecastConfiguration.getForecastConfigurationId() +
". Possible reason: The user's organization ("
+ forecastConfiguration.getVipsLogicUserId().getOrganizationId().getOrganizationName()
+ ") hasn't got a VIPSCoreUserId.");
}
//System.out.println("VIPSCoreUserId = " + VIPSCoreUserId + ", name=" + forecastConfiguration.getVipsLogicUserId().getLastName());
request.setVipsCoreUserId(VIPSCoreUserId);
//System.out.println("RunModel for wsId" + forecastConfiguration.getWeatherStationPointOfInterestId()); //System.out.println("RunModel for wsId" + forecastConfiguration.getWeatherStationPointOfInterestId());
Response resp = this.getManagerResource().runModel(config.getModelId(), request); Response resp = this.getManagerResource().runModel(config.getModelId(), request);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment