2. ルールの実行時にエラーが発生する、正しく動作しない¶
ルールの実行で発生するエラー
- DecisionTable で利用している項目が Glossary に存在しない
- 「SOAの実行に失敗しました」と表示され、ログにNullPointerExceptionが出力される
2.1. DecisionTable で利用している項目が Glossary に存在しない¶
2.1.1. 現象¶
2.1.2. 条件¶
bis.logやコンソールに下記のようなスタックトレースが出力されている。
[2015-03-23 21:10:15.028] ERROR - [resin-port-8080-99] - [default] - [bis.common.user_program.soa_executor] SOAを実行している最中に例外が発生しました。システム管理者に問い合わせてください。 [2015-03-23 21:17:32.762] ERROR - [resin-port-8080-200] - [default] - [jp.co.intra_mart.system.bis.soa.connector.rule.RuleConnector] ルールを実行している際にエラーが発生しました。 ERROR in Glossary: cannot find element 'テスト値1' org.openl.binding.OpenLRuntimeException: ERROR in Glossary: cannot find element 'テスト値1' ・・・ Caused by: org.apache.commons.lang.exception.NestableRuntimeException: ERROR in Glossary: cannot find element 'テスト値1' ・・・ [2015-03-23 21:17:32.889] ERROR - [resin-port-8080-200] - [default] - [bis.common.user_program.soa_executor] SOAを実行している最中に例外が発生しました。システム管理者に問い合わせてください。
2.1.3. 原因¶
Excelファイル内に下記の定義誤りが存在する場合に発生します。
- DecisionTable で Condition や Conclusion などに使用している項目が Glossary に定義されていない、または、項目名が間違っている。
2.1.4. 解決方法¶
スタックトレース中に、定義されていない項目名が出ていますので、その項目名と Glossary の定義を照らし合わせてください。上のスタックトレースの場合の読み方は、下記の通りです。下記の読み方に基づいて、Excelの定義ファイルを修正し、再度データソース定義にアップロードしてください。
- ERROR in Glossary: cannot find element ‘対象の項目名’
- DecisionTable で’対象の項目名’ が Glossary で見つけられないことを表しています。
2.2. 「SOAの実行に失敗しました」と表示され、ログにNullPointerExceptionが出力される¶
2.2.1. 現象¶
2.2.2. 条件¶
bis.logやコンソールに下記のようなスタックトレースが出力されている。ログの内容には、 OpenRules で処理ができているかのような内容とNullPointerExceptionが出力されている。[INFO] o.o.u.Log - [] *** Decision myRule *** [INFO] o.o.u.Log - [] Decision has been initialized [INFO] o.o.u.Log - [] Decision Run has been initialized [INFO] o.o.u.Log - [] Conclusion: メッセージ = 中学生 [中学生] [INFO] o.o.u.Log - [] Decision has been finalized java.lang.NullPointerException at jp.co.intra_mart.system.bis.soa.mapping.RuleObjectMapper.getMap(RuleObjectMapper.java:357) at jp.co.intra_mart.system.bis.soa.mapping.RuleObjectMapper.mapping(RuleObjectMapper.java:78) at jp.co.intra_mart.system.bis.soa.connector.rule.RuleConnector.executeResponseDef(RuleConnector.java:225) at jp.co.intra_mart.system.bis.internal.SoaClientManager.execute(SoaClientManager.java:93) at jp.co.intra_mart.system.bis.javascript.api.SoaClientManagerObject.execute(SoaClientManagerObject.java:111) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:497) at jp.co.intra_mart.system.javascript.MemberBox.invoke(MemberBox.java:126) at jp.co.intra_mart.system.javascript.FunctionObject.call(FunctionObject.java:442) at jp.co.intra_mart.system.javascript.optimizer.OptRuntime.callN(OptRuntime.java:52) at _forma._common._soa._soa_95_client_46_js._c_execute_1(C:\Resin\resin-pro-4.0.53\webapps\imart\WEB-INF\jssp\product\src\forma\common\soa\soa_client.js:37) at _forma._common._soa._soa_95_client_46_js.call(C:\Resin\resin-pro-4.0.53\webapps\imart\WEB-INF\jssp\product\src\forma\common\soa\soa_client.js) at jp.co.intra_mart.system.display.ScriptScope.call(ScriptScope.java:156) at jp.co.intra_mart.system.display.ScriptScope.call(ScriptScope.java:142) at jp.co.intra_mart.system.display.Content.executeFunction(Content.java:188) at jp.co.intra_mart.system.javascript.imapi.ContentObject.jsStaticFunction_executeFunction(ContentObject.java:170) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:497) at jp.co.intra_mart.system.javascript.MemberBox.invoke(MemberBox.java:126) at jp.co.intra_mart.system.javascript.FunctionObject.call(FunctionObject.java:379) at jp.co.intra_mart.system.javascript.optimizer.OptRuntime.callN(OptRuntime.java:52) at _forma._common._util._datasource_95_utils_46_js._c_execute_2(C:\Resin\resin-pro-4.0.53\webapps\imart\WEB-INF\jssp\product\src\forma\common\util\datasource_utils.js:30) at _forma._common._util._datasource_95_utils_46_js.call(C:\Resin\resin-pro-4.0.53\webapps\imart\WEB-INF\jssp\product\src\forma\common\util\datasource_utils.js) at jp.co.intra_mart.system.javascript.optimizer.OptRuntime.callN(OptRuntime.java:52) at _bis._common._user_95_program._soa_95_executor_46_js._c_execute_1(C:\Resin\resin-pro-4.0.53\webapps\imart\WEB-INF\jssp\product\src\bis\common\user_program\soa_executor.js:41) at _bis._common._user_95_program._soa_95_executor_46_js.call(C:\Resin\resin-pro-4.0.53\webapps\imart\WEB-INF\jssp\product\src\bis\common\user_program\soa_executor.js) at jp.co.intra_mart.system.display.ScriptScope.call(ScriptScope.java:156) at jp.co.intra_mart.system.display.ScriptScope.call(ScriptScope.java:142) at jp.co.intra_mart.system.display.Content.executeFunction(Content.java:188) at jp.co.intra_mart.system.javascript.imapi.ContentObject.jsStaticFunction_executeFunction(ContentObject.java:170) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:497) at jp.co.intra_mart.system.javascript.MemberBox.invoke(MemberBox.java:126) at jp.co.intra_mart.system.javascript.FunctionObject.call(FunctionObject.java:379) at jp.co.intra_mart.system.javascript.optimizer.OptRuntime.callN(OptRuntime.java:52) at _forma._designer._event_95_setting._reference_46_js._c_executeSoa_13(C:\Resin\resin-pro-4.0.53\webapps\imart\WEB-INF\jssp\product\src\forma\designer\event_setting\reference.js:566) at _forma._designer._event_95_setting._reference_46_js.call(C:\Resin\resin-pro-4.0.53\webapps\imart\WEB-INF\jssp\product\src\forma\designer\event_setting\reference.js) at jp.co.intra_mart.system.javascript.ContextFactory.doTopCall(ContextFactory.java:394) at jp.co.intra_mart.system.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3101) at _forma._designer._event_95_setting._reference_46_js.call(C:\Resin\resin-pro-4.0.53\webapps\imart\WEB-INF\jssp\product\src\forma\designer\event_setting\reference.js) at jp.co.intra_mart.system.display.ScriptScope.call(ScriptScope.java:156) at jp.co.intra_mart.system.display.ScriptScope.call(ScriptScope.java:142) at jp.co.intra_mart.system.servlet.jssp.JsspRpcServlet.invoke(JsspRpcServlet.java:177) at jp.co.intra_mart.system.servlet.jssp.JsspRpcServlet.execute(JsspRpcServlet.java:141) at jp.co.intra_mart.system.servlet.jssp.JsspRpcServlet.doPost(JsspRpcServlet.java:125) at javax.servlet.http.HttpServlet.service(HttpServlet.java:159) at javax.servlet.http.HttpServlet.service(HttpServlet.java:97) at com.caucho.server.dispatch.ServletFilterChain.doFilter(ServletFilterChain.java:109) at jp.co.intra_mart.system.servlet.jssp.JSSPContextFilter.doFilter(JSSPContextFilter.java:63) at com.caucho.server.dispatch.FilterFilterChain.doFilter(FilterFilterChain.java:89) at jp.co.intra_mart.common.aid.jsdk.javax.servlet.filter.impl.HTTPContextHandlingFilterImpl.doFilter(HTTPContextHandlingFilterImpl.java:53) at jp.co.intra_mart.common.aid.jsdk.javax.servlet.filter.HTTPContextHandlingFilter.doFilter(HTTPContextHandlingFilter.java:94) at com.caucho.server.dispatch.FilterFilterChain.doFilter(FilterFilterChain.java:89) at jp.co.intra_mart.system.servlet.filter.RequestScopeLockReleaseFilter.doFilter(RequestScopeLockReleaseFilter.java:44) at com.caucho.server.dispatch.FilterFilterChain.doFilter(FilterFilterChain.java:89) at jp.co.intra_mart.system.secure.filter.ApplicationPermissionFilter.doFilter(ApplicationPermissionFilter.java:65) at com.caucho.server.dispatch.FilterFilterChain.doFilter(FilterFilterChain.java:89) at jp.co.intra_mart.system.secure.filter.SystemPermissionFilter.doFilter(SystemPermissionFilter.java:68) at com.caucho.server.dispatch.FilterFilterChain.doFilter(FilterFilterChain.java:89) at jp.co.intra_mart.foundation.router.RoutingFilter.doFilter(RoutingFilter.java:41) at com.caucho.server.dispatch.FilterFilterChain.doFilter(FilterFilterChain.java:89) at jp.co.intra_mart.foundation.security.filter.SessionFilter.doFilter(SessionFilter.java:70) at com.caucho.server.dispatch.FilterFilterChain.doFilter(FilterFilterChain.java:89) at jp.co.intra_mart.system.log.transition.TransitionLogFilter.doFilter(TransitionLogFilter.java:73) at com.caucho.server.dispatch.FilterFilterChain.doFilter(FilterFilterChain.java:89) at jp.co.intra_mart.system.servlet.filter.RequestLogFilter.doFilter(RequestLogFilter.java:110) at com.caucho.server.dispatch.FilterFilterChain.doFilter(FilterFilterChain.java:89) at jp.co.intra_mart.system.servlet.filter.ResponseHeaderFilter.doFilter(ResponseHeaderFilter.java:154) at com.caucho.server.dispatch.FilterFilterChain.doFilter(FilterFilterChain.java:89) at jp.co.intra_mart.system.context.web.impl.ContextFilter.doContextFilter(ContextFilter.java:137) at jp.co.intra_mart.system.context.web.impl.PreContextFilterChain.doFilter(PreContextFilterChain.java:47) at jp.co.intra_mart.system.context.web.impl.ContextFilter.doFilter(ContextFilter.java:78) at com.caucho.server.dispatch.FilterFilterChain.doFilter(FilterFilterChain.java:89) at jp.co.intra_mart.foundation.security.filter.ResponseCharacterEncodingFilter.doFilter(ResponseCharacterEncodingFilter.java:90) at com.caucho.server.dispatch.FilterFilterChain.doFilter(FilterFilterChain.java:89) at jp.co.intra_mart.foundation.security.filter.RequestCharacterEncodingFilter.doFilter(RequestCharacterEncodingFilter.java:47) at com.caucho.server.dispatch.FilterFilterChain.doFilter(FilterFilterChain.java:89) at com.caucho.server.webapp.WebAppFilterChain.doFilter(WebAppFilterChain.java:156) at com.caucho.server.webapp.AccessLogFilterChain.doFilter(AccessLogFilterChain.java:95) at com.caucho.server.dispatch.ServletInvocation.service(ServletInvocation.java:290) at com.caucho.server.http.HttpRequest.handleRequest(HttpRequest.java:838) at com.caucho.network.listen.TcpSocketLink.dispatchRequest(TcpSocketLink.java:1353) at com.caucho.network.listen.TcpSocketLink.handleRequest(TcpSocketLink.java:1309) at com.caucho.network.listen.TcpSocketLink.handleRequestsImpl(TcpSocketLink.java:1293) at com.caucho.network.listen.TcpSocketLink.handleRequests(TcpSocketLink.java:1201) at com.caucho.network.listen.TcpSocketLink.handleAcceptTaskImpl(TcpSocketLink.java:997) at com.caucho.network.listen.ConnectionTask.runThread(ConnectionTask.java:117) at com.caucho.network.listen.ConnectionTask.run(ConnectionTask.java:93) at com.caucho.network.listen.SocketLinkThreadLauncher.handleTasks(SocketLinkThreadLauncher.java:169) at com.caucho.network.listen.TcpSocketAcceptThread.run(TcpSocketAcceptThread.java:61) at com.caucho.env.thread2.ResinThread2.runTasks(ResinThread2.java:173) at com.caucho.env.thread2.ResinThread2.run(ResinThread2.java:118)