[JBoss AOP] - Re: Maven 2 plugin?
by elysch
"afloom" wrote : I'm looking for a way of getting my jar files being named xxx.aop. After reading on
| the Maven forum, I understand it should be done by creating a new packaging type. Is that something
| supported by this plugin or something that could be added?
| ...
| /Anders
|
Hi all.
My project is composed by different modules, like "sades-common", "sades-core", "sades-web" and
"sades-app". (The standard AndroMDA structure)
What I needed to do in order to create the *.aop file in the ear is:
a) I added a module called "sades-aop" to contain my aop code.
It contains the jboss-aop.xml placed at: "src\main\resources\META-INF".
and
b) I added
<bundleFileName>${application.id}-aop-${pom.version}.aop</bundleFileName>
to the pom.xml file of my app module. (the one that builds the final ear file).
It contains:
...
| <dependencies>
| ..
| <dependency>
| <groupId>${pom.groupId}</groupId>
| <artifactId>sades-aop</artifactId>
| <version>${pom.version}</version>
| </dependency>
| ...
| </dependencies>
| ...
| <build>
| <finalName>${application.id}-${pom.version}</finalName>
| ...
| <plugins>
| <plugin>
| <groupId>org.apache.maven.plugins</groupId>
| <artifactId>maven-ear-plugin</artifactId>
| <version>2.1</version>
| <configuration>
| <includes>**/*.xml</includes>
| <excludes>**/jboss-app.xml</excludes>
| <version>1.4</version>
| <modules>
| <javaModule>
| <groupId>${pom.groupId}</groupId>
| <artifactId>sades-aop</artifactId>
| <bundleFileName>${application.id}-aop-${pom.version}.aop</bundleFileName>
| <includeInApplicationXml>true</includeInApplicationXml>
| </javaModule>
| <javaModule>
| <groupId>${pom.groupId}</groupId>
| <artifactId>sades-common</artifactId>
| <includeInApplicationXml>true</includeInApplicationXml>
| </javaModule>
| <ejbModule>
| <groupId>${pom.groupId}</groupId>
| <artifactId>sades-core</artifactId>
| </ejbModule>
| <webModule>
| <groupId>${pom.groupId}</groupId>
| <artifactId>sades-web</artifactId>
| <contextRoot>/${application.id}</contextRoot>
| </webModule>
| </modules>
| </configuration>
| </plugin>
| ...
This way I obtain an ear file with the correct structure (as far as I can tell):
sades-1.0-SNAPSHOT.ear
| META-INF
| application.xml
| ...
| sades-aop-1.0-SNAPSHOT.aop
| META-INF
| jboss-aop.xml
| ...
| sades-common-1.0-SNAPSHOT.jar
| ...
| sades-core-1.0-SNAPSHOT.jar
| ...
| sades-web-1.0-SNAPSHOT.war
| ...
I hope this helps someone else.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4109864#4109864
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4109864
17 years, 1 month
[JBossCache] - CacheLoader is not notified when a POJO is modified
by dmary
Hi all,
I've got a problem with JDBCCacheLoader, as when i change some datas from a POJO, these changes are not reflected on the datastore used (an mysql database)
Here is my config :
<?xml version="1.0" encoding="UTF-8"?>
| <server>
|
|
| <mbean code="org.jboss.cache.aop.PojoCache"
| name="jboss.cache:service=MyPojoCache">
| <depends>jboss:service=Naming</depends>
| <depends>jboss:service=TransactionManager</depends>
|
|
| <attribute name="TransactionManagerLookupClass">
| org.jboss.cache.JBossTransactionManagerLookup
| </attribute>
| <attribute name="NodeLockingScheme">OPTIMISTIC</attribute>
| <attribute name="IsolationLevel">REPEATABLE_READ</attribute>
| <attribute name="CacheMode">LOCAL</attribute>
| <attribute name="InitialStateRetrievalTimeout">5000</attribute>
| <attribute name="SyncReplTimeout">10000</attribute>
|
| <attribute name="LockAcquisitionTimeout">15000</attribute>
|
| <attribute name="EvictionPolicyClass">org.jboss.cache.aop.eviction.AopLRUPolicy</attribute>
|
|
| <attribute name="EvictionPolicyConfig">
| <config>
| <attribute name="wakeUpIntervalSeconds">5</attribute>
| <region name="/_default_">
| <attribute name="maxNodes">5000</attribute>
| <attribute name="timeToLiveSeconds">0</attribute>
| </region>
| </config>
| </attribute>
| <attribute name="CacheLoaderConfiguration">
| <config>
| <passivation>false</passivation>
| <preload></preload>
| <shared>false</shared>
|
| <cacheloader>
| <class>org.jboss.cache.loader.JDBCCacheLoader</class>
| <properties>
| cache.jdbc.driver=com.mysql.jdbc.Driver
| cache.jdbc.url=jdbc:mysql://localhost:3306/vcall
| cache.jdbc.user=root
| cache.jdbc.password=Pas7*!
| cache.jdbc.table.drop=false
| </properties>
| <async>false</async>
| <fetchPersistentState>false</fetchPersistentState>
| <ignoreModifications>false</ignoreModifications>
| <purgeOnStartup>false</purgeOnStartup>
| </cacheloader>
| </config>
| </attribute>
| </mbean>
|
| </server>
| |
| | I use JBOSS AS 4.0.5GA and JBossCache 1.4.0.SP1.
| |
| | Any help will be appreciated.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4109863#4109863
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4109863
17 years, 1 month