> This looks really good and will be really helpful to lots of people - thank
> you!
> I've had a look and have learnt some things from it myself, however I have
> a few questions.
> 
> Is the "@ImportModule(CommonModule.class)" required?
> 
> Instead of that I have something like this in my pom.xml
> <plugin>
>            <groupId>org.apache.maven.plugins</groupId>
>            <artifactId>maven-jar-plugin</artifactId>
>            <configuration>
>            <archive>
>              <manifestEntries>
> 
>  <Tapestry-Module-
> Classes>org.example.happylib.services.HappyModule</Tapestry-Module-
> Classes>
>              </manifestEntries>
>            </archive>
>            </configuration>
>        </plugin>
> 

No! But I find this method much easier (This was a tip from Kalle Korhonen in 
this thread)

> But of course I had the problem that it doesn't seem to run my
> contributeHibernateEntityPackageManager in HappyModule to add my
> entities
> package (in my common module) to hibernate - maybe this is why. I'm away
> from my work PC so I will have to check next time.

It should run for both methods.

BTW: In my real project I am not using contributeHibernateEntityPackageManager 
but <mapping class="..."/> in hibernate.cfg.xml because IntelliJ use it to 
resolve table information.


> 
> Also, is AppModule here needed?
> https://github.com/sveine/tapestry-multi-module-
> demo/blob/master/common/src/main/java/com/demo/commonlib/service
> s/AppModule.java

No! Can be removed.

> 
> If we do have to put "@ImportModule(CommonModule.class)" in the non-
> common
> appmodules then it means that if we grab a module from some library or
> repository that we need to know the name of the module which needs to be
> imported for it to work (i'm sure this can't be right).

> 
> There is a good chance my understanding is wrong, but in my understanding
> it's best to have the module be auto loaded without it needing importing,
> simply by adding it to the classpath (or pom.xml), otherwise the main
> projects need to know about the details of how the shared module work.

The way this is done in tapestry makes sense for me. My main module is addicted 
to the common module. I don't want a loose coupling. I want to make code in the 
common module (code-)shared between different front-end modules (end-user, 
admin, web-service).

 
> On 10 August 2015 at 15:51, Svein-Erik Løken <[hidden email]> wrote:
> 
> > >
> > > > Read about URL rewriting at
> > > > https://tapestry.apache.org/url-rewriting.html, but cannot figure out
> > > > how this can solve my question of how to access assets from javascript.
> > >
> > > Pass the asset URLs from Tapestry to JavaScript.
> > >
> >
> > Thank you Thiago!
> >
> >
> >
> > I have created a project for people who want a quick start with a
> > multi-module tapestry/maven project.
> >
> > https://github.com/sveine/tapestry-multi-module-demo
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [hidden email]
> > For additional commands, e-mail: [hidden email]
> >
> 
> ________________________________________
> If you reply to this email, your message will be added to the discussion
> below:
> http://apache-tapestry-mailing-list-
> archives.1045711.n5.nabble.com/Multiple-domains-one-webapp-
> tp5730972p5731050.html
> To unsubscribe from users@tapestry.apache.org Mailing List Archives, click
> here.
> NAML

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org

Reply via email to