adam bien's blog

Questions For 13th Airhacks Q&A Easter Egg Edition at Tuesday 7th April 📎

Last chance to ask questions. We will discuss them at 7th April (exceptionally at Tuesday), 6.PM. CET: http://www.ustream.tv/channel/adambien:

  1. I have never used Spring ,hibernate and struts ,I build my web app's using Jsf, ejb,cdi ,jpa ,is the same ? what's the difference? [@SoyRoji]
  2. Do you follow any java or software development related blogs? If so, would you share some with us. [matlach]
  3. JPA 2.1 has properties to drop and create the database but not to update it. How do you usually handle database schema updates and rollbacks? [xavistp]
  4. For multi tenancy application I am using JAVA EE 7. I need to change schema dynamically based on customer.Since there will be a lot of customer so multiple EntityManager will be insufficient. So I am using Hibernate's EmptyInterceptor along with ThreadLocal and changing schema dynamically which is working fine.Since, my solution is tightly couple with Hibernate, could you suggest me some generic way so that it will be vendor independent .

    Also Like to ask which application server( full java EE 7 support) will be best for production Glasfish(payara) or Wildfly or Liberty.

    [surajchhetry]
  5. In a JAVA EE 7 web application with an highly and dynamic configuration settings for the persistence tier, what will be your way? NoSQL or an entity abstraction layer like Atlassian JIRA (Apache OfBiz)? [riccardomerolla]
  6. Your thoughts on java ee "extensions" like deltaspike and picketlink as you always advocate slim "war"-files. i.e. few external dependencies?
I, for one, would miss for example "deltaspike data" or the powerful, though complicated, security features of picketlink (like build in JWT).

    I also noticed that you are a member of the JSR 375 (Java EE Security API) expert group. Do you have any infos/plans about that JSR?

    [haisi]
  7. Having read about the so called "onion architecture" as opposed to the traditional layered architecture I am wondering about how to realize that with Java EE. The onion promotes an application core, which is independent of libraries and infrastructure. With Java EE's POJOs I have a feeling that we are already close to that onion idea, right? Regards, Michael [micgn]
  8. How would you implement "RPC like" API between microservices using your Java EE approach? Do you think that JAX-RS can be used for that (especially with JAX-RS client API)? if not, what else could be used in Your opinion? Regards, Piotrek [pkucia]
  9. It's been announced a new MVC framework with Java EE 8. What do you see in the future of JSF? Do you think JSF will become obsoleted by this MVC framework? Thank you Antonio Varela.[antoniovl]
  10. Do you use JSF for the presentation layer of your projects, or you use someting else? Thank you again. Antonio Varela. [antoniovl]
  11. Why JNDI expose implementation bean name in global namespace? Why the caller must know name of bean for standardized JNDI java:global/appname/modulename/beanname!interfacename [n4noman]
  12. What are your recommended strategies for achieving zero downtime under continuous delivery principles? My team has a good pipeline in place for automated verification: from unit tests to functional tests to code coverage checks to corporate compliance checks to user acceptance tests. At the end of the pipe though, we still have to take a downtime while the application is redeployed. This can range from 1-5 minutes depending on the application, our current Java EE container is Apache TomEE. Thank you! jieryn
  13. Do you think there is value in having a JDBC driver wrapper which populates its configuration parameters (e.g. jdbc.url) from a distributed configuration management system like etcd (by CoreOS)? The idea being that a customer would stand up many instances of a JavaEE server, probably through Docker, and configure the database endpoint through etcd. Then the database could be dynamically migrated and update the etcd configuration. This might allow database migration without restarting all web layer microservices. Is this pathologically dangerous? Is there some alternative to this? Thank you! [jieryn]
  14. What is the best way to achieve a singleton JPA @Entity? I find I often I want to create a singleton object which holds runtime configuration data, configurable within the application itself, and persistently stored within the JPA environment for that application. In order to maintain that only one ApplicationConfiguration will ever exist within the application, I have to jump through hoops for all CRUD operations within my DAO layer and play tricks with the @Id (checking if @Entity exists, then remapping the CxUD with the getId() of the originally persisted entity, yuck). Would you please recommend a strategy for a JPA @Entity which follows @Singleton semantics. Thank you! [jieryn]
  15. Are cross-view (cross-rectangle) Presenter something valuable? Did you ever miss that? In JEE application I used to freedom in EJB assembly, for example: I have 3 EJB A,B,C. I can freely assembly other EJBs:
    
    @Stateless class AddressBean {
    @Inject A a;
    @Inject B b;
    }
    @Stateless class PaymentBean {
    @Inject B b;
    @Inject C c;
    }
    
    
    In JavaFx view is constructed in FXML with rectangles. For example one top rectangle is attendeeinput.fmxl and bottom rectangle is workshops.fxml. And bottom rectangle has inside other rectangle day.fxml. That is OK. What is hard to accept to me is that Presenter is tied to rectangles. I would like to have freedom with Presenter assembly, i would like to inject by @FMXL gui components from many rectangles. For example if checkbox from top rectangle is checked then textfield from bottom rectangle is disabled. It will be natural to me to have a dedicated Presenter, not tied to any rectangle, with injected by @FXML checkbox from top and textfield from bottom view. Conclusion: I want Presenter freedom. I didn't found the freedom in JavaFX so checked afterburner.fx. but there isn't also. My questions: 1. Is Presenter freedom something valuable or it is a wrong thinking. Bad analogy with JEE. 2. If valuable, is it possible to apply that concept to JavaFX, with or without afterburner.fx? [michaldo]

See you at Java EE Workshops at Munich Airport, Terminal 2 or Virtual Dedicated Workshops / consulting