You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@turbine.apache.org by Gunter Miessbrandt <mi...@ixtern.de> on 2002/03/21 15:04:13 UTC

link to a RawScreen

Hi List!

We have a RawScreen which should create a PDF-OutputStream.
Our Problem: How to point to this Screen from a Velocity-Template?
We have tried:
$link.setPage("admin.PDFRawScreen")
$link.setPage("admin,PDFRawScreen")
$link.setScreen("admin.PDFRawScreen")

We always get an class not found Exception.
What should we do?

Gunter M.

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: config layers

Posted by Jason van Zyl <jv...@zenplex.com>.
On Tue, 2002-03-26 at 10:15, Chris Shenton wrote:
> "Gareth Coltman" <ga...@majorband.co.uk> writes:
> 
> > Alternatively a method we used was to use tokens  like
> > 
> > @dbdriver@
> > 
> > in the tr.props file and have a seperate build.properties file outside of
> > cvs, e.g.
> > 
> > dbdriver=Oracle
> > 
> > Then use ant to filter the tr.props fill and fill in the tokens from the
> > build.props at build time.
> 
> Is it possible to make a decision on how to populate this at run-time,
> like based on the hostname? That way I wouldn't have to  have a
> separate mini-config file for each host.

I do have something for this but I have to dig it out. I made an sample
installer for Tambora that used a small configuration file to generate
the target db stuff. I'm planning on integrating it into the TDK, but no
time as yet. This is definitely possible, actually creating the db on
the client machine automatically.
 
> We take our source from CVS then wipe-and-install on the target QA
> systems where our DB also has different configs. After that, we
> wipe-and-install into our Production systems, where there's yet
> another config.  It would be real nice if we didn't have to tweak
> these DB-config files each time but could let Ant make a decision
> based on hostname or something else machine-specific.
> 
> Thanks.
> 
> --
> To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>
-- 
jvz.

Jason van Zyl
jvanzyl@apache.org

http://tambora.zenplex.org


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: config layers

Posted by Chris Shenton <Ch...@hq.nasa.gov>.
"Gareth Coltman" <ga...@majorband.co.uk> writes:

> Alternatively a method we used was to use tokens  like
> 
> @dbdriver@
> 
> in the tr.props file and have a seperate build.properties file outside of
> cvs, e.g.
> 
> dbdriver=Oracle
> 
> Then use ant to filter the tr.props fill and fill in the tokens from the
> build.props at build time.

Is it possible to make a decision on how to populate this at run-time,
like based on the hostname? That way I wouldn't have to  have a
separate mini-config file for each host.

We take our source from CVS then wipe-and-install on the target QA
systems where our DB also has different configs. After that, we
wipe-and-install into our Production systems, where there's yet
another config.  It would be real nice if we didn't have to tweak
these DB-config files each time but could let Ant make a decision
based on hostname or something else machine-specific.

Thanks.

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: config layers

Posted by Gareth Coltman <ga...@majorband.co.uk>.
Alternatively a method we used was to use tokens  like

@dbdriver@

in the tr.props file and have a seperate build.properties file outside of
cvs, e.g.

dbdriver=Oracle

Then use ant to filter the tr.props fill and fill in the tokens from the
build.props at build time.

This is also useful for different development/live builds.

Gareth

> -----Original Message-----
> From: Skip Walker [mailto:skipwork@skipwalker.com]
> Sent: 26 March 2002 03:19
> To: 'Turbine Users List'
> Subject: RE: config layers
>
>
>
> Simple!
>
> Cut the relevant database properties out of TR.props and put them into
> another file, say DB.properties.
>
> Add the following line to the TR.props file:
>
> include=DB.properties
>
>
> Use a different DB.properties file depending on your needed configuration.
>
> Skip
>
>
> > -----Original Message-----
> > From: Jesse Chen [mailto:jesse@jalvamedia.com]
> > Sent: Monday, March 25, 2002 9:03 PM
> > To: Turbine Users List
> > Subject: config layers
> >
> >
> > Hi,
> >
> > We have 2 teams that are currently developing on a shared
> > codebase using
> > Turbine2.1 in CVS in opposite parts of the world.
> > Unfortunately, the DB
> > settings need to be different for each team due to network
> > infrastructure
> > issues.
> >
> > I was wondering if there was an elegant way to point the
> > Database Settings
> > properties in TurbineResources.properties to an alternate
> > properties file
> > (ie: conf/localDev.properties) without having to extend the
> > TurbineResource
> > classes? This way, we can share config settings on everything
> > else except
> > the DB settings, which can be managed locally.
> >
> > thx,
> >
> > J
> >
> >
> >
> > --
> > To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> For additional commands, e-mail:
> <ma...@jakarta.apache.org>
>
>
> --
> To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> For additional commands, e-mail:
> <ma...@jakarta.apache.org>
>
>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: config layers

