Return-Path: Delivered-To: apmail-cocoon-dev-archive@www.apache.org Received: (qmail 94165 invoked from network); 6 Apr 2005 08:42:26 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 6 Apr 2005 08:42:26 -0000 Received: (qmail 54202 invoked by uid 500); 6 Apr 2005 08:41:48 -0000 Delivered-To: apmail-cocoon-dev-archive@cocoon.apache.org Received: (qmail 53994 invoked by uid 500); 6 Apr 2005 08:41:46 -0000 Mailing-List: contact dev-help@cocoon.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: dev@cocoon.apache.org Delivered-To: mailing list dev@cocoon.apache.org Received: (qmail 53924 invoked by uid 99); 6 Apr 2005 08:41:43 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: pass (hermes.apache.org: local policy includes SPF record at spf.trusted-forwarder.org) Received: from smtp002.mail.ukl.yahoo.com (HELO smtp002.mail.ukl.yahoo.com) (217.12.11.33) by apache.org (qpsmtpd/0.28) with SMTP; Wed, 06 Apr 2005 01:41:41 -0700 Received: from unknown (HELO ?192.168.1.31?) (reinhard?poetz@62.178.239.20 with plain) by smtp002.mail.ukl.yahoo.com with SMTP; 6 Apr 2005 08:41:37 -0000 Message-ID: <4253A0C0.8010601@apache.org> Date: Wed, 06 Apr 2005 10:41:36 +0200 From: Reinhard Poetz User-Agent: Mozilla Thunderbird 0.9 (Windows/20041103) X-Accept-Language: en-us, en MIME-Version: 1.0 To: dev@cocoon.apache.org Subject: Multiple block instances References: <42444CFF.4020807@yahoo.de> <42446062.8000404@nada.kth.se> <424529B7.2020409@yahoo.de> <4245512C.3000107@nada.kth.se> <4248F241.2050503@apache.org> <4249437A.80600@nada.kth.se> <424980CB.4030708@apache.org> <42499D1D.6000104@nada.kth.se> <4249ED2C.8060408@apache.org> <424A84B7.1000008@nada.kth.se> <424AD336.5090804@apache.org> <145538d32be941a4d4a0cdaf34368a84@betaversion.org> <42515C8B.50200@nada.kth.se> <27d16f2cfcb013d36d2df2f35f6ac93e@betaversion.org> <42517468.4040305@nada.kth.se> <4251B18F.80608@nada.kth.se> <4251E699.7050901@reverycodes.com> <42525111.70005@nada.kth.se> <4252C166.7010504@apache.org> <42539683.2060307@nada.kth.se> In-Reply-To: <42539683.2060307@nada.kth.se> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-Virus-Checked: Checked X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Daniel Fagerstrom wrote: > Consider the following case: One of my applications use a repository > block, and this repository block has a db connection with name and > password as deplyment parameters. If another application need to use the > same repository block, but connected to another db it will have other > deployment parameters. In this case we will have two deployed instances > of the same block with different deployment parameters. How do we differ > between them. If you need different behaviour of one block you will have to extend it (so it gets another unique ID) and only change the properties in block.xml. (Although I think that this isn't a good example because it's not a consuming block's concern to set the database connection IMO). > > Another case is if we follow the method of handling the profile info for > a portal block that Reinhard proposed. If we want to use two portals > under the same Cocoon the portal block will be deployed in two instances > with different implementations of the profile contract. Also here is the > question is how we differ between the two instances. Let's assume that you want to deploy two custom blocks that are based on the portal block. Doing so leds to two different blocks (--> different block IDs) which both extend the same block. Both blocks can use the same profile block to be customized or each gets its own - depends on your requirements. -- Reinhard P�tz Independent Consultant, Trainer & (IT)-Coach {Software Engineering, Open Source, Web Applications, Apache Cocoon} web(log): http://www.poetz.cc --------------------------------------------------------------------