Giter Site home page Giter Site logo

agoncal-book-javaee7's People

Contributors

agoncal avatar hasalex avatar madvens avatar pdudits avatar youness-teimoury avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

agoncal-book-javaee7's Issues

Error url chapter 11 servlets

When deploy the project of chapter 11 not alow, because, apper the next error: Error occurred during deployment: Exception while deploying the app [chapter11-1.0] : Servlet [RegistrationPortTypeRPCPortImpl] and Servlet [RegistrationRequesterPortTypePortImpl] have the same url pattern.

please help me, I don't now what is?

I give excuses for my english

Error at deploying jar Service from Chapter 8

At the last step in deploying the jar from chapter 8(Service), i got this error Exception while invoking class org.glassfish.ejb.startup.EjbApplication start methodjava.lang.RuntimeException: java.lang.ClassNotFoundException: org.hibernate.validator.cdi.internal.interceptor.ValidationInterceptor. I don't know if it's because glassfish has the wrong version for CDI validator or not.
Tested on :

  • JDK 1.8
  • Maven 3.5.2
  • Derby 10.14.1.0 database
  • GlassFish 5.0 application server

Erreur au déploiement de chapter22-service

Le module war est déployé correctement, mais avec l'erreur suivante :

PER01003: Deployment encountered SQL Exceptions:
PER01000: Got SQLException executing statement "CREATE TABLE SEQUENCE (SEQ_NAME VARCHAR(50) NOT NULL, SEQ_COUNT DECIMAL(15), PRIMARY KEY (SEQ_NAME))": java.sql.SQLException: Table/View 'SEQUENCE' existe déjà dans Schema 'APP'.
PER01000: Got SQLException executing statement "INSERT INTO SEQUENCE(SEQ_NAME, SEQ_COUNT) values ('SEQ_GEN', 0)": java.sql.SQLIntegrityConstraintViolationException: L'instruction a été abandonnée parce qu'elle aurait entraîné la duplication d'une valeur de clé dans une contrainte de clé ou d'index unique identifié par 'SQL121207220824430' définie sur 'SEQUENCE'.
Command deploy completed with warnings.

Test réalisé avec GlassFish Server Open Source Edition 4.0 (build 64)

Interceptor signature warnings (not spec-conformant)

From jdk8 (1.8.0u45) via intelliJ when executing the chapter 2 ex33 tests:

[main] WARN org.jboss.weld.Reflection - WELD-001471 Interceptor method logMethod defined on class org.agoncal.book.javaee7.chapter02.ex27.ProfileInterceptor27 is not defined according to the specification. It should not throw java.lang.Exception, which is a checked exception.
[main] WARN org.jboss.weld.Reflection - WELD-001471 Interceptor method init defined on class org.agoncal.book.javaee7.chapter02.ex25.LoggingInterceptor25 is not defined according to the specification. It should not throw java.lang.Exception, which is a checked exception.

page 46 of the book says "This method can throw a checked exception" in reference to Interceptors.

LoggingProducer.java does not produce log

https://github.com/agoncal/agoncal-book-javaee7/blob/master/chapter02/chapter02-putting-together/src/main/java/org/agoncal/book/javaee7/chapter02/LoggingProducer.java

Original code on the book.

@Produces
public Logger produceLogger(InjectionPoint injectionPoint) {
    return Logger.getLogger(injectionPoint.getMember().getDeclaringClass().getName());
}

Proposal code.

@Produces
public Logger produceLogger(InjectionPoint injectionPoint) {
    Logger logger = Logger.getLogger(injectionPoint.getMember().getDeclaringClass().getName());
    Handler h = new ConsoleHandler();
    h.setLevel(Level.ALL);
    logger.addHandler(h);
    logger.setLevel(Level.ALL); 
    return logger;
}

dependency failed

I got the following error when I do mvn dependency:go-offline

[ERROR] Failed to execute goal on project chapter08-consumer: Could not resolve dependencies for project org.agoncal.book.javaee7.chapter08:chapter08-consumer:jar:1.0: Failure to find org.agoncal.book.javaee7.chapter08:chapter08-service:jar:1.0 in http://maven.repository.redhat.com/techpreview/all was cached in the local repository, resolution will not be reattempted until the update interval of jboss-ga-repository has elapsed or updates are forced -> [Help 1]

It seems the dependency it's not in the repository

@Qualifier, @Target parameters

in documentations, it says the following;

///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
@qualifier
@retention(RUNTIME)
@target({TYPE, METHOD, FIELD, PARAMETER})
public @interface Informal {}
You can then define a bean class that extends the Greeting class and uses this qualifier:

package greetings;

@InFormal
public class InformalGreeting extends Greeting {
public String greet(String name) {
return "Hi, " + name + "!";
}
}
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////

However in the examples the book provide, the following annotations are used.

///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
@qualifier
@retention(RUNTIME)
@target({FIELD, TYPE, METHOD})
public @interface ThirteenDigits {
}
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////

In netbeans IDE, this gives an error (http://tinypic.com/view.php?pic=fknqs2&s=8#.U5R4Z3VdWhc), although it compiles and runs.

I tried changing the the target annotation to @target({METHOD, FIELD, PARAMETER, TYPE}), which works just as well without the error sign. Are there going to be cases where I'd want(because of necessity) to put 3 targets likeyou did, instead of 4 like documentation suggests?

chapter22-service : error 500 when calling getAllBooks / json

FAIL (Error 500) :

    curl -X GET -H "Accept: application/json" http://localhost:8080/chapter22-service-1.0/rs/book -v

WIN :

    curl -X GET -H "Accept: application/xml" http://localhost:8080/chapter22-service-1.0/rs/book -v

Tested with GlassFish Server Open Source Edition 4.0 (build 64)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.