Compare commits

...

133 Commits

Author SHA1 Message Date
mindthegab
89d0788e0e [maven-release-plugin] copy for tag alfresco-lifecycle-aggregator-1.0
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/tags/alfresco-lifecycle-aggregator-1.0@657 04253f4f-3451-0410-a141-5562f1e59037
2012-11-05 02:16:03 +00:00
mindthegab
4d60a2defc [maven-release-plugin] prepare release alfresco-lifecycle-aggregator-1.0
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@656 04253f4f-3451-0410-a141-5562f1e59037
2012-11-05 02:15:55 +00:00
mindthegab
2f3e4c4a18 -- added parent --> aggregator inheritance
-- removed duplicated
-- re-enabled aggregator level release 

git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@655 04253f4f-3451-0410-a141-5562f1e59037
2012-11-05 02:15:16 +00:00
mindthegab
5c0fad94ac -- removed SDK parent
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@654 04253f4f-3451-0410-a141-5562f1e59037
2012-11-05 02:00:39 +00:00
mindthegab
0f914216c1 [maven-release-plugin] rollback the release of alfresco-lifecycle-aggregator-1.0
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@653 04253f4f-3451-0410-a141-5562f1e59037
2012-11-05 01:45:21 +00:00
mindthegab
22102ca16f [maven-release-plugin] prepare for next development iteration
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@651 04253f4f-3451-0410-a141-5562f1e59037
2012-11-05 01:42:40 +00:00
mindthegab
30a59e0f05 [maven-release-plugin] copy for tag alfresco-lifecycle-aggregator-1.0
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/tags/alfresco-lifecycle-aggregator-1.0@650 04253f4f-3451-0410-a141-5562f1e59037
2012-11-05 01:42:35 +00:00
mindthegab
02f11b7a41 [maven-release-plugin] prepare release alfresco-lifecycle-aggregator-1.0
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@649 04253f4f-3451-0410-a141-5562f1e59037
2012-11-05 01:42:24 +00:00
mindthegab
be9ffb4f28 -- fixes release as there are inter-module deps, so 'clean verify' is not enough
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@648 04253f4f-3451-0410-a141-5562f1e59037
2012-11-05 01:38:50 +00:00
mindthegab
39a9bb3cc9 -- fixed typo
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@647 04253f4f-3451-0410-a141-5562f1e59037
2012-11-05 01:33:41 +00:00
mindthegab
e3458874da -- added autoVersionSubModules
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@646 04253f4f-3451-0410-a141-5562f1e59037
2012-11-05 01:28:07 +00:00
mindthegab
0a1ea9c34d -- preparing archetypes for 1.0 release
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@645 04253f4f-3451-0410-a141-5562f1e59037
2012-11-05 01:24:44 +00:00
mindthegab
c570ba5b38 -- fixed indentation
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@644 04253f4f-3451-0410-a141-5562f1e59037
2012-11-05 01:04:33 +00:00
maoo
572c8bdaed added link to devcon site
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@643 04253f4f-3451-0410-a141-5562f1e59037
2012-11-05 01:01:45 +00:00
maoo
eb3de51c9a added project history and few minor documentation fixes
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@642 04253f4f-3451-0410-a141-5562f1e59037
2012-11-05 01:00:31 +00:00
mindthegab
a69a6c240a -- misc site fixes
-- added change plugin

git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@641 04253f4f-3451-0410-a141-5562f1e59037
2012-11-05 00:54:36 +00:00
maoo
3805b97335 removed Parent Project menu item from alfresco-maven-plugin site.
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@640 04253f4f-3451-0410-a141-5562f1e59037
2012-11-05 00:16:26 +00:00
mindthegab
34fee645b8 -- fixed title for components section
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@639 04253f4f-3451-0410-a141-5562f1e59037
2012-11-05 00:16:01 +00:00
maoo
d42a868990 minor typo
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@638 04253f4f-3451-0410-a141-5562f1e59037
2012-11-04 23:45:34 +00:00
maoo
dc1b95cb08 maven site various fixes, mostly links
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@637 04253f4f-3451-0410-a141-5562f1e59037
2012-11-04 23:43:15 +00:00
mindthegab
830df696c5 -- fixed POM snippet
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@636 04253f4f-3451-0410-a141-5562f1e59037
2012-11-04 20:20:11 +00:00
maoo
394102051d fixing maven-site-plugin version to 3.2
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@635 04253f4f-3451-0410-a141-5562f1e59037
2012-11-04 20:07:08 +00:00
maoo
081321c879 added pluginRepositories configuration; avoids builds failing trying to find alfresco-maven-plugin
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@634 04253f4f-3451-0410-a141-5562f1e59037
2012-11-04 17:24:02 +00:00
mindthegab
fdc7942511 -- fixed site:deploy
-- added docs for each modules
-- deployed a staging snapshot at

https://artifacts.alfresco.com/nexus/content/repositories/alfresco-docs/alfresco-lifecycle-aggregator/latest/index.html

-- TODO: check links!

git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@633 04253f4f-3451-0410-a141-5562f1e59037
2012-11-04 14:02:45 +00:00
mindthegab
c9eceeddff -- fixed svn:ignore
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@632 04253f4f-3451-0410-a141-5562f1e59037
2012-11-04 10:06:33 +00:00
mindthegab
f623dfeecd -- fixed site staging for SDK pom (now running 'mvn clean site site:stage' to preview multimodule actually *works*)
-- Added full plugin documentation
-- Fixed layout issues on fluido-skin
-- added main index.html for the aggregator

git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@631 04253f4f-3451-0410-a141-5562f1e59037
2012-11-04 10:04:21 +00:00
mindthegab
11ff4a2942 -- javadocs and site improvements
-- forgot wcmqs in archetype

git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@630 04253f4f-3451-0410-a141-5562f1e59037
2012-11-03 20:34:31 +00:00
mindthegab
a869e55b25 -- fixed install plugin. Right now dependencies unpacking is handled from the unArchiver via standard <overlay> mechanism
-- modified semantics of install
   - by default not bound to any phase
   - accepts a parameter called ampLocation (a single AMP or a folder) and installs to a WAR (or exploded WAR)
   - warLocation can also be specified
   - mostly a utility plugin / MMT wrap to be embedded in Alfresco related builds
   - singleAmp does not exist anymore. either put your AMP in ${project.build.directory}/${project.build.finalName}.amp or configure 'ampLocation'
- updated site

git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@629 04253f4f-3451-0410-a141-5562f1e59037
2012-11-03 20:15:10 +00:00
mindthegab
56475bb755 -- fixed proper installation of modules at test time
-- created a separate test-classpath mimicking MMT behavior by adding module.properties in the right classpath location
-- separated amp-testing profile so that it only activated when src/test/java is enabled
-- externalized properties

git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@628 04253f4f-3451-0410-a141-5562f1e59037
2012-11-03 20:05:12 +00:00
mindthegab
884f1596a9 copying back parent POM site information in trunk, prior to refactoring
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@627 04253f4f-3451-0410-a141-5562f1e59037
2012-11-03 11:56:30 +00:00
mindthegab
9ff7d19278 Final switch fix
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@626 04253f4f-3451-0410-a141-5562f1e59037
2012-11-03 09:40:26 +00:00
mindthegab
58d01898bd Experimental / trunk switch: final folder fixes
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@625 04253f4f-3451-0410-a141-5562f1e59037
2012-11-03 09:38:59 +00:00
mindthegab
d36f8c00a3 Experimental / trunk switch - Part 3 - Copying of experimental branch to trunk
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@624 04253f4f-3451-0410-a141-5562f1e59037
2012-11-03 09:37:52 +00:00
mindthegab
adf8bd6392 Experimental / trunk switch - Part 2 - Removal of current trunk (already backed up in branches/maven-alfresco-lifecycle-3x
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@623 04253f4f-3451-0410-a141-5562f1e59037
2012-11-03 09:35:23 +00:00
mindthegab
b299709cc3 -- fixed svn:ignore
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@607 04253f4f-3451-0410-a141-5562f1e59037
2012-11-01 21:54:59 +00:00
rgauss
1fbfe5501c Fixed mFileMappingProperties javadoc
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@498 04253f4f-3451-0410-a141-5562f1e59037
2012-09-18 12:20:05 +00:00
rgauss
1c0056e6b2 Added support for existing file-mapping.properties and ability to specify location through mFileMappingProperties configuration
Update issue 5
Update issue 39
Update issue 53


git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@497 04253f4f-3451-0410-a141-5562f1e59037
2012-09-18 12:09:05 +00:00
billerby
ac87c8ef7a Fixed repository references in archetypes
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@495 04253f4f-3451-0410-a141-5562f1e59037
2012-08-29 12:37:04 +00:00
mindthegab
16226ee5ab fixed repositories references for distribution
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@494 04253f4f-3451-0410-a141-5562f1e59037
2012-08-17 20:11:05 +00:00
mindthegab
39086a6eb8 fixed repositories references
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@493 04253f4f-3451-0410-a141-5562f1e59037
2012-08-17 19:18:27 +00:00
jottley
e76e42865a Issue 97 http://code.google.com/p/maven-alfresco-archetypes/issues/detail?id=97.
Rename variables and methods to use mapping instead of mappings.  Rename file-mappings.properties string to file-mapping.properties.

git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@492 04253f4f-3451-0410-a141-5562f1e59037
2012-08-17 17:21:10 +00:00
maoo
cccc2201e0 prevent NPE, which occured when the AMP finalName was not complying with ${artifactId}-${version} structure
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@426 04253f4f-3451-0410-a141-5562f1e59037
2012-04-14 21:18:02 +00:00
skuro
824f744f84 Use a released version of the nosnapshot plugin
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@420 04253f4f-3451-0410-a141-5562f1e59037
2012-04-07 14:48:38 +00:00
skuro
c7edadab00 Typo in Alfresco logo image for the generated site
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@419 04253f4f-3451-0410-a141-5562f1e59037
2012-04-07 14:32:13 +00:00
mindthegab
f83762b8ef [maven-release-plugin] prepare for next development iteration
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@412 04253f4f-3451-0410-a141-5562f1e59037
2012-04-07 00:55:48 +00:00
mindthegab
4d9aa57708 [maven-release-plugin] prepare release maven-alfresco-lifecycle-3.9.1
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@410 04253f4f-3451-0410-a141-5562f1e59037
2012-04-07 00:55:26 +00:00
mindthegab
b810606967 fixed surefire generation
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@409 04253f4f-3451-0410-a141-5562f1e59037
2012-04-07 00:54:25 +00:00
mindthegab
5d7045d675 [maven-release-plugin] prepare for next development iteration
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@407 04253f4f-3451-0410-a141-5562f1e59037
2012-04-07 00:50:09 +00:00
mindthegab
0ab8d2d046 [maven-release-plugin] prepare release maven-alfresco-lifecycle-3.9.1
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@405 04253f4f-3451-0410-a141-5562f1e59037
2012-04-07 00:49:46 +00:00
mindthegab
dda0ecf97b -- removed further references to Sourcesense
-- ready for 3.9.1 release

git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@403 04253f4f-3451-0410-a141-5562f1e59037
2012-04-07 00:47:29 +00:00
mindthegab
c42a8e2039 [maven-release-plugin] prepare for next development iteration
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@399 04253f4f-3451-0410-a141-5562f1e59037
2012-04-06 19:31:21 +00:00
mindthegab
4daa8d48cb [maven-release-plugin] prepare release maven-alfresco-lifecycle-3.9.1
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@397 04253f4f-3451-0410-a141-5562f1e59037
2012-04-06 19:30:53 +00:00
mindthegab
ec7309087a updated svn:ignore
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@396 04253f4f-3451-0410-a141-5562f1e59037
2012-04-06 19:27:01 +00:00
mindthegab
38949c3728 updated svn:ignore
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@395 04253f4f-3451-0410-a141-5562f1e59037
2012-04-06 19:24:07 +00:00
mindthegab
3c4adab096 updated svn:ignore
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@394 04253f4f-3451-0410-a141-5562f1e59037
2012-04-06 19:22:49 +00:00
mindthegab
9dd860762c updated svn:ignore
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@393 04253f4f-3451-0410-a141-5562f1e59037
2012-04-06 19:21:41 +00:00
mindthegab
53014b9d78 removed site-deploy from standard release
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@392 04253f4f-3451-0410-a141-5562f1e59037
2012-04-06 19:14:47 +00:00
mindthegab
2c205788b4 -- updated changes per release 3.9.1 (to produce detailed release notes)
-- updated developers info

git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@391 04253f4f-3451-0410-a141-5562f1e59037
2012-04-06 19:13:14 +00:00
mindthegab
691a98030d -- fixing issue #19
-- applied patch provided at http://code.google.com/p/maven-alfresco-archetypes/issues/detail?id=19#c3 
 -- now src/main/resources/META-INF is only added to the JAR and not to the /config 
 -- only (non problematic) side effect is that a META-INF (maven default manifest.mf is generated at the root of the amp, but not in /config so does not get applied)

git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@390 04253f4f-3451-0410-a141-5562f1e59037
2012-04-06 17:54:42 +00:00
mindthegab
d6e8c57e45 -- completing fix for com.sourcesense renaming
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@389 04253f4f-3451-0410-a141-5562f1e59037
2012-04-06 17:52:46 +00:00
mindthegab
868f7a9c2e -- fixed version of amp plugin
-- referenced maven-amp-plugin 3.0.4-SNAPSHOT from all archetypes

git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@388 04253f4f-3451-0410-a141-5562f1e59037
2012-04-06 14:51:18 +00:00
mindthegab
2d13720b4f -- fixing issue #9, removing FTL filtering by default in any archetype
-- added inline POM doc to allow more selective filtering

git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@387 04253f4f-3451-0410-a141-5562f1e59037
2012-04-06 11:06:11 +00:00
mindthegab
120b53067a -- removed unused com folder
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@386 04253f4f-3451-0410-a141-5562f1e59037
2012-04-06 10:38:06 +00:00
mindthegab
7afe3e309c -- aligned package names / group Id to org.alfresco
-- removed com.sourcesense packages, since sourcesense has nothing to do with this project since at couple of years
-- requires testing...mao? :)

git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@385 04253f4f-3451-0410-a141-5562f1e59037
2012-04-06 10:34:05 +00:00
maoo
27fb75b1e1 Fixed Issue #73 - Tested with version 4.0.b; changed alfresco-global.properties to use pom.xml db.* params
Upgraded h2 support to 1.2

git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@384 04253f4f-3451-0410-a141-5562f1e59037
2012-04-06 10:05:44 +00:00
maoo
5ea00ed680 Fixed Issue #55
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@382 04253f4f-3451-0410-a141-5562f1e59037
2012-04-06 09:35:43 +00:00
maoo
353af25303 fixed links to new Maven Alfresco Repository
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@381 04253f4f-3451-0410-a141-5562f1e59037
2012-04-06 09:33:43 +00:00
maoo
0f40dfbf81 fixed issue #63, setup Eclipse IDE by using org.eclipse.m2e.lifecycle-mapping Plugin
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@379 04253f4f-3451-0410-a141-5562f1e59037
2012-04-04 17:11:02 +00:00
maoo
b74ac65a6a reopening Issue #43 - requiredProperties is not working as expected, it does not respect default value. Reverting changes to archetype-metadata.xml, use property <alfresco.edition> in each pom.xml
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@378 04253f4f-3451-0410-a141-5562f1e59037
2012-04-04 16:56:48 +00:00
maoo
1d8f9bf3c0 Update maven-amp-plugin from 3.0.1 to 3.0.2 across the whole project
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@377 04253f4f-3451-0410-a141-5562f1e59037
2012-04-04 13:59:48 +00:00
maoo
c558192e84 Issue #72 - improve JDBC connection with H2 database by setting some connection parameters
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@376 04253f4f-3451-0410-a141-5562f1e59037
2012-04-04 12:47:07 +00:00
maoo
6cf79d5104 Issue #43 - Added alfresco.edition property on every root pom; default value of this property is to set as Archetype required property called "alfresco-default-edition", which - by default - is set to "community". To override, set -Dalfresco-default-edition=myedition when invoking archetype:generate
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@375 04253f4f-3451-0410-a141-5562f1e59037
2012-04-04 08:43:35 +00:00
maoo
9bf1894d85 Issue #64 - Committed alfresco-core as provided dependency since it provides support for important objects that are often accessed during customizations
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@374 04253f4f-3451-0410-a141-5562f1e59037
2012-04-04 08:01:23 +00:00
maoo
f4e6dc30cd Issue #68 - Replaced ${artifactId} instances of the pom.xml archetype template of maven-alfresco-amp-archetype (which are replaced by the artifactId during archetype creation) with ${project.artifactId}, which is preserved and can be read and used by the archetype end user
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@373 04253f4f-3451-0410-a141-5562f1e59037
2012-04-04 07:37:09 +00:00
maoo
db4b7448bd Issue #36 - Reproduced issue with 3.9.0 version of alfresco share archetype; added ${project.basedir} on every Maven <filter> occurrency, also within alfresco-extension and alfresco-amp projects
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@370 04253f4f-3451-0410-a141-5562f1e59037
2012-04-03 17:00:11 +00:00
maoo
8e21884722 Issue #23 - reproduced issue with Maven AMP Plugin 3.0.1 and 3.0.2 . Applied patch attached to issue and retested.
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@369 04253f4f-3451-0410-a141-5562f1e59037
2012-04-03 16:26:35 +00:00
maoo
d98fd5728c fixing version number on <parent> tag of amp and nosnapshot plugin poms. mvn install was failing
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@368 04253f4f-3451-0410-a141-5562f1e59037
2012-04-03 15:36:42 +00:00
maoo
3fb674f33a issue #71 - a simple '@' char misplaced within an XML comment was causing unexpected (and silent) behaviors of maven-resources-plugin filtering processes. Replaced it with '[at]'. Tested with Maven 3.0.3, but could not reproduce issue with Maven 2.2.1
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@366 04253f4f-3451-0410-a141-5562f1e59037
2012-04-02 12:26:32 +00:00
skuro
a88707b52c Upgrade to the new h2-support group id
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@365 04253f4f-3451-0410-a141-5562f1e59037
2012-03-06 23:20:51 +00:00
mindthegab
27748d1c90 [maven-release-plugin] prepare for next development iteration
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@364 04253f4f-3451-0410-a141-5562f1e59037
2011-10-26 14:42:08 +00:00
mindthegab
fdf5d67008 [maven-release-plugin] prepare release maven-alfresco-lifecycle-3.9.0
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@362 04253f4f-3451-0410-a141-5562f1e59037
2011-10-26 14:41:13 +00:00
mindthegab
8601761e9a simplified release
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@361 04253f4f-3451-0410-a141-5562f1e59037
2011-10-26 14:40:05 +00:00
mindthegab
143defaf9b [maven-release-plugin] rollback the release of maven-alfresco-lifecycle-3.9.0
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@359 04253f4f-3451-0410-a141-5562f1e59037
2011-10-26 14:38:37 +00:00
mindthegab
afde9bdc09 [maven-release-plugin] prepare for next development iteration
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@358 04253f4f-3451-0410-a141-5562f1e59037
2011-10-26 14:20:56 +00:00
mindthegab
2b2e03a79c [maven-release-plugin] prepare release maven-alfresco-lifecycle-3.9.0
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@356 04253f4f-3451-0410-a141-5562f1e59037
2011-10-26 14:19:58 +00:00
mindthegab
0299ba9fc5 added change details
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@355 04253f4f-3451-0410-a141-5562f1e59037
2011-10-26 14:18:56 +00:00
mindthegab
e1f141fb43 [maven-release-plugin] rollback the release of maven-alfresco-lifecycle-3.9.0
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@353 04253f4f-3451-0410-a141-5562f1e59037
2011-10-26 14:16:51 +00:00
mindthegab
10722715c8 [maven-release-plugin] prepare for next development iteration
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@352 04253f4f-3451-0410-a141-5562f1e59037
2011-10-26 14:07:44 +00:00
mindthegab
9c75d59887 [maven-release-plugin] prepare release maven-alfresco-lifecycle-3.9.0
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@349 04253f4f-3451-0410-a141-5562f1e59037
2011-10-26 14:03:26 +00:00
mindthegab
b84a42cadb [maven-release-plugin] rollback the release of maven-alfresco-lifecycle-3.9.0
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@347 04253f4f-3451-0410-a141-5562f1e59037
2011-10-26 12:16:01 +00:00
mindthegab
0fdda216da [maven-release-plugin] prepare for next development iteration
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@346 04253f4f-3451-0410-a141-5562f1e59037
2011-10-26 09:18:34 +00:00
mindthegab
74051f916f [maven-release-plugin] prepare release maven-alfresco-lifecycle-3.9.0
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@344 04253f4f-3451-0410-a141-5562f1e59037
2011-10-26 09:18:19 +00:00
mindthegab
51df6fc3aa fixed parents
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@343 04253f4f-3451-0410-a141-5562f1e59037
2011-10-26 09:17:06 +00:00
mindthegab
a2bf44c33e -- tested against alfresco community 4.0b
-- updated references to CE / EE repos
-- reverted default to mysql since H2 does not work
-- updated lifecycle / archetypes version number to 3.9.0-SNAPSHOT (pre-release for 4.0 release), targeting to align to alfresco version numbering
-- preparing for 3.9.0 release

git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@342 04253f4f-3451-0410-a141-5562f1e59037
2011-10-26 09:12:32 +00:00
skuro
498803c05d Configuration for remotes now goes into share-config-custom.xml
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@341 04253f4f-3451-0410-a141-5562f1e59037
2011-09-29 10:31:15 +00:00
pmonks
2ee4244cb0 Fixed issue #5 - added a hardcoded file-mappings.properties that allows overriding resources in /WEB-INF/ (which is not recommended, but may be necessary in some cases).
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@338 04253f4f-3451-0410-a141-5562f1e59037
2011-08-31 18:34:04 +00:00
mindthegab
c6c2f0cf39 -- Fixed issue http://code.google.com/p/maven-alfresco-archetypes/issues/detail?id=60
-- Now maven-amp-plugin works fine with Maven 3.0.3, added prerequisite

git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@336 04253f4f-3451-0410-a141-5562f1e59037
2011-08-31 15:13:58 +00:00
mindthegab
c619d89421 updated svn:ignores
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@334 04253f4f-3451-0410-a141-5562f1e59037
2011-08-05 17:14:39 +00:00
mindthegab
64d5f113ab Finishing committing fix for Issue 49
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@333 04253f4f-3451-0410-a141-5562f1e59037
2011-08-05 12:16:09 +00:00
skuro
9e30f49e8d POM cleanup, updated to latest available artifacts versions, removed obsolete stuff, life, universe and everything. Changed an exact multiple of 42 characters.
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@332 04253f4f-3451-0410-a141-5562f1e59037
2011-08-05 07:42:29 +00:00
skuro
ea49f96271 Removed obsolete stuff
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@331 04253f4f-3451-0410-a141-5562f1e59037
2011-08-04 17:00:45 +00:00
skuro
bf5cb084eb Same as #47
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@330 04253f4f-3451-0410-a141-5562f1e59037
2011-08-04 16:58:21 +00:00
skuro
2b8511aea0 same as issue #49
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@329 04253f4f-3451-0410-a141-5562f1e59037
2011-08-04 16:56:49 +00:00
skuro
929bdaeb9d similar issue to #47
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@328 04253f4f-3451-0410-a141-5562f1e59037
2011-08-04 16:54:59 +00:00
skuro
39aa93fb61 #37 alfresco-global.properties instead of the old application.propertie
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@327 04253f4f-3451-0410-a141-5562f1e59037
2011-08-04 16:52:08 +00:00
skuro
dd61aa7921 #55 add h2 support (plus some cleanup)
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@326 04253f4f-3451-0410-a141-5562f1e59037
2011-08-04 16:05:32 +00:00
skuro
8dfffcd21a #47 removed archetype.xml, added jetty configuration
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@325 04253f4f-3451-0410-a141-5562f1e59037
2011-08-04 16:03:26 +00:00
skuro
61978e48b2 #37 application.properties and old Spring contextes now obsoleted by alfresco-global.properties
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@324 04253f4f-3451-0410-a141-5562f1e59037
2011-08-04 16:00:11 +00:00
skuro
6792f9e4da Purged empty/obsolete stuff
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@323 04253f4f-3451-0410-a141-5562f1e59037
2011-08-04 15:57:10 +00:00
skuro
02b56818e0 Purged Eclipse config files
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@322 04253f4f-3451-0410-a141-5562f1e59037
2011-08-04 15:52:50 +00:00
mindthegab
f89484d869 REALLY applying patch as per issue 47, previous commit is for issue 49 :)
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@314 04253f4f-3451-0410-a141-5562f1e59037
2011-08-04 00:10:08 +00:00
mindthegab
1622dd961a applying patch as per issue 47
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@313 04253f4f-3451-0410-a141-5562f1e59037
2011-08-04 00:09:19 +00:00
mindthegab
786d03d99d applying patch for issue 52, as per http://jira.codehaus.org/browse/MNG-4609
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@312 04253f4f-3451-0410-a141-5562f1e59037
2011-08-03 23:53:21 +00:00
skuro
3e7236abf9 Buildnumber version bumped to v1.0, now with Git support
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@308 04253f4f-3451-0410-a141-5562f1e59037
2011-07-18 12:25:44 +00:00
dupont.nicolas
23fcfbf4fb Init of maven-amp-plugin-test
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@307 04253f4f-3451-0410-a141-5562f1e59037
2010-10-05 18:28:29 +00:00
dupont.nicolas
64ff61f4e0 Initial import of maven-amp-plugin-test
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@306 04253f4f-3451-0410-a141-5562f1e59037
2010-10-05 18:27:18 +00:00
billerby
56544a7e10 As proposed by glaurung.aubrane removing the deprecated use of pom.* in favour of project.* issue #48
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@300 04253f4f-3451-0410-a141-5562f1e59037
2010-03-03 19:17:30 +00:00
billerby
2e44c84689 Missed one ${groupId} on issue #26 this now solves issue #48, thanks to glaurung.aubrane for spotting it so fast.
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@299 04253f4f-3451-0410-a141-5562f1e59037
2010-03-03 19:01:19 +00:00
billerby
82d38f6a42 Change the way moduleId is generated, from ${groupId}.${artifactId} to just ${artifactId}. The former way caused problems when loading classpath resources.
This solves issues 26 and 42.

git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@298 04253f4f-3451-0410-a141-5562f1e59037
2010-03-01 14:20:54 +00:00
mindthegab
33f83f9c21 -- added target to svn:ignore
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@295 04253f4f-3451-0410-a141-5562f1e59037
2010-02-23 18:12:38 +00:00
mindthegab
b276eddbb8 -- added maven-alfresco-share-module-archetype to build share JAR extensions as in http://mindthegab.com/2010/02/23/howto-build-your-jar-alfresco-share-dashlet-with-maven-in-3-minutes/
-- fixed minor issues in maven-alfresco-share-archetype
-- merged other fixes

git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@294 04253f4f-3451-0410-a141-5562f1e59037
2010-02-23 18:02:23 +00:00
tibber
cf97d54902 project.basedir reference typo fixed
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@288 04253f4f-3451-0410-a141-5562f1e59037
2009-12-14 13:54:17 +00:00
skuro
2c5cdc1b47 Issue#25: due to a bug in the latest maven eclipse plugin, the use of version 2.6 was enforced. See http://jira.codehaus.org/browse/MECLIPSE-576
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@287 04253f4f-3451-0410-a141-5562f1e59037
2009-12-11 09:57:50 +00:00
skuro
29c5a4f994 Issue#35: fixed maven repo URL
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@286 04253f4f-3451-0410-a141-5562f1e59037
2009-12-09 13:52:39 +00:00
tibber
97c6ba59ff Remove SNAPSHOT versions form pom.xml files. This closes issue #22
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@285 04253f4f-3451-0410-a141-5562f1e59037
2009-12-07 11:43:36 +00:00
mindthegab
3d70b7166d -- fixed broken filtering
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@281 04253f4f-3451-0410-a141-5562f1e59037
2009-12-04 10:51:40 +00:00
mindthegab
6b99082954 fixing the released packages
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@279 04253f4f-3451-0410-a141-5562f1e59037
2009-12-04 10:00:52 +00:00
mindthegab
55c749b299 [maven-release-plugin] prepare for next development iteration
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@278 04253f4f-3451-0410-a141-5562f1e59037
2009-12-03 21:45:22 +00:00
mindthegab
deb9fd16e6 [maven-release-plugin] prepare release maven-alfresco-lifecycle-1.1.0
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@276 04253f4f-3451-0410-a141-5562f1e59037
2009-12-03 21:44:55 +00:00
mindthegab
c285c4207c releasing share archetype
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@275 04253f4f-3451-0410-a141-5562f1e59037
2009-12-03 21:43:33 +00:00
mindthegab
aa68a4a621 [maven-release-plugin] rollback the release of maven-alfresco-lifecycle-1.1.0
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@273 04253f4f-3451-0410-a141-5562f1e59037
2009-12-03 21:41:17 +00:00
mindthegab
0d31e3ac32 [maven-release-plugin] prepare for next development iteration
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@272 04253f4f-3451-0410-a141-5562f1e59037
2009-12-03 21:34:35 +00:00
mindthegab
662d923e53 [maven-release-plugin] prepare release maven-alfresco-lifecycle-1.1.0
git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@270 04253f4f-3451-0410-a141-5562f1e59037
2009-12-03 21:34:09 +00:00
304 changed files with 9582 additions and 21676 deletions

252
DOCS.txt Normal file
View File

