Guiced Servlets - JSF

Configures Guice Servlet for JSF

License

License

Categories

Categories

Jakarta Server Faces Jakarta EE The Web Tier GUI User Interface Guice Application Layer Libs Dependency Injection
GroupId

GroupId

com.jwebmp
ArtifactId

ArtifactId

guiced-servlets-jsf
Last Version

Last Version

0.66.0.1
Release Date

Release Date

Type

Type

jar
Description

Description

Guiced Servlets - JSF
Configures Guice Servlet for JSF
Project URL

Project URL

https://github.com/GedMarc/Guiced-Servlets-JSF
Project Organization

Project Organization

Marc Magon
Source Code Management

Source Code Management

https://github.com/GedMarc/Guiced-Servlets-JSF.git

Download guiced-servlets-jsf

How to add to project

<!-- https://jarcasting.com/artifacts/com.jwebmp/guiced-servlets-jsf/ -->
<dependency>
    <groupId>com.jwebmp</groupId>
    <artifactId>guiced-servlets-jsf</artifactId>
    <version>0.66.0.1</version>
</dependency>
// https://jarcasting.com/artifacts/com.jwebmp/guiced-servlets-jsf/
implementation 'com.jwebmp:guiced-servlets-jsf:0.66.0.1'
// https://jarcasting.com/artifacts/com.jwebmp/guiced-servlets-jsf/
implementation ("com.jwebmp:guiced-servlets-jsf:0.66.0.1")
'com.jwebmp:guiced-servlets-jsf:jar:0.66.0.1'
<dependency org="com.jwebmp" name="guiced-servlets-jsf" rev="0.66.0.1">
  <artifact name="guiced-servlets-jsf" type="jar" />
</dependency>
@Grapes(
@Grab(group='com.jwebmp', module='guiced-servlets-jsf', version='0.66.0.1')
)
libraryDependencies += "com.jwebmp" % "guiced-servlets-jsf" % "0.66.0.1"
[com.jwebmp/guiced-servlets-jsf "0.66.0.1"]

Dependencies

compile (3)

Group / Artifact Type Version
com.jwebmp : guiced-servlets jar 0.66.0.1
com.jwebmp : commons-io jar 0.66.0.1
org.glassfish : javax.faces jar 2.3.5

provided (1)

Group / Artifact Type Version
org.glassfish : javax.el jar 3.0.0

test (6)

Group / Artifact Type Version
com.jwebmp : guiced-servlets test-jar 0.66.0.1
org.junit.jupiter : junit-jupiter-api jar 5.4.0
org.hamcrest : hamcrest-all jar 1.3
org.assertj : assertj-core jar 3.11.1
org.mockito : mockito-core jar 2.23.4
com.h2database : h2 jar 1.4.197

Project Modules

There are no modules declared in this project.

Guiced-Servlets-JSF

JSF Integration for Guiced Injection Framework. Allows for Faces to execute through the Guice Filter

To configure correctly, add the following to faces-config

<factory>
    <application-factory>com.jwebmp.guicedservlets.jsf.FacesApplicationFactoryWrapper</application-factory>
</factory>

Remember to remove your context path from web.xml or it will be skipped

REMOVE

 <servlet>
        <servlet-name>Faces Servlet</servlet-name>
        <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
    </servlet>
    <servlet-mapping>
        <servlet-name>Faces Servlet</servlet-name>
        <url-pattern>*.jsf</url-pattern>
    </servlet-mapping>
    <servlet-mapping>
        <servlet-name>Faces Servlet</servlet-name>
        <url-pattern>*.xhtml</url-pattern>
    </servlet-mapping>

This mapping is performed through the servlet binder

You can change/add URL mappings by configuring GuicedServletJSFBindings or by mapping your own

module.serve$("/faces/", "/faces/*", "*.jsf", "*.faces", "*.xhtml")
		      .with(FacesHttpServlet.class);

This implementation is a merge of http://javaevangelist.blogspot.com/2013/08/jsf-2x-tip-of-day-guice-elresolver.html and https://github.com/skuzzle/guice-jsf and uses the automated configurations of guiced-servlets and guiced-injection

Versions

Version
0.66.0.1
0.65.0.3
0.65.0.2
0.63.0.61
0.62.0.1