Search:

Apache » Lenya
project logo
  • Project
  • Developer
  • Community
  • Version 2.0
  • Version 1.2
  • Version 2.0
    • FAQs
    • Installation
      • Download
      • Subversion Access
      • Install Instructions
    • Tutorials
      • Create a Publication
      • Create a Resource Type
        • Declaration
        • Creation
        • Presentation
        • Editing (One-Form)
        • Editing (BXE)
      • Implement a Usecase
        • Prerequisites
        • The Usecase
      • Setting up Eclipse
      • Proxying
        • Proxying
        • mod_proxy
        • mod_proxy_ajp
      • Best Practises
      • Production Checklist
      • Writing Tests
    • Concepts
      • Publication
      • Working with Documents
      • Authoring and Live mode
      • WYSIWYG
    • Technical Reference
      • Overview of Lenya Sitemaps
      • Repository
      • Access Control Specification
      • Usecase Framework
        • Overview
        • AbstractUsecase
      • Publications
        • Configuration
        • Publication Templating
      • Resource Types
      • Modules
      • Meta data
      • Protocols
        • lenya Protocol
        • lenya-document Protocol
        • site Protocol
        • lenyadoc Protocol
        • fallback Protocol
      • URLs and Links
        • URL Mapping
        • Link Management
      • Clustering
    • Core API
    • Core Modules
      • ac
        • Overview
        • API
      • acusecases
        • Overview
        • API
      • administration
        • Overview
        • API
      • cache
        • Overview
        • API
      • janitor
        • Overview
        • API
      • ldap
        • Overview
        • API
      • linking
        • Overview
        • API
      • observation
        • Overview
        • API
      • properties
        • Overview
        • API
      • sitemanagement
        • Overview
        • API
      • templating
        • Overview
        • API
      • usecase
        • Overview
        • API
      • workflow
        • Overview
        • API
    • Standard Modules
      • blog
        • Overview
        • API
      • bxe
        • Overview
      • cforms
        • Overview
        • API
      • collection
        • Overview
        • API
      • contactform
        • Overview
        • API
      • development
        • Overview
        • API
      • editors
        • Overview
        • API
      • export
        • Overview
        • API
      • fckeditor
        • Overview
        • API
      • kupu
        • Overview
        • API
      • languageselector
        • Overview
      • lenyadoc
        • Overview
        • API
      • linkcheck
        • Overview
        • API
      • links
        • Overview
        • API
      • lucene
        • Overview
        • API
      • migration
        • Overview
        • API
      • navigation
      • neutron
        • Overview
      • news
        • Overview
        • API
      • notification
        • Overview
        • API
      • opendocument
        • Overview
        • API
      • prettyprinting
        • Overview
      • profiling
        • Overview
      • resource
        • Overview
        • API
      • simplesite
        • Overview
        • API
      • sitetree
        • Overview
        • API
      • sourcerepository
        • Overview
        • API
      • svg
        • Rounded Corners
        • Resizing Images
        • API
      • tinymce
        • Overview
        • API
      • usecasedocument
        • Overview
        • API
      • webdav
        • Getting started
        • Monitoring
        • WebDAV Servers
        • API
      • xhtml
        • Overview
        • API
      • xopus
        • Overview

Current Event

Built with Apache Lenya

The resource Module

Table of Contents
  • Introduction
  • Installation
  • Headless Mode
  • Resource Icons

Introduction

The resource module contains the "resource" resource type, it allows to store arbitrary media documents.

Installation

  1. Declare the module in the <modules/> section of $PUB_HOME/config/publication.xml:

    <module name="resource"/>
  2. Assign a workflow schema to the resource type in $PUB_HOME/config/publication.xml:

    <resource-type name="resource" workflow="fallback://config/workflow/workflow.xml"/>
  3. Define the usecase policies in $PUB_HOME/config/access-control/usecase-policies.xml (or use the usecase administration GUI):

    <usecase id="resource.create">
      <role id="admin"/>
      <role id="edit"/>
    </usecase>  
    <usecase id="resource.upload">
      <role id="admin"/>
      <role id="edit"/>
    </usecase>

Headless Mode

Options:

  • http://www.idautomation.com/kb/xwindow-error.html
  • http://www.jguru.com/faq/view.jsp?EID=222296
  • try java.awt.headless=true in the case of Java 1.4
  • run X servere:
    Virtual framebuffer X server:
    
    Installation instructions for debian
    
    apt-get install xvfb
    apt-get install xlibs
    apt-get install xfonts-base
    
    nohup Xvfb :0 -screen 0 1024x786x16 &
    export DISPLAY=:0

Also you might want to add export DISPLAY=:0 in lenya.sh, such that the DISPLAY variable is set during startup of Jetty, e.g.

# ----- Verify and Set Required Environment Variables -------------------------
        
if [ "$DISPLAY" = "" ] ; then
export DISPLAY=:0
fi

Resource Icons

This module provides only one complete icon (the default one) out of the box. The default icon (default_med.gif) is a question mark. An "empty" version of this icon (without the question mark) can be found in the core (webapp/lenya/resources/images/icons/empty-icon.png). For all file extensions with no corresponding icon, an icon is generated dynamically by adding the first three letters of the extension as a label to the empty icon.

If you can provide icons with a ASF style license we are happy to add them to the module.

If you want your own set of icons, then please add them to $PUB_HOME/lenya/modules/resource/resources/icons/.

You can download and extract e.g. the icon package from Wyona in your publication:

https://svn.wyona.com/repos/public/lenya/modules-resource-icons.tar
user: anonymous
pass: anonymous

Have fun!

Copyright © 1999-2011 The Apache Software Foundation. All rights reserved.

Apache Lenya, Apache, and the Apache feather logo are trademarks of The Apache Software Foundation.