@@ -0,0 +1,252 @@
This document needs updating...
**********************************
Disclaimer for maven-alfresco list
**********************************
This codebase is currently work in progress; the effort have been split in three directions:
a) The definition of 2 POM files that can handle versions and common build behaviors/features
b) The writing of an alfresco-maven-plugin to enable amp-to-war overlay provided by Alfresco
Repository built-in features (ModuleManagementTool) and replace the maven-amp-plugin (big
rewriting of the maven-war-plugin)
c) The definition of (initially 2) archetypes that show some simple project's configuration using
the parent POMs
Most of the build features have been successfully ported to a new structure, whose main advantage is
to keep pom.xml files extremely simple and readable (since a lot of logic have been moved to the parent).
Inherited behaviours are configurable simply defining specific properties in the project's or module's pom.xml
(see documentation below).
Here follows a list of build features that have not been ported yet:
- Maven SCM and release
- JBoss run
- Tomcat remote deployment
- Jetty Java source and resources reloading (Jetty currently runs .war files)
- Maven Site generation
- Maven reporting
- Maven distributionManagement
Apart from SCM and release, all the mentioned features are probably best suited for a more enterprise archetype,
using the Alfresco Web Integration POM as parent and adding more build features around Maven, Tomcat and JBoss.
******************
Alfresco Maven SDK
******************
The Maven SDK is an effort that have been developing in the last 5 years - mostly driven by community efforts on
Google Code (http://code.google.com/p/maven-alfresco-archetypes) - which delivers archetypes for building Alfresco
integration project with Maven; builds are based on artifacts that are deployed into maven.alfresco.com Repository
manually as a community effort.
The main advantages with the (currently official) Alfresco SDK follows:
- IDE-independent SDK, use IntelliJ, eMacs or any other IDE sto write your code
- No IDE manual configuration, all build-related features are provided by Apache Maven, which is the only
prerequisite to use this SDK
- Language independent, you don't like Maven? You can still use Ant, Ivy, Buildr, Gradle, Leiningen or any other build
system that is compatible with Maven artifact resolution mechanism; just configure maven.alfresco.com as (one of) your
Maven repositories and you're ready to go
- Javadoc and Sources support, provided by maven.alfresco.com related Maven artifacts; you don't need to manually
configure your IDE to attach (manually downloaded) sources to your (manually downloaded) binaries.
- Clean and readable, the build logic related with OOTB Alfresco features is wrapped in 50 lines of pom.xml
- Advanced build functionality, inherited by your parent POMs you can use embedded databases and j2ee
containers with (almost) no configuration at all, among other features exposed below.
- One mvn command to generate, one mvn command to run, this is all you need to do to have a local Alfresco running
on an empty laptop
- Supports community and enterprise flawlessly, allowing to switch one to another very easily
The following documentation aims to provide three different levels of complexity to tackle an Alfresco integration
project: simple, advanced and custom; the latter exposes in details the Maven Alfresco SDK features.
*************
Prerequisites
*************
The main and only prerequisite to follow reading this document is to have Apache Maven 3.0.3 (or higher) installed
on your machine; there is no preferred IDE nor web container and database requirements needed.
It is strongly advised to use the Apache Maven official binary distributions downloaded from maven.apache.org; avoid
OS-specific distributions as much as possible.
************
Use - Simple
************
If you're new to Alfresco, you probably want to know which is the impact of introducing such a technology within your
development team, run it locally, assess all development processes involved with the product and which
technologies/tools are best suited for those.
You can currently choose between two different flavors, depending on your final goal:
* If you want to assess efforts involved with AMP development, you can run the following commands:
1.
mvn archetype:generate \
-DarchetypeGroupId=org.alfresco.maven \
-DarchetypeArtifactId=quickstart-amp-archetype \
-DarchetypeVersion=1.0 \
-DgroupId=com.someco \
-DartifactId=alfresco-amp-quickstart \
-Dversion=1.0-SNAPSHOT \
-DarchetypeRepository=http://maven.alfresco.com/nexus/content/repositories/releases \
-DinteractiveMode=false
You can always switch Alfresco versions/editions by editing the <parent> coordinates of your generated pom.xml
2.
cd alfresco-amp-quickstart && MAVEN_OPTS="-Xms256m -Xmx1G -XX:PermSize=300m" mvn package -Drunamp
Browse to http://localhost:8080/amp-quickstart and you will find Alfresco Explorer Client running against a local
Alfresco Repository sitting on top of an H2 embedded database and loading your AMP package.
* If you want to customise Alfresco Explorer and/or Share clients, embed AMP packages/projects or simply run both
Alfresco Explorer and Share on the same machine, run the following commands:
1.
mvn archetype:generate \
-DarchetypeGroupId=org.alfresco.maven \
-DarchetypeArtifactId=quickstart-allinone-archetype \
-DarchetypeVersion=1.0 \
-DgroupId=com.someco \
-DartifactId=alfresco-allinone-quickstart \
-Dversion=1.0-SNAPSHOT \
-Dedition=community \
-DarchetypeRepository=http://maven.alfresco.com/nexus/content/repositories/releases \
-DinteractiveMode=false
2.
cd alfresco-allinone-quickstart && MAVEN_OPTS="-Xms256m -Xmx1G -XX:PermSize=300m" mvn package -Drun
Compared with the previous flavor, alfresco-allinone-quickstart is a Maven multi-module project, which also includes
an AMP project that gets 'overlaid' into both Alfresco and Share web applications.
Alfresco Explorer is available at http://localhost:8080/alfresco whereas Alfresco Share is available at
http://localhost:8080/share
************
Use - Custom
************
When the build logic becomes tough, integrating with third party technologies, introducing complex build scenarios,
you might want to have a lower integration level with Alfresco SDK; there are basically 2 big integration points
you can rely on, which are basically Alfresco-maintained POM files that provide:
- A list of Alfresco artifacts, including binaries, javadoc and sources, Maven plugins successfully tested against
the standard and supported build process; artifacts come with correct platform versions and editions
(community vs enterprise) according with the <groupId> and <version> tags parent coordinates.
You can simply define the following parent POM in your project's pom.xml:
<parent>
<groupId>org.alfresco.enterprise</groupId>
<artifactId>alfresco-platform-parent</artifactId>
<version>4.0.1</version>
</parent>
In Maven geek terms, this parent POM will define <dependencyManagement>, <pluginManagement> and <properties> elements
related with Alfresco-produced artifacts.
The main goal of this approach is to give you full access to Alfresco artifacts without needing to handle dependency
and plugin management inside your pom.xml.
Please note that Alfresco artifacts are not shipped with POM files at the moment, therefore transitive dependencies
are not handled; you will need to define them explicitly in your pom.xml (using <scope>provided</scope>
- A set of useful build features around Alfresco web integrations, which are also inherited by alfresco-platform-parent;
if you want to use it directly and skip alfresco-platform-parent, you can define:
<parent>
<groupId>org.alfresco.enterprise</groupId>
<artifactId>alfresco-developer-parent</artifactId>
<version>1</version>
</parent>
In this case you will have to re-define a list of properties to set your dependency versions:
<alfresco.version>4.0.1</alfresco.version>
<spring.version>3.0.5.RELEASE</spring.version>
<h2.version>1.3.158</h2.version>
<h2-support.version>1.2</h2-support.version>
<servlet.api.version>2.5</servlet.api.version>
<faces.version>1.1_02</faces.version>
<digester.version>1.6</digester.version>
<log4j.version>1.2.15</log4j.version>
Besides the alfresco-integration-parent items inherited, this parent POM provides 3 commonly used features that can
be easily enabled/disabled/configured:
* AMP overlay into an Alfresco (or Share) Extension
---
Activation: built-in
---
When your project (or sub-module) is a <packaging>war</packaging>, you can automatically include one or more
AMP files by defining the dependencies into the pom.xml, as follows:
<dependency>
<groupId>com.mycompany</groupId>
<artifactId>amp-module</artifactId>
<version>1.0-SNAPSHOT</version>
<type>amp</type>
</dependency>
The AMP files will be overlayed on top of your current WAR customizations, therefore
they can override the content of the original WAR.
-- oOo --
* Multi-environment property filtering
---
Activation: exists src/main/properties
---
You can enable multi-environment property filtering by simply creating the
src/main/properties/${env}/${webapp.resource.filter} file with your property values;
all files included in src/main/resources and src/main/properties will be filtered
with your properties defined; in order to switch between environments,
simply attach -Denv=yourenv to your mvn commands.
---
Properties
---
<env>local</env>
<webapp.resource.filter>alfresco-global.properties</webapp.resource.filter>
<webapp.resource.build.folder>${project.build.outputDirectory}</webapp.resource.build.folder>
<webapp.name>${project.artifactId}</webapp.name>
-- oOo --
* Jetty H2 configuration
---
Activation: exists jetty/jetty.xml
---
You can enable Jetty to run your application(s); by default Jetty will run all contexts
using jetty/jetty.xml as Jetty Server configuration, allowing to add the jndi resource
needed to start Alfresco Repository webapp; if you want to run multiple webapps - for
example share and alfresco - follow the example listed below:
<plugin>
<groupId>org.mortbay.jetty</groupId>
<artifactId>maven-jetty-plugin</artifactId>
<executions>
<execution>
<id>run</id>
<goals><goal>run</goal></goals>
<phase>package</phase>
<configuration>
<contextPath>/</contextPath>
<webAppSourceDirectory>.</webAppSourceDirectory>
<webXml>jetty/root-web.xml</webXml>
<contextHandlers>
<contextHandler implementation="org.mortbay.jetty.webapp.WebAppContext">
<war>${project.basedir}/../alfresco/target/alfresco.war</war>
<contextPath>/alfresco</contextPath>
</contextHandler>
<contextHandler implementation="org.mortbay.jetty.webapp.WebAppContext">
<war>${project.basedir}/../share/target/share.war</war>
<contextPath>/share</contextPath>
</contextHandler>
</contextHandlers>
</configuration>
</execution>
</executions>
</plugin>

199
README.txt Normal file
View File

@@ -0,0 +1,199 @@
This document needs updating...
Archetypes using the SDK can be generated with:
mvn archetype:generate -DarchetypeCatalog=https://artifacts.alfresco.com/nexus/content/groups/public-snapshots/archetype-catalog.xml
**********
Disclaimer
**********
This codebase is currently work in progress; the effort have been split in three directions:
a) The definition of 2 POM files that can handle versions and common build behaviors/features
b) The writing of an alfresco-maven-plugin to enable amp-to-war overlay provided by Alfresco
Repository built-in features (ModuleManagementTool) and replace the maven-amp-plugin (big
rewriting of the maven-war-plugin)
c) The definition of (initially 2) archetypes that show some simple project's configuration using
the parent POMs
Most of the build features have been successfully ported to a new structure, whose main advantage is
to keep pom.xml files extremely simple and readable (since a lot of logic have been moved to the parent).
Inherited behaviours are configurable simply defining specific properties in the project's or module's pom.xml
(see documentation below).
Here follows a list of build features that have not been ported yet:
- Maven SCM and release
- JBoss run
- Tomcat remote deployment
- Jetty Java source and resources reloading (Jetty currently runs .war files)
- Maven Site generation
- Maven reporting
- Maven distributionManagement
Apart from SCM and release, all the mentioned features are probably best suited for a more enterprise archetype,
using the Alfresco Web Integration POM as parent and adding more build features around Maven, Tomcat and JBoss.
Regarding the POM files, I'd like to see them deployed on maven.alfresco.com, hopefully generated (by the
Alfresco build?) and tested for each Alfresco release.
--- oOo ---
*************
Prerequisites
*************
- Maven 3.0.3 (official binary distribution from maven.apache.org)
--- oOo ---
*************
Build and Run
*************
-----
Build
-----
All the steps that follow are necessary because neither POMs nor
alfresco-maven-plugin are yet available on maven.alfresco.com; as soon
as their implementation is consolidated, you will be able to skip
this first part and just enjoy the second.
---
mvn clean install
(with empty repository, Maven will download 365Mb)
---
---
Run
---
cd archetypes/quickstart-allinone-archetype
MAVEN_OPTS="-Xms256m -Xmx1G -XX:PermSize=300m" mvn clean package -Drun
-> http://localhost:8080/alfresco and http://localhost:8080/share
--- OR
cd archetypes/quickstart-amp-archetype
MAVEN_OPTS="-Xms256m -Xmx1G -XX:PermSize=300m" mvn clean package -Drun-amp
-> http://localhost:8080/quickstart-amp-archetype
---
--- oOo ---
**********
Archetypes
**********
---------------------------
ALFRESCO ALLINONE ARCHETYPE
---------------------------
- run mvn clean install to package all apps
- run mvn clean install -Prun to run the full platform embedded in Jetty/H2
---
---
ALFRESCO AMP ARCHETYPE
---
---
--- oOo ---
*********
POM files
*********
-------------------------------
ALFRESCO PLATFORM POM
-------------------------------
* Describes the Alfresco platform. Lives in the Alfresco SVN and gets deployed at every release.
* DependencyManagement for all Alfresco commonly used JAR/WAR/AMP artifacts
* IInherits alfresco-developer-parent POM
---
ALFRESCO DEVELOPER PARENT POM
---
* Alfresco Repository Log and storage cleaning
---
Activation: built-in
---
When mvn clean is invoked, all files produced by Maven runs must be removed; this is the list of
filesets inherited from alfresco-developer-parent:
* target/ (default behaviour)
* *.log
* ${alfresco.data.location}
---
Properties
---
<alfresco.data.location>alf_data_dev</alfresco.data.location>
---
---
* AMP overlay into an Alfresco (or Share) Extension
---
Activation: built-in
---
When your project (or sub-module) is a <packaging>war</packaging>, you can automatically include one or more
AMP files by defining the dependencies into the pom.xml, as follows:
<dependency>
<groupId>com.mycompany</groupId>
<artifactId>amp-module</artifactId>
<version>1.0-SNAPSHOT</version>
<type>amp</type>
</dependency>
The AMP files will be overlayed on top of your current WAR customizations, therefore
they can override the content of the original WAR.
---
---
* Multi-environment property filtering
---
Activation: exists src/main/properties
---
You can enable multi-environment property filtering by simply creating the
src/main/properties/${env}/${webapp.resource.filter} file with your property values;
all files included in src/main/resources and src/main/properties will be filtered
with your properties defined; in order to switch between environments,
simply attach -Denv=yourenv to your mvn commands.
---
Properties
---
<env>local</env>
<webapp.resource.filter>alfresco-global.properties</webapp.resource.filter>
<webapp.resource.build.folder>${project.build.outputDirectory}</webapp.resource.build.folder>
<webapp.name>${project.artifactId}</webapp.name>
---
---
* Jetty H2 configuration
---
Activation: exists jetty/jetty.xml
---
You can enable Jetty to run your application(s); by default Jetty will run all contexts
using jetty/jetty.xml as Jetty Server configuration, allowing to add the jndi resource
needed to start Alfresco Repository webapp; if you want to run multiple webapps - for
example share and alfresco - follow the example listed below:
<plugin>
<groupId>org.mortbay.jetty</groupId>
<artifactId>maven-jetty-plugin</artifactId>
<executions>
<execution>
<id>run</id>
<goals><goal>run</goal></goals>
<phase>package</phase>
<configuration>
<contextPath>/</contextPath>
<webAppSourceDirectory>.</webAppSourceDirectory>
<webXml>jetty/root-web.xml</webXml>
<contextHandlers>
<contextHandler implementation="org.mortbay.jetty.webapp.WebAppContext">
<war>${project.basedir}/../alfresco/target/alfresco.war</war>
<contextPath>/alfresco</contextPath>
</contextHandler>
<contextHandler implementation="org.mortbay.jetty.webapp.WebAppContext">
<war>${project.basedir}/../share/target/share.war</war>
<contextPath>/share</contextPath>
</contextHandler>
</contextHandlers>
</configuration>
</execution>
</executions>
</plugin>
---

42
TODO.txt Normal file
View File

@@ -0,0 +1,42 @@
Short term (pre 4.x release):
-----------------------------
- Generate archetypes for sample projects
- Cleanup issues
- Release
- Testing against 1 Community and 1 Enterprise version
- Documentation, documentation, documentation
- Maven Site
- https://wiki.alfresco.com/index.php?title=Maven_Alfresco_SDK (from scratch)
- http://code.google.com/p/maven-alfresco-archetypes/
Mid term (post 4.x release):
----------------------------
- More archetypes
**************************************************
Enterprise Supported Archetypes (aka Advanced Use)
**************************************************
If you have built integration projects with Alfresco, you're familiar with Maven and you have a case study in mind,
wondering how to integrate it with your software development around the product, you can start from the Alfresco
Enterprise archetype suite:
1.
mvn archetype:generate \
-DarchetypeGroupId=org.alfresco.enterprise \
-DarchetypeArtifactId=supported-alfresco-archetype \
-DarchetypeVersion=1.0 \
-DgroupId=com.someco \
-DartifactId=alfresco-enterprise \
-Dversion=1.0-SNAPSHOT \
-DarchetypeRepository=http://maven.alfresco.com/nexus/content/repositories/releases \
-DinteractiveMode=false
2.
cd alfresco-enterprise && MAVEN_OPTS="-Xms256m -Xmx1G -XX:PermSize=300m" mvn package -Drun
Run the following command if you want to have a list of the available archetypes:
mvn archetype:generate \
-DarchetypeCatalog=http://maven.alfresco.com/nexus/content/repositories/releases/archetype-catalog.xml

View File

@@ -0,0 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>org.alfresco.maven.archetype</groupId>
<artifactId>alfresco-allinone-archetype</artifactId>
<packaging>maven-archetype</packaging>
<name>All-in-One Archetype from Maven Alfresco SDK</name>
<description>Sample multi-module project for All-in-One development on the Alfresco plaftorm. Includes modules for: Repository, AMP, Share, Solr, Web Quick Start and embedded Jetty run</description>
<parent>
<groupId>org.alfresco.maven</groupId>
<artifactId>alfresco-lifecycle-aggregator</artifactId>
<version>1.0</version>
<relativePath>../../pom.xml</relativePath>
</parent>
</project>

View File

@@ -0,0 +1,154 @@
<?xml version="1.0" encoding="UTF-8"?>
<archetype-descriptor xsi:schemaLocation="http://maven.apache.org/plugins/maven-archetype-plugin/archetype-descriptor/1.0.0 http://maven.apache.org/xsd/archetype-descriptor-1.0.0.xsd" name="quickstart-allinone-archetype"
xmlns="http://maven.apache.org/plugins/maven-archetype-plugin/archetype-descriptor/1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<requiredProperties>
<requiredProperty key="version">
<defaultValue>1.0-SNAPSHOT</defaultValue>
</requiredProperty>
<requiredProperty key="alfresco_target_groupId">
<defaultValue>org.alfresco</defaultValue>
</requiredProperty>
<requiredProperty key="alfresco_target_version">
<defaultValue>4.2.b</defaultValue>
</requiredProperty>
<requiredProperty key="package">
<defaultValue>(not used)</defaultValue>
</requiredProperty>
</requiredProperties>
<modules>
<module id="amp" dir="amp" name="amp">
<fileSets>
<fileSet filtered="false" packaged="false" encoding="UTF-8">
<directory>src/main/java</directory>
<includes>
<include>**/*.java</include>
</includes>
</fileSet>
<fileSet encoding="UTF-8" filtered="false">
<directory>src/main/amp</directory>
<includes>
<include>**</include>
</includes>
</fileSet>
<fileSet encoding="UTF-8" filtered="false">
<directory>src/test/resources</directory>
<includes>
<include>**</include>
</includes>
</fileSet>
<fileSet encoding="UTF-8" filtered="false">
<directory>src/test/properties</directory>
<includes>
<include>**/*.properties</include>
</includes>
</fileSet>
<fileSet encoding="UTF-8" filtered="false">
<directory>jetty</directory>
<includes>
<include>**</include>
</includes>
</fileSet>
</fileSets>
</module>
<module id="alfresco" dir="alfresco" name="alfresco">
<fileSets>
<fileSet encoding="UTF-8" filtered="false">
<directory>src/main/webapp</directory>
<includes>
<include>**</include>
</includes>
</fileSet>
<fileSet encoding="UTF-8" filtered="false">
<directory>src/main/properties</directory>
<includes>
<include>**/*.properties</include>
</includes>
</fileSet>
<fileSet encoding="UTF-8" filtered="false">
<directory>src/main/resources</directory>
<includes>
<include>**</include>
</includes>
</fileSet>
</fileSets>
</module>
<module id="solr" dir="solr" name="solr" filtered="false">
<fileSets>
<fileSet encoding="UTF-8">
<directory>src/main/solr-properties</directory>
<includes>
<include>**</include>
<include>**</include>
</includes>
</fileSet>
<fileSet encoding="UTF-8" filtered="false">
<directory>src/main/webapp</directory>
<includes>
<include>**</include>
</includes>
</fileSet>
<fileSet encoding="UTF-8" filtered="false">
<directory>src/main/resources</directory>
<includes>
<include>**</include>
</includes>
</fileSet>
</fileSets>
</module>
<module id="share" dir="share" name="share" filtered="false">
<fileSets>
<fileSet encoding="UTF-8">
<directory>src/main/webapp</directory>
<includes>
<include>**</include>
</includes>
</fileSet>
<fileSet encoding="UTF-8">
<directory>src/main/properties</directory>
<includes>
<include>**/*.properties</include>
</includes>
</fileSet>
<fileSet encoding="UTF-8" filtered="false">
<directory>src/main/resources</directory>
<includes>
<include>**</include>
</includes>
</fileSet>
</fileSets>
</module>
<module id="wcmqs" dir="wcmqs" name="share" filtered="false">
<fileSets>
<fileSet encoding="UTF-8">
<directory>src/main/webapp</directory>
<includes>
<include>**</include>
</includes>
</fileSet>
<fileSet encoding="UTF-8" filtered="false">
<directory>src/main/resources</directory>
<includes>
<include>**</include>
</includes>
</fileSet>
<fileSet encoding="UTF-8" filtered="false">
<directory>src/main/webapp</directory>
<includes>
<include>**</include>
</includes>
</fileSet>
</fileSets>
</module>
<module id="runner" dir="runner" name="runner" filtered="false">
<fileSets>
<fileSet encoding="UTF-8">
<directory>jetty</directory>
<includes>
<include>**</include>
</includes>
</fileSet>
</fileSets>
</module>
</modules>
</archetype-descriptor>

View File

@@ -0,0 +1,87 @@
<?xml version="1.0" encoding="UTF-8"?>
<!-- Licensed to the Apache Software Foundation (ASF) under one or more contributor
license agreements. See the NOTICE file distributed with this work for additional
information regarding copyright ownership. The ASF licenses this file to
You under the Apache License, Version 2.0 (the "License"); you may not use
this file except in compliance with the License. You may obtain a copy of
the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required
by applicable law or agreed to in writing, software distributed under the
License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS
OF ANY KIND, either express or implied. See the License for the specific
language governing permissions and limitations under the License. -->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<artifactId>${artifactId}</artifactId>
<name>Alfresco Repository and Explorer Client</name>
<packaging>war</packaging>
<description>Alfresco Repository and Explorer Client</description>
<parent>
<groupId>${groupId}</groupId>
<artifactId>${rootArtifactId}</artifactId>
<version>${version}</version>
</parent>
<dependencies>
<dependency>
<groupId>${alfresco.groupId}</groupId>
<artifactId>alfresco</artifactId>
<type>war</type>
</dependency>
<!-- Demonstrating the dependency on the AMP developed in the 'amp' project -->
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>amp</artifactId>
<version>${project.version}</version>
<type>amp</type>
</dependency>
<!-- Demonstrating the usage of a well known GA AMP (Web Quick Start Repository component) -->
<dependency>
<groupId>${alfresco.groupId}</groupId>
<artifactId>alfresco-wcm-quickstart-repo</artifactId>
<version>${alfresco.version}</version>
<type>amp</type>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<artifactId>maven-war-plugin</artifactId>
<configuration>
<!-- Here is can control the order of overlay of your (WAR, AMP, etc.) dependencies
| NOTE: At least one WAR dependency must be uncompressed first
| NOTE: In order to have a dependency effectively added to the WAR you need to
| explicitly mention it in the overlay section.
| NOTE: First-win resource strategy is used by the WAR plugin
-->
<overlays>
<!-- Current project customizations -->
<overlay/>
<!-- The Alfresco WAR -->
<overlay>
<groupId>${alfresco.groupId}</groupId>
<artifactId>alfresco</artifactId>
<type>war</type>
<!-- To allow inclusion of META-INF -->
<excludes/>
</overlay>
<!-- Add / order your AMPs here -->
<overlay>
<groupId>${project.groupId}</groupId>
<artifactId>amp</artifactId>
<type>amp</type>
</overlay>
<overlay>
<groupId>${alfresco.groupId}</groupId>
<artifactId>alfresco-wcm-quickstart-repo</artifactId>
<type>amp</type>
</overlay>
</overlays>
</configuration>
</plugin>
</plugins>
</build>
</project>

View File

@@ -12,28 +12,41 @@
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# BUILD TIME PROPERTIES
# ---------------------
# NB: This group of properties is only used by ant for tomcat deployment, and may not be maintained.
# Appserver to deploy to (tomcat) - used only by ant ATM.
# Use $M2_HOME/conf/settings.xml (or ~/.m2/settings.xml) for maven2 appservers username/password
appserver.dir=/your/appserver/dir
appserver.host=localhost
appserver.manager.url=http://${appserver.host}:8080/manager
appserver.username=tomcat
appserver.password=tomcat
# RUN TIME PROPERTIES
# -------------------
# Sample custom content and index data location
# This will create alf_data Relative to appserver run folder
# In this default file we take the property from the POM (for compatbility with local jetty and jboss deployments) but it can also be edited here.
###############################
## Common Alfresco Properties #
###############################
dir.root=${alfresco.data.location}
# Allowed values are: NONE, AUTO, FULL
index.recovery.mode=NONE
index.recovery.mode=FULL
index.subsystem.name=solr
solr.host=localhost
solr.port=8080
solr.secureComms=none
# Setting Solr backup for the future. Tweak this if needed (ideally in other env properties files)
solr.backup.alfresco.cronExpression=0 30 2 * * ? 2050
solr.backup.archive.cronExpression=0 30 3 * * ? 2050
solr.backup.alfresco.remoteBackupLocation=${dir.root}/solrBackup/alfresco
solr.backup.archive.remoteBackupLocation=${dir.root}/solrBackup/archive
# We are in the local DEV properties file, no need for Solr backup
solr.backup.alfresco.numberToKeep=0
solr.backup.archive.numberToKeep=0
# These jobs seem to require Lucene (Unsupported Operation with Solr) so we disasble them / set to future date
# See https://forums.alfresco.com/en/viewtopic.php?f=52&t=41597
# If you want to enable them (and so full WQS functionality), please also set index.subsystem.name=lucene
wcmqs.dynamicCollectionProcessor.schedule=0 30 2 * * ? 2060
wcmqs.feedbackProcessor.schedule=0 40 2 * * ? 2060
wcmqs.publishQueueProcessor.schedule=0 50 2 * * ? 2060
# Fail or not when there are node integrity checker errors
integrity.failOnError=true
@@ -41,15 +54,171 @@ integrity.failOnError=true
# database connection properties
# MySQL connection (This is default and requires mysql-connector-java-5.0.3-bin.jar, which ships with the Alfresco server)
db.driver=org.gjt.mm.mysql.Driver
db.url=jdbc:mysql://localhost/${alfresco.db.name}
db.driver=${alfresco.db.datasource.class}
db.url=${alfresco.db.url}
db.username=${alfresco.db.username}
db.password=${alfresco.db.password}
db.pool.initial=10
db.pool.max=100
# MySQL dialect
hibernate.dialect=org.hibernate.dialect.MySQLInnoDBDialect
#
# Sample custom content and index data location
#
#dir.root=/srv/alfresco/alf_data
#dir.keystore=${dir.root}/keystore
#
# Sample database connection properties
#
#db.username=alfresco
#db.password=alfresco
#
# External locations
#-------------
#ooo.exe=soffice
#ooo.enabled=false
#jodconverter.officeHome=./OpenOffice.org
#jodconverter.portNumbers=8101
#jodconverter.enabled=true
#img.root=./ImageMagick
#swf.exe=./bin/pdf2swf
#
# Property to control whether schema updates are performed automatically.
# Updates must be enabled during upgrades as, apart from the static upgrade scripts,
# there are also auto-generated update scripts that will need to be executed. After
# upgrading to a new version, this can be disabled.
#
#db.schema.update=true
#
# MySQL connection
#
#db.driver=org.gjt.mm.mysql.Driver
#db.url=jdbc:mysql://localhost/alfresco?useUnicode=yes&characterEncoding=UTF-8
#
# Oracle connection
#
#db.driver=oracle.jdbc.OracleDriver
#db.url=jdbc:oracle:thin:@localhost:1521:alfresco
#
# SQLServer connection
# Requires jTDS driver version 1.2.5 and SNAPSHOT isolation mode
# Enable TCP protocol on fixed port 1433
# Prepare the database with:
# ALTER DATABASE alfresco SET ALLOW_SNAPSHOT_ISOLATION ON;
#
#db.driver=net.sourceforge.jtds.jdbc.Driver
#db.url=jdbc:jtds:sqlserver://localhost:1433/alfresco
#db.txn.isolation=4096
#
# PostgreSQL connection (requires postgresql-8.2-504.jdbc3.jar or equivalent)
#
#db.driver=org.postgresql.Driver
#db.url=jdbc:postgresql://localhost:5432/alfresco
#
# DB2 connection
#
#db.driver=com.ibm.db2.jcc.DB2Driver
#db.url=jdbc:db2://localhost:50000/alfresco:retrieveMessagesFromServerOnGetMessage=true;
#
# Index Recovery Mode
#-------------
#index.recovery.mode=AUTO
#
# Outbound Email Configuration
#-------------
#mail.host=
#mail.port=25
#mail.username=anonymous
#mail.password=
#mail.encoding=UTF-8
#mail.from.default=alfresco@alfresco.org
#mail.smtp.auth=false
#
# Alfresco Email Service and Email Server
#-------------
# Enable/Disable the inbound email service. The service could be used by processes other than
# the Email Server (e.g. direct RMI access) so this flag is independent of the Email Service.
#-------------
#email.inbound.enabled=true
# Email Server properties
#-------------
#email.server.enabled=true
#email.server.port=25
#email.server.domain=alfresco.com
#email.inbound.unknownUser=anonymous
# A comma separated list of email REGEX patterns of allowed senders.
# If there are any values in the list then all sender email addresses
# must match. For example:
# .*\@alfresco\.com, .*\@alfresco\.org
# Allow anyone:
#-------------
#email.server.allowed.senders=.*
#
# The default authentication chain
# To configure external authentication subsystems see:
# http://wiki.alfresco.com/wiki/Alfresco_Authentication_Subsystems
#-------------
#authentication.chain=alfrescoNtlm1:alfrescoNtlm
#
# URL Generation Parameters (The ${localname} token is replaced by the local server name)
#-------------
#alfresco.context=alfresco
#alfresco.host=${localname}
#alfresco.port=8080
#alfresco.protocol=http
#
#share.context=share
#share.host=${localname}
#share.port=8080
#share.protocol=http
#imap.server.enabled=true
#imap.server.port=143
#imap.server.host=localhost
# Default value of alfresco.rmi.services.host is 0.0.0.0 which means 'listen on all adapters'.
# This allows connections to JMX both remotely and locally.
#
alfresco.rmi.services.host=0.0.0.0
#
# RMI service ports for the individual services.
# These seven services are available remotely.
#
# Assign individual ports for each service for best performance
# or run several services on the same port. You can even run everything on 50500 if needed.
#
# Select 0 to use a random unused port.
#
#avm.rmi.service.port=50501
#avmsync.rmi.service.port=50502
#attribute.rmi.service.port=50503
#authentication.rmi.service.port=50504
#repo.rmi.service.port=50505
#action.rmi.service.port=50506
#wcm-deployment-receiver.rmi.service.port=50507
#monitor.rmi.service.port=50508
# Dialect is autodetected starting from 3.2
# H2 dialect
#hibernate.dialect=org.hibernate.dialect.H2Dialect
# Property to control whether schema updates are performed automatically.
@@ -69,7 +238,7 @@ smb.tcpip.port=1445
netbios.session.port=1139
netbios.name.port=1137
netbios.datagram.port=1138
ftp.server.enables=false
ftp.server.enabled=false
ftp.port=1121
ftp.authenticator=alfresco
@@ -137,5 +306,3 @@ ldap.synchronisation.import.group.cron=0 45 21 * * ?
# - setting this to true means old group definitions will be tidied up.
ldap.synchronisation.import.group.clearAllChildren=false

View File

@@ -0,0 +1,2 @@
# You can add here custom log4j classes. This will be merged with the main log4j.properties
# See http://wiki.alfresco.com/wiki/Developing_an_Alfresco_Module#Best_Log4j_Configuration_Practices

View File