Posted by Skip Walker <sk...@skipwalker.com>.
Simple!

Cut the relevant database properties out of TR.props and put them into
another file, say DB.properties.

Add the following line to the TR.props file:

include=DB.properties


Use a different DB.properties file depending on your needed configuration.

Skip


> -----Original Message-----
> From: Jesse Chen [mailto:jesse@jalvamedia.com]
> Sent: Monday, March 25, 2002 9:03 PM
> To: Turbine Users List
> Subject: config layers
>
>
> Hi,
>
> We have 2 teams that are currently developing on a shared
> codebase using
> Turbine2.1 in CVS in opposite parts of the world.
> Unfortunately, the DB
> settings need to be different for each team due to network
> infrastructure
> issues.
>
> I was wondering if there was an elegant way to point the
> Database Settings
> properties in TurbineResources.properties to an alternate
> properties file
> (ie: conf/localDev.properties) without having to extend the
> TurbineResource
> classes? This way, we can share config settings on everything
> else except
> the DB settings, which can be managed locally.
>
> thx,
>
> J
>
>
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


config layers

Posted by Jesse Chen <je...@jalvamedia.com>.
Hi,

We have 2 teams that are currently developing on a shared codebase using
Turbine2.1 in CVS in opposite parts of the world. Unfortunately, the DB
settings need to be different for each team due to network infrastructure
issues.

I was wondering if there was an elegant way to point the Database Settings
properties in TurbineResources.properties to an alternate properties file
(ie: conf/localDev.properties) without having to extend the TurbineResource
classes? This way, we can share config settings on everything else except
the DB settings, which can be managed locally.

thx,

J



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


AW: link to a RawScreen

Posted by Gunter Miessbrandt <mi...@ixtern.de>.
Thanks for your reply!

It works now.
The package was correct, but the class was defined abstract and so
turbine couldn't take an instance of it.
A little cut and paste fault!


Gunter M.

> -----Ursprungliche Nachricht-----
> Von: Steve [mailto:turbine_user@knology.net]
> Gesendet: Dienstag, 26. Marz 2002 03:20
> An: Turbine Users List
> Betreff: RE: link to a RawScreen
> 
> 
> I use a class that extends RawScreen to output PDF and I call it (from a
> template) like your #3 & it works for me...
> 
> <a href="$link.setScreen("Reports.Billing.DailyStaffBillsScreen")">Daily
> Staff Bills</a>
> 
> and of course my screen is in screens/Reports/Billing
> 
> Maybe a typo on your part somewhere?
> 
> Usually when I have a class not found error, it's because I 
> forgot to change
> the package name, so the class file ends up in the wrong directory...
> 
> HTH,
> Steve
> 
> 
> -----Original Message-----
> From: Gunter Miessbrandt [mailto:miessbrandt@ixtern.de]
> Sent: Thursday, March 21, 2002 8:04 AM
> To: Turbine Users List
> Subject: link to a RawScreen
> 
> 
> Hi List!
> 
> We have a RawScreen which should create a PDF-OutputStream.
> Our Problem: How to point to this Screen from a Velocity-Template?
> We have tried:
> $link.setPage("admin.PDFRawScreen")
> $link.setPage("admin,PDFRawScreen")
> $link.setScreen("admin.PDFRawScreen")
> 
> We always get an class not found Exception.
> What should we do?
> 
> Gunter M.
> 
> --
> To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> For additional commands, e-mail:
> <ma...@jakarta.apache.org>
> 
> 
> 
> --
> To unsubscribe, e-mail:   
> <ma...@jakarta.apache.org>
> For additional commands, e-mail: 
> <ma...@jakarta.apache.org>
> 

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: link to a RawScreen

Posted by Steve <tu...@knology.net>.
I use a class that extends RawScreen to output PDF and I call it (from a
template) like your #3 & it works for me...

<a href="$link.setScreen("Reports.Billing.DailyStaffBillsScreen")">Daily
Staff Bills</a>

and of course my screen is in screens/Reports/Billing

Maybe a typo on your part somewhere?

Usually when I have a class not found error, it's because I forgot to change
the package name, so the class file ends up in the wrong directory...

HTH,
Steve


-----Original Message-----
From: Gunter Miessbrandt [mailto:miessbrandt@ixtern.de]
Sent: Thursday, March 21, 2002 8:04 AM
To: Turbine Users List
Subject: link to a RawScreen


Hi List!

We have a RawScreen which should create a PDF-OutputStream.
Our Problem: How to point to this Screen from a Velocity-Template?
We have tried:
$link.setPage("admin.PDFRawScreen")
$link.setPage("admin,PDFRawScreen")
$link.setScreen("admin.PDFRawScreen")

We always get an class not found Exception.
What should we do?

Gunter M.

--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>