javax.el.PropertyNotFoundException:目标无法到达,标识符 bean 解析为空
javax.el.PropertyNotFoundException: Target Unreachable, identifier bean resolved to null
当我尝试通过 eclipse 部署我的应用程序时收到此错误消息,因为我通过 weblogic 控制台构建和安装包我的应用程序工作正常,但每次我从 eclipse 部署我的应用程序时我的服务器启动通常,但是当我尝试访问任何页面时都会收到此消息,如果有人可以帮助我,我将非常感激。下面是我的服务器日志。
我正在使用 weblogic 12 C
Bean 管理的 CDI。
<04/12/2015 11h48min22s BRST> <Warning> <javax.enterprise.resource.webcontainer.jsf.lifecycle> <BEA-000000> <#{productUI.resetTelaConsulta}: javax.el.PropertyNotFoundException: web/src/main/webapp/WEB-INF/template/menu.xhtml @31,127 action="#{productUI.resetTelaConsulta}": Target Unreachable, identifier 'productUI' resolved to null
javax.faces.FacesException: #{productUI.resetTelaConsulta}: javax.el.PropertyNotFoundException:web/src/main/webapp/WEB-INF/template/menu.xhtml @31,127 action="#{productUI.resetTelaConsulta}": Target Unreachable, identifier 'productUI' resolved to null
at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:117)
at javax.faces.component.UICommand.broadcast(UICommand.java:315)
at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:786)
at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:1251)
at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:81)
Truncated. see log file for complete stacktrace
Caused By: javax.faces.el.EvaluationException: javax.el.PropertyNotFoundException: /web/src/main/webapp/WEB-INF/template/menu.xhtml @31,127 action="#{productUI.resetTelaConsulta}": Target Unreachable, identifier 'productUI' resolved to null
at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:94)
at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:101)
at javax.faces.component.UICommand.broadcast(UICommand.java:315)
at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:786)
at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:1251)
Truncated. see log file for complete stacktrace
Caused By: javax.el.PropertyNotFoundException: /web/src/main/webapp/WEB-INF/template/menu.xhtml @31,127 action="#{productUI.resetTelaConsulta}": Target Unreachable, identifier 'productUI' resolved to null
at com.sun.faces.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:107)
at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:87)
at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:101)
at javax.faces.component.UICommand.broadcast(UICommand.java:315)
at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:786)
Truncated. see log file for complete stacktrac
管理豆:
/**
* Managed-bean Product
*/
@Named
@SessionScoped
public class ProductUI extends AbstractUI {
private static final long serialVersionUID = 3033815555702729279L;
private static final String PRODUTO_CONSULTA = "/produto/produto_consulta.xhtml";
@Inject
private ProdutoCadastroUI produtoCadastroUI;
@Inject
private ProdutoOpcionalNovoUI produtoOpcionalNovoUI;
/**
* Construtor
*/
public ProductUI() {
searchProdutos = new ArrayList<Produto>();
ServiceLocator serviceLocator = new ServiceLocator();
produtoService = serviceLocator.lookupRemoteEJB(ProdutoService.class);
tipoProdutoService = serviceLocator.lookupRemoteEJB(TipoProdutoService.class);
generoService = serviceLocator.lookupRemoteEJB(GeneroService.class);
canalService = serviceLocator.lookupRemoteEJB(CanalService.class);
categoriaService = serviceLocator.lookupRemoteEJB(CategoriaService.class);
ofertaService = serviceLocator.lookupRemoteEJB(OfertaService.class);
opcionalService = serviceLocator.lookupRemoteEJB(OpcionalService.class);
regraProdutoService = serviceLocator.lookupRemoteEJB(RegraProdutoService.class);
disponibilidadeService = serviceLocator.lookupRemoteEJB(DisponibilidadeService.class);
equipamentoService = serviceLocator.lookupRemoteEJB(EquipamentoService.class);
}
@PostConstruct
public void init() {
filter = new ProdutoFilter();
tiposProduto = tipoProdutoService.findTiposProduto();
generos = generoService.findGenerosAtivos();
categorias = categoriaService.findCategoriasAtivas();
produtos = produtoService.findProdutosAtivos();
}
/**
* Reseta a tela de filtro
*/
public String resetTelaConsulta() {
init();
return PRODUTO_CONSULTA;
}
//Get/set methods
}
我在 WL 12.1.3 上遇到了同样的问题:尝试通过 eclipse 将其部署为展开的存档(标准是虚拟应用程序)。
右键单击服务器 -> 属性 -> 展开主题 WebLogic -> 发布 -> 单击 "Publish as an exploded archive" 并应用更改
当我尝试通过 eclipse 部署我的应用程序时收到此错误消息,因为我通过 weblogic 控制台构建和安装包我的应用程序工作正常,但每次我从 eclipse 部署我的应用程序时我的服务器启动通常,但是当我尝试访问任何页面时都会收到此消息,如果有人可以帮助我,我将非常感激。下面是我的服务器日志。
我正在使用 weblogic 12 C Bean 管理的 CDI。
<04/12/2015 11h48min22s BRST> <Warning> <javax.enterprise.resource.webcontainer.jsf.lifecycle> <BEA-000000> <#{productUI.resetTelaConsulta}: javax.el.PropertyNotFoundException: web/src/main/webapp/WEB-INF/template/menu.xhtml @31,127 action="#{productUI.resetTelaConsulta}": Target Unreachable, identifier 'productUI' resolved to null
javax.faces.FacesException: #{productUI.resetTelaConsulta}: javax.el.PropertyNotFoundException:web/src/main/webapp/WEB-INF/template/menu.xhtml @31,127 action="#{productUI.resetTelaConsulta}": Target Unreachable, identifier 'productUI' resolved to null
at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:117)
at javax.faces.component.UICommand.broadcast(UICommand.java:315)
at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:786)
at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:1251)
at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:81)
Truncated. see log file for complete stacktrace
Caused By: javax.faces.el.EvaluationException: javax.el.PropertyNotFoundException: /web/src/main/webapp/WEB-INF/template/menu.xhtml @31,127 action="#{productUI.resetTelaConsulta}": Target Unreachable, identifier 'productUI' resolved to null
at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:94)
at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:101)
at javax.faces.component.UICommand.broadcast(UICommand.java:315)
at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:786)
at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:1251)
Truncated. see log file for complete stacktrace
Caused By: javax.el.PropertyNotFoundException: /web/src/main/webapp/WEB-INF/template/menu.xhtml @31,127 action="#{productUI.resetTelaConsulta}": Target Unreachable, identifier 'productUI' resolved to null
at com.sun.faces.facelets.el.TagMethodExpression.invoke(TagMethodExpression.java:107)
at javax.faces.component.MethodBindingMethodExpressionAdapter.invoke(MethodBindingMethodExpressionAdapter.java:87)
at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:101)
at javax.faces.component.UICommand.broadcast(UICommand.java:315)
at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:786)
Truncated. see log file for complete stacktrac
管理豆:
/**
* Managed-bean Product
*/
@Named
@SessionScoped
public class ProductUI extends AbstractUI {
private static final long serialVersionUID = 3033815555702729279L;
private static final String PRODUTO_CONSULTA = "/produto/produto_consulta.xhtml";
@Inject
private ProdutoCadastroUI produtoCadastroUI;
@Inject
private ProdutoOpcionalNovoUI produtoOpcionalNovoUI;
/**
* Construtor
*/
public ProductUI() {
searchProdutos = new ArrayList<Produto>();
ServiceLocator serviceLocator = new ServiceLocator();
produtoService = serviceLocator.lookupRemoteEJB(ProdutoService.class);
tipoProdutoService = serviceLocator.lookupRemoteEJB(TipoProdutoService.class);
generoService = serviceLocator.lookupRemoteEJB(GeneroService.class);
canalService = serviceLocator.lookupRemoteEJB(CanalService.class);
categoriaService = serviceLocator.lookupRemoteEJB(CategoriaService.class);
ofertaService = serviceLocator.lookupRemoteEJB(OfertaService.class);
opcionalService = serviceLocator.lookupRemoteEJB(OpcionalService.class);
regraProdutoService = serviceLocator.lookupRemoteEJB(RegraProdutoService.class);
disponibilidadeService = serviceLocator.lookupRemoteEJB(DisponibilidadeService.class);
equipamentoService = serviceLocator.lookupRemoteEJB(EquipamentoService.class);
}
@PostConstruct
public void init() {
filter = new ProdutoFilter();
tiposProduto = tipoProdutoService.findTiposProduto();
generos = generoService.findGenerosAtivos();
categorias = categoriaService.findCategoriasAtivas();
produtos = produtoService.findProdutosAtivos();
}
/**
* Reseta a tela de filtro
*/
public String resetTelaConsulta() {
init();
return PRODUTO_CONSULTA;
}
//Get/set methods
}
我在 WL 12.1.3 上遇到了同样的问题:尝试通过 eclipse 将其部署为展开的存档(标准是虚拟应用程序)。
右键单击服务器 -> 属性 -> 展开主题 WebLogic -> 发布 -> 单击 "Publish as an exploded archive" 并应用更改