@@ -0,0 +1,265 @@
# This is a full override of Alfresco 4.2.b log4j.properties
# This file overwrites the alfresco.war log4j.properties
# Set root logger level to error
log4j.rootLogger=${app.log.root.level}, Console, File
###### Console appender definition #######
# All outputs currently set to be a ConsoleAppender.
log4j.appender.Console=org.apache.log4j.ConsoleAppender
log4j.appender.Console.layout=org.apache.log4j.PatternLayout
# use log4j NDC to replace %x with tenant domain / username
log4j.appender.Console.layout.ConversionPattern=%d{ISO8601} %x %-5p [%c{3}] [%t] %m%n
#log4j.appender.Console.layout.ConversionPattern=%d{ABSOLUTE} %-5p [%c] %m%n
###### File appender definition #######
log4j.appender.File=org.apache.log4j.DailyRollingFileAppender
log4j.appender.File.File=${app.log.dir}alfresco.log
log4j.appender.File.Append=true
log4j.appender.File.DatePattern='.'yyyy-MM-dd
log4j.appender.File.layout=org.apache.log4j.PatternLayout
log4j.appender.File.layout.ConversionPattern=%d{ABSOLUTE} %-5p [%c] %m%n
###### Hibernate specific appender definition #######
#log4j.appender.file=org.apache.log4j.FileAppender
#log4j.appender.file.File=hibernate.log
#log4j.appender.file.layout=org.apache.log4j.PatternLayout
#log4j.appender.file.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L - %m%n
###### Log level overrides #######
# Commented-in loggers will be exposed as JMX MBeans (refer to org.alfresco.repo.admin.Log4JHierarchyInit)
# Hence, generally useful loggers should be listed with at least ERROR level to allow simple runtime
# control of the level via a suitable JMX Console. Also, any other loggers can be added transiently via
# Log4j addLoggerMBean as long as the logger exists and has been loaded.
# Hibernate
log4j.logger.org.hibernate=error
log4j.logger.org.hibernate.util.JDBCExceptionReporter=fatal
log4j.logger.org.hibernate.event.def.AbstractFlushingEventListener=fatal
log4j.logger.org.hibernate.type=warn
log4j.logger.org.hibernate.cfg.SettingsFactory=warn
# Spring
log4j.logger.org.springframework=warn
# Turn off Spring remoting warnings that should really be info or debug.
log4j.logger.org.springframework.remoting.support=error
log4j.logger.org.springframework.util=error
# Axis/WSS4J
log4j.logger.org.apache.axis=info
log4j.logger.org.apache.ws=info
# CXF
log4j.logger.org.apache.cxf=error
# MyFaces
log4j.logger.org.apache.myfaces.util.DebugUtils=info
log4j.logger.org.apache.myfaces.el.VariableResolverImpl=error
log4j.logger.org.apache.myfaces.application.jsp.JspViewHandlerImpl=error
log4j.logger.org.apache.myfaces.taglib=error
# OpenOfficeConnection
log4j.logger.net.sf.jooreports.openoffice.connection=fatal
# log prepared statement cache activity ###
log4j.logger.org.hibernate.ps.PreparedStatementCache=info
# Alfresco
log4j.logger.org.alfresco=error
log4j.logger.org.alfresco.repo.admin=info
log4j.logger.org.alfresco.repo.cache.TransactionalCache=warn
log4j.logger.org.alfresco.repo.model.filefolder=warn
log4j.logger.org.alfresco.repo.tenant=info
log4j.logger.org.alfresco.repo.avm=info
log4j.logger.org.alfresco.config=warn
log4j.logger.org.alfresco.config.JndiObjectFactoryBean=warn
log4j.logger.org.alfresco.config.JBossEnabledWebApplicationContext=warn
log4j.logger.org.alfresco.repo.management.subsystems=warn
log4j.logger.org.alfresco.repo.management.subsystems.ChildApplicationContextFactory=info
log4j.logger.org.alfresco.repo.management.subsystems.ChildApplicationContextFactory$ChildApplicationContext=warn
log4j.logger.org.alfresco.repo.security.sync=info
log4j.logger.org.alfresco.repo.security.person=info
log4j.logger.org.alfresco.sample=info
log4j.logger.org.alfresco.web=info
#log4j.logger.org.alfresco.web.app.AlfrescoNavigationHandler=debug
#log4j.logger.org.alfresco.web.ui.repo.component.UIActions=debug
#log4j.logger.org.alfresco.web.ui.repo.tag.PageTag=debug
#log4j.logger.org.alfresco.web.bean.clipboard=debug
log4j.logger.org.alfresco.repo.webservice=info
log4j.logger.org.alfresco.service.descriptor.DescriptorService=info
#log4j.logger.org.alfresco.web.page=debug
log4j.logger.org.alfresco.repo.importer.ImporterBootstrap=error
#log4j.logger.org.alfresco.repo.importer.ImporterBootstrap=info
log4j.logger.org.alfresco.web.ui.common.Utils=error
#log4j.logger.org.alfresco.web.ui.common.Utils=info
log4j.logger.org.alfresco.repo.admin.patch.PatchExecuter=info
log4j.logger.org.alfresco.repo.domain.patch.ibatis.PatchDAOImpl=info
# Specific patches
log4j.logger.org.alfresco.repo.admin.patch.impl.DeploymentMigrationPatch=info
log4j.logger.org.alfresco.repo.version.VersionMigrator=info
log4j.logger.org.alfresco.repo.admin.patch.impl.ResetWCMToGroupBasedPermissionsPatch=info
log4j.logger.org.alfresco.repo.module.ModuleServiceImpl=info
log4j.logger.org.alfresco.repo.domain.schema.SchemaBootstrap=info
log4j.logger.org.alfresco.repo.admin.ConfigurationChecker=info
log4j.logger.org.alfresco.repo.node.index.AbstractReindexComponent=warn
log4j.logger.org.alfresco.repo.node.index.IndexTransactionTracker=warn
log4j.logger.org.alfresco.repo.node.index.FullIndexRecoveryComponent=info
log4j.logger.org.alfresco.repo.node.index.AVMFullIndexRecoveryComponent=info
log4j.logger.org.alfresco.util.OpenOfficeConnectionTester=info
log4j.logger.org.alfresco.repo.node.db.hibernate.HibernateNodeDaoServiceImpl=warn
log4j.logger.org.alfresco.repo.domain.hibernate.DirtySessionMethodInterceptor=warn
log4j.logger.org.alfresco.repo.transaction.RetryingTransactionHelper=warn
log4j.logger.org.alfresco.util.transaction.SpringAwareUserTransaction.trace=warn
log4j.logger.org.alfresco.util.AbstractTriggerBean=warn
log4j.logger.org.alfresco.enterprise.repo.cache.cluster.KeepAliveHeartbeatReceiver=info
log4j.logger.org.alfresco.repo.version.Version2ServiceImpl=warn
#log4j.logger.org.alfresco.web.app.DebugPhaseListener=debug
log4j.logger.org.alfresco.repo.workflow=info
# CIFS server debugging
log4j.logger.org.alfresco.smb.protocol=error
#log4j.logger.org.alfresco.smb.protocol.auth=debug
#log4j.logger.org.alfresco.acegi=debug
# FTP server debugging
log4j.logger.org.alfresco.ftp.protocol=error
#log4j.logger.org.alfresco.ftp.server=debug
# WebDAV debugging
#log4j.logger.org.alfresco.webdav.protocol=debug
log4j.logger.org.alfresco.webdav.protocol=error
# NTLM servlet filters
#log4j.logger.org.alfresco.web.app.servlet.NTLMAuthenticationFilter=debug
#log4j.logger.org.alfresco.repo.webdav.auth.NTLMAuthenticationFilter=debug
# Kerberos servlet filters
#log4j.logger.org.alfresco.web.app.servlet.KerberosAuthenticationFilter=debug
#log4j.logger.org.alfresco.repo.webdav.auth.KerberosAuthenticationFilter=debug
# File servers
log4j.logger.org.alfresco.fileserver=warn
# Repo filesystem debug logging
#log4j.logger.org.alfresco.filesys.repo.ContentDiskDriver=debug
# AVM filesystem debug logging
#log4j.logger.org.alfresco.filesys.avm.AVMDiskDriver=debug
# Integrity message threshold - if 'failOnViolation' is off, then WARNINGS are generated
log4j.logger.org.alfresco.repo.node.integrity=ERROR
# Indexer debugging
log4j.logger.org.alfresco.repo.search.Indexer=error
#log4j.logger.org.alfresco.repo.search.Indexer=debug
log4j.logger.org.alfresco.repo.search.impl.lucene.index=error
log4j.logger.org.alfresco.repo.search.impl.lucene.fts.FullTextSearchIndexerImpl=warn
#log4j.logger.org.alfresco.repo.search.impl.lucene.index=DEBUG
# Audit debugging
# log4j.logger.org.alfresco.repo.audit=DEBUG
# log4j.logger.org.alfresco.repo.audit.model=DEBUG
# Forms debugging
# log4j.logger.org.alfresco.web.forms=debug
# log4j.logger.org.chiba.xml.xforms=debug
log4j.logger.org.alfresco.web.forms.xforms.XFormsBean=error
log4j.logger.org.alfresco.web.forms.XSLTRenderingEngine=error
# Property sheet and modelling debugging
# change to error to hide the warnings about missing properties and associations
log4j.logger.alfresco.missingProperties=warn
log4j.logger.org.alfresco.web.ui.repo.component.property.UIChildAssociation=warn
log4j.logger.org.alfresco.web.ui.repo.component.property.UIAssociation=warn
#log4j.logger.org.alfresco.web.ui.repo.component.property=debug
# Dictionary/Model debugging
log4j.logger.org.alfresco.repo.dictionary=warn
log4j.logger.org.alfresco.repo.dictionary.types.period=warn
# Virtualization Server Registry
log4j.logger.org.alfresco.mbeans.VirtServerRegistry=error
# Spring context runtime property setter
log4j.logger.org.alfresco.util.RuntimeSystemPropertiesSetter=info
# Debugging options for clustering
log4j.logger.org.alfresco.repo.content.ReplicatingContentStore=error
log4j.logger.org.alfresco.repo.content.replication=error
#log4j.logger.org.alfresco.repo.deploy.DeploymentServiceImpl=debug
# Activity service
log4j.logger.org.alfresco.repo.activities=warn
# User usage tracking
log4j.logger.org.alfresco.repo.usage=info
# Sharepoint
log4j.logger.org.alfresco.module.vti=info
# Forms Engine
log4j.logger.org.alfresco.repo.forms=info
log4j.logger.org.alfresco.web.config.forms=info
log4j.logger.org.alfresco.web.scripts.forms=info
# CMIS
log4j.logger.org.alfresco.opencmis=error
log4j.logger.org.alfresco.opencmis.AlfrescoCmisServiceInterceptor=error
log4j.logger.org.alfresco.cmis=error
log4j.logger.org.alfresco.cmis.dictionary=warn
log4j.logger.org.apache.chemistry.opencmis=info
# IMAP
log4j.logger.org.alfresco.repo.imap=info
# JBPM
# Note: non-fatal errors (eg. logged during job execution) should be handled by Alfresco's retrying transaction handler
log4j.logger.org.jbpm.graph.def.GraphElement=fatal
#log4j.logger.org.alfresco.repo.googledocs=debug
###### Scripting #######
# Web Framework
log4j.logger.org.springframework.extensions.webscripts=info
log4j.logger.org.springframework.extensions.webscripts.ScriptLogger=warn
log4j.logger.org.springframework.extensions.webscripts.ScriptDebugger=off
# Repository
log4j.logger.org.alfresco.repo.web.scripts=warn
log4j.logger.org.alfresco.repo.web.scripts.BaseWebScriptTest=info
log4j.logger.org.alfresco.repo.web.scripts.AlfrescoRhinoScriptDebugger=off
log4j.logger.org.alfresco.repo.jscript=error
log4j.logger.org.alfresco.repo.jscript.ScriptLogger=warn
log4j.logger.org.alfresco.repo.cmis.rest.CMISTest=info
log4j.logger.org.alfresco.repo.avm.actions=info
# Freemarker
# Note the freemarker.runtime logger is used to log non-fatal errors that are handled by Alfresco's retrying transaction handler
log4j.logger.freemarker.runtime=
# Metadata extraction
log4j.logger.org.alfresco.repo.content.metadata.AbstractMappingMetadataExtracter=warn
# Reduces PDFont error level due to ALF-7105
log4j.logger.org.apache.pdfbox.pdmodel.font.PDSimpleFont=fatal
log4j.logger.org.apache.pdfbox.pdmodel.font.PDFont=fatal
log4j.logger.org.apache.pdfbox.pdmodel.font.PDCIDFont=fatal
# no index support
log4j.logger.org.alfresco.repo.search.impl.noindex.NoIndexIndexer=fatal
log4j.logger.org.alfresco.repo.search.impl.noindex.NoIndexSearchService=fatal

View File

@@ -1,4 +1,4 @@
<?xml version='1.0' encoding='UTF-8'?>
<?xml version='1.0' encoding='UTF-8'?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
@@ -16,18 +16,18 @@
limitations under the License.
-->
<!DOCTYPE faces-config PUBLIC "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.1//EN"
"http://java.sun.com/dtd/web-facesconfig_1_1.dtd">
<faces-config>
<!--
|
| Insert here custom faces configurations like:
| <managed-bean>
| <navigation-rule>
|
| This is loaded as part of the alfresco convention over configuration
-->
</faces-config>
<!DOCTYPE faces-config PUBLIC "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.1//EN"
"http://java.sun.com/dtd/web-facesconfig_1_1.dtd">
<faces-config>
<!--
|
| Insert here custom faces configurations like:
| <managed-bean>
| <navigation-rule>
|
| This is loaded as part of the alfresco convention over configuration
-->
</faces-config>

View File

@@ -19,6 +19,11 @@
<param-value>server</param-value>
</context-param>
<context-param>
<param-name>javax.faces.PARTIAL_STATE_SAVING_METHOD</param-name>
<param-value>false</param-value>
</context-param>
<context-param>
<param-name>javax.faces.CONFIG_FILES</param-name>
<param-value>/WEB-INF/faces-config-app.xml,/WEB-INF/faces-config-beans.xml,/WEB-INF/faces-config-navigation.xml,/WEB-INF/faces-config-common.xml,/WEB-INF/faces-config-repo.xml,/WEB-INF/faces-config-wcm.xml,/WEB-INF/faces-config-custom.xml</param-value>
@@ -65,25 +70,22 @@
</description>
</context-param>
<!-- Spring Application Context location -->
<context-param>
<param-name>contextConfigLocation</param-name>
<param-value>/WEB-INF/web-application-context.xml</param-value>
<description>Spring config file location</description>
</context-param>
<context-param>
<param-name>contextClass</param-name>
<param-value>org.alfresco.config.JBossEnabledWebApplicationContext</param-value>
<description>Spring context class</description>
</context-param>
<context-param>
<param-name>log4jExposeWebAppRoot</param-name>
<param-value>false</param-value>
<description>Do not try to resolve web app root as file</description>
</context-param>
<!-- These were previously init params for the WebDAV servlet,
but since they are also needed to MT-enable the
ExternalAccess servlet, I have made them context wide. -->
<!-- These were previously init params for the WebDAV servlet,
but since they are also needed to MT-enable the
ExternalAccess servlet, I have made them context wide. -->
<context-param>
<param-name>store</param-name>
<param-value>workspace://SpacesStore</param-value>
@@ -93,7 +95,19 @@
<param-value>/app:company_home</param-value>
</context-param>
<context-param>
<param-name>org.apache.myfaces.ERROR_HANDLING</param-name>
<param-value>false</param-value>
</context-param>
<!-- Activiti context param placeholder -->
<context-param>
<param-name>com.ibm.ws.jsf.loadExternalDtd</param-name>
<param-value>false</param-value>
<description>Sets "http://apache.org/xml/features/nonvalidating/load-external-dtd" feature on the SAXParser to false if this parameter is false</description>
</context-param>
<filter>
<filter-name>Authentication Filter</filter-name>
<description>Authentication filter mapped only to faces URLs. Other URLs generally use proprietary means to talk to the AuthenticationComponent</description>
@@ -102,24 +116,11 @@
<param-name>beanName</param-name>
<param-value>AuthenticationFilter</param-value>
</init-param>
<!-- For Novell IChain support use the following filter -->
<!--
<filter-class>org.alfresco.web.app.servlet.HTTPRequestAuthenticationFilter</filter-class>
<init-param>
<param-name>httpServletRequestAuthHeaderName</param-name>
<param-value>x-user</param-value>
</init-param>
<init-param>
<param-name>authPatternString</param-name>
<param-value>.*</param-value>
</init-param>
-->
</filter>
<filter>
<filter-name>Global Authentication Filter</filter-name>
<description>Authentication filter mapped to all authenticated URLs (except web scripts). Mainly for NTLM support</description>
<description>Authentication filter mapped to all authenticated URLs. Mainly for SSO support</description>
<filter-class>org.alfresco.repo.web.filter.beans.BeanProxyFilter</filter-class>
<init-param>
<param-name>beanName</param-name>
@@ -129,7 +130,7 @@
<filter>
<filter-name>WebScript Authentication Filter</filter-name>
<description>Authentication filter mapped to web script URLs. Mainly for NTLM support</description>
<description>Authentication filter mapped to web script URLs. Mainly for SSO support</description>
<filter-class>org.alfresco.repo.web.filter.beans.BeanProxyFilter</filter-class>
<init-param>
<param-name>beanName</param-name>
@@ -150,6 +151,33 @@
<filter-name>Admin Authentication Filter</filter-name>
<filter-class>org.alfresco.web.app.servlet.AdminAuthenticationFilter</filter-class>
</filter>
<filter>
<filter-name>CacheExpiresFilter</filter-name>
<description>Set HTTP cache Expires header 30 days forward for a mapping.</description>
<filter-class>org.alfresco.web.scripts.servlet.StaticAssetCacheFilter</filter-class>
<init-param>
<param-name>expires</param-name>
<param-value>30</param-value>
<description>Add an Expires Header 30 days forward</description>
</init-param>
</filter>
<filter>
<filter-name>Global Localization Filter</filter-name>
<description>Sets fallback default locale for ALL requests</description>
<filter-class>org.alfresco.web.app.servlet.GlobalLocalizationFilter</filter-class>
</filter>
<filter>
<filter-name>JSF Session Synchronized Filter</filter-name>
<filter-class>org.alfresco.repo.web.filter.beans.SessionSynchronizedFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>Global Localization Filter</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>Global Authentication Filter</filter-name>
@@ -191,6 +219,7 @@
<url-pattern>/d/*</url-pattern>
</filter-mapping>
<!-- The WebScript Authentication filter sits in front of web service URLs in addition to the global authentication filter -->
<filter-mapping>
<filter-name>WebScript Authentication Filter</filter-name>
<url-pattern>/wcservice/*</url-pattern>
@@ -201,6 +230,16 @@
<url-pattern>/wcs/*</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>Global Authentication Filter</filter-name>
<url-pattern>/wcservice/*</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>Global Authentication Filter</filter-name>
<url-pattern>/wcs/*</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>Global Authentication Filter</filter-name>
<url-pattern>/ajax/*</url-pattern>
@@ -250,7 +289,32 @@
<filter-name>Admin Authentication Filter</filter-name>
<url-pattern>/faces/jsp/admin/system-info.jsp</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>JSF Session Synchronized Filter</filter-name>
<url-pattern>/faces/*</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>CacheExpiresFilter</filter-name>
<url-pattern>*.jpg</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>CacheExpiresFilter</filter-name>
<url-pattern>*.png</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>CacheExpiresFilter</filter-name>
<url-pattern>*.gif</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>CacheExpiresFilter</filter-name>
<url-pattern>*.css</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>CacheExpiresFilter</filter-name>
<url-pattern>*.js</url-pattern>
</filter-mapping>
<listener>
<listener-class>org.apache.myfaces.webapp.StartupServletContextListener</listener-class>
@@ -260,14 +324,29 @@
<listener-class>org.springframework.web.util.Log4jConfigListener</listener-class>
</listener>
<!-- Spring Context Loader listener - can disable loading of context if runtime config changes are needed -->
<listener>
<listener-class>org.alfresco.web.app.ContextLoaderListener</listener-class>
</listener>
<!-- Web Application Context listener - session create/destroy debugging and bootstrap Spring init -->
<listener>
<listener-class>org.alfresco.web.app.ContextListener</listener-class>
</listener>
<!-- WebDAV session listener - ensures that no locked resources is left after session expires -->
<listener>
<listener-class>org.alfresco.repo.webdav.WebDAVSessionListener</listener-class>
</listener>
<!-- Web Services context listener for OpenCMIS -->
<listener>
<listener-class>com.sun.xml.ws.transport.http.servlet.WSServletContextListener</listener-class>
</listener>
<!-- Activiti listener placeholder -->
<!-- Faces Servlet -->
<servlet>
<servlet-name>Faces Servlet</servlet-name>
@@ -345,16 +424,16 @@
<servlet>
<servlet-name>apiServlet</servlet-name>
<servlet-class>org.alfresco.web.scripts.servlet.WebScriptServlet</servlet-class>
<servlet-class>org.springframework.extensions.webscripts.servlet.WebScriptServlet</servlet-class>
<init-param>
<param-name>authenticator</param-name>
<param-value>webscripts.authenticator.basic</param-value>
</init-param>
</servlet>
<servlet>
<servlet-name>wcapiServlet</servlet-name>
<servlet-class>org.alfresco.web.scripts.servlet.WebScriptServlet</servlet-class>
<servlet-class>org.springframework.extensions.webscripts.servlet.WebScriptServlet</servlet-class>
<init-param>
<param-name>authenticator</param-name>
<param-value>webscripts.authenticator.webclient</param-value>
@@ -363,7 +442,7 @@
<servlet>
<servlet-name>portalapiServlet</servlet-name>
<servlet-class>org.alfresco.web.scripts.servlet.WebScriptServlet</servlet-class>
<servlet-class>org.springframework.extensions.webscripts.servlet.WebScriptServlet</servlet-class>
<init-param>
<param-name>authenticator</param-name>
<param-value>webscripts.authenticator.webclient</param-value>
@@ -372,7 +451,7 @@
<servlet>
<servlet-name>facebookServlet</servlet-name>
<servlet-class>org.alfresco.web.scripts.facebook.FacebookServlet</servlet-class>
<servlet-class>org.alfresco.repo.web.scripts.facebook.FacebookServlet</servlet-class>
<init-param>
<param-name>authenticator</param-name>
<param-value>webscripts.authenticator.facebook</param-value>
@@ -381,7 +460,7 @@
<servlet>
<servlet-name>fbapiServlet</servlet-name>
<servlet-class>org.alfresco.web.scripts.facebook.FacebookAPIServlet</servlet-class>
<servlet-class>org.alfresco.repo.web.scripts.facebook.FacebookAPIServlet</servlet-class>
<init-param>
<param-name>authenticator</param-name>
<param-value>webscripts.authenticator.facebook</param-value>
@@ -390,7 +469,7 @@
<servlet>
<servlet-name>proxyServlet</servlet-name>
<servlet-class>org.alfresco.web.scripts.servlet.HTTPProxyServlet</servlet-class>
<servlet-class>org.alfresco.web.app.servlet.HTTPProxyServlet</servlet-class>
</servlet>
<servlet>
@@ -403,6 +482,94 @@
<servlet-class>org.alfresco.web.app.servlet.JBPMDeployProcessServlet</servlet-class>
</servlet>
<servlet>
<servlet-name>CMISFileShareServlet</servlet-name>
<servlet-class>org.apache.chemistry.opencmis.browser.BrowseServlet</servlet-class>
<init-param>
<param-name>auxroot</param-name>
<param-value>cmisfs/browser/</param-value>
</init-param>
<init-param>
<param-name>allow</param-name>
<param-value>http.*</param-value>
</init-param>
<init-param>
<param-name>stylesheet:application/atomsvc+xml</param-name>
<param-value>/cmisfs/stylesheets/service.xsl</param-value>
</init-param>
<init-param>
<param-name>stylesheet:application/atom+xml;type=feed</param-name>
<param-value>/cmisfs/stylesheets/feed.xsl</param-value>
</init-param>
<init-param>
<param-name>stylesheet:application/cmistree+xml</param-name>
<param-value>/cmisfs/stylesheets/feed.xsl</param-value>
</init-param>
<init-param>
<param-name>stylesheet:application/atom+xml;type=entry</param-name>
<param-value>/cmisfs/stylesheets/entry.xsl</param-value>
</init-param>
<init-param>
<param-name>stylesheet:application/cmisallowableactions+xml</param-name>
<param-value>/cmisfs/stylesheets/actions.xsl</param-value>
</init-param>
<init-param>
<param-name>stylesheet:application/cmisacl+xml</param-name>
<param-value>/cmisfs/stylesheets/acl.xsl</param-value>
</init-param>
<init-param>
<param-name>override-stylesheet:renditions</param-name>
<param-value>/cmisfs/stylesheets/renditions.xsl</param-value>
</init-param>
<init-param>
<param-name>override-stylesheet:relationships</param-name>
<param-value>/cmisfs/stylesheets/relationships.xsl</param-value>
</init-param>
<init-param>
<param-name>override-stylesheet:thumbnails</param-name>
<param-value>/cmisfs/stylesheets/thumbnails.xsl</param-value>
</init-param>
</servlet>
<servlet>
<servlet-name>cmisws</servlet-name>
<servlet-class>com.sun.xml.ws.transport.http.servlet.WSServlet</servlet-class>
<load-on-startup>7</load-on-startup>
</servlet>
<servlet>
<servlet-name>cmisatom</servlet-name>
<servlet-class>org.apache.chemistry.opencmis.server.impl.atompub.CmisAtomPubServlet</servlet-class>
<init-param>
<param-name>callContextHandler</param-name>
<param-value>org.apache.chemistry.opencmis.server.shared.BasicAuthCallContextHandler</param-value>
</init-param>
<load-on-startup>8</load-on-startup>
</servlet>
<servlet>
<servlet-name>cmisbrowser</servlet-name>
<servlet-class>org.apache.chemistry.opencmis.server.impl.browser.CmisBrowserBindingServlet</servlet-class>
<init-param>
<param-name>callContextHandler</param-name>
<param-value>org.apache.chemistry.opencmis.server.shared.BasicAuthCallContextHandler</param-value>
</init-param>
<load-on-startup>8</load-on-startup>
</servlet>
<servlet>
<servlet-name>cmistck</servlet-name>
<servlet-class>org.apache.chemistry.opencmis.tck.runner.WebRunnerServlet</servlet-class>
<load-on-startup>8</load-on-startup>
</servlet>
<servlet>
<servlet-name>authenticatorServlet</servlet-name>
<servlet-class>org.alfresco.repo.web.scripts.servlet.AuthenticatorServlet</servlet-class>
</servlet>
<!-- Activiti servlet placeholder -->
<servlet-mapping>
<servlet-name>Faces Servlet</servlet-name>
<url-pattern>/faces/*</url-pattern>
@@ -568,6 +735,36 @@
<url-pattern>/workflowdefinitionimage/*</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>CMISFileShareServlet</servlet-name>
<url-pattern>/cmisbrowse</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>cmisws</servlet-name>
<url-pattern>/cmisws/*</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>cmisatom</servlet-name>
<url-pattern>/cmisatom/*</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>cmisbrowser</servlet-name>
<url-pattern>/cmisbrowser/*</url-pattern>
</servlet-mapping>
<!-- The CMIS TCK is deactivated by default. -->
<!-- CMISTCK
<servlet-mapping>
<servlet-name>cmistck</servlet-name>
<url-pattern>/cmistck</url-pattern>
</servlet-mapping>
CMISTCK -->
<!-- Activiti servlet mapping placeholder -->
<session-config>
<session-timeout>60</session-timeout>
</session-config>
@@ -581,14 +778,83 @@
<location>/jsp/error.jsp</location>
</error-page>
<!-- GC: Commented out for jetty running. -->
<!-- <resource-ref>-->
<!-- <description>The Alfresco database connection</description>-->
<!-- <res-ref-name>jdbc/dataSource</res-ref-name>-->
<!-- <res-type>javax.sql.DataSource</res-type>-->
<!-- <res-auth>Container</res-auth>-->
<!-- <res-sharing-scope>Unshareable</res-sharing-scope>-->
<!-- </resource-ref>-->
<resource-ref>
<description>The Alfresco database connection</description>
<res-ref-name>jdbc/dataSource</res-ref-name>
<res-type>javax.sql.DataSource</res-type>
<res-auth>Container</res-auth>
<res-sharing-scope>Unshareable</res-sharing-scope>
</resource-ref>
<!--
<security-constraint>
<web-resource-collection>
<web-resource-name>SOLR</web-resource-name>
<url-pattern>/service/api/solr/*</url-pattern>
</web-resource-collection>
<auth-constraint>
<role-name>repoclient</role-name>
</auth-constraint>
<user-data-constraint>
<transport-guarantee>CONFIDENTIAL</transport-guarantee>
</user-data-constraint>
</security-constraint>
<security-constraint>
<web-resource-collection>
<web-resource-name>SOLR</web-resource-name>
<url-pattern>/s/api/solr/*</url-pattern>
</web-resource-collection>
<auth-constraint>
<role-name>repoclient</role-name>
</auth-constraint>
<user-data-constraint>
<transport-guarantee>CONFIDENTIAL</transport-guarantee>
</user-data-constraint>
</security-constraint>
<security-constraint>
<web-resource-collection>
<web-resource-name>SOLR</web-resource-name>
<url-pattern>/wcservice/api/solr/*</url-pattern>
</web-resource-collection>
<auth-constraint>
<role-name>repoclient</role-name>
</auth-constraint>
<user-data-constraint>
<transport-guarantee>CONFIDENTIAL</transport-guarantee>
</user-data-constraint>
</security-constraint>
<security-constraint>
<web-resource-collection>
<web-resource-name>SOLR</web-resource-name>
<url-pattern>/wcs/api/solr/*</url-pattern>
</web-resource-collection>
<auth-constraint>
<role-name>repoclient</role-name>
</auth-constraint>
<user-data-constraint>
<transport-guarantee>CONFIDENTIAL</transport-guarantee>
</user-data-constraint>
</security-constraint>
<login-config>
<auth-method>CLIENT-CERT</auth-method>
<realm-name>Repository</realm-name>
</login-config>
<security-role>
<role-name>repoclient</role-name>
</security-role>
-->
<env-entry>
<description>A flag that globally enables or disables startup of the major Alfresco subsystems.</description>

View File

@@ -0,0 +1,16 @@
<?xml version="1.0"?>
<!DOCTYPE Configure PUBLIC "-//Mort Bay Consulting//DTD Configure//EN" "http://jetty.mortbay.org/configure.dtd">
<Configure id="Server" class="org.mortbay.jetty.Server">
<New id="myDataSource"
class="org.mortbay.jetty.plus.naming.Resource">
<Arg>jdbc/dataSource</Arg>
<Arg>
<New class="${alfresco.db.datasource.class}">
<Set name="URL">${alfresco.db.url}</Set>
<Set name="User">${alfresco.db.username}</Set>
<Set name="Password">${alfresco.db.password}</Set>
</New>
</Arg>
</New>
</Configure>

View File

@@ -0,0 +1,37 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<artifactId>${artifactId}</artifactId>
<name>Alfresco AMP Module</name>
<packaging>amp</packaging>
<description>This is a sample AMP project, depended upon by the alfresco WAR module</description>
<parent>
<groupId>${groupId}</groupId>
<artifactId>${rootArtifactId}</artifactId>
<version>${version}</version>
</parent>
<!--
Following dependencies are needed for compiling
Java code in src/main/java; <scope>provided</scope>
is inherited for each of the following; for more
info, please refer to alfresco-integration-parent
POM definition
@TODO - document
-->
<dependencies>
<dependency>
<groupId>${alfresco.groupId}</groupId>
<artifactId>alfresco-repository</artifactId>
</dependency>
</dependencies>
<properties>
<!-- This property allow to switch Repo AMP vs Share AMP.
Set alfresco.client.war=share to run this AMP against Share
-->
<alfresco.client.war>alfresco</alfresco.client.war>
</properties>
</project>

View File

@@ -20,11 +20,11 @@
<beans>
<!-- A simple class that is initialized by Spring -->
<bean id="${groupId}.${artifactId}.exampleBean" class="org.alfresco.demoamp.Demo" init-method="init" />
<bean id="changeMe.exampleBean" class="org.alfresco.demoamp.Demo" init-method="init" />
<!-- A simple module component that will be executed once -->
<bean id="${groupId}.${artifactId}.exampleComponent" class="org.alfresco.demoamp.DemoComponent" parent="module.baseComponent" >
<property name="moduleId" value="${pom.groupId}.${pom.artifactId}" /> <!-- See module.properties -->
<bean id="changeMe.exampleComponent" class="org.alfresco.demoamp.DemoComponent" parent="module.baseComponent" >
<property name="moduleId" value="${project.artifactId}" /> <!-- See module.properties -->
<property name="name" value="exampleComponent" />
<property name="description" value="A demonstration component" />
<property name="sinceVersion" value="2.0" />

View File

@@ -20,6 +20,6 @@
<beans>
<import resource="classpath:alfresco/module/${groupId}.${artifactId}/context/service-context.xml" />
<import resource="classpath:alfresco/module/${artifactId}/context/service-context.xml" />
</beans>

View File

@@ -19,11 +19,11 @@
# ==== Beginning of Alfresco required/optional properties ====== #
module.id=${pom.groupId}.${pom.artifactId}
module.id=${project.artifactId}
#module.aliases=myModule-123, my-module
module.title=${pom.name}
module.description=${pom.description}
module.version=${noSnapshotVersion}.${buildNumber}
module.title=${project.name}
module.description=${project.description}
module.version=${noSnapshotVersion}
# The following optional properties can be used to prevent the module from being added
# to inappropriate versions of the WAR file.

View File

@@ -0,0 +1,15 @@
package org.alfresco.demoamp;
/**
* This class does nothing except dump some output to <i>system.out</i>.
* This is a sample taken from Alfresco SDK
*
* @author Derek Hulley
*/
public class Demo
{
public void init()
{
System.out.println("SDK Demo AMP class has been loaded");
}
}

View File

@@ -0,0 +1,26 @@
package org.alfresco.demoamp;
import java.util.logging.Logger;
import org.alfresco.repo.module.AbstractModuleComponent;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
/**
* A basic component that will be started for this module.
* This is a sample taken from Alfresco SDK
*
* @author Derek Hulley
*/
public class DemoComponent extends AbstractModuleComponent
{
Log log = LogFactory.getLog(DemoComponent.class);
@Override
protected void executeInternal() throws Throwable
{
System.out.println("DemoComponent has been executed");
log.debug("Test debug logging is working");
log.info("This should not be outputted by default");
}
}

View File

@@ -0,0 +1,57 @@
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# RUN TIME PROPERTIES
# -------------------
# Sample custom content and index data location
# This will create alf_data Relative to appserver run folder
# In this default file we take the property from the POM (for compatbility with local jetty and jboss deployments) but it can also be edited here.
dir.root=${alfresco.data.location}
# Allowed values are: NONE, AUTO, FULL
index.recovery.mode=NONE
# This is default. Allowed values are: solr, lucene, noindex
index.subsystem.name=solr
#dir.keystore=.
#keystore.password=storepassword
#metadata.password=metapassword
# Fail or not when there are node integrity checker errors
integrity.failOnError=true
# Database connection properties
db.driver=${alfresco.db.datasource.class}
db.url=${alfresco.db.url}
db.username=${alfresco.db.username}
db.password=${alfresco.db.password}
db.pool.initial=10
db.pool.max=100
# File servers related properties
# For local builds we disable CIFS and FTP. Edit the following property to reenable them
smb.server.enabled=false
smb.server.name=CFS_SHARE_LOCAL
smb.server.domain=mycompany.com
smb.server.bindto=127.0.0.1
smb.tcpip.port=1445
netbios.session.port=1139
netbios.name.port=1137
netbios.datagram.port=1138
ftp.server.enables=false
ftp.port=1121
ftp.authenticator=alfresco

View File

@@ -0,0 +1,23 @@
# Overrides only log4j locations and add the test logging properties
# This gets merged with the main file
# Set root logger level to error
log4j.rootLogger=${app.log.root.level}, Console, File
###### Console appender definition #######
# All outputs currently set to be a ConsoleAppender.
log4j.appender.Console=org.apache.log4j.ConsoleAppender
log4j.appender.Console.layout=org.apache.log4j.PatternLayout
# use log4j NDC to replace %x with tenant domain / username
log4j.appender.Console.layout.ConversionPattern=%d{ISO8601} %x %-5p [%c{3}] [%t] %m%n
#log4j.appender.Console.layout.ConversionPattern=%d{ABSOLUTE} %-5p [%c] %m%n
###### File appender definition #######
log4j.appender.File=org.apache.log4j.DailyRollingFileAppender
log4j.appender.File.File=${app.log.dir}alfresco.log
log4j.appender.File.Append=true
log4j.appender.File.DatePattern='.'yyyy-MM-dd
log4j.appender.File.layout=org.apache.log4j.PatternLayout
log4j.appender.File.layout.ConversionPattern=%d{ABSOLUTE} %-5p [%c] %m%n

View File

