Maven2 settings.xml

Maven2 settings.xml is located in ~/.m2/settings.xml and looks like this:

The Wnt- β-catenin / -canonical pathway

Wnt Pathway
Wnt Pathway
  • Ligand: Wnt factors, Receptor: Frizzled
  • Cascade:
    1. Wnt activates Frizzled receptor.
    2. Glycogen synthase kinase-3β (GSK-3β) is suppressed (via dishevelled).
    3. GSK-3β cannot phosphorylate β-catenin.
      • without active frizzled, β-catenin will form a multiprotein complex with Apc and axin. This protein complex helps to bring β-catenin together with GSK-3β for phosphorylation.
      • When β-catenin is phosphorylated, it subsequently is ubiquitylated, what leads to rapid degradation of β-catenin.
    4. β-catenin is not degraded
    5. β-catenin accumulates in cytoplasm and nucleus
    6. Two distinct effects:
      • in nucleus, β-catenin associates with Tcf/Lef transcription factors which enable the expression of genes (e.g. Cyclin D1, Myc), that drive increased proliferation and prevent differentiation. This way the canonical wnt pathway mainly contributes to the stem-cell phenotype.
      • At the cell membrane, β-catenin in involved in the formation of adherens junction, since β-catenin together with p120 and alpha-catenein establishes the linkage between cadherin and the actin cytosceleton.

The capacity to blunder slightly is the real marvel of DNA

The capacity to blunder slightly is the real marvel of DNA. Without this special attribute, we would still be anaerobic bacteria and there would be no music.

Lewis Thomas, biologist, 1979

This nicely points out the other side of the double-edged sword of genetic mutations, which often are considered to be evil without exception. In fact, the human body makes every effort to prevent them, and even will send his own cells to death without hesitation if they are affected.

But equally, every once in a while, they will give rise to new life, when they from a new organism, that has improved it’s adaptations to it’s world.

This way, genetic mutations maintain variety and richness of life.

NoClassDefFoundError while deploying EAR

  • Problem:
    When deploying an EAR (enterprise archive file) to an application server like JBOSS,
    java.lang.NoClassDefFoundError
    is thrown.
  • Solution:
    Fix your EAR package structure.

    ear-package-structure
    wrong
    ear-package-structure.2
    right
    javaee.module.dependencies
    In Eclipse, go to EAR-Project properties, select "Java EE Module Dependencies" and toggle "In Lib Dir" for your shared Java Project
  • Further information:

    • All projects/files have been created with Eclipse
    • application.ear: Exported “Enterprise Application Project”
    • app-ejb.jar: Exported “Enterprise Java Beans Project”
    • app-web.war: Exported “Dynamic Web Project”
    • app-shared.jar: Exported “Java Project”, that contains classes that are used by more than one of the sub-projects. Can also be a third party jar-File with library classes.
    • Exception occurs, since app-web.war or app-ejb.jar may be deployed just before app-shared.jar has been deployed. A workaround for that would be to first deploy app-shared.jar separately and remove it from your enterprise application compilation.

CSS styles ignored

  • Problem:
    JSF page layout defined in a CSS-file is ignored when using PrettyFaces.
  • Solution:
    Fix link to CSS file in non-working JSF’s either by using the relative path, or by providing an absolute path.
  • Further information:
    PrettyFaces page navigation breaks up link to CSS file when page navigation goes to deeper directory levels
    (www.my-domain.net/home/page/entry/1).
    That is because URL’s generated by PrettyFaces do not represent real folder structure on server:
    A multi-level URL like “www.my-domain.net/home/page/entry/1” does not actually refer to the folder structure “/home/page/entry/1”.
  • Code snippets:
    “Normal” link to CSS in a JSF:

    <link href=”css/main.css” rel=”stylesheet” type=”text/css” />

    “Fixed” link to find CSS one level above current (e.g. if page URL is like www.my-domain.net/page/1):

    <link href=”../css/main.css” rel=”stylesheet” type=”text/css” />

EJB ClassCastException

  • Problem:
    [Ljava.lang.Object; cannot be cast to x.y.z.beanEJB: java.lang.ClassCastException: [Ljava.lang.Object; cannot be cast to x.y.z.beanEJB
  • Solution:
    Add a “SELECT” statement to your (named) query.
    e.g. change :

    FROM beanEJB e
    INNER JOIN e.tags AS t
    WHERE t LIKE :ttt

    to

    SELECT e FROM beanEJB e
    INNER JOIN e.tags AS t
    WHERE t.string LIKE :ttt

  • Further information:
    A (named) query may return more than one distinct Object. An additional SELECT clause will specify the return type.
  • Code snippets:
    • </named-query>
      <named-query name=”namedQuery”>
      <query>
      <![CDATA[SELECT e FROM beanEJB e
      INNER JOIN e.tags AS t
      WHERE t LIKE :ttt]]>
      </query>
      </named-query>

    • Query q = em.createNamedQuery(“namedQuery”);
      q.setParameter(“ttt”, s);
      Log.info(q.getResultList());