@@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>${groupId}</groupId>
<artifactId>${artifactId}</artifactId>
<version>${version}</version>
<name>Quickstart of Alfresco and Share with DB and runner embedded</name>
<description>This All-in-One project allows to manage all the components involved in Alfresco development (Repo, Share, Solr, AMPs) in one project</description>
<packaging>pom</packaging>
<parent>
<groupId>org.alfresco.maven</groupId>
<artifactId>alfresco-sdk-parent</artifactId>
<version>1.0</version>
</parent>
<!--
| SDK properties have sensible defaults in the SDK parent,
| but you can override the properties below to use another version.
| For more available properties see the alfresco-sdk-parent POM.
-->
<properties>
<alfresco.groupId>${alfresco_target_groupId}</alfresco.groupId>
<alfresco.version>${alfresco_target_version}</alfresco.version>
<app.log.root.level>WARN</app.log.root.level>
<alfresco.data.location>alf_data_dev</alfresco.data.location>
<!-- This controls which properties will be picked in src/test/properties for embedded run -->
<env>local</env>
</properties>
<!-- Here we realize the connection with the Alfresco selected platform (e.g.version and edition) -->
<dependencyManagement>
<dependencies>
<!-- This will import the dependencyManagement for all artifacts in the selected Alfresco plaftorm
(see http://maven.apache.org/guides/introduction/introduction-to-dependency-mechanism.html#Importing_Dependencies)
NOTE: You still need to define dependencies in your POM, but you can omit version as it's enforced by this dependencyManagement.
NOTE: It defaults to the latest version this SDK pom has been tested with, but alfresco version can/should be overridden in your project's pom
-->
<dependency>
<groupId>${alfresco.groupId}</groupId>
<artifactId>alfresco-platform-distribution</artifactId>
<version>${alfresco.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>
<!--
No more repos are needed since they will be inherited by the parent POM.
This is needed to download the alfresco-plaftorm POM.
-->
<repositories>
<repository>
<id>alfresco-artifacts</id>
<url>https://artifacts.alfresco.com/nexus/content/groups/public</url>
</repository>
<repository>
<id>alfresco-artifacts-snapshots</id>
<url>https://artifacts.alfresco.com/nexus/content/groups/public-snapshots</url>
<snapshots>
<updatePolicy>never</updatePolicy>
</snapshots>
</repository>
</repositories>
</project>

View File

@@ -0,0 +1,34 @@
<?xml version="1.0"?>
<!DOCTYPE Configure PUBLIC "-//Mort Bay Consulting//DTD Configure//EN" "http://jetty.mortbay.org/configure.dtd">
<Configure id="Server" class="org.mortbay.jetty.Server">
<New id="myDataSource" class="org.mortbay.jetty.plus.naming.Resource">
<Arg>jdbc/dataSource</Arg>
<Arg>
<New class="${alfresco.db.datasource.class}">
<Set name="URL">${alfresco.db.url}</Set>
<Set name="User">${alfresco.db.username}</Set>
<Set name="Password">${alfresco.db.password}</Set>
</New>
</Arg>
</New>
<Call name="addConnector">
<Arg>
<New class="org.mortbay.jetty.nio.SelectChannelConnector">
<Set name="host">
<Property name="jetty.host" default="${runner.host}" />
</Set>
<Set name="port">
<Property name="jetty.port" default="${runner.port}" />
</Set>
<Set name="maxIdleTime">300000</Set>
<Set name="Acceptors">2</Set>
<Set name="statsOn">false</Set>
<Set name="confidentialPort">8443</Set>
<Set name="lowResourcesConnections">20000</Set>
<Set name="lowResourcesMaxIdleTime">5000</Set>
</New>
</Arg>
</Call>
</Configure>

View File

@@ -0,0 +1,10 @@
<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE web-app PUBLIC
"-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
"http://java.sun.com/dtd/web-app_2_3.dtd">
<web-app>
<display-name>Alfresco Runner</display-name>
<description>Alfresco Runner</description>
</web-app>

View File

@@ -0,0 +1,76 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<artifactId>${artifactId}</artifactId>
<name>Alfresco and Share Runner</name>
<packaging>pom</packaging>
<description>Alfresco and Share Runner</description>
<parent>
<groupId>${groupId}</groupId>
<artifactId>${rootArtifactId}</artifactId>
<version>${version}</version>
</parent>
<profiles>
<profile>
<id>run</id>
<activation>
<property>
<name>run</name>
</property>
</activation>
<properties>
<alfresco.solr.dir>${project.basedir}/../solr/solr_home</alfresco.solr.dir>
<runner.host>127.0.0.1</runner.host>
<runner.port>8080</runner.port>
</properties>
<build>
<plugins>
<plugin>
<groupId>org.mortbay.jetty</groupId>
<artifactId>maven-jetty-plugin</artifactId>
<executions>
<execution>
<id>run</id>
<goals><goal>run</goal></goals>
<phase>integration-test</phase>
</execution>
</executions>
<configuration>
<!-- Following 3 properties set an empty ROOT context,
which is mandatory to run jetty:run plugin -->
<contextPath>/</contextPath>
<webAppSourceDirectory>.</webAppSourceDirectory>
<webXml>jetty/root-web.xml</webXml>
<contextHandlers>
<contextHandler implementation="org.mortbay.jetty.webapp.WebAppContext">
<war>${project.basedir}/../alfresco/target/alfresco.war</war>
<contextPath>/alfresco</contextPath>
</contextHandler>
<contextHandler implementation="org.mortbay.jetty.webapp.WebAppContext">
<war>${alfresco.solr.dir}/apache-solr-1.4.1-overlay.war</war>
<contextPath>/solr</contextPath>
</contextHandler>
<contextHandler implementation="org.mortbay.jetty.webapp.WebAppContext">
<war>${project.basedir}/../share/target/share.war</war>
<contextPath>/share</contextPath>
</contextHandler>
<contextHandler implementation="org.mortbay.jetty.webapp.WebAppContext">
<war>${project.basedir}/../wcmqs/target/wcmqs.war</war>
<contextPath>/wcmqs</contextPath>
</contextHandler>
</contextHandlers>
<systemProperties>
<systemProperty>
<name>solr.solr.home</name>
<value>${alfresco.solr.dir}</value>
</systemProperty>
</systemProperties>
</configuration>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</project>

View File

@@ -0,0 +1,64 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<artifactId>${artifactId}</artifactId>
<name>Alfresco Share Client</name>
<packaging>war</packaging>
<description>Alfresco Share Client</description>
<parent>
<groupId>${groupId}</groupId>
<artifactId>${rootArtifactId}</artifactId>
<version>${version}</version>
</parent>
<dependencies>
<dependency>
<groupId>${alfresco.groupId}</groupId>
<artifactId>share</artifactId>
<type>war</type>
</dependency>
<!-- Demonstrating the usage of a well known GA AMP (Web Quick Start
Share component) -->
<dependency>
<groupId>${alfresco.groupId}</groupId>
<artifactId>alfresco-wcm-quickstart-share</artifactId>
<version>${alfresco.version}</version>
<type>amp</type>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<artifactId>maven-war-plugin</artifactId>
<configuration>
<!-- Here is can control the order of overlay of your (WAR, AMP, etc.) dependencies
| NOTE: At least one WAR dependency must be uncompressed first
| NOTE: In order to have a dependency effectively added to the WAR you need to
| explicitly mention it in the overlay section.
| NOTE: First-win resource strategy is used by the WAR plugin
-->
<overlays>
<!-- The current project customizations -->
<overlay/>
<!-- The Share WAR -->
<overlay>
<groupId>${alfresco.groupId}</groupId>
<artifactId>share</artifactId>
<type>war</type>
<!-- To allow inclusion of META-INF -->
<excludes/>
</overlay>
<!-- Add / order your AMPs here -->
<overlay>
<groupId>${alfresco.groupId}</groupId>
<artifactId>alfresco-wcm-quickstart-share</artifactId>
<type>amp</type>
</overlay>
</overlays>
</configuration>
</plugin>
</plugins>
</build>
</project>

View File

@@ -0,0 +1,8 @@
# SHARE client environment dependent properties (local build)
share.server.scheme=http
share.server.name=localhost
share.server.port=${jetty.port}
alfresco.server.scheme=http
alfresco.server.name=localhost
alfresco.server.port=${jetty.port}
alfresco.webapp.name=alfresco

View File

@@ -0,0 +1,112 @@
<?xml version='1.0' encoding='UTF-8'?>
<!-- This is a sample configuration file from Alfresco Community 4.2.b - Please adapt to your version -->
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:hz="http://www.hazelcast.com/schema/config"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
http://www.hazelcast.com/schema/config
http://www.hazelcast.com/schema/config/hazelcast-spring.xsd">
<!--
Hazelcast distributed messaging configuration - Share web-tier cluster config (3.4.8 and 4.0.1)
- see http://www.hazelcast.com/docs.jsp
- and specifically http://www.hazelcast.com/docs/1.9.4/manual/single_html/#SpringIntegration
-->
<!-- Configure cluster to use either Multicast or direct TCP-IP messaging - multicast is default -->
<!-- Optionally specify network interfaces - server machines likely to have more than one interface -->
<!-- The messaging topic - the "name" is also used by the persister config below -->
<!--
<hz:topic id="topic" instance-ref="webframework.cluster.slingshot" name="slingshot-topic"/>
<hz:hazelcast id="webframework.cluster.slingshot">
<hz:config>
<hz:group name="slingshot" password="alfresco"/>
<hz:network port="5801" port-auto-increment="true">
<hz:join>
<hz:multicast enabled="true"
multicast-group="224.2.2.5"
multicast-port="54327"/>
<hz:tcp-ip enabled="false">
<hz:members></hz:members>
</hz:tcp-ip>
</hz:join>
<hz:interfaces enabled="false">
<hz:interface>192.168.1.*</hz:interface>
</hz:interfaces>
</hz:network>
</hz:config>
</hz:hazelcast>
<bean id="webframework.slingshot.persister.remote" class="org.alfresco.web.site.ClusterAwarePathStoreObjectPersister" parent="webframework.sitedata.persister.abstract">
<property name="store" ref="webframework.webapp.store.remote" />
<property name="pathPrefix"><value>alfresco/site-data/${objectTypeIds}</value></property>
<property name="hazelcastInstance" ref="webframework.cluster.slingshot" />
<property name="hazelcastTopicName"><value>slingshot-topic</value></property>
</bean>
<bean id="webframework.factory.requestcontext.servlet" class="org.alfresco.web.site.ClusterAwareRequestContextFactory" parent="webframework.factory.base">
<property name="linkBuilderFactory" ref="webframework.factory.linkbuilder.servlet" />
<property name="extensibilityModuleHandler" ref="webscripts.extensibility.handler" />
<property name="clusterObjectPersister" ref="webframework.slingshot.persister.remote" />
</bean>
-->
<!-- Legacy Share web-tier cluster config (3.4.7 and 4.0.0) -->
<!--
<bean id="webframework.slingshot.persister.remote" class="org.springframework.extensions.surf.persister.PathStoreObjectPersister" parent="webframework.sitedata.persister.abstract">
<property name="store" ref="webframework.webapp.store.remote" />
<property name="pathPrefix"><value>alfresco/site-data/${objectTypeIds}</value></property>
<property name="noncachableObjectTypes">
<set>
<value>page</value>
<value>component</value>
<value>configuration</value>
</set>
</property>
</bean>
-->
<!-- Override WebScripts searchpath - to include remote store -->
<!-- This enables remote component load via a central Alfresco server -->
<!--
<bean id="webframework.webscripts.store.alfresco.remote" parent="webframework.store.remote.abstract">
<property name="path"><value>alfresco/site-webscripts</value></property>
</bean>
<bean id="webframework.webscripts.searchpath" class="org.springframework.extensions.webscripts.SearchPath">
<property name="searchPath">
<list>
<ref bean="webframework.webscripts.store.alfresco.remote" />
<ref bean="webframework.webscripts.store.alfresco.custom" />
<ref bean="webframework.webscripts.store.alfresco.classpath" />
<ref bean="webframework.webscripts.store.classpath" />
<ref bean="webscripts.store.alfresco" />
<ref bean="webscripts.store" />
</list>
</property>
</bean>
-->
<!-- Override Templates and Scripts searchpath - to include remote store -->
<!-- This enables remote component load via a central Alfresco server -->
<!--
<bean id="webframework.templates.store.alfresco.remote" parent="webframework.store.remote.abstract">
<property name="path"><value>alfresco/templates</value></property>
</bean>
<bean id="webframework.templates.searchpath" class="org.springframework.extensions.webscripts.SearchPath">
<property name="searchPath">
<list>
<ref bean="webframework.templates.store.alfresco.remote" />
<ref bean="webframework.templates.store.alfresco.custom" />
<ref bean="webframework.webscripts.store.alfresco.custom" />
<ref bean="webframework.templates.store.alfresco.classpath" />
<ref bean="webframework.webscripts.store.alfresco.classpath" />
<ref bean="webframework.templates.store.classpath" />
<ref bean="webframework.webscripts.store.classpath" />
</list>
</property>
</bean>
-->
</beans>

View File

@@ -0,0 +1,346 @@
<!-- This is a sample configuration file from Alfresco Community 4.2.b - Please adapt to your version -->
<alfresco-config>
<!-- Global config section -->
<config replace="true">
<flags>
<!--
Developer debugging setting to turn on DEBUG mode for client scripts in the browser
-->
<client-debug>false</client-debug>
<!--
LOGGING can always be toggled at runtime when in DEBUG mode (Ctrl, Ctrl, Shift, Shift).
This flag automatically activates logging on page load.
-->
<client-debug-autologging>false</client-debug-autologging>
</flags>
</config>
<config evaluator="string-compare" condition="WebFramework">
<web-framework>
<!-- SpringSurf Autowire Runtime Settings -->
<!--
Developers can set mode to 'development' to disable; SpringSurf caches,
FreeMarker template caching and Rhino JavaScript compilation.
-->
<autowire>
<!-- Pick the mode: "production" or "development" -->
<mode>production</mode>
</autowire>
<!-- Allows extension modules with <auto-deploy> set to true to be automatically deployed -->
<module-deployment>
<mode>manual</mode>
<enable-auto-deploy-modules>true</enable-auto-deploy-modules>
</module-deployment>
</web-framework>
</config>
<config evaluator="string-compare" condition="Replication">
<share-urls>
<!--
To discover a Repository Id, browse to the remote server's CMIS landing page at:
http://{server}:{port}/alfresco/service/cmis/index.html
The Repository Id field is found under the "CMIS Repository Information" expandable panel.
Example config entry:
<share-url repositoryId="622f9533-2a1e-48fe-af4e-ee9e41667ea4">http://new-york-office:8080/share/</share-url>
-->
</share-urls>
</config>
<!-- Document Library config section -->
<config evaluator="string-compare" condition="DocumentLibrary" replace="true">
<tree>
<!--
Whether the folder Tree component should enumerate child folders or not.
This is a relatively expensive operation, so should be set to "false" for Repositories with broad folder structures.
-->
<evaluate-child-folders>false</evaluate-child-folders>
<!--
Optionally limit the number of folders shown in treeview throughout Share.
-->
<maximum-folder-count>-1</maximum-folder-count>
</tree>
<!--
Used by the "Manage Aspects" action
For custom aspects, remember to also add the relevant i18n string(s)
cm_myaspect=My Aspect
-->
<aspects>
<!-- Aspects that a user can see -->
<visible>
<aspect name="cm:generalclassifiable" />
<aspect name="cm:complianceable" />
<aspect name="cm:dublincore" />
<aspect name="cm:effectivity" />
<aspect name="cm:summarizable" />
<aspect name="cm:versionable" />
<aspect name="cm:templatable" />
<aspect name="cm:emailed" />
<aspect name="emailserver:aliasable" />
<aspect name="cm:taggable" />
<aspect name="app:inlineeditable" />
<aspect name="gd:googleEditable" />
<aspect name="cm:geographic" />
<aspect name="exif:exif" />
</visible>
<!-- Aspects that a user can add. Same as "visible" if left empty -->
<addable>
</addable>
<!-- Aspects that a user can remove. Same as "visible" if left empty -->
<removeable>
</removeable>
</aspects>
<!--
Used by the "Change Type" action
Define valid subtypes using the following example:
<type name="cm:content">
<subtype name="cm:mysubtype" />
</type>
Remember to also add the relevant i18n string(s):
cm_mysubtype=My SubType
-->
<types>
<type name="cm:content">
</type>
<type name="cm:folder">
</type>
</types>
<!--
If set, will present a WebDAV link for the current item on the Document and Folder details pages.
Also used to generate the "View in Alfresco Explorer" action for folders.
-->
<repository-url>http://localhost:8080/alfresco</repository-url>
<!--
Google Docs™ integration
-->
<google-docs>
<!--
Enable/disable the Google Docs UI integration (Extra types on Create Content menu, Google Docs actions).
-->
<enabled>false</enabled>
<!--
The mimetypes of documents Google Docs allows you to create via the Share interface.
The I18N label is created from the "type" attribute, e.g. google-docs.doc=Google Docs&trade; Document
-->
<creatable-types>
<creatable type="doc">application/msword</creatable>
<creatable type="xls">application/vnd.ms-excel</creatable>
<creatable type="ppt">application/vnd.ms-powerpoint</creatable>
</creatable-types>
</google-docs>
<!--
File upload configuration
-->
<file-upload>
<!--
Adobe Flash™
In certain environments, an HTTP request originating from Flash cannot be authenticated using an existing session.
See: http://bugs.adobe.com/jira/browse/FP-4830
For these cases, it is useful to disable the Flash-based uploader for Share Document Libraries.
-->
<adobe-flash-enabled>true</adobe-flash-enabled>
</file-upload>
</config>
<!-- Custom DocLibActions config section -->
<config evaluator="string-compare" condition="DocLibActions">
<actionGroups>
<actionGroup id="document-browse">
<!-- Simple Repo Actions -->
<!--
<action index="340" id="document-extract-metadata" />
<action index="350" id="document-increment-counter" />
-->
<!-- Dialog Repo Actions -->
<!--
<action index="360" id="document-transform" />
<action index="370" id="document-transform-image" />
<action index="380" id="document-execute-script" />
-->
</actionGroup>
</actionGroups>
</config>
<!-- Global folder picker config section -->
<config evaluator="string-compare" condition="GlobalFolder">
<siteTree>
<container type="cm:folder">
<!-- Use a specific label for this container type in the tree -->
<rootLabel>location.path.documents</rootLabel>
<!-- Use a specific uri to retreive the child nodes for this container type in the tree -->
<uri>slingshot/doclib/treenode/site/{site}/{container}{path}?children={evaluateChildFoldersSite}&amp;max={maximumFolderCountSite}</uri>
</container>
</siteTree>
</config>
<!-- Repository Library config section -->
<config evaluator="string-compare" condition="RepositoryLibrary" replace="true">
<!--
Root nodeRef or xpath expression for top-level folder.
e.g. alfresco://user/home, /app:company_home/st:sites/cm:site1
If using an xpath expression, ensure it is properly ISO9075 encoded here.
-->
<root-node>alfresco://company/home</root-node>
<tree>
<!--
Whether the folder Tree component should enumerate child folders or not.
This is a relatively expensive operation, so should be set to "false" for Repositories with broad folder structures.
-->
<evaluate-child-folders>false</evaluate-child-folders>
<!--
Optionally limit the number of folders shown in treeview throughout Share.
-->
<maximum-folder-count>500</maximum-folder-count>
</tree>
</config>
<!-- Kerberos settings -->
<!-- To enable kerberos rename this condition to "Kerberos" -->
<config evaluator="string-compare" condition="KerberosDisabled" replace="true">
<kerberos>
<!--
Password for HTTP service account.
The account name *must* be built from the HTTP server name, in the format :
HTTP/<server_name>@<realm>
(NB this is because the web browser requests an ST for the
HTTP/<server_name> principal in the current realm, so if we're to decode
that ST, it has to match.)
-->
<password>secret</password>
<!--
Kerberos realm and KDC address.
-->
<realm>ALFRESCO.ORG</realm>
<!--
Service Principal Name to use on the repository tier.
This must be like: HTTP/host.name@REALM
-->
<endpoint-spn>HTTP/repository.server.com@ALFRESCO.ORG</endpoint-spn>
<!--
JAAS login configuration entry name.
-->
<config-entry>ShareHTTP</config-entry>
</kerberos>
</config>
<!-- example port config used to access remote Alfresco server (default is 8080) -->
<!--
<config evaluator="string-compare" condition="Remote">
<remote>
<endpoint>
<id>alfresco-noauth</id>
<name>Alfresco - unauthenticated access</name>
<description>Access to Alfresco Repository WebScripts that do not require authentication</description>
<connector-id>alfresco</connector-id>
<endpoint-url>http://localhost:8080/alfresco/s</endpoint-url>
<identity>none</identity>
</endpoint>
<endpoint>
<id>alfresco</id>
<name>Alfresco - user access</name>
<description>Access to Alfresco Repository WebScripts that require user authentication</description>
<connector-id>alfresco</connector-id>
<endpoint-url>http://localhost:8080/alfresco/s</endpoint-url>
<identity>user</identity>
</endpoint>
<endpoint>
<id>alfresco-feed</id>
<name>Alfresco Feed</name>
<description>Alfresco Feed - supports basic HTTP authentication via the EndPointProxyServlet</description>
<connector-id>http</connector-id>
<endpoint-url>http://localhost:8080/alfresco/s</endpoint-url>
<basic-auth>true</basic-auth>
<identity>user</identity>
</endpoint>
<endpoint>
<id>activiti-admin</id>
<name>Activiti Admin UI - user access</name>
<description>Access to Activiti Admin UI, that requires user authentication</description>
<connector-id>activiti-admin-connector</connector-id>
<endpoint-url>http://localhost:8080/alfresco/activiti-admin</endpoint-url>
<identity>user</identity>
</endpoint>
</remote>
</config>
-->
<!--
Overriding endpoints to reference an Alfresco server with external SSO enabled
NOTE: If utilising a load balancer between web-tier and repository cluster, the "sticky
sessions" feature of your load balancer must be used.
NOTE: If alfresco server location is not localhost:8080 then also combine changes from the
"example port config" section below.
*Optional* keystore contains SSL client certificate + trusted CAs.
Used to authenticate share to an external SSO system such as CAS
Remove the keystore section if not required i.e. for NTLM.
NOTE: For Kerberos SSO rename the "KerberosDisabled" condition above to "Kerberos"
NOTE: For external SSO, switch the endpoint connector to "AlfrescoHeader" and set
the userHeader to the name of the HTTP header that the external SSO
uses to provide the authenticated user name.
-->
<!--
<config evaluator="string-compare" condition="Remote">
<remote>
<keystore>
<path>alfresco/web-extension/alfresco-system.p12</path>
<type>pkcs12</type>
<password>alfresco-system</password>
</keystore>
<connector>
<id>alfrescoCookie</id>
<name>Alfresco Connector</name>
<description>Connects to an Alfresco instance using cookie-based authentication</description>
<class>org.alfresco.web.site.servlet.SlingshotAlfrescoConnector</class>
</connector>
<connector>
<id>alfrescoHeader</id>
<name>Alfresco Connector</name>
<description>Connects to an Alfresco instance using header and cookie-based authentication</description>
<class>org.alfresco.web.site.servlet.SlingshotAlfrescoConnector</class>
<userHeader>SsoUserHeader</userHeader>
</connector>
<endpoint>
<id>alfresco</id>
<name>Alfresco - user access</name>
<description>Access to Alfresco Repository WebScripts that require user authentication</description>
<connector-id>alfrescoCookie</connector-id>
<endpoint-url>http://localhost:8080/alfresco/wcs</endpoint-url>
<identity>user</identity>
<external-auth>true</external-auth>
</endpoint>
</remote>
</config>
-->
</alfresco-config>

View File

@@ -0,0 +1,262 @@
# Set root logger level to error
log4j.rootLogger=${app.log.root.level}, Console, File
###### Console appender definition #######
# All outputs currently set to be a ConsoleAppender.
log4j.appender.Console=org.apache.log4j.ConsoleAppender
log4j.appender.Console.layout=org.apache.log4j.PatternLayout
# use log4j NDC to replace %x with tenant domain / username
log4j.appender.Console.layout.ConversionPattern=%d{ISO8601} %x %-5p [%c{3}] [%t] %m%n
#log4j.appender.Console.layout.ConversionPattern=%d{ABSOLUTE} %-5p [%c] %m%n
###### File appender definition #######
log4j.appender.File=org.apache.log4j.DailyRollingFileAppender
log4j.appender.File.File=${app.log.dir}share.log
log4j.appender.File.Append=true
log4j.appender.File.DatePattern='.'yyyy-MM-dd
log4j.appender.File.layout=org.apache.log4j.PatternLayout
log4j.appender.File.layout.ConversionPattern=%d{ABSOLUTE} %-5p [%c] %m%n
###### Hibernate specific appender definition #######
#log4j.appender.file=org.apache.log4j.FileAppender
#log4j.appender.file.File=hibernate.log
#log4j.appender.file.layout=org.apache.log4j.PatternLayout
#log4j.appender.file.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L - %m%n
###### Log level overrides #######
# Commented-in loggers will be exposed as JMX MBeans (refer to org.alfresco.repo.admin.Log4JHierarchyInit)
# Hence, generally useful loggers should be listed with at least ERROR level to allow simple runtime
# control of the level via a suitable JMX Console. Also, any other loggers can be added transiently via
# Log4j addLoggerMBean as long as the logger exists and has been loaded.
# Hibernate
log4j.logger.org.hibernate=error
log4j.logger.org.hibernate.util.JDBCExceptionReporter=fatal
log4j.logger.org.hibernate.event.def.AbstractFlushingEventListener=fatal
log4j.logger.org.hibernate.type=warn
log4j.logger.org.hibernate.cfg.SettingsFactory=warn
# Spring
log4j.logger.org.springframework=warn
# Turn off Spring remoting warnings that should really be info or debug.
log4j.logger.org.springframework.remoting.support=error
log4j.logger.org.springframework.util=error
# Axis/WSS4J
log4j.logger.org.apache.axis=info
log4j.logger.org.apache.ws=info
# CXF
log4j.logger.org.apache.cxf=error
# MyFaces
log4j.logger.org.apache.myfaces.util.DebugUtils=info
log4j.logger.org.apache.myfaces.el.VariableResolverImpl=error
log4j.logger.org.apache.myfaces.application.jsp.JspViewHandlerImpl=error
log4j.logger.org.apache.myfaces.taglib=error
# OpenOfficeConnection
log4j.logger.net.sf.jooreports.openoffice.connection=fatal
# log prepared statement cache activity ###
log4j.logger.org.hibernate.ps.PreparedStatementCache=info
# Alfresco
log4j.logger.org.alfresco=error
log4j.logger.org.alfresco.repo.admin=info
log4j.logger.org.alfresco.repo.cache.TransactionalCache=warn
log4j.logger.org.alfresco.repo.model.filefolder=warn
log4j.logger.org.alfresco.repo.tenant=info
log4j.logger.org.alfresco.repo.avm=info
log4j.logger.org.alfresco.config=warn
log4j.logger.org.alfresco.config.JndiObjectFactoryBean=warn
log4j.logger.org.alfresco.config.JBossEnabledWebApplicationContext=warn
log4j.logger.org.alfresco.repo.management.subsystems=warn
log4j.logger.org.alfresco.repo.management.subsystems.ChildApplicationContextFactory=info
log4j.logger.org.alfresco.repo.management.subsystems.ChildApplicationContextFactory$ChildApplicationContext=warn
log4j.logger.org.alfresco.repo.security.sync=info
log4j.logger.org.alfresco.repo.security.person=info
log4j.logger.org.alfresco.sample=info
log4j.logger.org.alfresco.web=info
#log4j.logger.org.alfresco.web.app.AlfrescoNavigationHandler=debug
#log4j.logger.org.alfresco.web.ui.repo.component.UIActions=debug
#log4j.logger.org.alfresco.web.ui.repo.tag.PageTag=debug
#log4j.logger.org.alfresco.web.bean.clipboard=debug
log4j.logger.org.alfresco.repo.webservice=info
log4j.logger.org.alfresco.service.descriptor.DescriptorService=info
#log4j.logger.org.alfresco.web.page=debug
log4j.logger.org.alfresco.repo.importer.ImporterBootstrap=error
#log4j.logger.org.alfresco.repo.importer.ImporterBootstrap=info
log4j.logger.org.alfresco.web.ui.common.Utils=error
#log4j.logger.org.alfresco.web.ui.common.Utils=info
log4j.logger.org.alfresco.repo.admin.patch.PatchExecuter=info
log4j.logger.org.alfresco.repo.domain.patch.ibatis.PatchDAOImpl=info
# Specific patches
log4j.logger.org.alfresco.repo.admin.patch.impl.DeploymentMigrationPatch=info
log4j.logger.org.alfresco.repo.version.VersionMigrator=info
log4j.logger.org.alfresco.repo.admin.patch.impl.ResetWCMToGroupBasedPermissionsPatch=info
log4j.logger.org.alfresco.repo.module.ModuleServiceImpl=info
log4j.logger.org.alfresco.repo.domain.schema.SchemaBootstrap=info
log4j.logger.org.alfresco.repo.admin.ConfigurationChecker=info
log4j.logger.org.alfresco.repo.node.index.AbstractReindexComponent=warn
log4j.logger.org.alfresco.repo.node.index.IndexTransactionTracker=warn
log4j.logger.org.alfresco.repo.node.index.FullIndexRecoveryComponent=info
log4j.logger.org.alfresco.repo.node.index.AVMFullIndexRecoveryComponent=info
log4j.logger.org.alfresco.util.OpenOfficeConnectionTester=info
log4j.logger.org.alfresco.repo.node.db.hibernate.HibernateNodeDaoServiceImpl=warn
log4j.logger.org.alfresco.repo.domain.hibernate.DirtySessionMethodInterceptor=warn
log4j.logger.org.alfresco.repo.transaction.RetryingTransactionHelper=warn
log4j.logger.org.alfresco.util.transaction.SpringAwareUserTransaction.trace=warn
log4j.logger.org.alfresco.util.AbstractTriggerBean=warn
log4j.logger.org.alfresco.enterprise.repo.cache.cluster.KeepAliveHeartbeatReceiver=info
log4j.logger.org.alfresco.repo.version.Version2ServiceImpl=warn
#log4j.logger.org.alfresco.web.app.DebugPhaseListener=debug
log4j.logger.org.alfresco.repo.workflow=info
# CIFS server debugging
log4j.logger.org.alfresco.smb.protocol=error
#log4j.logger.org.alfresco.smb.protocol.auth=debug
#log4j.logger.org.alfresco.acegi=debug
# FTP server debugging
log4j.logger.org.alfresco.ftp.protocol=error
#log4j.logger.org.alfresco.ftp.server=debug
# WebDAV debugging
#log4j.logger.org.alfresco.webdav.protocol=debug
log4j.logger.org.alfresco.webdav.protocol=error
# NTLM servlet filters
#log4j.logger.org.alfresco.web.app.servlet.NTLMAuthenticationFilter=debug
#log4j.logger.org.alfresco.repo.webdav.auth.NTLMAuthenticationFilter=debug
# Kerberos servlet filters
#log4j.logger.org.alfresco.web.app.servlet.KerberosAuthenticationFilter=debug
#log4j.logger.org.alfresco.repo.webdav.auth.KerberosAuthenticationFilter=debug
# File servers
log4j.logger.org.alfresco.fileserver=warn
# Repo filesystem debug logging
#log4j.logger.org.alfresco.filesys.repo.ContentDiskDriver=debug
# AVM filesystem debug logging
#log4j.logger.org.alfresco.filesys.avm.AVMDiskDriver=debug
# Integrity message threshold - if 'failOnViolation' is off, then WARNINGS are generated
log4j.logger.org.alfresco.repo.node.integrity=ERROR
# Indexer debugging
log4j.logger.org.alfresco.repo.search.Indexer=error
#log4j.logger.org.alfresco.repo.search.Indexer=debug
log4j.logger.org.alfresco.repo.search.impl.lucene.index=error
log4j.logger.org.alfresco.repo.search.impl.lucene.fts.FullTextSearchIndexerImpl=warn
#log4j.logger.org.alfresco.repo.search.impl.lucene.index=DEBUG
# Audit debugging
# log4j.logger.org.alfresco.repo.audit=DEBUG
# log4j.logger.org.alfresco.repo.audit.model=DEBUG
# Forms debugging
# log4j.logger.org.alfresco.web.forms=debug
# log4j.logger.org.chiba.xml.xforms=debug
log4j.logger.org.alfresco.web.forms.xforms.XFormsBean=error
log4j.logger.org.alfresco.web.forms.XSLTRenderingEngine=error
# Property sheet and modelling debugging
# change to error to hide the warnings about missing properties and associations
log4j.logger.alfresco.missingProperties=warn
log4j.logger.org.alfresco.web.ui.repo.component.property.UIChildAssociation=warn
log4j.logger.org.alfresco.web.ui.repo.component.property.UIAssociation=warn
#log4j.logger.org.alfresco.web.ui.repo.component.property=debug
# Dictionary/Model debugging
log4j.logger.org.alfresco.repo.dictionary=warn
log4j.logger.org.alfresco.repo.dictionary.types.period=warn
# Virtualization Server Registry
log4j.logger.org.alfresco.mbeans.VirtServerRegistry=error
# Spring context runtime property setter
log4j.logger.org.alfresco.util.RuntimeSystemPropertiesSetter=info
# Debugging options for clustering
log4j.logger.org.alfresco.repo.content.ReplicatingContentStore=error
log4j.logger.org.alfresco.repo.content.replication=error
#log4j.logger.org.alfresco.repo.deploy.DeploymentServiceImpl=debug
# Activity service
log4j.logger.org.alfresco.repo.activities=warn
# User usage tracking
log4j.logger.org.alfresco.repo.usage=info
# Sharepoint
log4j.logger.org.alfresco.module.vti=info
# Forms Engine
log4j.logger.org.alfresco.repo.forms=info
log4j.logger.org.alfresco.web.config.forms=info
log4j.logger.org.alfresco.web.scripts.forms=info
# CMIS
log4j.logger.org.alfresco.opencmis=error
log4j.logger.org.alfresco.opencmis.AlfrescoCmisServiceInterceptor=error
log4j.logger.org.alfresco.cmis=error
log4j.logger.org.alfresco.cmis.dictionary=warn
log4j.logger.org.apache.chemistry.opencmis=info
# IMAP
log4j.logger.org.alfresco.repo.imap=info
# JBPM
# Note: non-fatal errors (eg. logged during job execution) should be handled by Alfresco's retrying transaction handler
log4j.logger.org.jbpm.graph.def.GraphElement=fatal
#log4j.logger.org.alfresco.repo.googledocs=debug
###### Scripting #######
# Web Framework
log4j.logger.org.springframework.extensions.webscripts=info
log4j.logger.org.springframework.extensions.webscripts.ScriptLogger=warn
log4j.logger.org.springframework.extensions.webscripts.ScriptDebugger=off
# Repository
log4j.logger.org.alfresco.repo.web.scripts=warn
log4j.logger.org.alfresco.repo.web.scripts.BaseWebScriptTest=info
log4j.logger.org.alfresco.repo.web.scripts.AlfrescoRhinoScriptDebugger=off
log4j.logger.org.alfresco.repo.jscript=error
log4j.logger.org.alfresco.repo.jscript.ScriptLogger=warn
log4j.logger.org.alfresco.repo.cmis.rest.CMISTest=info
log4j.logger.org.alfresco.repo.avm.actions=info
# Freemarker
# Note the freemarker.runtime logger is used to log non-fatal errors that are handled by Alfresco's retrying transaction handler
log4j.logger.freemarker.runtime=
# Metadata extraction
log4j.logger.org.alfresco.repo.content.metadata.AbstractMappingMetadataExtracter=warn
# Reduces PDFont error level due to ALF-7105
log4j.logger.org.apache.pdfbox.pdmodel.font.PDSimpleFont=fatal
log4j.logger.org.apache.pdfbox.pdmodel.font.PDFont=fatal
log4j.logger.org.apache.pdfbox.pdmodel.font.PDCIDFont=fatal
# no index support
log4j.logger.org.alfresco.repo.search.impl.noindex.NoIndexIndexer=fatal
log4j.logger.org.alfresco.repo.search.impl.noindex.NoIndexSearchService=fatal

View File

@@ -0,0 +1,167 @@
<?xml version='1.0' encoding='UTF-8'?>
<!-- This is a sample from Alfresco Share 4.2.b to demonstrate how to override web.xml in your project.
| Uncomment this file to overlay to the webapp.
| NOTE: you will need to change/update this if you use a different Alfresco version / edition
-->
<web-app xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd" version="2.4">
<display-name>Alfresco Project Slingshot</display-name>
<description>Alfresco Project Slingshot application</description>
<context-param>
<param-name>org.jboss.jbossfaces.WAR_BUNDLES_JSF_IMPL</param-name>
<param-value>true</param-value>
</context-param>
<!-- Spring Application Context location and context class -->
<context-param>
<description>Spring config file location</description>
<param-name>contextConfigLocation</param-name>
<param-value>/WEB-INF/classes/web-application-config.xml</param-value>
</context-param>
<filter>
<description>Set HTTP cache Expires header 30 days forward for a mapping.</description>
<filter-name>CacheExpiresFilter</filter-name>
<filter-class>org.alfresco.web.scripts.servlet.StaticAssetCacheFilter</filter-class>
<init-param>
<description>Add an Expires Header 30 days forward</description>
<param-name>expires</param-name>
<param-value>30</param-value>
</init-param>
</filter>
<filter>
<description>MT authentication support - NOTE: does not support portlets</description>
<filter-name>MTAuthentationFilter</filter-name>
<filter-class>org.alfresco.web.site.servlet.MTAuthenticationFilter</filter-class>
</filter>
<filter>
<description>Redirects view and service URLs to the dispatcher servlet.</description>
<filter-name>UrlRewriteFilter</filter-name>
<filter-class>org.tuckey.web.filters.urlrewrite.UrlRewriteFilter</filter-class>
</filter>
<filter>
<description>Share SSO authentication support filter.</description>
<filter-name>Authentication Filter</filter-name>
<filter-class>org.alfresco.web.site.servlet.SSOAuthenticationFilter</filter-class>
<init-param>
<param-name>endpoint</param-name>
<param-value>alfresco</param-value>
</init-param>
</filter>
<filter-mapping>
<filter-name>CacheExpiresFilter</filter-name>
<url-pattern>*.jpg</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>CacheExpiresFilter</filter-name>
<url-pattern>*.png</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>CacheExpiresFilter</filter-name>
<url-pattern>*.gif</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>CacheExpiresFilter</filter-name>
<url-pattern>*.css</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>CacheExpiresFilter</filter-name>
<url-pattern>*.js</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>Authentication Filter</filter-name>
<url-pattern>/page/*</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>Authentication Filter</filter-name>
<url-pattern>/p/*</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>Authentication Filter</filter-name>
<url-pattern>/proxy/*</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>UrlRewriteFilter</filter-name>
<url-pattern>/proxy/*</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>UrlRewriteFilter</filter-name>
<url-pattern>/service/*</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>UrlRewriteFilter</filter-name>
<url-pattern>/feedservice/*</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>UrlRewriteFilter</filter-name>
<url-pattern>/res/*</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>UrlRewriteFilter</filter-name>
<url-pattern>/system/*</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>MTAuthentationFilter</filter-name>
<url-pattern>/page/*</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>MTAuthentationFilter</filter-name>
<url-pattern>/p/*</url-pattern>
</filter-mapping>
<!-- Spring Context Loader listener - the name of the default global context is passed to the DispatcherServlet
in the servlet definition below - this is to allow the NTLM filter etc. to find the single app context -->
<listener>
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
</listener>
<servlet>
<servlet-name>Spring Surf Dispatcher Servlet</servlet-name>
<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
<init-param>
<param-name>contextAttribute</param-name>
<param-value>org.springframework.web.context.WebApplicationContext.ROOT</param-value>
</init-param>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>Spring Surf Dispatcher Servlet</servlet-name>
<url-pattern>/page/*</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>Spring Surf Dispatcher Servlet</servlet-name>
<url-pattern>/p/*</url-pattern>
</servlet-mapping>
<session-config>
<session-timeout>60</session-timeout>
</session-config>
<!-- welcome file list precedence order is index.jsp -->
<welcome-file-list>
<welcome-file>page</welcome-file>
<welcome-file>index.jsp</welcome-file>
</welcome-file-list>
<error-page>
<error-code>500</error-code>
<location>/error500.jsp</location>
</error-page>
</web-app>

View File

@@ -0,0 +1,148 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<artifactId>${artifactId}</artifactId>
<name>Alfresco Apache Solr customization</name>
<packaging>pom</packaging>
<description>Alfresco Apache Solr Customization</description>
<parent>
<groupId>${groupId}</groupId>
<artifactId>${rootArtifactId}</artifactId>
<version>${version}</version>
</parent>
<properties>
<alfresco.solr.dir>${project.basedir}/solr_home</alfresco.solr.dir>
<alfresco.solr.war.overlay>${project.build.directory}/${project.artifactId}-overlay</alfresco.solr.war.overlay>
</properties>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>copy-alfresco-community-lib</id>
<goals><goal>unpack</goal></goals>
<phase>generate-resources</phase>
<configuration>
<outputDirectory>${alfresco.solr.dir}</outputDirectory>
<artifactItems>
<artifactItem>
<artifactId>alfresco-solr</artifactId>
<groupId>${alfresco.groupId}</groupId>
<version>${alfresco.version}</version>
<type>zip</type>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<version>1.7</version>
<executions>
<execution>
<id>overlay-solr-war</id>
<phase>generate-resources</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<tasks>
<echo message="Unpacking Apache Solr for web.xml overlay" />
<unzip src="${alfresco.solr.dir}/apache-solr-1.4.1.war" dest="${alfresco.solr.war.overlay}" />
</tasks>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<executions>
<execution>
<id>overlay-web-xml</id>
<phase>process-resources</phase>
<goals><goal>copy-resources</goal></goals>
<configuration>
<outputDirectory>${alfresco.solr.war.overlay}/WEB-INF</outputDirectory>
<overwrite>true</overwrite>
<resources>
<resource>
<directory>src/main/webapp/WEB-INF</directory>
<includes>
<include>web.xml</include>
</includes>
</resource>
<resource>
<directory>src/main/resources</directory>
<filtering>true</filtering>
<targetPath>classes</targetPath>
</resource>
</resources>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<version>1.7</version>
<executions>
<execution>
<id>create-solr-war</id>
<phase>package</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<tasks>
<echo message="Packaging Apache Solr WAR overlay" />
<zip basedir="${alfresco.solr.war.overlay}" destfile="${alfresco.solr.dir}/apache-solr-1.4.1-overlay.war" />
</tasks>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<executions>
<execution>
<id>copy-lib</id>
<phase>package</phase>
<goals><goal>copy-resources</goal></goals>
<configuration>
<outputDirectory>${alfresco.solr.dir}</outputDirectory>
<resources>
<resource>
<directory>src/main/solr-properties/archive</directory>
<filtering>true</filtering>
<targetPath>${alfresco.solr.dir}/archive-SpacesStore/conf</targetPath>
</resource>
<resource>
<directory>src/main/solr-properties/workspace</directory>
<filtering>true</filtering>
<targetPath>${alfresco.solr.dir}/workspace-SpacesStore/conf</targetPath>
</resource>
</resources>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>${alfresco.groupId}</groupId>
<artifactId>alfresco-solr</artifactId>
<version>${alfresco.version}</version>
<type>zip</type>
</dependency>
</dependencies>
</project>

View File

@@ -0,0 +1,18 @@
# Set root logger level to error
log4j.rootLogger=${app.log.root.level}, Console, File
###### Console appender definition #######
# All outputs currently set to be a ConsoleAppender.
log4j.appender.Console=org.apache.log4j.ConsoleAppender
log4j.appender.Console.layout=org.apache.log4j.PatternLayout
log4j.appender.Console.layout.ConversionPattern=%d{ISO8601} %x %-5p [%c{3}] [%t] %m%n
###### File appender definition #######
log4j.appender.File=org.apache.log4j.DailyRollingFileAppender
log4j.appender.File.File=${app.log.dir}solr.log
log4j.appender.File.Append=true
log4j.appender.File.DatePattern='.'yyyy-MM-dd
log4j.appender.File.layout=org.apache.log4j.PatternLayout
log4j.appender.File.layout.ConversionPattern=%d{ABSOLUTE} %-5p [%c] %m%n

View File

@@ -0,0 +1,83 @@
#
# solrcore.properties - used in solrconfig.xml
#
# data is in ${data.dir.root}/${data.dir.store}
data.dir.root=${alfresco.solr.dir}
data.dir.store=archive/SpacesStore
enable.alfresco.tracking=true
cache.alfresco.size=100
max.field.length=2147483647
#
# Properties loaded during alfresco tracking
#
alfresco.host=localhost
alfresco.port=8080
alfresco.port.ssl=8443
alfresco.baseUrl=/alfresco
alfresco.cron=0/15 * * * * ? *
alfresco.stores=archive://SpacesStore
alfresco.lag=1000
alfresco.hole.retention=3600000
alfresco.batch.count=1000
# encryption
# none, https
alfresco.secureComms=none
# ssl
alfresco.encryption.ssl.keystore.type=JCEKS
alfresco.encryption.ssl.keystore.provider=
alfresco.encryption.ssl.keystore.location=ssl.repo.client.keystore
alfresco.encryption.ssl.keystore.passwordFileLocation=ssl-keystore-passwords.properties
alfresco.encryption.ssl.truststore.type=JCEKS
alfresco.encryption.ssl.truststore.provider=
alfresco.encryption.ssl.truststore.location=ssl.repo.client.truststore
alfresco.encryption.ssl.truststore.passwordFileLocation=ssl-truststore-passwords.properties
## Tracking
alfresco.enableMultiThreadedTracking=true
alfresco.corePoolSize=3
alfresco.maximumPoolSize=-1
alfresco.keepAliveTime=120
alfresco.threadPriority=5
alfresco.threadDaemon=true
alfresco.workQueueSize=-1
# HTTP Client
alfresco.maxTotalConnections=40
alfresco.maxHostConnections=40
# SOLR caching
solr.filterCache.size=512
solr.filterCache.initialSize=512
solr.queryResultCache.size=512
solr.queryResultCache.initialSize=512
solr.documentCache.size=512
solr.documentCache.initialSize=512
solr.queryResultMaxDocsCached=200
solr.authorityCache.size=512
solr.authorityCache.initialSize=512
solr.pathCache.size=512
solr.pathCache.initialSize=512
# SOLR
solr.maxBooleanClauses=10000
#
# TODO
#
# cross language support
# locale expansion
# logging check report ....
#
#

View File

@@ -0,0 +1,103 @@
#
# solrcore.properties - used in solrconfig.xml
#
# data is in ${data.dir.root}/${data.dir.store}
data.dir.root=${alfresco.solr.dir}
data.dir.store=workspace/SpacesStore
enable.alfresco.tracking=true
cache.alfresco.size=100
max.field.length=2147483647
#
# Properties loaded during alfresco tracking
#
alfresco.host=localhost
alfresco.port=8080
alfresco.port.ssl=8443
alfresco.baseUrl=/alfresco
alfresco.cron=0/15 * * * * ? *
alfresco.stores=workspace://SpacesStore
#alfresco.index.transformContent=false
#alfresco.ignore.datatype.1=d:content
alfresco.lag=1000
alfresco.hole.retention=3600000
# alfresco.hole.check.after is not used yet
# It will reduce the hole checking load
alfresco.hole.check.after=300000
alfresco.batch.count=1000
# encryption
# none, https
alfresco.secureComms=none
# ssl
alfresco.encryption.ssl.keystore.type=JCEKS
alfresco.encryption.ssl.keystore.provider=
alfresco.encryption.ssl.keystore.location=ssl.repo.client.keystore
alfresco.encryption.ssl.keystore.passwordFileLocation=ssl-keystore-passwords.properties
alfresco.encryption.ssl.truststore.type=JCEKS
alfresco.encryption.ssl.truststore.provider=
alfresco.encryption.ssl.truststore.location=ssl.repo.client.truststore
alfresco.encryption.ssl.truststore.passwordFileLocation=ssl-truststore-passwords.properties
# Tracking
alfresco.enableMultiThreadedTracking=true
alfresco.corePoolSize=3
alfresco.maximumPoolSize=-1
alfresco.keepAliveTime=120
alfresco.threadPriority=5
alfresco.threadDaemon=true
alfresco.workQueueSize=-1
# HTTP Client
alfresco.maxTotalConnections=40
alfresco.maxHostConnections=40
# SOLR caching
solr.filterCache.size=512
solr.filterCache.initialSize=512
solr.queryResultCache.size=1024
solr.queryResultCache.initialSize=1024
solr.documentCache.size=512
solr.documentCache.initialSize=512
solr.queryResultMaxDocsCached=2000
solr.authorityCache.size=512
solr.authorityCache.initialSize=512
solr.pathCache.size=512
solr.pathCache.initialSize=512
# SOLR
solr.maxBooleanClauses=10000
# Batch fetch
alfresco.transactionDocsBatchSize=100
alfresco.changeSetAclsBatchSize=100
alfresco.aclBatchSize=10
# Warming
solr.filterCache.autowarmCount=128
solr.authorityCache.autowarmCount=0
solr.pathCache.autowarmCount=128
solr.queryResultWindowSize=200
#
# TODO
#
# cross language support
# locale expansion
# logging check report ....
#
#

View File

@@ -0,0 +1,175 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<web-app>
<!-- Uncomment if you are trying to use a Resin version before 3.0.19.
Their XML implementation isn't entirely compatible with Xerces.
Below are the implementations to use with Sun's JVM.
<system-property javax.xml.xpath.XPathFactory=
"com.sun.org.apache.xpath.internal.jaxp.XPathFactoryImpl"/>
<system-property javax.xml.parsers.DocumentBuilderFactory=
"com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl"/>
<system-property javax.xml.parsers.SAXParserFactory=
"com.sun.org.apache.xerces.internal.jaxp.SAXParserFactoryImpl"/>
-->
<!-- People who want to hardcode their "Solr Home" directly into the
WAR File can set the JNDI property here...
-->
<!--
<env-entry>
<env-entry-name>solr/home</env-entry-name>
<env-entry-value>/put/your/solr/home/here</env-entry-value>
<env-entry-type>java.lang.String</env-entry-type>
</env-entry>
-->
<!-- Any path (name) registered in solrconfig.xml will be sent to that filter -->
<filter>
<filter-name>SolrRequestFilter</filter-name>
<filter-class>org.apache.solr.servlet.SolrDispatchFilter</filter-class>
<!-- If you are wiring Solr into a larger web application which controls
the web context root, you will probably want to mount Solr under
a path prefix (app.war with /app/solr mounted into it, for example).
You will need to put this prefix in front of the SolrDispatchFilter
url-pattern mapping too (/solr/*), and also on any paths for
legacy Solr servlet mappings you may be using.
For the admin JSP's to work properly in a path-prefixed configuration,
the admin folder containing the JSPs needs to be under the app context root
named to match the path-prefix. For example:
.war
xxx
admin
stats.jsp
-->
<!--
<init-param>
<param-name>path-prefix</param-name>
<param-value>/xxx</param-value>
</init-param>
-->
</filter>
<filter-mapping>
<!--
NOTE: When using multicore, /admin JSP URLs with a core specified
such as /solr/coreName/admin/stats.jsp get forwarded by a
RequestDispatcher to /solr/admin/stats.jsp with the specified core
put into request scope keyed as "org.apache.solr.SolrCore".
It is unnecessary, and potentially problematic, to have the SolrDispatchFilter
configured to also filter on forwards. Do not configure
this dispatcher as <dispatcher>FORWARD</dispatcher>.
-->
<filter-name>SolrRequestFilter</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
<!-- Otherwise it will continue to the old servlets -->
<servlet>
<servlet-name>SolrServer</servlet-name>
<display-name>Solr</display-name>
<description>Solr Server</description>
<servlet-class>org.apache.solr.servlet.SolrServlet</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet>
<servlet-name>SolrUpdate</servlet-name>
<display-name>SolrUpdate</display-name>
<description>Solr Update Handler</description>
<servlet-class>org.apache.solr.servlet.SolrUpdateServlet</servlet-class>
<load-on-startup>2</load-on-startup>
</servlet>
<servlet>
<servlet-name>Logging</servlet-name>
<servlet-class>org.apache.solr.servlet.LogLevelSelection</servlet-class>
</servlet>
<!-- @Deprecated -->
<servlet>
<servlet-name>ping</servlet-name>
<jsp-file>/admin/ping.jsp</jsp-file>
</servlet>
<servlet-mapping>
<servlet-name>SolrServer</servlet-name>
<url-pattern>/select/*</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>SolrUpdate</servlet-name>
<url-pattern>/update/*</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>Logging</servlet-name>
<url-pattern>/admin/logging</url-pattern>
</servlet-mapping>
<!-- @Deprecated -->
<servlet-mapping>
<servlet-name>ping</servlet-name>
<url-pattern>/admin/ping</url-pattern>
</servlet-mapping>
<!-- @Deprecated -->
<servlet-mapping>
<servlet-name>Logging</servlet-name>
<url-pattern>/admin/logging.jsp</url-pattern>
</servlet-mapping>
<mime-mapping>
<extension>.xsl</extension>
<!-- per http://www.w3.org/TR/2006/PR-xslt20-20061121/ -->
<mime-type>application/xslt+xml</mime-type>
</mime-mapping>
<!--
| Needs to be commented out to use HTTP
| Uncomment to re-renable https alongside changing alfresco.secureComms=https
| in the solrcore.properties
|
-->
<!--
<security-constraint>
<web-resource-collection>
<url-pattern>/*</url-pattern>
</web-resource-collection>
<auth-constraint>
<role-name>repository</role-name>
</auth-constraint>
<user-data-constraint>
<transport-guarantee>CONFIDENTIAL</transport-guarantee>
</user-data-constraint>
</security-constraint>
<login-config>
<auth-method>CLIENT-CERT</auth-method>
<realm-name>Solr</realm-name>
</login-config>
<security-role>
<role-name>repository</role-name>
</security-role>
-->
</web-app>

View File

@@ -0,0 +1,42 @@
<?xml version="1.0"?>
<project
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>${groupId}</groupId>
<artifactId>${rootArtifactId}</artifactId>
<version>${version}</version>
</parent>
<artifactId>wcmqs</artifactId>
<packaging>war</packaging>
<name>Alfresco Web Quick Start customization</name>
<description>This project allows you to customize and overlay Alfresco Web Quick Start</description>
<dependencies>
<dependency>
<groupId>${alfresco.groupId}</groupId>
<artifactId>alfresco-wcm-quickstart</artifactId>
<version>${alfresco.version}</version>
<type>war</type>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<artifactId>maven-war-plugin</artifactId>
<configuration>
<overlays>
<!-- The current project customizations -->
<overlay />
<!-- The Alfresco WCMQS War -->
<overlay>
<artifactId>alfresco-wcm-quickstart</artifactId>
<groupId>${alfresco.groupId}</groupId>
</overlay>
</overlays>
</configuration>
</plugin>
</plugins>
</build>
</project>

View File

@@ -0,0 +1,55 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE log4j:configuration PUBLIC "-//LOGGER" "../dtd/log4j.dtd">
<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/">
<!-- Appenders -->
<appender name="console" class="org.apache.log4j.ConsoleAppender">
<param name="Target" value="System.out" />
<layout class="org.apache.log4j.PatternLayout">
<param name="ConversionPattern" value="%d{ABSOLUTE} %-5p [%c] %m%n" />
</layout>
</appender>
<appender name="file" class="org.apache.log4j.DailyRollingFileAppender">
<param name="File" value="${app.log.dir}webquickstart.log" />
<param name="Append" value="true" />
<param name="Encoding" value="UTF-8" />
<param name="DatePattern" value="'.'yyyy-MM-dd" />
<layout class="org.apache.log4j.PatternLayout">
<param name="ConversionPattern" value="%d{ABSOLUTE} %-5p [%c] %m%n" />
</layout>
</appender>
<!-- Application Loggers -->
<logger name="org.alfresco.samples.quickstart">
<level value="warn" />
</logger>
<!-- 3rdparty Loggers -->
<logger name="org.springframework.core">
<level value="warn" />
</logger>
<logger name="org.springframework.beans">
<level value="warn" />
</logger>
<logger name="org.springframework.context">
<level value="warn" />
</logger>
<logger name="org.springframework.web">
<level value="warn" />
</logger>
<logger name="org.alfresco.wcm">
<level value="warn" />
</logger>
<!-- Root Logger -->
<root>
<priority value="${app.log.root.level}" />
<appender-ref ref="console" />
<appender-ref ref="file" />
</root>
</log4j:configuration>

View File

@@ -0,0 +1,39 @@
------
Alfresco Maven All-in-One Archetype Advanced Usage
------
Gabriele Columbro
------
Nov 2012
------
All-in-One Archetype properties
In each of the modules of the archetype (as in the whole Maven Alfresco SDK\x99) properties are configurable at many levels:
* as POM properties
* direclty in *.properties, particularly
* For Alfresco WAR projects
* <<<src/main/properties/<env>/alfresco-global.properties>>> (environment dependent <<<alfresco-global.properties>>> packaged in the WAR )
* For Alfresco AMP projects
* <<<src/test/properties/<env>/alfresco-global.properties>>> (environment dependent <<<alfresco-global.properties>>> for test WAR run)
Build Environment (e.g. local, test, staging, prod) can be easily switched by setting the <<<<env>>>> property in your POM or
adding <<<-Denv=yourEnv>>> on the command line.
* Common properties
Archetype behavior can mostly be controlled directly in the POM, via common properties provided by the parent POM.
See {{{../../poms/alfresco-sdk-parent/sdk-properties.html} SDK properties reference}} for details.
Parent POM and behavior customization
To customize the behavior of your project, check out full set of the properties and plugin configurations defined in the
{{{./poms/alfresco-sdk-parent/index.html}single entry point parent POM}}.
One quick way to do that is to use the <<<maven-help-plugin:effective-pom>>> to analyze your POM at runtime.

View File

@@ -0,0 +1,48 @@
------
Building AMPs (Alfresco Module Packages) with Maven
------
Gabriele Columbro
------
Nov 2012
------
Introduction
The Alfresco All-in-One Archetype is a multi-module project,
leveraging Maven Alfresco SDK\x99 powerful capabilities to customize and run the full Alfresco platform embedded and all it's components.
The archetype does not require additional download and provides a perfect starting point for full-blown Alfresco projects.
* Features
Amongst other features, this archetype provides support for:
* <<<amp>>> packaging support for your projects
* AMP Dependency management and overlay in an Alfresco Repository or Share WAR
* Embedded run in Jetty and embedded H2 database of the full Alfresco suite, including Repository, Share, Solr and Web Quick Start
* Support for unit and integration testings
How to create a project:
You can create the latest release archetype with the following command:
+---+
mvn archetype:generate -DarchetypeCatalog=https://artifacts.alfresco.com/nexus/content/groups/public/archetype-catalog.xml
+---+
You should then:
[[1]] Select the <<<alfresco-allinone-archetype>>> option
[[2]] Specify the <<<groupId>>> and <<<artifactId>>> for the project you want to create
[[3]] (<Optionally>) Select Alfresco Version / Edition (current default is: Alfresco Community 4.2.b)
You can find new Alfresco All-in-One project ready to go in the <<<artifactId>>> folder.
Usage
Instructions on how to use the Alfresco AMP archetype can be found on the {{{./usage.html}usage page}}, while
for more advanced use cases refer to the {{{./advanced-usage.html}advanced usage page}}

View File

@@ -0,0 +1,83 @@
------
Alfresco Maven All-in-One Archetype Usage
------
Gabriele Columbro
------
Nov 2012
------
Prerequisites
See {{{../../prerequisites.html} SDK Pre-Requisites}} to successfully run this archetype.
Project layout
The archetype generated multi-module project should look like:
+---+
pom.xml
|-> amp
|-> alfresco
|-> share
|-> solr
|-> wcmqs (Alfresco Web Quick Start)
|-> runner (a Jetty embedded runner / integration test runner)
+---+
* Modules
The All-in-One Alfresco project is composed by the following modules:
* <<<amp>>>: An Repository Tier AMP project, demonstrating sample project structure and demo component loading. It can be configured to work for Share
* <<<alfresco>>>: An <<<alfresco.war>>> Repository Extension, overlaying the Alfresco WAR with custom resources / classes
and depending on the <<<amp>>> project
* <<<share>>>: A <<<share.war>>> extension, overlaying the Share WAR with custom resoruces / classes
* <<<solr>>>: An Alfresco <<<alfresco-*-*-solr.zip>>> overlay / customization to configure {{{http://solr.apache.org}Apache Solr}} cores properties
* <<<wcmqs>>>: An Alfresco Web Quick Start overlay / customization. WQS Repository and Share AMPs are also installed on Alfresco and Share.
* <<<runner>>>: A Jetty + H2 runner, capable of running all the aforementioned projects in embedded mode for demo / integration-testing purposes
Usage
The project provides support for typical development lifecycle use cases like
* AMP/WAR packaging
* AMP Unit testing
* run embedded in Jetty + H2 database.
(<<NOTE>>: this is not a {{{http://www.alfresco.com/services/subscription/supported-platforms/} supported stack}} so use <<only for development purposes>>)
* Integration testing
* AMP to WAR installation and overlay (embedding {{{http://wiki.alfresco.com/wiki/Module_Management_Tool}Alfresco Module Managment Tool}})
* release and distribution
for all the components of the Alfresco landscape. For more information, check the See the {{{./advanced-usage.html}advanced usage page}} page.
<<NOTE>>: AMPs produced with this project are fully compatible with Alfresco MMT,in fact the Alfresco Maven plugin - used to manage AMPs in this SDK - embeds the official Alfresco MMT to install depended AMPs.
Commands
* Commands from the root aggregator project
Common Alfresco project lifecycle commands you want to run from the aggregator :
* <<<mvn package>>>: Runs unit tests and packages all customized modules in their respective <<<$\{project.build.directory\}/$\{project.build.finalName\}.amp>>>
* <<<mvn install>>>: Like <<<mvn package>>> but also installs all modules in local Maven repository to be depended upon
* <<<mvn install -Dmaven.test.skip=true>>>: Like <<<mvn install>>> but skips unit tests
* <<<mvn install -Prun>>>: Like <<<mvn install>>> but also trigger the <<<runner>>> project to run Alfresco, Share, Solr and Web Quick Start in Jetty (with H2 embedded database)
* <<<mvn clean -Ppurge>>>: Removes DB, alf_data and log files
* Commands from from the <<<runner>>> project
* <<<mvn jetty:run -Prun'>>> or <<<'mvn integration-test -Prun'>>> to quickly run already packaged webapps

View File

@@ -0,0 +1,33 @@
<project>
<body>
<menu ref="parent" inherit="bottom"/>
<menu name="Alfresco All-in-One Archetype">
<item name="Introduction" href="index.html"/>
<item name="Usage" href="usage.html"/>
<item name="Advanced Usage" href="advanced-usage.html"/>
</menu>
<menu name="SDK components">
<item name="Maven Alfresco SDK" href="../../index.html" />
<item name="Alfresco AMP Archetype" href="../alfresco-amp-archetype/index.html" />
<item name="Alfresco All-in-One Archetype" href="./index.html" />
<item name="Alfresco SDK Parent POM" href="../../poms/alfresco-sdk-parent/index.html" />
<item name="Alfresco Platform Distribution POM" href="https://artifacts.alfresco.com/nexus/content/repositories/alfresco-docs/alfresco-platform-distribution/latest/index.html" />
<item name="Alfresco Maven Plugin" href="../../plugins/alfresco-maven-plugin/index.html" />
</menu>
<menu name="Maven Alfresco Community">
<item name="Alfresco Maven Wiki Docs" href="http://wiki.alfresco.com/wiki/Maven_Alfresco_SDK" />
<item name="Alfresco with Maven for Dummies" href="https://wiki.alfresco.com/wiki/Maven_For_Dummies" />
<item name="Developer Access (Google Code)" href="http://code.google.com/p/maven-alfresco-archetypes/" />
<item name="Gabriele Columbro's blog" href="http://www.mindthegab.com/" />
<item name="Maurizio Pillitu's blog" href="http://www.session.it/" />
<item name="Carlo Sciolla's blog" href="http://skuro.tk/" />
<item name="Enterprise adoption" href="http://www.slideshare.net/guest67a9ba/maven-application-lifecycle-management-for-alfresco" />
</menu>
<!--<menu ref="reports"/>-->
</body>
</project>

View File

@@ -1,11 +1,8 @@
#set( $symbol_pound = '#' )
#set( $symbol_dollar = '$' )
#set( $symbol_escape = '\' )
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry excluding="**" kind="src" output="target/classes" path="src/main/resources"/>
<classpathentry excluding="**" kind="src" output="target/classes" path="src/main/properties"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry excluding="**" kind="src" output="target/test-classes" path="src/test/resources"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.4"/>
<classpathentry kind="con" path="org.maven.ide.eclipse.MAVEN2_CLASSPATH_CONTAINER"/>
<classpathentry kind="output" path="target/classes"/>
</classpath>

View File

@@ -1,9 +1,6 @@
#set( $symbol_pound = '#' )
#set( $symbol_dollar = '$' )
#set( $symbol_escape = '\' )
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>${artifactId}</name>
<name>alfresco-amp-archetype</name>
<comment></comment>
<projects>
</projects>

View File

@@ -0,0 +1,19 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>org.alfresco.maven.archetype</groupId>
<artifactId>alfresco-amp-archetype</artifactId>
<packaging>maven-archetype</packaging>
<name>AMP Archetype from Maven Alfresco SDK</name>
<description>Sample project with full support for lifecycle and rapid development of AMPs (Alfresco Module Packages)</description>
<parent>
<groupId>org.alfresco.maven</groupId>
<artifactId>alfresco-lifecycle-aggregator</artifactId>
<version>1.0</version>
<relativePath>../../pom.xml</relativePath>
</parent>
</project>

View File

@@ -0,0 +1,67 @@
<?xml version="1.0" encoding="UTF-8"?>
<archetype-descriptor xsi:schemaLocation="http://maven.apache.org/plugins/maven-archetype-plugin/archetype-descriptor/1.0.0 http://maven.apache.org/xsd/archetype-descriptor-1.0.0.xsd" name="quickstart-amp-archetype"
xmlns="http://maven.apache.org/plugins/maven-archetype-plugin/archetype-descriptor/1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<requiredProperties>
<requiredProperty key="version">
<defaultValue>1.0-SNAPSHOT</defaultValue>
</requiredProperty>
<requiredProperty key="alfresco_target_groupId">
<defaultValue>org.alfresco</defaultValue>
</requiredProperty>
<requiredProperty key="alfresco_target_version">
<defaultValue>4.2.b</defaultValue>
</requiredProperty>
<requiredProperty key="package">
<defaultValue>(not used)</defaultValue>
</requiredProperty>
</requiredProperties>
<fileSets>
<fileSet filtered="true" packaged="false" encoding="UTF-8">
<directory>src/main/java</directory>
<includes>
<include>**/*.java</include>
</includes>
</fileSet>
<fileSet filtered="false" encoding="UTF-8">
<directory>src/main/amp</directory>
<includes>
<include>**/*.jsp</include>
<include>**/*.xml</include>
<include>**/*.properties</include>
<include>**/*.txt</include>
</includes>
</fileSet>
<fileSet encoding="UTF-8">
<directory>src/main/amp</directory>
<includes>
<include>**/*.js</include>
<include>**/*.css</include>
</includes>
</fileSet>
<fileSet filtered="false" packaged="false" encoding="UTF-8">
<directory>src/test/java</directory>
<includes>
<include>**/*.java</include>
</includes>
</fileSet>
<fileSet filtered="false" encoding="UTF-8">
<directory>src/test/resources</directory>
<includes>
<include>**/*.properties</include>
</includes>
</fileSet>
<fileSet filtered="false" encoding="UTF-8">
<directory>src/test/properties</directory>
<includes>
<include>**/*.properties</include>
</includes>
</fileSet>
<fileSet filtered="false" encoding="UTF-8">
<directory>jetty</directory>
<includes>
<include>**/*.xml</include>
</includes>
</fileSet>
</fileSets>
</archetype-descriptor>

View File

@@ -0,0 +1,16 @@
<?xml version="1.0"?>
<!DOCTYPE Configure PUBLIC "-//Mort Bay Consulting//DTD Configure//EN" "http://jetty.mortbay.org/configure.dtd">
<Configure id="Server" class="org.mortbay.jetty.Server">
<New id="myDataSource"
class="org.mortbay.jetty.plus.naming.Resource">
<Arg>jdbc/dataSource</Arg>
<Arg>
<New class="${alfresco.db.datasource.class}">
<Set name="URL">${alfresco.db.url}</Set>
<Set name="User">${alfresco.db.username}</Set>
<Set name="Password">${alfresco.db.password}</Set>
</New>
</Arg>
</New>
</Configure>

View File

@@ -0,0 +1,85 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>${groupId}</groupId>
<artifactId>${artifactId}</artifactId>
<version>${version}</version>
<name>${artifactId} AMP project</name>
<packaging>amp</packaging>
<description>Manages the lifecycle of the ${artifactId} AMP (Alfresco Module Package)</description>
<parent>
<groupId>org.alfresco.maven</groupId>
<artifactId>alfresco-sdk-parent</artifactId>
<version>1.0</version>
</parent>
<!--
| SDK properties have sensible defaults in the SDK parent,
| but you can override the properties below to use another version.
| For more available properties see the alfresco-sdk-parent POM.
-->
<properties>
<alfresco.groupId>${alfresco_target_groupId}</alfresco.groupId>
<alfresco.version>${alfresco_target_version}</alfresco.version>
<app.log.root.level>WARN</app.log.root.level>
<alfresco.data.location>alf_data_dev</alfresco.data.location>
<!-- Defines the target WAR for this AMP. Allowed values: alfresco | share -->
<!-- Defaults to a repository AMP -->
<alfresco.client.war>alfresco</alfresco.client.war>
<!-- This controls which properties will be picked in src/test/properties for embedded run -->
<env>local</env>
</properties>
<!-- Here we realize the connection with the Alfresco selected platform
(e.g.version and edition) -->
<dependencyManagement>
<dependencies>
<!-- This will import the dependencyManagement for all artifacts in the selected Alfresco version/edition
(see http://maven.apache.org/guides/introduction/introduction-to-dependency-mechanism.html#Importing_Dependencies)
NOTE: You still need to define dependencies in your POM, but you can omit version as it's enforced by this dependencyManagement. NOTE: It defaults
to the latest version this SDK pom has been tested with, but alfresco version can/should be overridden in your project's pom -->
<dependency>
<groupId>${alfresco.groupId}</groupId>
<artifactId>alfresco-platform-distribution</artifactId>
<version>${alfresco.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>
<!-- Following dependencies are needed for compiling Java code in src/main/java;
<scope>provided</scope> is inherited for each of the following;
for more info, please refer to alfresco-platform-distribution POM -->
<dependencies>
<dependency>
<groupId>${alfresco.groupId}</groupId>
<artifactId>alfresco-repository</artifactId>
</dependency>
<!-- Test dependencies -->
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.8.1</version>
<scope>test</scope>
</dependency>
</dependencies>
<!-- This repository is only needed to retrieve Alfresco parent POM.
NOTE: This can be removed when/if Alfresco will be on Maven Central -->
<repositories>
<repository>
<id>alfresco-public</id>
<url>https://artifacts.alfresco.com/nexus/content/groups/public</url>
</repository>
<repository>
<id>alfresco-public-snapshots</id>
<url>https://artifacts.alfresco.com/nexus/content/groups/public-snapshots</url>
<snapshots>
<enabled>true</enabled>
<updatePolicy>daily</updatePolicy>
</snapshots>
</repository>
</repositories>
</project>

View File

@@ -1,4 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?>
<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE beans PUBLIC '-//SPRING//DTD BEAN//EN' 'http://www.springframework.org/dtd/spring-beans.dtd'>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
@@ -6,29 +7,29 @@
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<!DOCTYPE beans PUBLIC '-//SPRING//DTD BEAN//EN' 'http://www.springframework.org/dtd/spring-beans.dtd'>
<beans>
<!-- Registration of new models -->
<bean id="extension.dictionaryBootstrap"
parent="dictionaryModelBootstrap" depends-on="dictionaryBootstrap">
<property name="models">
<list>
<value>alfresco/extension/custom-model.xml</value>
</list>
</property>
</bean>
</beans>
-->
<beans>
<!-- A simple class that is initialized by Spring -->
<bean id="changeme.exampleBean" class="org.alfresco.demoamp.Demo" init-method="init" />
<!-- A simple module component that will be executed once -->
<bean id="changeme.exampleComponent" class="org.alfresco.demoamp.DemoComponent" parent="module.baseComponent" >
<property name="moduleId" value="${project.artifactId}" /> <!-- See module.properties -->
<property name="name" value="exampleComponent" />
<property name="description" value="A demonstration component" />
<property name="sinceVersion" value="2.0" />
<property name="appliesFromVersion" value="2.0" />
<property name="nodeService" ref="NodeService" />
<property name="nodeLocatorService" ref="nodeLocatorService" />
</bean>
</beans>

View File

@@ -0,0 +1,40 @@
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#-----------------------------------------------------------------------
# ${artifactId} module log4j.properties
#
# NOTE
# ----
# Log4j uses the following logging levels:
# debug,info,warn,error,fatal
#
# To set the logging level of {fullClassName} to {loglevel},
# add a line to this file of the following form:
#
# log4j.logger.{fullClassName}={loglevel}
#
# For example, to make 'com.example.MyExample' produce 'debug'
# logs, add a line like this:
#
# log4j.logger.com.example.MyExample=debug
#
#
# WARNING
# -------
# Log properties in this log4j.properties file override/augment
# those in the webapp's main log4j.properties.
#
#-----------------------------------------------------------------------
log4j.logger.org.alfresco.demoamp.DemoComponent=${module.log.level}

View File

@@ -0,0 +1,24 @@
<?xml version='1.0' encoding='UTF-8'?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<!DOCTYPE beans PUBLIC '-//SPRING//DTD BEAN//EN' 'http://www.springframework.org/dtd/spring-beans.dtd'>
<beans>
<!-- This is filtered by Maven at build time, so that module name is single sourced. -->
<import resource="classpath:alfresco/module/${project.artifactId}/context/service-context.xml" />
</beans>

View File

@@ -0,0 +1,4 @@
# Define here logging properties for your AMP specific classes
# This will end up in alfresco.war/WEB-INF/classes/alfresco/module/log4j.properties
# and loaded as per http://wiki.alfresco.com/wiki/Developing_an_Alfresco_Module#log4j.properties
log4j.logger.org.alfresco.demoamp=DEBUG

View File

@@ -0,0 +1,48 @@
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# SDK Sample module
# ==== Beginning of Alfresco required/optional properties ====== #
# NB: These properties are filtered at build time by Maven, single
# sourcing from POM properties
module.id=${project.artifactId}
#module.aliases=myModule-123, my-module
module.title=${project.name}
module.description=${project.description}
module.version=${noSnapshotVersion}
# The following optional properties can be used to prevent the module from being added
# to inappropriate versions of the WAR file.
# module.repo.version.min=2.0
# module.repo.version.max=2.1
# FIXME: This dependencies should come out of mvn dependencies on amp
# The following describe dependencies on other modules
# Depends on net.sf.myproject.module.SupportModuleA version ${version} or later
# module.depends.net.sf.myproject.module.SupportModuleA=${version}-*
# Depends on net.sf.myproject.module.SupportModuleA version ${version} to 2.0
# module.depends.net.sf.myproject.module.SupportModuleB=${version}-2.0
# Depends on net.sf.myproject.module.SupportModuleC - any version
# module.depends.net.sf.myproject.module.SupportModuleB=*
# ==== End of Alfresco required/optional properties ======= #
# ==== Beginning of module required properties/optional ====== #

View File

@@ -1,41 +1,16 @@
/*
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
package org.alfresco.demoamp;
import java.util.logging.Logger;
import org.alfresco.repo.module.AbstractModuleComponent;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
/**
* A basic component that will be started for this module.
*
* @author Derek Hulley
*/
public class DemoComponent extends AbstractModuleComponent
{
Log log = LogFactory.getLog(DemoComponent.class);
@Override
protected void executeInternal() throws Throwable
{
System.out.println("DemoComponent has been executed");
log.debug("Test debug logging is working");
log.info("This should not be outputted by default");
}
}
/*
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/

View File

@@ -0,0 +1,19 @@
#set( $symbol_pound = '#' )
#set( $symbol_dollar = '$' )
#set( $symbol_escape = '\' )
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->

View File

@@ -0,0 +1,2 @@
This folder (root in the AMP) gets mapped automagically in WEB-INF/licenses
by the MMT or the alfresco-maven-plugin

View File

@@ -0,0 +1,16 @@
/*
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/

View File

@@ -26,7 +26,7 @@ package org.alfresco.demoamp;
/**
* This class does nothing except dump some output to <i>system.out</i>.
*
* NB: This code is taken from Alfresco Eclipse SDK Samples
* @author Derek Hulley
*/
public class Demo

View File

@@ -0,0 +1,85 @@
/*
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
package org.alfresco.demoamp;
import org.alfresco.model.ContentModel;
import org.alfresco.repo.module.AbstractModuleComponent;
import org.alfresco.repo.nodelocator.NodeLocatorService;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.repository.NodeService;
import org.alfresco.service.cmr.repository.StoreRef;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
/**
* A basic component that will be started for this module.
* Uses the NodeLocatorService to easily find nodes and the
* NodeService to display them
*
* @author Gabriele Columbro
* @author Maurizio Pillitu
*/
public class DemoComponent extends AbstractModuleComponent
{
Log log = LogFactory.getLog(DemoComponent.class);
private NodeService nodeService;
private NodeLocatorService nodeLocatorService;
public void setNodeService(NodeService nodeService) {
this.nodeService = nodeService;
}
public void setNodeLocatorService(NodeLocatorService nodeLocatorService) {
this.nodeLocatorService = nodeLocatorService;
}
/**
* Bogus component execution
*/
@Override
protected void executeInternal() throws Throwable
{
System.out.println("DemoComponent has been executed");
log.debug("Test debug logging. Congratulation your AMP is working");
log.info("This is only for information purposed. Better remove me from the log in Production");
}
/**
* This is a demo service interaction with Alfresco Foundation API.
* This sample method returns the number of child nodes of a certain type
* under a certain node.
*
* @return
*/
public int childNodesCount(NodeRef nodeRef)
{
return nodeService.countChildAssocs(nodeRef, true);
}
/**
* Returns the NodeRef of "Company Home"
*
* @return
*/
public NodeRef getCompanyHome()
{
return nodeLocatorService.getNode("companyhome", null, null);
}
}

View File

@@ -0,0 +1,77 @@
package org.alfresco.demoamp.test;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;
import org.alfresco.demoamp.DemoComponent;
import org.alfresco.model.ContentModel;
import org.alfresco.repo.security.authentication.AuthenticationUtil;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.repository.NodeService;
import org.alfresco.util.ApplicationContextHelper;
import org.apache.log4j.Logger;
import org.junit.BeforeClass;
import org.junit.Test;
import org.springframework.context.ApplicationContext;
/**
* A simple class demonstrating how to run out-of-container tests
* loading Alfresco application context.
*
* @author columbro
*
*/
public class DemoComponentTest {
private static final String ADMIN_USER_NAME = "admin";
static Logger log = Logger.getLogger(DemoComponentTest.class);
protected static ApplicationContext applicationContext;
protected static DemoComponent demoComponent;
protected static NodeService nodeService;
@BeforeClass
public static void initAppContext()
{
// TODO: Make testing properly working without need for helpers
// TODO: Provide this in an SDK base class
ApplicationContextHelper.setUseLazyLoading(false);
ApplicationContextHelper.setNoAutoStart(true);
applicationContext = ApplicationContextHelper.getApplicationContext(new String[] { "classpath:alfresco/application-context.xml" });
demoComponent = (DemoComponent) applicationContext.getBean("changeme.exampleComponent");
nodeService = (NodeService) applicationContext.getBean("NodeService");
AuthenticationUtil.setFullyAuthenticatedUser(ADMIN_USER_NAME);
log.debug("Sample test logging: If you see this message, means your unit test logging is properly configured. Change it in test-log4j.properties");
log.debug("Sample test logging: Application Context properly loaded");
}
@Test
public void testWiring() {
assertNotNull(demoComponent);
}
@Test
public void testGetCompanyHome() {
NodeRef companyHome = demoComponent.getCompanyHome();
assertNotNull(companyHome);
String companyHomeName = (String) nodeService.getProperty(companyHome, ContentModel.PROP_NAME);
assertNotNull(companyHomeName);
assertEquals("Company Home", companyHomeName);
}
@Test
public void testChildNodesCount() {
NodeRef companyHome = demoComponent.getCompanyHome();
int childNodeCount = demoComponent.childNodesCount(companyHome);
assertNotNull(childNodeCount);
// There are 5 folders by default under Company Home
assertEquals(5, childNodeCount);
}
}

View File

@@ -0,0 +1,59 @@
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# RUN TIME PROPERTIES
# -------------------
# Sample custom content and index data location
# This will create alf_data Relative to appserver run folder
# In this default file we take the property from the POM (for compatbility with local jetty and jboss deployments) but it can also be edited here.
dir.root=${alfresco.data.location}
# Allowed values are: NONE, AUTO, FULL
index.recovery.mode=NONE
# As we run embedded, we set Lucene
index.subsystem.name=lucene
#dir.keystore=.
#keystore.password=storepassword
#metadata.password=metapassword
# Fail or not when there are node integrity checker errors
integrity.failOnError=true
# Database connection properties
# These are also filtered from Maven at build time from POM properties.
# Alternatively you can directly define them directly here
db.driver=${alfresco.db.datasource.class}
db.url=${alfresco.db.url}
db.username=${alfresco.db.username}
db.password=${alfresco.db.password}
db.pool.initial=10
db.pool.max=100
# File servers related properties
# For local builds we disable CIFS and FTP. Edit the following property to reenable them
smb.server.enabled=false
smb.server.name=CFS_SHARE_LOCAL
smb.server.domain=mycompany.com
smb.server.bindto=127.0.0.1
smb.tcpip.port=1445
netbios.session.port=1139
netbios.name.port=1137
netbios.datagram.port=1138
ftp.server.enables=false
ftp.port=1121
ftp.authenticator=alfresco

View File

@@ -0,0 +1,266 @@
# This is a full override of Alfresco 4.2.b log4j.properties
# This file overwrites the alfresco.war log4j.properties
# Set root logger level to error
log4j.rootLogger=${app.log.root.level}, Console, File
###### Console appender definition #######
# All outputs currently set to be a ConsoleAppender.
log4j.appender.Console=org.apache.log4j.ConsoleAppender
log4j.appender.Console.layout=org.apache.log4j.PatternLayout
# use log4j NDC to replace %x with tenant domain / username
log4j.appender.Console.layout.ConversionPattern=%d{ISO8601} %x %-5p [%c{3}] [%t] %m%n
#log4j.appender.Console.layout.ConversionPattern=%d{ABSOLUTE} %-5p [%c] %m%n
###### File appender definition #######
log4j.appender.File=org.apache.log4j.DailyRollingFileAppender
log4j.appender.File.File=${app.log.dir}alfresco.log
log4j.appender.File.Append=true
log4j.appender.File.DatePattern='.'yyyy-MM-dd
log4j.appender.File.layout=org.apache.log4j.PatternLayout
log4j.appender.File.layout.ConversionPattern=%d{ABSOLUTE} %-5p [%c] %m%n
###### Hibernate specific appender definition #######
#log4j.appender.file=org.apache.log4j.FileAppender
#log4j.appender.file.File=hibernate.log
#log4j.appender.file.layout=org.apache.log4j.PatternLayout
#log4j.appender.file.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L - %m%n
###### Log level overrides #######
# Commented-in loggers will be exposed as JMX MBeans (refer to org.alfresco.repo.admin.Log4JHierarchyInit)
# Hence, generally useful loggers should be listed with at least ERROR level to allow simple runtime
# control of the level via a suitable JMX Console. Also, any other loggers can be added transiently via
# Log4j addLoggerMBean as long as the logger exists and has been loaded.
# Hibernate
log4j.logger.org.hibernate=error
log4j.logger.org.hibernate.util.JDBCExceptionReporter=fatal
log4j.logger.org.hibernate.event.def.AbstractFlushingEventListener=fatal
log4j.logger.org.hibernate.type=warn
log4j.logger.org.hibernate.cfg.SettingsFactory=warn
# Spring
log4j.logger.org.springframework=warn
# Turn off Spring remoting warnings that should really be info or debug.
log4j.logger.org.springframework.remoting.support=error
log4j.logger.org.springframework.util=error
# Axis/WSS4J
log4j.logger.org.apache.axis=info
log4j.logger.org.apache.ws=info
# CXF
log4j.logger.org.apache.cxf=error
# MyFaces
log4j.logger.org.apache.myfaces.util.DebugUtils=info
log4j.logger.org.apache.myfaces.el.VariableResolverImpl=error
log4j.logger.org.apache.myfaces.application.jsp.JspViewHandlerImpl=error
log4j.logger.org.apache.myfaces.taglib=error
# OpenOfficeConnection
log4j.logger.net.sf.jooreports.openoffice.connection=fatal
# log prepared statement cache activity ###
log4j.logger.org.hibernate.ps.PreparedStatementCache=info
# Alfresco
log4j.logger.org.alfresco=error
log4j.logger.org.alfresco.repo.admin=info
log4j.logger.org.alfresco.repo.cache.TransactionalCache=warn
log4j.logger.org.alfresco.repo.model.filefolder=warn
log4j.logger.org.alfresco.repo.tenant=info
log4j.logger.org.alfresco.repo.avm=info
log4j.logger.org.alfresco.config=warn
log4j.logger.org.alfresco.config.JndiObjectFactoryBean=warn
log4j.logger.org.alfresco.config.JBossEnabledWebApplicationContext=warn
log4j.logger.org.alfresco.repo.management.subsystems=warn
log4j.logger.org.alfresco.repo.management.subsystems.ChildApplicationContextFactory=info
log4j.logger.org.alfresco.repo.management.subsystems.ChildApplicationContextFactory$ChildApplicationContext=warn
log4j.logger.org.alfresco.repo.security.sync=info
log4j.logger.org.alfresco.repo.security.person=info
log4j.logger.org.alfresco.sample=info
log4j.logger.org.alfresco.web=info
#log4j.logger.org.alfresco.web.app.AlfrescoNavigationHandler=debug
#log4j.logger.org.alfresco.web.ui.repo.component.UIActions=debug
#log4j.logger.org.alfresco.web.ui.repo.tag.PageTag=debug
#log4j.logger.org.alfresco.web.bean.clipboard=debug
log4j.logger.org.alfresco.repo.webservice=info
log4j.logger.org.alfresco.service.descriptor.DescriptorService=info
#log4j.logger.org.alfresco.web.page=debug
log4j.logger.org.alfresco.repo.importer.ImporterBootstrap=error
#log4j.logger.org.alfresco.repo.importer.ImporterBootstrap=info
log4j.logger.org.alfresco.web.ui.common.Utils=error
#log4j.logger.org.alfresco.web.ui.common.Utils=info
log4j.logger.org.alfresco.repo.admin.patch.PatchExecuter=info
log4j.logger.org.alfresco.repo.domain.patch.ibatis.PatchDAOImpl=info
# Specific patches
log4j.logger.org.alfresco.repo.admin.patch.impl.DeploymentMigrationPatch=info
log4j.logger.org.alfresco.repo.version.VersionMigrator=info
log4j.logger.org.alfresco.repo.admin.patch.impl.ResetWCMToGroupBasedPermissionsPatch=info
log4j.logger.org.alfresco.repo.module.ModuleServiceImpl=info
log4j.logger.org.alfresco.repo.domain.schema.SchemaBootstrap=info
log4j.logger.org.alfresco.repo.admin.ConfigurationChecker=info
log4j.logger.org.alfresco.repo.node.index.AbstractReindexComponent=warn
log4j.logger.org.alfresco.repo.node.index.IndexTransactionTracker=warn
log4j.logger.org.alfresco.repo.node.index.FullIndexRecoveryComponent=info
log4j.logger.org.alfresco.repo.node.index.AVMFullIndexRecoveryComponent=info
log4j.logger.org.alfresco.util.OpenOfficeConnectionTester=info
log4j.logger.org.alfresco.repo.node.db.hibernate.HibernateNodeDaoServiceImpl=warn
log4j.logger.org.alfresco.repo.domain.hibernate.DirtySessionMethodInterceptor=warn
log4j.logger.org.alfresco.repo.transaction.RetryingTransactionHelper=warn
log4j.logger.org.alfresco.util.transaction.SpringAwareUserTransaction.trace=warn
log4j.logger.org.alfresco.util.AbstractTriggerBean=warn
log4j.logger.org.alfresco.enterprise.repo.cache.cluster.KeepAliveHeartbeatReceiver=info
log4j.logger.org.alfresco.repo.version.Version2ServiceImpl=warn
#log4j.logger.org.alfresco.web.app.DebugPhaseListener=debug
log4j.logger.org.alfresco.repo.workflow=info
# CIFS server debugging
log4j.logger.org.alfresco.smb.protocol=error
#log4j.logger.org.alfresco.smb.protocol.auth=debug
#log4j.logger.org.alfresco.acegi=debug
# FTP server debugging
log4j.logger.org.alfresco.ftp.protocol=error
#log4j.logger.org.alfresco.ftp.server=debug
# WebDAV debugging
#log4j.logger.org.alfresco.webdav.protocol=debug
log4j.logger.org.alfresco.webdav.protocol=error
# NTLM servlet filters
#log4j.logger.org.alfresco.web.app.servlet.NTLMAuthenticationFilter=debug
#log4j.logger.org.alfresco.repo.webdav.auth.NTLMAuthenticationFilter=debug
# Kerberos servlet filters
#log4j.logger.org.alfresco.web.app.servlet.KerberosAuthenticationFilter=debug
#log4j.logger.org.alfresco.repo.webdav.auth.KerberosAuthenticationFilter=debug
# File servers
log4j.logger.org.alfresco.fileserver=warn
# Repo filesystem debug logging
#log4j.logger.org.alfresco.filesys.repo.ContentDiskDriver=debug
# AVM filesystem debug logging
#log4j.logger.org.alfresco.filesys.avm.AVMDiskDriver=debug
# Integrity message threshold - if 'failOnViolation' is off, then WARNINGS are generated
log4j.logger.org.alfresco.repo.node.integrity=ERROR
# Indexer debugging
log4j.logger.org.alfresco.repo.search.Indexer=error
#log4j.logger.org.alfresco.repo.search.Indexer=debug
log4j.logger.org.alfresco.repo.search.impl.lucene.index=error
log4j.logger.org.alfresco.repo.search.impl.lucene.fts.FullTextSearchIndexerImpl=warn
#log4j.logger.org.alfresco.repo.search.impl.lucene.index=DEBUG
# Audit debugging
# log4j.logger.org.alfresco.repo.audit=DEBUG
# log4j.logger.org.alfresco.repo.audit.model=DEBUG
# Forms debugging
# log4j.logger.org.alfresco.web.forms=debug
# log4j.logger.org.chiba.xml.xforms=debug
log4j.logger.org.alfresco.web.forms.xforms.XFormsBean=error
log4j.logger.org.alfresco.web.forms.XSLTRenderingEngine=error
# Property sheet and modelling debugging
# change to error to hide the warnings about missing properties and associations
log4j.logger.alfresco.missingProperties=warn
log4j.logger.org.alfresco.web.ui.repo.component.property.UIChildAssociation=warn
log4j.logger.org.alfresco.web.ui.repo.component.property.UIAssociation=warn
#log4j.logger.org.alfresco.web.ui.repo.component.property=debug
# Dictionary/Model debugging
log4j.logger.org.alfresco.repo.dictionary=warn
log4j.logger.org.alfresco.repo.dictionary.types.period=warn
# Virtualization Server Registry
log4j.logger.org.alfresco.mbeans.VirtServerRegistry=error
# Spring context runtime property setter
log4j.logger.org.alfresco.util.RuntimeSystemPropertiesSetter=info
# Debugging options for clustering
log4j.logger.org.alfresco.repo.content.ReplicatingContentStore=error
log4j.logger.org.alfresco.repo.content.replication=error
#log4j.logger.org.alfresco.repo.deploy.DeploymentServiceImpl=debug
# Activity service
log4j.logger.org.alfresco.repo.activities=warn
# User usage tracking
log4j.logger.org.alfresco.repo.usage=info
# Sharepoint
log4j.logger.org.alfresco.module.vti=info
# Forms Engine
log4j.logger.org.alfresco.repo.forms=info
log4j.logger.org.alfresco.web.config.forms=info
log4j.logger.org.alfresco.web.scripts.forms=info
# CMIS
log4j.logger.org.alfresco.opencmis=error
log4j.logger.org.alfresco.opencmis.AlfrescoCmisServiceInterceptor=error
log4j.logger.org.alfresco.cmis=error
log4j.logger.org.alfresco.cmis.dictionary=warn
log4j.logger.org.apache.chemistry.opencmis=info
# IMAP
log4j.logger.org.alfresco.repo.imap=info
# JBPM
# Note: non-fatal errors (eg. logged during job execution) should be handled by Alfresco's retrying transaction handler
log4j.logger.org.jbpm.graph.def.GraphElement=fatal
#log4j.logger.org.alfresco.repo.googledocs=debug
###### Scripting #######
# Web Framework
log4j.logger.org.springframework.extensions.webscripts=info
log4j.logger.org.springframework.extensions.webscripts.ScriptLogger=warn
log4j.logger.org.springframework.extensions.webscripts.ScriptDebugger=off
# Repository
log4j.logger.org.alfresco.repo.web.scripts=warn
log4j.logger.org.alfresco.repo.web.scripts.BaseWebScriptTest=info
log4j.logger.org.alfresco.repo.web.scripts.AlfrescoRhinoScriptDebugger=off
log4j.logger.org.alfresco.repo.jscript=error
log4j.logger.org.alfresco.repo.jscript.ScriptLogger=warn
log4j.logger.org.alfresco.repo.cmis.rest.CMISTest=info
log4j.logger.org.alfresco.repo.avm.actions=info
# Freemarker
# Note the freemarker.runtime logger is used to log non-fatal errors that are handled by Alfresco's retrying transaction handler
log4j.logger.freemarker.runtime=
# Metadata extraction
log4j.logger.org.alfresco.repo.content.metadata.AbstractMappingMetadataExtracter=warn
# Reduces PDFont error level due to ALF-7105
log4j.logger.org.apache.pdfbox.pdmodel.font.PDSimpleFont=fatal
log4j.logger.org.apache.pdfbox.pdmodel.font.PDFont=fatal
log4j.logger.org.apache.pdfbox.pdmodel.font.PDCIDFont=fatal
# no index support
log4j.logger.org.alfresco.repo.search.impl.noindex.NoIndexIndexer=fatal
log4j.logger.org.alfresco.repo.search.impl.noindex.NoIndexSearchService=fatal
log4j.logger.org.alfresco.demoamp.test=DEBUG

View File

@@ -0,0 +1,59 @@
------
Alfresco Maven AMP Archetype Advanced Usage
------
Gabriele Columbro
------
Nov 2012
------
AMP Unit Testing
Unit test your AMP customization is as easy as adding your tests in <<<src/test/java>>>. The current module in development
will be added to the test classpath together with all necessary Alfresco Spring contexts.
Running <<<mvn test>>> will results in your unit tests to be run. You can skip this (<<<not recommended>>>)
adding <<<-DskipTests>>> to your command line.
AMP Archetype properties
In the AMP archetype (as in the whole Part of the Maven Alfresco SDK\x99) properties are configurable at many levels:
* as POM properties
* direclty in *.properties, particularly
* <<<src/main/amp/module.properties>>> (filtered and packaged in the AMP)
* <<<src/test/properties/<env>/alfresco-global.properties>>> (environment dependent properties for WAR run embedded)
* Common properties
Archetype behavior can mostly be controlled directly in the POM, via common properties provided by the parent POM.
See {{{../../poms/alfresco-sdk-parent/sdk-properties.html} SDK properties reference}} for details.
* AMP specific properties
In addition to the common properties, the following properties are specific of the AMP archetype:
+---+
<project>
...
<properties>
<!--
Determines the target WAR for this AMP
Allowed values: alfresco (default) | share
-->
<alfresco.client.war>alfresco</alfresco.client.war>
</properties>
...
</project>
+---+
Parent POM and behavior customization
To customize the behavior of your project, check out full set of the properties and plugin configurations defined in the
{{{../../poms/alfresco-sdk-parent/index.html}single entry point parent POM}}.
One quick way to do that is to use the <<<maven-help-plugin:effective-pom>>> to analyze your POM at runtime.

View File

@@ -0,0 +1,51 @@
------
Building AMPs (Alfresco Module Packages) with Maven
------
Gabriele Columbro
------
Nov 2012
------
Introduction
The Alfresco AMP Archetype is a sample fully featured project to manage AMP (Alfresco Module Package) projects.
This archetype can be used both for Alfresco Repository and Alfresco Share AMPs.
* Features
Amongst other features, this archetype provides support for:
* <<<amp>>> packaging support for your projects
* AMP dependency management in Maven
* Installation of AMPs in an Alfresco or Share WAR
* AMP Unit Testing support. Just run the standard <<<mvn test>>> and see your <<<src/test/java>>> Alfresco unit tests run.
An sample Unit Test is provided in this archetype.
* Embedded run in Jetty and embedded H2 database for demo purposes, rapid application development and integration testing
(<<NOTE>>: this is not a {{{http://www.alfresco.com/services/subscription/supported-platforms/} supported stack}} so use <<only for development purposes>>)
How to create a project:
You can create the latest release archetype with the following command:
+---+
mvn archetype:generate -DarchetypeCatalog=https://artifacts.alfresco.com/nexus/content/groups/public/archetype-catalog.xml
+---+
You should then:
[[1]] Select the <<<alfresco-amp-archetype>>> option
[[2]] Specify the <<<groupId>>> and <<<artifactId>>> for the project you want to create
[[3]] (<Optionally>) Select Alfresco Version / Edition (current default is: Alfresco Community 4.2.b)
You can find new Alfresco AMP project ready to go in the <<<artifactId>>> folder.
Usage
Instructions on how to use the Alfresco AMP archetype can be found on the {{{./usage.html}usage page}}, while
for more advanced use cases refer to the {{{./advanced-usage.html}advanced usage page}}

View File

@@ -0,0 +1,72 @@
------
Alfresco Maven AMP Archetype Usage
------
Gabriele Columbro
------
Nov 2012
------
Prerequisites
See {{{../../prerequisites.html}SDK Pre-Requisites}} to successfully run this archetype.
Project layout
The archetype generated project should look like:
+---+
pom.xml
src/main/amp
|-> module.properties
|-> file-mappings.properties (optional)
|-> config/
|-> web/
|-> licenses/
src/main/java //Java classes to be packaged in the AMP embedded JAR)
src/main/resources //resources to the packaged in the AMP embedded JAR)
src/test/java // Unit tests
src/test/resources // Unit test resources
src/test/properties/<env> // Environment aware alfresco-global.properties. By default <env>=local
+---+
Basically by default the folder <<<src/main/amp>>> maps the {{{https://wiki.alfresco.com/wiki/AMP_Files#The_structure_of_an_AMP_file}AMP structure}} and it's where you can build your module.
Usage
This project manages an AMP and provides support for typical development lifecycle use cases like:
* packaging
* testing
* run embedded
* integration testing
* release and distribution of your AMP artifact.
The AMPs produced with this project are fully compatible with Alfresco MMT, in fact the Alfresco Maven plugin used to manage AMPs in this SDK embeds the official Alfresco MMT to install depdended AMPs.
Commands
Common AMP project lifecycle commands you want to run are:
* <<<mvn package>>>: Runs unit tests and packages AMP in <<<$\{project.build.directory\}/$\{project.build.finalName\}.amp>>>
* <<<mvn install>>>: Like <<<mvn package>>> but also installs AMP in local Maven repository to be depended upon
* <<<mvn install -Dmaven.test.skip=true>>>: Like <<<mvn install>>> but skips unit tests
* <<<mvn package -Pamp-to-war>>>: Like <<<mvn package>>> but also installs the AMP onto an Alfresco WAR.
* <<<mvn integration-test -Pamp-to-war>>> Like <<<mvn package -Pamp-to-war>>>
but also runs the resulting WAR+AMP in Jetty + H2 embedded for integration testing
* <<<mvn integration-test -Pamp-to-war -Dalfresco.client.war=share>>>: Like <<<mvn integration-test -Pamp-to-war>>> but installs the AMP and runs on the Share WAR in Jetty embedded.
* <<<mvn clean -Ppurge>>>: Removes DB, alf_data, indexes and log files. Useful to purge the development repo (by default self contained in <<<$\{project.basedir\}/alf_data_dev>>>

View File

@@ -0,0 +1,34 @@
<project>
<body>
<menu ref="parent" inherit="bottom"/>
<menu name="Alfresco AMP Archetype">
<item name="Introduction" href="index.html"/>
<item name="Usage" href="usage.html"/>
<item name="Advanced Usage" href="advanced-usage.html"/>
</menu>
<menu name="SDK components">
<item name="Maven Alfresco SDK" href="../../index.html" />
<item name="Alfresco AMP Archetype" href="./index.html" />
<item name="Alfresco All-in-One Archetype" href="../alfresco-allinone-archetype/index.html" />
<item name="Alfresco SDK Parent POM" href="../../poms/alfresco-sdk-parent/index.html" />
<item name="Alfresco Platform Distribution POM" href="https://artifacts.alfresco.com/nexus/content/repositories/alfresco-docs/alfresco-platform-distribution/latest/index.html" />
<item name="Alfresco Maven Plugin" href="../../plugins/alfresco-maven-plugin/index.html" />
</menu>
<menu name="Maven Alfresco Community">
<item name="Alfresco Maven Wiki Docs" href="http://wiki.alfresco.com/wiki/Maven_Alfresco_SDK" />
<item name="Alfresco with Maven for Dummies" href="https://wiki.alfresco.com/wiki/Maven_For_Dummies" />
<item name="Developer Access (Google Code)" href="http://code.google.com/p/maven-alfresco-archetypes/" />
<item name="Gabriele Columbro's blog" href="http://www.mindthegab.com/" />
<item name="Maurizio Pillitu's blog" href="http://www.session.it/" />
<item name="Carlo Sciolla's blog" href="http://skuro.tk/" />
<item name="Enterprise adoption" href="http://www.slideshare.net/guest67a9ba/maven-application-lifecycle-management-for-alfresco" />
</menu>
<!-- maybe it's inherited? -->
<!--<menu ref="reports"/>-->
</body>
</project>

View File

@@ -0,0 +1,8 @@
#Tue Oct 30 14:23:01 CET 2012
package=it.pkg
version=0.1-SNAPSHOT
groupId=archetype.it
alfresco_target_version=4.2.b
$=cat archetype.properties
alfresco_target_groupId=org.alfresco
artifactId=basic

View File

@@ -1,46 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<artifactId>maven-alfresco-amp-archetype</artifactId>
<packaging>maven-archetype</packaging>
<name>Maven Alfresco Amp Archetype</name>
<description>
This archetype aims to provide a standardized approach to development, release and deployment of Alfresco AMPs (as opposed to Alfresco
extensions, released as a different artifact ). Using standard m2 lifecycle commands (mvn compile package deploy) and generally available
plugins (cargo, release, assembly) we are able to cover a very high percentage of Alfresco lifecycle common use cases. You are able within
minutes to have a compatible AMP module built and its lifecycle supported by Maven, in a fully transparent way also with open source available
AMPs.
</description>
<parent>
<groupId>com.sourcesense.alfresco</groupId>
<artifactId>maven-alfresco-archetypes</artifactId>
<version>1.9.1-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>
<build>
<extensions>
<extension>
<groupId>org.apache.maven.archetype</groupId>
<artifactId>archetype-packaging</artifactId>
<version>2.0-alpha-3</version>
</extension>
</extensions>
</build>
</project>

View File

@@ -1,39 +0,0 @@
<document>
<properties>
<title>Maven Alfresco AMP archetype</title>
<author email="gabriele.columbro@alfresco.com">Gabriele Columbro</author>
</properties>
<body>
<release version="1.9.1" date="2009-12-07"
description="Moved to maven.alfresco.com">
<action dev="columbro" type="add">
Moved to http://maven.alfresco.com
</action>
<action dev="columbro" type="fix">
Fixed version of maven-buildnumber-plugin (for compatibility issues with maven 2.2.1)
</action>
<action dev="columbro" type="update">
Documented versioning scheme and maven-nosnapshot-plugin
</action>
</release>
<release version="1.0.0" date="2008-07-06" description="Public release">
<action dev="g.columbro" type="add">
Added full AMP lifecycle management
</action>
</release>
<release version="1.9.0" date="2009-11-07"
description="Public release alfresco 3.2r based">
<action dev="g.columbro" type="add">
Updated to Alfresco 3.2r artifacts
</action>
<action dev="g.columbro" type="add">
Updated to new Sourcesense repository
</action>
</release>
<release version="1.0.0" date="2008-07-06" description="Public release">
<action dev="g.columbro" type="add">
Added full AMP lifecycle management
</action>
</release>
</body>
</document>

View File

@@ -1,60 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?><archetype-descriptor name="test">
<fileSets>
<fileSet filtered="false" packaged="true" encoding="UTF-8">
<directory>src/main/java</directory>
<includes>
<include>**/*.java</include>
</includes>
</fileSet>
<fileSet filtered="false" encoding="UTF-8">
<directory>src/main/webapp</directory>
<includes>
<include>**/*.txt</include>
<include>**/*.jsp</include>
</includes>
</fileSet>
<fileSet filtered="false" encoding="UTF-8">
<directory>src/main/config</directory>
<includes>
<include>**/*.xml</include>
<include>**/*.properties</include>
</includes>
</fileSet>
<fileSet filtered="false" encoding="UTF-8">
<directory>src/main/resources</directory>
<includes>
<include>**/*.xml</include>
<include>**/*.properties</include>
</includes>
</fileSet>
<fileSet encoding="UTF-8">
<directory>src/main/webapp</directory>
<includes>
<include>**/*.js</include>
<include>**/*.gif</include>
<include>**/*.css</include>
</includes>
</fileSet>
<fileSet filtered="false" encoding="UTF-8">
<directory>src/test/properties</directory>
<includes>
<include>**/*.properties</include>
</includes>
</fileSet>
<fileSet filtered="false" encoding="UTF-8">
<directory>src/test/resources</directory>
<includes>
<include>**/*.xml</include>
<include>**/*.properties</include>
</includes>
</fileSet>
<fileSet filtered="false" encoding="UTF-8">
<directory></directory>
<includes>
<include>module.properties</include>
<include>README.txt</include>
<include>TODO.txt</include>
</includes>
</fileSet>
</fileSets>
</archetype-descriptor>

View File

@@ -1,26 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?><archetype>
<id>maven-alfresco-amp-archetype</id>
<sources>
<source>src/main/java/com/sourcesense/demoamp/Demo.java</source>
<source>src/main/java/com/sourcesense/demoamp/DemoComponent.java</source>
</sources>
<resources>
<resource filtered="false">src/main/config/context/service-context.xml</resource>
<resource filtered="false">src/main/config/log4j.properties</resource>
<resource filtered="false">src/main/config/module-context.xml</resource>
<resource filtered="false">src/main/webapp/css/demoamp.css</resource>
<resource filtered="false">src/main/webapp/images/sourcesense.gif</resource>
<resource filtered="false">src/main/webapp/jsp/demoamp.jsp</resource>
<resource filtered="false">src/main/webapp/licenses/README-licenses.txt</resource>
<resource filtered="false">src/main/webapp/scripts/demoamp.js</resource>
<resource filtered="false">module.properties</resource>
<resource filtered="false">README.txt</resource>
<resource filtered="false">TODO.txt</resource>
</resources>
<testResources>
<resource filtered="false">src/test/properties/local/application.properties</resource>
<resource filtered="false">src/test/resources/alfresco/extension/custom-repository-context.xml</resource>
<resource filtered="false">src/test/resources/alfresco/extension/file-servers-custom.xml</resource>
<resource filtered="false">src/test/resources/log4j.properties</resource>
</testResources>
</archetype>

View File

@@ -1,95 +0,0 @@
======================================================================
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
======================================================================
---------------------------------------
Archetype Release: Archetype - maven-amp-archetype
Author: g.columbro@sourcesense.com
http://forge.alfresco.com/m2alfresco
Contacts:
- alfresco-dev@lists.sourcesense.com (developer)
- alfresco@sourcesense.com (commercial)
See Also:
http://wiki.alfresco.com/wiki/Module_Management_Tool
-----------------------------------------------------
M2 Instructions for Alfresco AMP:
--------------------------------
The project can be built using Maven2.
Alfresco maven2 AMP build
-------------------------
One command quickstart:
$ MAVEN_OPTS="-Xms256m -Xmx512m -XX:PermSize=128m" mvn clean integration-test -P webapp
Runs the jetty embedded with overlayed the currently developed AMP
FEATURES:
---------
- AMP customized build : mvn clean package
- AMP dependencies management: 'mvn clean package' can take care of overlay deps
- Alfresco webapp integration via war creation mvn clean package -P webapp
- jetty embedded build for fast testing, mvn clean integration-test -P webapp
- install/deployment of Alfresco compatible AMPs on a m2 repo mvn install / deploy [ params ]
- using the maven-amp-plugin (http://forge.alfresco.com/maven4alfresco) WAR can depend on AMP artifacts and have them overlayed within the maven
lifecycle, avoiding the boring MMT run.
Specific dependencies and different Alfresco versions can be specified in 'webapp' profile dependecies. Alfresco test webapp is overlayed (apart with
all AMP and WAR dependencies specified) also with a sensible default 'alfresco/extension' folder to have a clean safe reproduceable and portable
default alfresco run. Find these test configuaration files in 'src/test/resources' and environment dependent properties in src/test/properties/<env>/application.properties
PROJECT LAYOUT
--------------
src --------------------------------------------------------> (source folder)
|
|__ main ___ __ resources --------------------------> mapped in the classpath. Add here classpath resources
| |
| |__ config----- alfresco module config goes here.
| | | Get's copied (by best practice) by build into package alfresco/module/groupId.artifactId.
| | | This convention is used by the archetype and by the AMP unpacker.
| | |__ ex: alfresco/module/com.sourcesense.alfresco.mymodule ---> Example Alfresco module config
| |
| |
| |__ java -------------------------------> customization java classes
| |
| |__ webapp -----------------------------> AMP overlay folder - this folder is overlayed (so may overwrite other dependent AMPs)
|
|__ test __ __ resources
|
| | |__ alfresco/extension ---> alfresco overriding Spring contexts
| |__ properties -------------------------> environment aware application properties files
| | |
| | |__ local -------------> default application.properties
| |
|
target - Project build dir

View File

@@ -1,34 +0,0 @@
======================================================================
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
======================================================================
Known Issues:
-------------
MAJOR:
MINOR:
- cannot use maven SNAPSHOT versioning as it's copied over in the module.properties
file and not accepted by alfresco as valid module version number
TRIVIAL:
IMPROVEMENTS:
- maven-sql-plugin to autocreate jetty db

View File

@@ -1,429 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version
2.0 (the "License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0 Unless required by
applicable law or agreed to in writing, software distributed under the
License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
CONDITIONS OF ANY KIND, either express or implied. See the License for
the specific language governing permissions and limitations under the
License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>${groupId}</groupId>
<artifactId>${artifactId}</artifactId>
<packaging>amp</packaging>
<name>Maven Alfresco AMP Packaging Sample</name>
<!--
An Alfresco version number must be of the form 1.2.3.4. Using
1.0-SNAPSHOT as the AMP version will create an exception. See
http://wiki.alfresco.com/wiki/Developing_an_Alfresco_Module: "The
version number must be made up of numeric values separated by dots.
For example '2.1.56' is a valid version number, '2.3.4a' is not. " In
order to be able to use Maven snapshots we cannot use the <version/>
below as the AMP module version. Instead we use the
buildnumber-maven-plugin. This requires a scm connection.
-->
<version>${version}</version>
<description>Test AMP project</description>
<repositories>
<repository>
<id>alfresco-public-snapshots</id>
<url>http://maven.alfresco.com/nexus/content/groups/public-snapshots</url>
<snapshots>
<enabled>true</enabled>
<updatePolicy>daily</updatePolicy>
</snapshots>
</repository>
<repository>
<id>alfresco-public</id>
<url>http://maven.alfresco.com/nexus/content/groups/public</url>
s </repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>alfresco-public</id>
<url>http://maven.alfresco.com/nexus/content/groups/public</url>
</pluginRepository>
<pluginRepository>
<id>alfresco-public-snapshots</id>
<url>http://repository.sourcesense.com/nexus/content/groups/public-snapshots</url>
<snapshots>
<enabled>true</enabled>
<updatePolicy>daily</updatePolicy>
</snapshots>
</pluginRepository>
</pluginRepositories>
<properties>
<!--
Default for which src/main/properties/<env>/application.properties is
loaded. NB: used only for the 'test' profile (e.g. '-P test' on the
mvn commandline) jetty run deployment, does not impact AMP behavior
which is typically environment independent
-->
<env>local</env>
<!-- Webapp used to test/develop locally the AMP -->
<webapp.name>${artifactId}-webapp</webapp.name>
<!--
| | By default the src/test/properties/local/application.properties
uses the property "alfresco.data.location" to specify where |
alf_data gets created. | For local jetty:run deployment default
creation dir is under project root folder (as location is specified
relatively to run | dir). Please add alf_data_jetty in svn/cvs
ignores in order not to commit that. You can also specified a
different (out of the | sproject) folder | by editing the following
properties. | DB is also configurable here. Of course keep in sync
these two values otherwise you'll get integrity errors. | | Empty log
dir creates file alfresco.log in appserver default dir. You can also
specify a meaningful log directory for the server | (add a trailing
slash, e.g. '/var/log/alfresco/' ) | | Jetty embedded run logs by
default in target/alfresco.log
-->
<alfresco.data.location>./alf_data_jetty</alfresco.data.location>
<alfresco.db.name>alf_jetty</alfresco.db.name>
<alfresco.db.username>alfresco</alfresco.db.username>
<alfresco.db.password>alfresco</alfresco.db.password>
<webapp.log.level>error</webapp.log.level>
<webapp.log.dir></webapp.log.dir>
<!-- End of testing webapp specific properties -->
<!-- Module specific build time properties -->
<module.log.level>debug</module.log.level>
</properties>
<!--
need to list these as a provided so that Maven doesn't download them
and include them in the AMP, they are provided by Alfresco
-->
<dependencies>
<dependency>
<groupId>org.alfresco</groupId>
<artifactId>alfresco-repository</artifactId>
<version>3.2r</version>
<scope>provided</scope>
<classifier>community</classifier>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring</artifactId>
<version>2.0</version>
<scope>provided</scope>
</dependency>
<!--
Example Jar dependency: will be properly packed into the AMP /lib
directory <dependency> <groupId>rome</groupId>
<artifactId>opensearch</artifactId> <version>0.1</version>
</dependency>
-->
<!--
Example AMP dependency: will be properly overlayed in the WAR
produced by the integration-test phase in profile 'webapp'
<dependency> <groupId>org.alfresco</groupId>
<artifactId>recordsmanagement</artifactId> <version>2.1.0</version>
<type>amp</type> </dependency>
-->
<!--
By default archetype assumes mysql for test webapp. Change
src/test/properties/<env>/application.properties FIXME: support in
memory db for cleaner and safer test runs
-->
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>5.0.3</version>
</dependency>
<!-- Don't add here amp dependencies as it will break amp packaging -->
</dependencies>
<!--
The scm is required for the buildnumber-maven-plugin which is required
for AMP version numbering
-->
<scm>
<connection>scm:svn:http://domain.com/svn/trunk/</connection>
<developerConnection>scm:svn:https://${maven.username}@domain.com/svn/trunk/</developerConnection>
<url>http://domain.com/svn/trunk/</url>
</scm>
<build>
<plugins>
<plugin>
<artifactId>maven-nosnapshot-plugin</artifactId>
<groupId>com.sourcesense.maven</groupId>
<version>0.0.5-SNAPSHOT</version>
<executions>
<execution>
<id>default</id>
<phase>initialize</phase>
<goals>
<goal>strip</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>buildnumber-maven-plugin</artifactId>
<version>1.0-beta-2</version>
<executions>
<execution>
<phase>validate</phase>
<goals>
<goal>create</goal>
</goals>
</execution>
</executions>
<configuration>
<revisionOnScmFailure>1</revisionOnScmFailure>
<doCheck>false</doCheck>
<doUpdate>false</doUpdate>
</configuration>
</plugin>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.5</source>
<target>1.5</target>
</configuration>
</plugin>
<plugin>
<groupId>org.alfresco.maven.plugin</groupId>
<artifactId>maven-amp-plugin</artifactId>
<version>3.0.1-SNAPSHOT</version>
<extensions>true</extensions>
<configuration>
<archive>
<addMavenDescriptor>false</addMavenDescriptor>
</archive>
<overlays>
<!--
This sample adds records management module in the finally built
AMP <overlay> <groupId>org.org.alfresco</groupId>
<artifactId>recordsmanagement</artifactId>
<version>2.1.0</version> <type>amp</type> </overlay>
-->
<!--
The current AMP is always last in order to overwrite other
modules' modules.properties <overlay></overlay>
-->
</overlays>
</configuration>
</plugin>
</plugins>
<!--
Copies and filters resources in build folder so maven-amp-plugin can
pick them up
-->
<resources>
<resource>
<filtering>true</filtering>
<directory>src/main/resources</directory>
<excludes>
<exclude>**README-*</exclude>
</excludes>
</resource>
<!--
Copies and filters AMP config in the proper package
'alfresco/module/${groupId}.${artifactId}' so to enforce full module
naming single sourcing from POM properties
-->
<resource>
<filtering>true</filtering>
<directory>src/main/config</directory>
<targetPath>alfresco/module/${groupId}.${artifactId}</targetPath>
<excludes>
<exclude>**README-*</exclude>
</excludes>
</resource>
</resources>
</build>
<profiles>
<!--
Profile used to trigger war creation and integration within Jetty
embedded
-->
<profile>
<id>webapp</id>
<build>
<filters>
<filter>src/test/properties/${env}/application.properties</filter>
</filters>
<defaultGoal>jetty:run-exploded</defaultGoal>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>unpack-amps</id>
<phase>process-resources</phase>
<goals>
<goal>unpack-dependencies</goal>
</goals>
<configuration>
<includeTypes>amp</includeTypes>
<outputDirectory>${build.directory}/${webapp.name}</outputDirectory>
<excludes>META*</excludes>
</configuration>
</execution>
</executions>
<dependencies>
<!--
This is required to be re-defined explicitly at plugin level as
otherwise the 'amp' extension unArchiver won't be available to
the maven-dependency-plugin
-->
<dependency>
<groupId>org.alfresco.maven.plugin</groupId>
<artifactId>maven-amp-plugin</artifactId>
<version>3.0.1-SNAPSHOT</version>
</dependency>
</dependencies>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<executions>
<!-- Runs war packaging when 'integration-test' phase is called -->
<execution>
<id>it</id>
<phase>package</phase>
<goals>
<goal>exploded</goal>
</goals>
<configuration>
<archiveClasses>true</archiveClasses>
</configuration>
</execution>
</executions>
<configuration>
<primaryArtifact>false</primaryArtifact>
<!--
Don't remove the following line otherwise WAR and AMP builds
will be done in the same folder, with unexpected results
-->
<webappDirectory>${build.directory}/${webapp.name}</webappDirectory>
<archive>
<addMavenDescriptor>false</addMavenDescriptor>
</archive>
<warSourceExcludes>licenses/**</warSourceExcludes>
<webResources></webResources>
<webResources>
<resource>
<directory>${build.testOutputDirectory}</directory>
<targetPath>WEB-INF/classes</targetPath>
<filtering>true</filtering>
<includes>
<include>**</include>
</includes>
</resource>
<!-- Here we add default this AMP web/ resources-->
<resource>
<directory>src/main/webapp</directory>
<targetPath>WEB-INF/licenses</targetPath>
<includes>
<include>licenses/*.*</include>
</includes>
<filtering>false</filtering>
</resource>
</webResources>
</configuration>
<dependencies>
<!--
This is required to be re-defined explicitly at plugin level as
otherwise the 'amp' extension unArchiver won't be available to
the maven-war-plugin
-->
<dependency>
<groupId>org.alfresco.maven.plugin</groupId>
<artifactId>maven-amp-plugin</artifactId>
<version>3.0.1-SNAPSHOT</version>
</dependency>
</dependencies>
</plugin>
<plugin>
<groupId>org.mortbay.jetty</groupId>
<artifactId>maven-jetty-plugin</artifactId>
<executions>
<!-- Runs jetty when 'integration-test' phase is called -->
<execution>
<id>it</id>
<phase>integration-test</phase>
<goals>
<goal>run-exploded</goal>
</goals>
<configuration>
<contextPath>/${webapp.name}</contextPath>
<webApp>${pom.build.directory}/${webapp.name}</webApp>
<scanIntervalSeconds>10</scanIntervalSeconds>
<connectors>
<connector implementation="org.mortbay.jetty.nio.SelectChannelConnector">
<port>8080</port>
<maxIdleTime>60000</maxIdleTime>
</connector>
</connectors>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
<!--
When invoking 'mvn integration-test', the following alf configs are
added to the test war in order to be able to run it seamlessly. NB:
the application.properties file is filtered with alfresco.db.name
and alf.data.location POM properties as default configuration
-->
<testResources>
<testResource>
<filtering>true</filtering>
<directory>src/test/resources</directory>
</testResource>
<!-- Includes default properties for alfresco test war -->
<testResource>
<filtering>true</filtering>
<directory>src/test/properties/${env}</directory>
<targetPath>alfresco/extension</targetPath>
</testResource>
<!--
src/main/config/ is copied into ==>
target/test-classes/alfresco/module/${groupId}.${artifactId} to be
picked up by the maven-war plugin Best practice tacken from
recordsmanagement.amp, is enforced troughout the whole archetype.
This convention is also used for module.properties filtering.
-->
<testResource>
<filtering>true</filtering>
<directory>.</directory>
<includes>
<include>module.properties</include>
</includes>
<targetPath>alfresco/module/${groupId}.${artifactId}</targetPath>
</testResource>
</testResources>
</build>
<!--
Here you can add test dependencies you want to have included in the
the WAR (not in the AMP, built in the main profile) | | Typical use
case: add here additional AMPs that you want to test compatibility
of with the current module |
-->
<dependencies>
<!--
This is the alfresco version you're testing the AMP against. Don't
remove if you want jetty to be able to deploy a WAR :)
-->
<dependency>
<groupId>org.alfresco</groupId>
<artifactId>alfresco</artifactId>
<version>3.2r</version>
<type>war</type>
<classifier>community</classifier>
</dependency>
</dependencies>
</profile>
</profiles>
</project>

View File

@@ -1,41 +0,0 @@
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#-----------------------------------------------------------------------
# ${artifactId} module log4j.properties
#
# NOTE
# ----
# Log4j uses the following logging levels:
# debug,info,warn,error,fatal
#
# To set the logging level of {fullClassName} to {loglevel},
# add a line to this file of the following form:
#
# log4j.logger.{fullClassName}={loglevel}
#
# For example, to make 'com.example.MyExample' produce 'debug'
# logs, add a line like this:
#
# log4j.logger.com.example.MyExample=debug
#
#
# WARNING
# -------
# Log properties in this log4j.properties file override/augment
# those in the webapp's main log4j.properties.
#
#-----------------------------------------------------------------------
log4j.logger.org.alfresco.demoamp.DemoComponent=${module.log.level}

View File

@@ -1,139 +0,0 @@
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# RUN TIME PROPERTIES
# -------------------
# Sample custom content and index data location
# This will create alf_data Relative to appserver run folder
# In this default file we take the property from the POM (for compatbility with local jetty and jboss deployments) but it can also be edited here.
dir.root=${alfresco.data.location}
# Allowed values are: NONE, AUTO, FULL
index.recovery.mode=AUTO
# Fail or not when there are node integrity checker errors
integrity.failOnError=true
# database connection properties
# MySQL connection (This is default and requires mysql-connector-java-5.0.3-bin.jar, which ships with the Alfresco server)
db.driver=org.gjt.mm.mysql.Driver
db.url=jdbc:mysql://localhost/${alfresco.db.name}
db.username=${alfresco.db.username}
db.password=${alfresco.db.password}
db.pool.initial=10
db.pool.max=100
# MySQL dialect
hibernate.dialect=org.hibernate.dialect.MySQLInnoDBDialect
# Change the following values only if you know what you're doing.
# Default should suffice in most cases when running jetty embedded
# for amp testing
# Property to control whether schema updates are performed automatically.
# Updates must be enabled during upgrades as, apart from the static upgrade scripts,
# there are also auto-generated update scripts that will need to be executed. After
# upgrading to a new version, this can be disabled.
#db.schema.update=true
# File servers related properties
# For local builds we disable CIFS and FTP. Edit the following property to reenable them
smb.server.enabled=false
smb.server.name=CFS_SHARE_LOCAL
smb.server.domain=mycompany.com
smb.server.bindto=127.0.0.1
smb.tcpip.port=1445
netbios.session.port=1139
netbios.name.port=1137
netbios.datagram.port=1138
ftp.server.enabled=false
ftp.port=1121
ftp.authenticator=alfresco
# This properties file is used to configure LDAP authentication
# NB: The following LDAP related properties are read only in case -Denteprise mvn build property is specified
# Wheter to allow silent deletion of users in the Alfresco UI (note: users will be then resynced in the next synchronization)
ldap.authentication.allowDeleteUser=true
# LDAP JNDI provider
ldap.authentication.provider=com.sun.jndi.ldap.LdapCtxFactory
# Url and protocol for LDAP server to carry authentication against
ldap.authentication.url=ldap://ldap.mycompany.com:636
# can be (simple, ssl)
ldap.authentication.protcol=ssl
# Credentials with full access to the directoty used
ldap.authentication.adminUser=ou=Admin,ou=Services,o=Company
ldap.authentication.adminPassword=secret
# Wheter to allow unauthenticated guest a read only login
ldap.authentication.guestLogin.allowed=false
# Wheter users can be created on the fly upon successful external (e.g. LDAP) authentication. Useful to avoid user synchronization in case just uid and pwd are needed for a user
server.transaction.allow-writes=true
# Wheter user names are case sensitive
user.name.caseSensitive=true
# Wheter the synchronization process has to process duplicated users (e.g. synced users and users coming from the sync)
personService.processDuplicates=true
# Which action to take when processin duplicates. One of: LEAVE, SPLIT, DELETE
personService.duplicateMode=DELETE
# Which of the users (in case of SPLIT duplicates policy) should be considered valid
personService.lastIsBest=true
# Wheter auto created users should be considered when processing duplicates
personService.includeAutoCreated=true
# The query to find the people to import
ldap.synchronisation.personQuery=(objectclass=inetOrgPerson)
# The search base of the query to find people to import
ldap.synchronisation.personSearchBase=ou=Identities,ou=mycompany,o=com
# The attribute name on people objects found in LDAP to use as the uid in Alfresco
ldap.synchronisation.userIdAttributeName=cn
# The attribute on person objects in LDAP to map to the first name property in Alfresco
ldap.synchronisation.userFirstNameAttributeName=givenName
# The attribute on person objects in LDAP to map to the last name property in Alfresco
ldap.synchronisation.userLastNameAttributeName=sn
# The attribute on person objects in LDAP to map to the email property in Alfresco
ldap.synchronisation.userEmailAttributeName=cn
# The attribute on person objects in LDAP to map to the organizational id property in Alfresco
ldap.synchronisation.userOrganizationalIdAttributeName=maildomain
# The default home folder provider to use for people created via LDAP import
ldap.synchronisation.defaultHomeFolderProvider=companyHomeFolderProvider
# The query to find group objects
ldap.synchronisation.groupQuery=(objectclass=AlfrescoGroup)
# The search base to use to find group objects
ldap.synchronisation.groupSearchBase=ou=AlfrescoGroups,ou=mycompany,o=com
# The attribute on LDAP group objects to map to the gid property in Alfrecso
ldap.synchronisation.groupIdAttributeName=cn
# The group type in LDAP
ldap.synchronisation.groupType=AlfrescoGroup
# The person type in LDAP
ldap.synchronisation.personType=inetOrgPerson
# The attribute in LDAP on group objects that defines the DN for its members
ldap.synchronisation.groupMemberAttributeName=member
# The cron expression defining when people imports should take place (e.g. every evening at 22:00 hours)
ldap.synchronisation.import.person.cron=0 0 22 * * ?
# The cron expression defining when group imports should take place (e.g. every evening at 21:45 hours)
ldap.synchronisation.import.group.cron=0 45 21 * * ?
# Should all groups be cleared out at import time?
# - this is safe as groups are not used in Alfresco for other things (unlike person objects which you should never clear out during an import)
# - setting this to true means old group definitions will be tidied up.
ldap.synchronisation.import.group.clearAllChildren=false

View File

@@ -1,53 +0,0 @@
<?xml version='1.0' encoding='UTF-8'?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<!DOCTYPE beans PUBLIC '-//SPRING//DTD BEAN//EN' 'http://www.springframework.org/dtd/spring-beans.dtd'>
<!--
This shows the common minimum configuration overrides.
By default, the content and indexes are located at a relative location, which should only
be used when doing a quick preview of the Alfresco server.
-->
<beans>
<!-- overriding to point to custom properties -->
<bean id="repository-properties" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
<property name="ignoreUnresolvablePlaceholders">
<value>true</value>
</property>
<property name="locations">
<list>
<value>classpath:alfresco/repository.properties</value>
<value>classpath:alfresco/version.properties</value>
<value>classpath:alfresco/domain/transaction.properties</value>
<!-- Override basic repository properties, dir.root and hibernate dialect -->
<value>classpath:alfresco/extension/application.properties</value>
</list>
</property>
</bean>
<bean id="hibernateConfigProperties" class="org.springframework.beans.factory.config.PropertiesFactoryBean">
<property name="locations">
<list>
<value>classpath:alfresco/domain/hibernate-cfg.properties</value>
</list>
</property>
</bean>
</beans>

View File

@@ -1,152 +0,0 @@
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<!--
| Default property based configuration.
| Example configurations are also provided.
|
-->
<alfresco-config area="file-servers">
<!-- To override the default Alfresco filesystem use replace="true", to -->
<!-- add additional filesystems remove the replace="true" attribute -->
<!-- Sample passtrhu Novel authentication
<config evaluator="string-compare" condition="Filesystem Security" replace="true">
<authenticator type="passthru">
<Server>passtrhu1.mycompany.com,passthru2.mycompany.com</Server>
</authenticator>
</config>
-->
<!-- Sample kerberos configuration. Untested.
config evaluator="string-compare" condition="Filesystem Security" replace="true">
<authenticator type="enterprise">
<KDC>authserver.company.com</KDC>
<Realm>MYCOMPANY.COM</Realm>
<Password>secret</Password>
<LoginEntry>AlfCommon</LoginEntry>
</authenticator>
</config-->
<config evaluator="string-compare" condition="Filesystem Security" replace="true">
<authenticator type="alfresco"/>
</config>
<config evaluator="string-compare" condition="CIFS Server" replace="true">
<serverEnable enabled="${smb.server.enabled}"/>
<host name="${smb.server.name}" domain="${smb.server.domain}"/>
<comment>Alfresco CIFS Server</comment>
<!-- Set to the broadcast mask for the subnet -->
<broadcast>255.255.255.0</broadcast>
<!-- Use Java socket based NetBIOS over TCP/IP and native SMB on linux -->
<tcpipSMB platforms="linux,solaris,macosx"/>
<netBIOSSMB platforms="linux,solaris,macosx"/>
<!-- bind to the frontend facing interface of this server -->
<bindto>${smb.server.bindto}</bindto>
<!-- Can be mapped to non-privileged ports, then use firewall rules to forward requests from the standard ports -->
<tcpipSMB port="${smb.tcpip.port}" platforms="linux,solaris,macosx"/>
<netBIOSSMB sessionPort="${netbios.session.port}" namePort="${netbios.name.port}" datagramPort="${netbios.datagram.port}" platforms="linux,solaris,macosx"/>
<hostAnnounce interval="5"/>
<!-- Use Win32 NetBIOS interface on Windows -->
<Win32NetBIOS/>
<Win32Announce interval="5"/>
<!--
<WINS>
<primary>1.2.3.4</primary>
<secondary>5.6.7.8</secondary>
</WINS>
-->
<sessionDebug flags="Negotiate,Socket"/>
</config>
<config evaluator="string-compare" condition="FTP Server">
<serverEnable enabled="${ftp.server.enabled}"/>
<port>${ftp.port}</port>
<!-- FTP authentication -->
<authenticator type="${ftp.authenticator}"/>
<!-- <debug flags="File,Search,Error,Directory,Info,DataPort"/> -->
</config>
<config evaluator="string-compare" condition="Filesystems" replace="true">
<filesystems>
<filesystem name="Alfresco">
<store>workspace://SpacesStore</store>
<rootPath>/app:company_home</rootPath>
<!-- Add a URL file to each folder that links back to the web client -->
<urlFile>
<filename>__Alfresco.url</filename>
<webpath>http://${localname}/</webpath>
</urlFile>
<!-- Mark locked files as offline -->
<offlineFiles/>
<!-- Desktop actions -->
<desktopActions>
<global>
<path>alfresco/desktop/Alfresco.exe</path>
<webpath>http://${localname}/</webpath>
</global>
<action>
<class>org.alfresco.filesys.smb.server.repo.desk.CheckInOutDesktopAction</class>
<name>CheckInOut</name>
<filename>__CheckInOut.exe</filename>
</action>
<action>
<class>org.alfresco.filesys.smb.server.repo.desk.JavaScriptDesktopAction</class>
<name>JavaScriptURL</name>
<filename>__ShowDetails.exe</filename>
<script>alfresco/desktop/showDetails.js</script>
<attributes>anyFiles</attributes>
<preprocess>copyToTarget</preprocess>
</action>
</desktopActions>
<!--
<accessControl default="Write">
<user name="admin" access="Write"/>
<address subnet="90.${version}.0" mask="255.255.0.0" access="Write"/>
</accessControl>
-->
</filesystem>
<!-- AVM virtualization view of all stores/versions for WCM -->
<avmfilesystem name="AVM">
<virtualView/>
</avmfilesystem>
</filesystems>
</config>
</alfresco-config>

View File

@@ -1,147 +0,0 @@
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# Customized alfresco log location
# Set root logger level to error
log4j.rootLogger=${webapp.log.level}, Console, File
###### Console appender definition #######
# All outputs currently set to be a ConsoleAppender.
log4j.appender.Console=org.apache.log4j.ConsoleAppender
log4j.appender.Console.layout=org.apache.log4j.PatternLayout
log4j.appender.Console.layout.ConversionPattern=%d{ABSOLUTE} %-5p [%c{3}] %m%n
#log4j.appender.Console.layout.ConversionPattern=%d{ABSOLUTE} %-5p [%c] %m%n
###### File appender definition #######
log4j.appender.File=org.apache.log4j.DailyRollingFileAppender
log4j.appender.File.File=${webapp.log.dir}alfresco.log
log4j.appender.File.Append=true
log4j.appender.File.DatePattern='.'yyyy-MM-dd
log4j.appender.File.layout=org.apache.log4j.PatternLayout
log4j.appender.File.layout.ConversionPattern=%d{ABSOLUTE} %-5p [%c] %m%n
###### Hibernate specific appender definition #######
#log4j.appender.file=org.apache.log4j.FileAppender
#log4j.appender.file.File=hibernate.log
#log4j.appender.file.layout=org.apache.log4j.PatternLayout
#log4j.appender.file.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L - %m%n
###### Log level overrides #######
log4j.logger.org.alfresco.repo.model.filefolder=info
# Hibernate
log4j.logger.org.hibernate=error
log4j.logger.org.hibernate.util.JDBCExceptionReporter=fatal
log4j.logger.org.hibernate.event.def.AbstractFlushingEventListener=fatal
#log4j.logger.org.hibernate.cache.EhCacheProvider=warn
log4j.logger.org.hibernate.type=warn
# log4j.logger.org.hibernate.persister.collection=DEBUG
# Spring
log4j.logger.org.springframework=warn
# Axis/WSS4J
log4j.logger.org.apache.axis=info
log4j.logger.org.apache.ws=info
# MyFaces
log4j.logger.org.apache.myfaces.util.DebugUtils=info
log4j.logger.org.apache.myfaces.el.VariableResolverImpl=error
log4j.logger.org.apache.myfaces.application.jsp.JspViewHandlerImpl=error
log4j.logger.org.apache.myfaces.taglib=error
# log prepared statement cache activity ###
log4j.logger.org.hibernate.ps.PreparedStatementCache=info
# Alfresco
log4j.logger.org.alfresco=error
log4j.logger.org.alfresco.repo.avm=info
log4j.logger.org.alfresco.config=info
log4j.logger.org.alfresco.sample=info
log4j.logger.org.alfresco.web=info
log4j.logger.org.alfresco.web.scripts=warn
#log4j.logger.org.alfresco.web.ui.repo.component.UIActions=debug
#log4j.logger.org.alfresco.web.ui.repo.tag.PageTag=debug
#log4j.logger.org.alfresco.web.bean.clipboard=debug
log4j.logger.org.alfresco.repo.webservice=info
log4j.logger.org.alfresco.service.descriptor.DescriptorService=info
#log4j.logger.org.alfresco.repo.importer.ImporterBootstrap=info
#log4j.logger.org.alfresco.web.ui.common.Utils=info
log4j.logger.org.alfresco.repo.admin.patch.PatchExecuter=info
log4j.logger.org.alfresco.repo.module.ModuleServiceImpl=info
log4j.logger.org.alfresco.repo.domain.schema.SchemaBootstrap=info
log4j.logger.org.alfresco.repo.admin.ConfigurationChecker=info
log4j.logger.org.alfresco.repo.node.index.FullIndexRecoveryComponent=info
log4j.logger.org.alfresco.util.OpenOfficeConnectionTester=warn
log4j.logger.org.alfresco.repo.node.db.hibernate.HibernateNodeDaoServiceImpl=warn
#log4j.logger.org.alfresco.web.app.DebugPhaseListener=debug
#log4j.logger.org.alfresco.repo.cache.EhCacheTracerJob=debug
#log4j.logger.org.alfresco.repo.search.Indexer=debug
#log4j.logger.org.alfresco.repo.workflow=info
#log4j.logger.org.alfresco.repo.jscript=DEBUG
log4j.logger.org.alfresco.repo.jscript.AlfrescoRhinoScriptDebugger=off
# CIFS server debugging
#log4j.logger.org.alfresco.smb.protocol=debug
#log4j.logger.org.alfresco.smb.protocol.auth=debug
#log4j.logger.org.alfresco.acegi=debug
# FTP server debugging
#log4j.logger.org.alfresco.ftp.protocol=debug
#log4j.logger.org.alfresco.ftp.server=debug
# WebDAV debugging
#log4j.logger.org.alfresco.webdav.protocol=debug
# NTLM servlet filters
#log4j.logger.org.alfresco.web.app.servlet.NTLMAuthenticationFilter=debug
#log4j.logger.org.alfresco.repo.webdav.auth.NTLMAuthenticationFilter=debug
# Integrity message threshold - if 'failOnViolation' is off, then WARNINGS are generated
log4j.logger.org.alfresco.repo.node.integrity=ERROR
# New indexer debugging
#log4j.logger.org.alfresco.repo.search.impl.lucene.index=DEBUG
# Audit debugging
# log4j.logger.org.alfresco.repo.audit=DEBUG
# log4j.logger.org.alfresco.repo.audit.model=DEBUG
# Turn off Spring remoting warnings that should really be info or debug.
log4j.logger.org.springframework.remoting.support=error
# Templating debugging
# log4j.logger.org.alfresco.web.forms=debug
# log4j.logger.org.chiba.xml.xforms=debug
# Property sheet and modelling debugging
# change to error to hide the warnings about missing properties and associations
log4j.logger.alfresco.missingProperties=warn
log4j.logger.org.alfresco.web.ui.repo.component.property.UIChildAssociation=warn
log4j.logger.org.alfresco.web.ui.repo.component.property.UIAssociation=warn
#log4j.logger.org.alfresco.web.ui.repo.component.property=debug
#log4j.logger.org.alfresco.repo.dictionary.DictionaryDAO=info
# Virtualization Server Registry
#log4j.logger.org.alfresco.mbeans.VirtServerRegistry=debug
# Link Validation debugging
#log4j.logger.org.alfresco.linkvalidation.LinkValidationServiceImpl=debug
#log4j.logger.org.alfresco.linkvalidation.LinkValidationStoreCallbackHandler=debug

View File

@@ -1,44 +0,0 @@
-----
Maven Alfresco Extension Archetype
-----
Alfresco
-----
Welcome to the Maven Alfresco AMP Archetype home
You've reached the Maven Alfresco AMP archetype version ${site_pom_version} ) home page.
Description
${site_pom_description}
You can use this Archetype to build and add AMPs to Alfresco WAR packages in conjunction with the maven-alfresco-extension-archetype.
Using Maven you will benefit of a more structured and scalable way of using AMPs without the Module Management Tool (MMT).
Quick Start (maven2)
For a quick start you can a maven alfresco AMP project created by just running <<(maven 2.1+ required)>>:
--------------------------------------------
mvn archetype:generate -DarchetypeCatalog=http://maven.alfresco.com/nexus/content/repositories/releases/archetype-catalog.xml
--------------------------------------------
and then choose the option 'maven-alfresco-amp-archetype'
Usage
You can package and install your AMP module in the local Maven repo by just running
--------------------------------------------
mvn install
--------------------------------------------
You can then use the AMP by depending on it using the Maven Alfresco Extension Archetype, without any external tool (e.g. MMT).
See {{{http://maven.alfresco.com/nexus/content/repositories/alfresco-docs/maven-alfresco-lifecycle/maven-alfresco-archetypes/maven-alfresco-extension-archetype/profiles.html} available profiles for Extension archetypes}}

View File

@@ -1,43 +0,0 @@
-----
Archetype Project Generated Layout
-----
What do I have when I created the project?
You will encounter an AMP project structure, filtered with values you provided in creation phase,
which has the following layout:
------------------------------------------------------------------
src --------------------------------------------------------> (source folder)
|
|__ main ___ __ resources --------------------------> mapped in the classpath. Add here classpath resources
| |
| |__ config----- alfresco module config goes here.
| | | Get's copied (by best practice) by build into package alfresco/module/groupId.artifactId.
| | | This convention is used by the archetype and by the AMP unpacker.
| | |__ ex: alfresco/module/com.sourcesense.alfresco.mymodule ---> Example Alfresco module config
| |
| |
| |__ java -------------------------------> customization java classes
| |
| |__ webapp -----------------------------> AMP overlay folder - this folder is overlayed (so may overwrite other dependent AMPs)
|
|__ test __ __ resources _
| | |
| | |__ alfresco/extension ---> alfresco overriding Spring contexts
| |
| |__ properties -------------------------> environment aware application properties files
| | |
| | |__ local -------------> default application.properties
| |
|
target - Project build dir
------------------------------------------------------------------

View File

@@ -1,56 +0,0 @@
-----
Alfresco maven2 AMP lifecycle
-----
What an AMP is?
Alfresco Module packages are software modules to be added on top of the Alfresco ECM
platform. \
As opposed to Alfresco Extensions (which can be generated with {{{http://repository.sourcesense.com/maven2-sites/maven-alfresco-extension-archetype} maven-alfresco-extension-archetype }})
which are meant to mainly produce a single customized build of Alfresco, an AMP is a small
ZIP file primary product of the build lifecyle defined by the
---------
<packaging>amp</packaging>
---------
POM property. Use this build to create and modules which then can be used as dependencies
by a maven-alfresco-extension generated project (e.g. enterprise Alfresco WAR customization).
One command quickstart
-------------
$ MAVEN_OPTS="-Xms256m -Xmx512m -XX:PermSize=128m" mvn clean integration-test -P webapp
----------------
will runns the jetty embedded with overlayed the currently developed AMP
FEATURES:
AMP archetype + plugin features:
* AMP customized build : <<<mvn clean package>>>
* Alfresco webapp integrationt test via war creation and embedded run <<<mvn clean integration-test -P webapp>>>
* Install/deployment of Alfresco compatible AMPs on a m2 repo <<< mvn install / deploy [ params ] >>>
* using the {{{http://repository.sourcesense.com/maven2-sites/maven-amp-plugin} maven-amp-plugin}} WAR can depend on AMP artifacts and have them overlayed within the maven lifecycle, avoiding the boring MMT run.
* AMP dependencies management: <<<mvn clean package>>> can take care of overlay AMP deps
* Error safe single sourcing of POM properties <<<groupId>>> and <<<artifactId>>> used to copy config in the proper package and to ensure consistency
Specific dependencies and different Alfresco versions can be specified in 'webapp' profile dependecies. Alfresco test webapp is overlayed (apart with
all AMP and WAR dependencies specified) also with a sensible default 'alfresco/extension' folder to have a clean safe reproduceable and portable
default alfresco run. Find these test configuaration files in 'src/test/resources' and environment dependent properties in src/test/properties/<env>/application.properties

View File

@@ -1,33 +0,0 @@
-----
AMP used versioning scheme
-----
Progressive Versioning Scheme
This scheme was designed to:
* reach properties single sourcing from the POM (so to automatically fill module.properties based on POM properties)
* to be able to use Maven SNAPSHOT capabilities during development
* maintain a senseful progressive order in the versions and builds
and had to overcome the following shortcomings:
* Alfresco Module Packages (AMPs) versions cannot contain letters (therefore no -SNAPSHOT is allowed)
For this the AMP version (in the module.properties) is filtered to be equals to:
<<<module.version=${noSnapshotVersion}.${buildNumber}>>>
where:
* noShapshotVersion --> is anything before '-SNAPSHOT' in the current POM version, generated by the maven-no-snapshot-plugin
* buildNumber --> is the buildNumber generated by the maven-buildnumber-plugin from the SCM information for your project, or defaults to 1 if no SCM was configured
Custom Versioning Schemes
You can always maintain your <<<module.properties>>> version manually and remove the plugins invocations from the generated POMs.

View File

@@ -1,72 +0,0 @@
<?xml version="1.0"?>
<faqs id="Maven Alfresco Extension FAQ">
<part id="General">
<title>General</title>
<faq id="build">
<question>How do I build an AMP?</question>
<answer>
<p>
Just Run
<source>mvn clean package</source>
</p>
</answer>
</faq>
<faq id="test">
<question>How do I test the AMP?</question>
<answer>
<p>
You can run Jetty embedded in maven by typing
<source>mvn clean integration-test -P webapp</source>
</p>
</answer>
</faq>
<faq id="transitive">
<question>Are AMP transitive dependencies supported?</question>
<answer>
<p>
Yes, they are, both from AMP and WAR packaging projects. For AMP projects this will turn out into having a final built AMP which
contains all the chain of AMPs the current AMP is depending upon. For WAR projects all AMPs will be unpacked in the proper
position same as the MMT would do.
</p>
</answer>
</faq>
<faq id="mmt">
<question>Is MMT needed with maven?</question>
<answer>
<p>
No, it is not. The whole point of it is getting rid of the annoying non integrated in the lifecycle MMT run. We created the
<a href="https://forge.alfresco.com/projects/maven4alfresco" target="_blank">maven-amp-plugin</a>
for managing and processing AMP lifecycle, making MMT obsolete.
</p>
</answer>
</faq>
</part>
<part id="Developer">
<title>Developer questions</title>
<faq id="Eclipse">
<question>How do I configure Eclipse?</question>
<answer>
<ul>
<li>Run <source> mvn eclipse:eclipse </source></li>
<li>hit "Refresh" on your Eclipse project</li>
</ul>
</answer>
</faq>
<faq id="Memory">
<question>Why I get PermGen or HeapSpace errors</question>
<answer>
<p>Run your build with : <source>MAVEN_OPTS="-Xms256m -Xmx512m -XX:PermSize=128m" mvn ...</source> </p>
</answer>
</faq>
<faq id="AMPs">
<question>How do I deploy a generally available AMP into a maven repo for dependency usage</question>
<answer>
<source>
mvn deploy:deploy-file -DrepositoryId=repo -Dfile=/Users/youruser/projectz/alfresco/alfresco-recordsmanagement-2.1.0.amp
-DgroupId=org.alfresco.community -DartifactId=recordsmanagement -Dversion=2.1.0 -Dpackaging=amp -Durl=scp://...
</source>
</answer>
</faq>
</part>
</faqs>

View File

@@ -1,35 +0,0 @@
<project>
<skin>
<groupId>org.apache.maven.skins</groupId>
<artifactId>maven-stylus-skin</artifactId>
<version>1.0</version>
</skin>
<poweredBy>
<logo name="Maven" href="http://maven.apache.org" img="http://maven.apache.org/images/logos/maven-feather.png"/>
<logo name="Alfresco - Open source ECM" img="http://alfresco.com/assets/images/icons/powered_by_alfresco.gif" href="http://www.sourcesense.com" />
</poweredBy>
<publishDate position="navigation-bottom" format="MM-dd-yy" />
<body>
<links>
<item name="Maven" href="http://maven.apache.org/"/>
<item name="Apache" href="http://www.apache.org/"/>
</links>
<menu name="M2 Alfresco AMP Archetype">
<item name="Introduction" href="/index.html"/>
<item name="README" href="/readme.html"/>
<item name="Generated Project Layout " href="layout.html"/>
<item name="Versioning scheme" href="/versions.html"/>
<item name="FAQ" href="faq.html"/>
</menu>
<menu name="See also">
<item name="Maven Alfresco Extension Archetype" href="http://repository.sourcesense.com/nexus/content/repositories/alfresco.public.sites/maven-alfresco-lifecyle/maven-alfresco-archetypes/maven-alfresco-extension-archetype"/>
<item name="Maven AMP Plugin" href="http://repository.sourcesense.com/nexus/content/repositories/alfresco.public.sites/maven-alfresco-lifecyle/plugins/maven-amp-plugin"/>
<item name="Alfresco AMP files" href="http://wiki.alfresco.com/wiki/AMP_Files" />
</menu>
<menu ref="reports" />
</body>
</project>

View File

@@ -1,123 +0,0 @@
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
NOTE: This file maybe obsolete. Please refer to documentation site.
Maven2/Ant Alfresco extension archetype
---------------------------------------
What is an Alfresco extension?
------------------------------
We define an "Alfresco extension" (or customization) a custom build of Alfresco which does not impact on Alfresco source code (while depends on binary releases of the libraries and webapp).
This is realized overriding (and in certain particular cases overwriting) Alfresco default configuration using Convention over Configuration hooks (e.g. classpath:alfresco/extension/*-context.xml autoloading), in order to ease integration in enterprise environments and to simplify full lifecycle management (from scratch-start to release and deploy) also for non experienced developers, resulting in a less error prone controlled process.
Alternative to an "Alfresco extension" is the "Alfresco Module" (or AMP) which is meant to be deployed on an existing Alfresco instance and above all to coexist with other modules on top of this instance: as a general rule of thumb an extension is an exclusive customization while a module is one of many customizations which have a separate lifecycle (and owner).
For an maven2 archetype of AMP Alfresco build please have a look at:
https://dev.sourcesense.com/cargo/maven2-sites/maven-alfresco-extension-archetype
Quick Start:
------------
Wanna skip all the discussion (or you know already the thing) and want a zero conf maven2 alfresco customization project generation?
Just run:
mvn org.apache.maven.plugins:maven-archetype-plugin:1.0-alpha-7:create -DarchetypeGroupId=${pom.groupId} -DarchetypeArtifactId=${pom.artifactId} -DarchetypeVersion=${pom.version} \
-DgroupId=mycompany.com -DartifactId=my-alfresco-customization -Dversion=0.1-SNAPSHOT
-DremoteRepositories=http://repository.sourcesense.com/maven2 (archetype is deployed there)
-DpomRemoteRepositories=http://repository.sourcesense.com/maven2 (wagon-dav ssh version patched is here)
Introduction:
-------------
This archetype developed within Sourcesense (http://www.sourcesense.com) aims to provide a standardized approach to development, release and deployment of Alfresco extensions (as opposed to AMP builds). Using standard m2 lifecycle commands (mvn compile package deploy) and generally available plugins (cargo, release, assembly) we are able to cover a very high percentage of Alfresco lifecycle common use cases.
It can be used both with Maven2 and Ant build systems, but it must be clear that *only* the Maven2 approach provides all the automation features we will describe in the next paragraphs.
In addition to that the m2 approach provides a zero-conf approach while ant requires (as usual) manual gathering and selection of required alfresco libraries and webapp (please refer to README-ant.txt for further info about the Ant build). Last but not the least, m2 build is more likely to be maintained and improved (especially in the likely case Alfresco moves to maven2).
For more details on the m2 apprach please refer instead to README-m2.txt.
Features (maven2 only):
----------------------
-- Easy dependency management and upgrade testing
Webapp WAR dependency on Alfresco community/enterprise wars (or even environment dependent builds, e.g. WAR without log4j for Jboss-4.0.X) can be easily switched and build
for different platforms in custom maven2 build profiles.
Alfresco JAR dependency are only included for compilation (scope="provided") and IDE configuration and must manually be kept in sync with the WAR version (we used a maven style library naming, renaming Alfresco distributed libraries).
-- Single source environment dependent properties filtering:
One of the biggest flaws (and most frequent cause for runtime errors) for Alfresco (and more in general for webapplications) is a poor build system which requires manual editing of properties in the source code in a developer/environment dependent way. With this build system just by specifying the -Denv=<yourEnv> command line property your able to switch between different buildtime/runtime properties configuration and also have all common properties in one file for simple edit. No more messing up with Spring files when what you need to change is just a property.
Properties files are stored in src/main/properties/<yourEnv> and get automatically copied over the classpath to provide complete code and configuration separation. Typical examples of developer/environment dependent properties are: db connection, LDAP server connection, alf_data location, SMB/FTP server enabling and configuration.
-- Automated (convention over configuration based) full Alfresco repository restore (boostrap)
Alfresco bootstrap process requires manual actions to be taken, and namely to include the restore-context.xml and the 6 full repo export ACP files to be included in the alfresco/extension/restore package. With this build this becomes as easy as specifying the -DrestoreVersion=<myVersion> build property which will automatically pick up ACP files (alfresco package name = "export") found in tools/export/<myVersion> and include them in the right position in the classpath. When the property is specified also the restore-context.xml to load them is automatically included
-- Automated LDAP configuration (and associated personService behaviors)
Fill in your application.properties with appropriate LDAP connection and synchronization values and by specifying the -Denterprise build property on the command line you will have the LDAP authentication and sychronization context already configured. No more hassles in digging into huge Spring files ;)
-- Jboss/Tomcat cargo based deployment
Using cargo we're able to provide (local) Jboss and (local/remote) Tomcat deployment. This comes handy both in the development phases and in the release phases when we want the release operation (scm tagging, m2 repo deployment, version update, appserver deployment) to be transactional and managed by maven. For additional configuration please refer to maven-cargo-plugin configuration and fine tune your $M2_HOME/conf/settings.xml (for system level settings) or ~/.m2/settings.xml (for user level settings) in order to match your host/credentials configuration
-- Zero conf startup
Community artifacts (alfresco 2.x) artifacts are available on Sourcesense public repository (http://repository.sourcesense.com/maven2) and allow all the default dependencies specified in this POM to be successfully retrieved with no additional configuration. If you want to use instead enterprise dependencies you either need to have a private access to Sourcesense private repositories or push alfresco for releasing this artifacts on public Alfresco maven repositories
--- Configurable log location and easy database setup
By editing the <log.dir> POM property in the appropriate profile you can have the setting applied where it makes sense (jboss configures everything centrally).
Database creation/remove scripts are filtered according to the build profile, so you can directly run them for the different environment they were 'built' for.
--- Easy ide (Eclipse) integration
As difficult as running mvn eclipse:eclipse and hitting "Refresh in your eclipse proje"
--- Release process
One command release deploy for this artifact and for the project generated from it. See README-m2.txt for more details.
--- Integrated documentation system
Documentation is integrated and can be modified with one of the supported formats (Xdoc, APT, FML): project resources can be also linked (e.g.physical documents) .
To test an example typing 'mvn site:run' will run your site in jetty embedded on port 8080, with redeployment of sited source files.
To stage the site just type 'mvn site:stage' and to deploy to remote site location, guess what, 'mvn site:deploy'
TODO:
----
See TODO.txt
ROADMAP:
--------
See ROADMAP.txt
REFERENCES:
----------
http://www.mortbay.org/maven-plugin
http://docs.codehaus.org/display/JETTY/Maven+Jetty+Plugin
http://maven.apache.org/plugins/maven-war-plugin/war-mojo.html
http://maven.apache.org/guides/getting-started/index.html#How_do_I_filter_resource_files
http://maven.apache.org/pom.html#Final
http://maven.apache.org/plugins/maven-resources-plugin/resources-mojo.html
http://jira.codehaus.org/browse/CARGO-416
http://www.javaworld.com/javaworld/jw-05-2006/jw-0529-maven.html
http://cargo.codehaus.org/Maven2+Plugin+Installation
http://cargo.codehaus.org/Deploying+to+a+running+container
http://maven.apache.org/plugins/maven-release-plugin/
http://www.javaworld.com/javaworld/jw-02-2006/jw-0227-maven.html?page=2
http://maven.apache.org/doxia/references/apt-format.html
http://maven.apache.org/guides/mini/guide-site.html

View File

@@ -1,21 +0,0 @@
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
TODO (in order of priority):
-----
- make jetty:run-inplace work for easy runtime editing
- Integration testing with selenium
- unit testing suite

View File

@@ -1,52 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version
2.0 (the "License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0 Unless required by
applicable law or agreed to in writing, software distributed under the
License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
CONDITIONS OF ANY KIND, either express or implied. See the License for
the specific language governing permissions and limitations under the
License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<artifactId>maven-alfresco-extension-archetype</artifactId>
<packaging>maven-archetype</packaging>
<name>Maven alfresco Extension archetype</name>
<parent>
<groupId>com.sourcesense.alfresco</groupId>
<artifactId>maven-alfresco-archetypes</artifactId>
<version>1.9.1-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>
<description>
This archetype developed aims to provide a standardized approach to development, release and deployment of Alfresco extensions (as opposed to
AMP builds, to be released as a different artifact ). Using standard m2 lifecycle commands (mvn compile package deploy) and generally
available plugins (cargo, release, assembly) we are able to cover a very high percentage of Alfresco lifecycle common use cases. It can be
used both with Maven2 and Ant build systems, but it must be clear that *only* the Maven2 approach provides all the automation features we will
describe in this website. In addition to that the m2 approach provides a zero-conf approach while ant requires (as usual) manual gathering and
selection of required alfresco libraries and webapp (please refer to README-ant.txt for further info about the Ant build). Last but not the
least, m2 build is more likely to be maintained and improved (especially in the likely case Alfresco moves to maven2). For more details on the
m2 apprach please refer instead to README Section (or directly and to README-m2.txt of the generated project).
</description>
<build>
<extensions>
<extension>
<groupId>org.apache.maven.archetype</groupId>
<artifactId>archetype-packaging</artifactId>
<version>2.0-alpha-2</version>
</extension>
<!--
Unreleased version of webdav wagon plugin which fixes a boring
stacktrace logging from this provider. FIXME: Improve the fix and
submit the patch
-->
</extensions>
</build>
</project>

View File

@@ -1,35 +0,0 @@
<document>
<properties>
<title>Maven Alfresco Extension archetype</title>
<author email="gabriele.columbro@alfresco.com">Gabriele Columbro</author>
</properties>
<body>
<release version="1.9.1" date="2009-12-03" description="Consolidated release to maven.alfresco.com">
<action dev="columbro" type="add">
Added -Prun profile to encapsulate jetty embedded running capabilities
</action>
<action dev="columbro" type="add">
Added -Pinitialize profile to clean alf_data and drop/create DB within the build
</action>
<action dev="columbro" type="add">
Updated all docs to Maven Alfresco repository
</action>
<action dev="columbro" type="update">
Incapsulated jetty run in the -Prun profile, which runs by default jetty during the integration-test phase
</action>
</release>
<release version="1.9.0" date="2009-11-07" description="Public release alfresco 3.2r based">
<action dev="columbro" type="add">
Updated to Alfresco 3.2r artifacts
</action>
<action dev="columbro" type="add">
Updated to new Sourcesense repository
</action>
</release>
<release version="1.1.0" date="2008-07-11" description="Public release">
<action dev="columbro" type="add">
Added full AMP lifecycle management.
</action>
</release>
</body>
</document>

View File

@@ -1,112 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?><archetype-descriptor name="maven-alfresco-extension-archetype">
<fileSets>
<fileSet filtered="true" encoding="UTF-8">
<directory>src/main/java</directory>
<includes>
<include>**/*.java</include>
</includes>
</fileSet>
<fileSet filtered="true" encoding="UTF-8">
<directory>src/main/webapp</directory>
<includes>
<include>**/*.xml</include>
<include>**/*.txt</include>
</includes>
</fileSet>
<fileSet filtered="true" encoding="UTF-8">
<directory>src/main/properties</directory>
<includes>
<include>**/*.txt</include>
<include>**/*.properties</include>
</includes>
</fileSet>
<fileSet filtered="true" encoding="UTF-8">
<directory>src/main/resources</directory>
<includes>
<include>**/*.xml</include>
<include>**/*.properties</include>
</includes>
</fileSet>
<fileSet encoding="UTF-8">
<directory>src/main/resources</directory>
<includes>
<include>**/*.js</include>
<include>**/*.ftl</include>
</includes>
</fileSet>
<fileSet filtered="true" encoding="UTF-8">
<directory>tools/export</directory>
<includes>
<include>**/*.txt</include>
</includes>
</fileSet>
<fileSet filtered="true" encoding="UTF-8">
<directory>tools/ant</directory>
<includes>
<include>**/*.txt</include>
<include>**/*.html</include>
<include>**/*.jsp</include>
<include>**/*.xml</include>
<include>**/*.properties</include>
</includes>
</fileSet>
<fileSet encoding="UTF-8">
<directory>tools/m2</directory>
<includes>
<include>**/*.sh</include>
</includes>
</fileSet>
<fileSet encoding="UTF-8">
<directory>tools/ant</directory>
<includes>
<include>**/*.access</include>
<include>**/*.tld</include>
<include>**/*.xsd</include>
<include>**/*.sample</include>
<include>**/*.gif</include>
<include>**/*.ftl</include>
<include>**/*.ico</include>
<include>**/*.MF</include>
<include>**/*.0-community/scripts/ajax/dojo/src/crypto/LICENSE</include>
<include>**/*.as</include>
<include>**/*.fla</include>
<include>**/*.pdf</include>
<include>**/*.0-community/scripts/ajax/dojo/src/i18n/calendar/nls/README</include>
<include>**/*.0-community/scripts/ajax/dojo/src/i18n/currency/nls/README</include>
<include>**/*.svg</include>
<include>**/*.sql</include>
<include>**/*.htm</include>
<include>**/*.password</include>
<include>**/*.exe</include>
<include>**/*.jar</include>
<include>**/*.js</include>
<include>**/*.class</include>
<include>**/*.dtd</include>
<include>**/*.wsdd</include>
<include>**/*.css</include>
<include>**/*.png</include>
<include>**/*.wsdl</include>
<include>**/*.jpg</include>
<include>**/*.smd</include>
<include>**/*.acp</include>
</includes>
</fileSet>
<fileSet encoding="UTF-8">
<directory>.externalToolBuilders</directory>
<includes>
<include>**/*.launch</include>
</includes>
</fileSet>
<fileSet filtered="true" encoding="UTF-8">
<directory></directory>
<includes>
<include>.classpath</include>
<include>.project</include>
<include>build.xml</include>
<include>maven-eclipse.xml</include>
<include>README-ANT.txt</include>
<include>README-m2.txt</include>
</includes>
</fileSet>
</fileSets>
</archetype-descriptor>

View File

@@ -1,46 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<archetype>
<id>maven-alfresco-extension-archetype</id>
<sources></sources>
<resources>
<resource>src/books/manual.xml</resource>
<resource>src/site/site.xml</resource>
<resource>src/site/apt/index.apt.vm</resource>
<resource>src/site/apt/book-index.apt</resource>
<resource>src/site/fml/faq.fml</resource>
<resource>src/main/properties/local/application.properties</resource>
<resource>src/main/properties/local/README-properties.txt</resource>
<resource>src/main/resources/alfresco/extension/custom-model-context.xml</resource>
<resource>src/main/resources/alfresco/extension/custom-model.xml</resource>
<resource>src/main/resources/alfresco/extension/custom-repository-context.xml</resource>
<resource>src/main/resources/alfresco/extension/restore-context.xml</resource>
<resource>src/main/resources/alfresco/extension/web-client-config-custom.xml</resource>
<resource>src/main/resources/alfresco/extension/webclient.properties</resource>
<resource>tools/ant/tasks/tomcat-tasks.properties</resource>
<resource>tools/ant/tasks/tomcat-tasks.xml</resource>
<resource>tools/ant/ant-bootstrap.sh</resource>
<resource>tools/m2/m2-bootstrap.sh</resource>
<resource>README-ANT.txt</resource>
<resource>README-m2.txt</resource>
<resource>build.xml</resource>
<resource>pom.xml</resource>
<resource>src/main/resources/alfresco/extension/custom-model-context.xml</resource>
<resource>src/main/resources/alfresco/extension/custom-model.xml</resource>
<resource>src/main/resources/alfresco/extension/custom-repository-context.xml</resource>
<resource>src/main/resources/alfresco/extension/file-servers-custom.xml</resource>
<resource>src/main/resources/alfresco/extension/ldap-authentication-context.xml</resource>
<resource>src/main/resources/alfresco/extension/ldap-synchronisation-context.xml</resource>
<resource>src/main/resources/alfresco/extension/restore-context.xml</resource>
<resource>src/main/resources/alfresco/extension/web-client-config-custom.xml</resource>
<resource>src/main/resources/alfresco/extension/webclient.properties</resource>
<resource>src/main/resources/log4j.properties</resource>
<resource>src/main/webapp/WEB-INF/web.xml</resource>
<resource>src/main/webapp/WEB-INF/README-WEB-INF.txt</resource>
<resource>src/main/webapp/WEB-INF/faces-config-custom.xml</resource>
<resource>tools/ant/tasks/tomcat-tasks.properties</resource>
<resource>tools/ant/tasks/tomcat-tasks.xml</resource>
<resource>tools/export/testRestoreVersion/README-restore.txt</resource>
<resource>tools/mysql/db_remove.sql</resource>
<resource>tools/mysql/db_setup.sql</resource>
</resources>
</archetype>

Some files were not shown because too many files have changed in this diff Show More