You can subscribe to this list here.
| 2001 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(35) |
Nov
(38) |
Dec
(112) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2002 |
Jan
(20) |
Feb
(24) |
Mar
(47) |
Apr
(18) |
May
(28) |
Jun
(17) |
Jul
(15) |
Aug
(40) |
Sep
(14) |
Oct
(5) |
Nov
(26) |
Dec
(31) |
| 2003 |
Jan
(8) |
Feb
(14) |
Mar
(38) |
Apr
(34) |
May
(33) |
Jun
(32) |
Jul
(24) |
Aug
(9) |
Sep
|
Oct
(20) |
Nov
(43) |
Dec
(22) |
| 2004 |
Jan
(23) |
Feb
(25) |
Mar
(15) |
Apr
(3) |
May
(31) |
Jun
(13) |
Jul
(3) |
Aug
(3) |
Sep
(13) |
Oct
(15) |
Nov
(3) |
Dec
(5) |
| 2005 |
Jan
|
Feb
|
Mar
(16) |
Apr
(24) |
May
|
Jun
(2) |
Jul
|
Aug
(5) |
Sep
(4) |
Oct
|
Nov
(3) |
Dec
(2) |
| 2006 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: Chris M. <Chr...@te...> - 2002-01-29 21:17:59
|
Just wondering if there was a way I could set up per-user update rights on specific static pages using the existing page-edit interface. Thanks, Chris McDaniel |
|
From: Chris W. <ch...@cw...> - 2002-01-22 12:30:19
|
On Tue, 2002-01-22 at 02:08, Chris McDaniel wrote:
>
> Hello,
>
> Looking over this code, I'm noticing that it's awfully messy, but I'm hoping
> someone can help me out. In the code below is the save routine from the
> package I'm working on. It branches near the end for new records and
> updates. Anyway, the save works in the case of a new record, but not an
> update. The only error I get is:
>
> Can't call method "save" on unblessed reference at
> /var/www/testsite/pkg/monitoring-0.01/testsite/Handler/Monitoring.pm line
> 410.
With errors like this, the variable ($host in this case) was probably
initialized to something other than you think. Probably the best thing
to do is ensure:
- $R->host returns the class for your object
- $host is an object rather than just a hashref. (Data::Dumper can be
your best friend for this)
so add:
use Data::Dumper qw( Dumper );
at the top of your handler, then do something like:
# New
$R->scrib( 1, "Host class is [", $R->host, "] and ",
"host is: ", Dumper( $host ) );
# Existing
if ($apr->param("delete".$i) eq "yes") {
$host->remove({DEBUG => 5});
} else {
$host->save({DEBUG => 5});
}
As long as your server is set to debugging level 1 or above. Hopefully
the results will be illuminating.
Chris
--
Chris Winters (ch...@cw...)
Building enterprise-capable snack solutions since 1988.
|
|
From: Chris M. <Chr...@te...> - 2002-01-22 07:14:08
|
Hello,
Looking over this code, I'm noticing that it's awfully messy, but I'm hoping
someone can help me out. In the code below is the save routine from the
package I'm working on. It branches near the end for new records and
updates. Anyway, the save works in the case of a new record, but not an
update. The only error I get is:
Can't call method "save" on unblessed reference at
/var/www/testsite/pkg/monitoring-0.01/testsite/Handler/Monitoring.pm line
410.
The error log simply adds that it died, and the above was what was left.
And here is the code...
The form displays multiple records for editing, hence the loop and the
counter...
sub save {
my $class = shift;
my $p = shift;
my $R = OpenInteract::Request->instance;
my $apr = $R->apache;
my $done;
my $i = 1;
my $search_host;
my $host = $R->host->new;
until ($done == 1) {
undef $host;
undef $search_host;
if ($apr->param("host".$i)) {
# , customer_id int(11) not null
# , host varchar(255) not null
# , ping_type varchar(25) not null
# , is_alive varchar(1) not null
# , email varchar(255)
# , pager_number varchar(15)
# , pager_configuration_id int(11)
if ($apr->param("sqltype") =~ /update/ ) {
$search_host =
$apr->param("monitored_host_id").$i;
$host = $R->host->fetch($search_host);
} else {
$host = $R->host->new;
$host->{is_alive} = "n";
}
$host->{customer_id} =
$R->{auth}->{user}->{customer_id};
$host->{host} = $apr->param("host".$i);
$host->{ping_type} = $apr->param("ping_type".$i);
$host->{email} = $apr->param("email".$i);
$host->{pager_number} =
$apr->param("pager_number".$i);
$host->{paging_configuration_id} =
$apr->param("paging_configuration_id".$i);
if ($apr->param("delete".$i) eq "yes") {
$host->remove({DEBUG => 5});
} else {
$host->save({DEBUG => 5});
}
$i ++;
} else {
$done = 1;
}
}
my $params = { main_script => '/Monitoring', error_msg =>
$p->{error_msg} };
return $R->template->handler( {}, $params, { db => 'view_options',
package => 'monitoring' } );
}
Thanks!
Chris McDaniel
|
|
From: Chris W. <ch...@cw...> - 2002-01-16 13:53:43
|
On Mon, 2002-01-14 at 20:53, Victor Piterbarg wrote: > Thanks. Yes that's what I was asking. I'm not sure why it didn't occur to me > to just write a custom method. > > Now that we are on the subject of object relationships though...I was > looking over the mysqld query log recently to figure out why a certain > operation on the OI fron-end was taking an unusually long time. I was > unpleasantly surprised, because it turned out that one request to the page > generated ~5800 SELECT queries to the DB. The final result was about 83 > rows. The request itself took several seconds to complete. Granted, the > request involves about 15 tables, but when I rewrote it as a single query > with multiple JOIN's it took less then a second to execute. Wow -- 5800! Is part of the problem the security checking as well? If so, I'm hoping to make this more streamlined in a near-future release. If it's not part of the security checking, you're probably better off creating custom fetch_group queries that use multiple tables. If you haven't seen this yet, let me know and I'll post an example to the group. > I wasn't expecting SPOPS to build elaborate JOIN's for me (although that > would be nice :-), but it also appeared that certain identical queries were > sent multiple times! > > Oh, and what about transactions? Let's say I want to save a series of > objects as a transaction. Anything planned for that? Nothing definite, yet. OI assumes that you're using AutoCommit, but you can turn it off, do actions and commit/rollback as needed. LMK if you'd like to see an example as I'm running out the door :-) Later, Chris -- Chris Winters (ch...@cw...) Building enterprise-capable snack solutions since 1988. |
|
From: Chris W. <ch...@cw...> - 2002-01-16 13:50:54
|
On Tue, 2002-01-15 at 03:53, Andreas Fitzner wrote:
> I found a workaround. It took all my courage, but I looked at the postgresql
> source code & after a while I found src/include/postgres_ext.h with the
> definition #define NAMEDATALEN 32
>
> after some grepping i found that postgresql saves its relationnames,
> sequencenames, ... in a internal table called "pg_class c" as datatype "Name"
> (VARCHAR(NAMEDATALEN-1)).
>
> I increased its value to 250, recompiled postgresql. regession tests ->
> core dump. hm.
> set it to 80. recompiled. regession tests. all succeded except one: name.sql,
> where postgresql tests whether "all inputs are silently truncated at
> NAMEDATALEN (32) characters". :)
> So far it works. ...
Wow. I'll keep this in mind as an alternate method :-)
> another point:
>
> I recognised that i had to do a chmod 777 $OIWEBSITE/cache, so that
> httpd ("nobody") can use it. It would be good if
> oi_manage --website_name=? create_website
> would do this automatically.
Actually, I think I'll put this in the INSTALL.website since we (a)
don't know what user the website is running under and (b) run on
non-Unix OSes.
> and $OIWEBSITE/html/{index,login}.html and $OIWEBSITE/images/* have
> permission 775. shouldn't this be 644?
Maybe so. However, don't people also run servers so that the webserver
*group* has read/write permissions to the files? Or maybe not...
I will also put this in the INSTALL.website as 'Permission issues' or
something.
Thanks,
Chris
--
Chris Winters (ch...@cw...)
Building enterprise-capable snack solutions since 1988.
|
|
From: Andreas F. <fi...@in...> - 2002-01-15 08:53:39
|
On Mon, Jan 14, 2002 at 08:42:38AM -0500, Chris Winters wrote: > I was hoping to get the next version of OI out before anyone using > Postgres noticed this! :-) > > SPOPS lets you specify a sequence name other than the default, so the > latest version of the base_page package[1] has the truncated sequence > name. The 0.55 release of SPOPS has a fix to let the custom sequence > name work properly. > > Chris > > [1] http://sourceforge.net/project/showfiles.php?group_id=16810 Hi Chris, Thanks for your reply. I found a workaround. It took all my courage, but I looked at the postgresql source code & after a while I found src/include/postgres_ext.h with the definition #define NAMEDATALEN 32 after some grepping i found that postgresql saves its relationnames, sequencenames, ... in a internal table called "pg_class c" as datatype "Name" (VARCHAR(NAMEDATALEN-1)). I increased its value to 250, recompiled postgresql. regession tests -> core dump. hm. set it to 80. recompiled. regession tests. all succeded except one: name.sql, where postgresql tests whether "all inputs are silently truncated at NAMEDATALEN (32) characters". :) So far it works. .... another point: I recognised that i had to do a chmod 777 $OIWEBSITE/cache, so that httpd ("nobody") can use it. It would be good if oi_manage --website_name=? create_website would do this automatically. and $OIWEBSITE/html/{index,login}.html and $OIWEBSITE/images/* have permission 775. shouldn't this be 644? anyhow, best wishes, Andreas :) |
|
From: Victor P. <ope...@ha...> - 2002-01-15 01:55:00
|
Thanks. Yes that's what I was asking. I'm not sure why it didn't occur to me
to just write a custom method.
Now that we are on the subject of object relationships though...I was
looking over the mysqld query log recently to figure out why a certain
operation on the OI fron-end was taking an unusually long time. I was
unpleasantly surprised, because it turned out that one request to the page
generated ~5800 SELECT queries to the DB. The final result was about 83
rows. The request itself took several seconds to complete. Granted, the
request involves about 15 tables, but when I rewrote it as a single query
with multiple JOIN's it took less then a second to execute.
I wasn't expecting SPOPS to build elaborate JOIN's for me (although that
would be nice :-), but it also appeared that certain identical queries were
sent multiple times!
Oh, and what about transactions? Let's say I want to save a series of
objects as a transaction. Anything planned for that?
Thanks.
-Victor
-----Original Message-----
From: ope...@li...
[mailto:ope...@li...]On Behalf Of Chris
Winters
Sent: Monday, January 14, 2002 5:52 AM
To: Victor Piterbarg
Cc: oc-help
Subject: Re: [Openinteract-help] couple of questions abour
links_torelationships.
On Sun, 2002-01-13 at 21:18, Victor Piterbarg wrote:
> I am writing a product system which is turning out to be fairly complex.
One
> of the features I want to implement is product dependecy, i.e you can't
buy
> X without buying Y as well. Now to do this I would need to link a product
> object to a bunch of other product objects. However, using the current
> links_to implementation, I wouldn't be able to this in a straighforward
> manner because links to expects to see the ID's from the respective
objects
> that are being linked. I can't do that, since the ID fields in this case
> would be the same -- can't make a table like that.
>
> I could do this in a round-about way by creating a wrapper object, which
> would contain a single product_id (named as something else, like
> product_id_dep). Then I would create a links_to relationship from my real
> product object, to a bunch of the wrapper objects. This would waste space
> and time, however.
>
> Now, I have another hypothetical question. Let's say I also wanted to link
> and product to a list of products which can not be purchased at the same
> time as the original product. Currently I would have to create another
> wrapper object for this.
>
> So, am I missing something? Or should I just go with the wrapper objects?
> Thanks.
In my experience, business logic tasks like this should be done with
custom rather than generated code. It's easy to create a custom linking
method that fetches required relationships from a linking table, where
you have something like:
product --> product_link
product_id product_id
required_product_id
And then create a method like:
sub get_required_products {
my ( $self ) = @_;
my $where = 'product_link.product_id = ? AND ' .
'product_link.required_product_id = product.product_id';
return $self->fetch_group({
from => [ $self->table_name, 'ProductLink' ],
where => $where,
value => [ $self->id ] });
}
And then later on in your process if you need to modify how these
relationships are created/fetched -- e.g., you order them based on
strength, or what other products are in the cart, or whatever -- then
you have one place to do it and an API already in place.
Hope I understood your question correctly.
Later,
Chris
--
Chris Winters (ch...@cw...)
Building enterprise-capable snack solutions since 1988.
_______________________________________________
openinteract-help mailing list
ope...@li...
https://lists.sourceforge.net/lists/listinfo/openinteract-help
|
|
From: Chris W. <ch...@cw...> - 2002-01-14 13:46:18
|
On Mon, 2002-01-14 at 08:12, Jochen Lillich wrote:
> Is there a proper documentation what I have to do when I upgrade from
> OI 1.30 to OI 1.36? I'm going to do that with a few sites.
>
> Because of the changes to server.perl mentioned in the UPGRADE file, I
> recreated it from the sample file.
>
> File permission problems with the new 'tmplib' directory were solved
> quickly. But now I run into heavy security and template problems.
>
> After copying base_main from pkg/base_theme/template into
> WEBSITE_DIR/templates at least the site came up. But OI said "Access
> Forbidden". The log:
>
> [Mon Jan 14 14:11:06 2002] null: linuxde::Handler::BasicPage::_retrieve_object (341) >> Trying to retrieve OBJECT with location (/)
> [Mon Jan 14 14:11:06 2002] null: linuxde::Handler::BasicPage::_retrieve_object (351) >> Trying to grab a directory; adding home
> [Mon Jan 14 14:11:07 2002] null: -- Found error when fetching object: $VAR1 = {
> [Mon Jan 14 14:11:07 2002] null: 'user_msg' => 'Action prohibited due to security. Insufficient access for requested action',
> [Mon Jan 14 14:11:07 2002] null: 'line' => 157,
> [Mon Jan 14 14:11:07 2002] null: 'extra' => {
> [Mon Jan 14 14:11:07 2002] null: 'security' => '1'
> [Mon Jan 14 14:11:07 2002] null: },
> [Mon Jan 14 14:11:07 2002] null: 'filename' => '/usr/lib/perl5/site_perl/5.6.1/SPOPS/Secure.pm',
> [Mon Jan 14 14:11:07 2002] null: 'system_msg' => 'Required access: 4; retrieved access: 1',
> [Mon Jan 14 14:11:07 2002] null: 'method' => 'SPOPS::Error::set',
> [Mon Jan 14 14:11:07 2002] null: 'package' => 'SPOPS::Secure',
> [Mon Jan 14 14:11:07 2002] null: 'type' => 'security'
> [Mon Jan 14 14:11:07 2002] null: };
>
> Logged in as superuser, the page displays. But normal users should
> also see the page!
The 'static_page' module is deprecated now -- see if you can follow the
directions in $WEBSITE_DIR/pkg/base_page-x.xx/doc/base_page.pod under
'MIGRATION' to move those pages over to the new system.
> Then, still as su, I clicked the link "Security" in admin tools, and
> got:
>
> Cannot process template!file error - Template (error_message) is not in
> the website common directory and is not in the format 'package::name'
> at /usr/lib/perl5/site_perl/5.6.1/OpenInteract/Template/Process.pm line
> 162.
Ah, for this you should be able to do the following:
1) Create a file '.no_overwrite' in $WEBSITE_DIR/template and add the
line:
base_main
to it. This ensures your main template won't get overwritten.
2) Run:
$ export OIWEBSITE=/path/to/mysite
$ oi_manage refresh_widget
Which will ensure that all the 'widgets' in OI are in your website,
including the 'error_message' and a number of others.
If you run into anything else, let the list know. The next version is
pretty much ready to go but I'd like to make sure the upgrading process
isn't totally painful...
Chris
--
Chris Winters (ch...@cw...)
Building enterprise-capable snack solutions since 1988.
|
|
From: Chris W. <ch...@cw...> - 2002-01-14 13:26:38
|
On Sun, 2002-01-13 at 21:18, Victor Piterbarg wrote:
> I am writing a product system which is turning out to be fairly complex. One
> of the features I want to implement is product dependecy, i.e you can't buy
> X without buying Y as well. Now to do this I would need to link a product
> object to a bunch of other product objects. However, using the current
> links_to implementation, I wouldn't be able to this in a straighforward
> manner because links to expects to see the ID's from the respective objects
> that are being linked. I can't do that, since the ID fields in this case
> would be the same -- can't make a table like that.
>
> I could do this in a round-about way by creating a wrapper object, which
> would contain a single product_id (named as something else, like
> product_id_dep). Then I would create a links_to relationship from my real
> product object, to a bunch of the wrapper objects. This would waste space
> and time, however.
>
> Now, I have another hypothetical question. Let's say I also wanted to link
> and product to a list of products which can not be purchased at the same
> time as the original product. Currently I would have to create another
> wrapper object for this.
>
> So, am I missing something? Or should I just go with the wrapper objects?
> Thanks.
In my experience, business logic tasks like this should be done with
custom rather than generated code. It's easy to create a custom linking
method that fetches required relationships from a linking table, where
you have something like:
product --> product_link
product_id product_id
required_product_id
And then create a method like:
sub get_required_products {
my ( $self ) = @_;
my $where = 'product_link.product_id = ? AND ' .
'product_link.required_product_id = product.product_id';
return $self->fetch_group({
from => [ $self->table_name, 'ProductLink' ],
where => $where,
value => [ $self->id ] });
}
And then later on in your process if you need to modify how these
relationships are created/fetched -- e.g., you order them based on
strength, or what other products are in the cart, or whatever -- then
you have one place to do it and an API already in place.
Hope I understood your question correctly.
Later,
Chris
--
Chris Winters (ch...@cw...)
Building enterprise-capable snack solutions since 1988.
|
|
From: Chris W. <ch...@cw...> - 2002-01-14 13:17:41
|
On Sun, 2002-01-13 at 14:46, Andreas Fitzner wrote: > ... > I get > Error: DBD::Pg::st execute failed: ERROR: ExecAppend: > Fail to add null value in not null attribute content_type_id at /usr/local/libdata > /perl5/site_perl/SPOPS/SQLInterface.pm line 309. > > ... > > because there is no sequence content_type_content_type_id_seq (=32 character). > > when i do > > opensci=# create table content_type_content_type_id_seq (test int); > NOTICE: identifier "content_type_content_type_id_seq" will be truncated to "content_type_content_type_id_se" > CREATE > opensci=# > > it will be truncated. > > anyone who knows how to fix this? > is there a tweak to let postgres accept longer columnnames? > > OpenInteract ist not running without it. I was hoping to get the next version of OI out before anyone using Postgres noticed this! :-) SPOPS lets you specify a sequence name other than the default, so the latest version of the base_page package[1] has the truncated sequence name. The 0.55 release of SPOPS has a fix to let the custom sequence name work properly. Chris [1] http://sourceforge.net/project/showfiles.php?group_id=16810 -- Chris Winters (ch...@cw...) Building enterprise-capable snack solutions since 1988. |
|
From: Jochen L. <jl...@te...> - 2002-01-14 13:13:33
|
Hi!
Is there a proper documentation what I have to do when I upgrade from
OI 1.30 to OI 1.36? I'm going to do that with a few sites.
Because of the changes to server.perl mentioned in the UPGRADE file, I
recreated it from the sample file.
File permission problems with the new 'tmplib' directory were solved
quickly. But now I run into heavy security and template problems.
After copying base_main from pkg/base_theme/template into
WEBSITE_DIR/templates at least the site came up. But OI said "Access
Forbidden". The log:
[Mon Jan 14 14:11:06 2002] null: linuxde::Handler::BasicPage::_retrieve_object (341) >> Trying to retrieve OBJECT with location (/)
[Mon Jan 14 14:11:06 2002] null: linuxde::Handler::BasicPage::_retrieve_object (351) >> Trying to grab a directory; adding home
[Mon Jan 14 14:11:07 2002] null: -- Found error when fetching object: $VAR1 = {
[Mon Jan 14 14:11:07 2002] null: 'user_msg' => 'Action prohibited due to security. Insufficient access for requested action',
[Mon Jan 14 14:11:07 2002] null: 'line' => 157,
[Mon Jan 14 14:11:07 2002] null: 'extra' => {
[Mon Jan 14 14:11:07 2002] null: 'security' => '1'
[Mon Jan 14 14:11:07 2002] null: },
[Mon Jan 14 14:11:07 2002] null: 'filename' => '/usr/lib/perl5/site_perl/5.6.1/SPOPS/Secure.pm',
[Mon Jan 14 14:11:07 2002] null: 'system_msg' => 'Required access: 4; retrieved access: 1',
[Mon Jan 14 14:11:07 2002] null: 'method' => 'SPOPS::Error::set',
[Mon Jan 14 14:11:07 2002] null: 'package' => 'SPOPS::Secure',
[Mon Jan 14 14:11:07 2002] null: 'type' => 'security'
[Mon Jan 14 14:11:07 2002] null: };
Logged in as superuser, the page displays. But normal users should
also see the page!
Then, still as su, I clicked the link "Security" in admin tools, and
got:
Cannot process template!file error - Template (error_message) is not in
the website common directory and is not in the format 'package::name'
at /usr/lib/perl5/site_perl/5.6.1/OpenInteract/Template/Process.pm line
162.
What now?
Regards,
Jochen
--
----------------------------------------------------------------
*Jochen Lillich*, Dipl.-Inform. (FH)
Consultant/Trainer @ /TeamLinux GbR/
Tel. +49 7254 985187-0 http://www.teamlinux.de
----------------------------------------------------------------
|
|
From: Victor P. <ope...@ha...> - 2002-01-14 02:20:01
|
Hello, I am writing a product system which is turning out to be fairly complex. One of the features I want to implement is product dependecy, i.e you can't buy X without buying Y as well. Now to do this I would need to link a product object to a bunch of other product objects. However, using the current links_to implementation, I wouldn't be able to this in a straighforward manner because links to expects to see the ID's from the respective objects that are being linked. I can't do that, since the ID fields in this case would be the same -- can't make a table like that. I could do this in a round-about way by creating a wrapper object, which would contain a single product_id (named as something else, like product_id_dep). Then I would create a links_to relationship from my real product object, to a bunch of the wrapper objects. This would waste space and time, however. Now, I have another hypothetical question. Let's say I also wanted to link and product to a list of products which can not be purchased at the same time as the original product. Currently I would have to create another wrapper object for this. So, am I missing something? Or should I just go with the wrapper objects? Thanks. -Victor |
|
From: Andreas F. <fi...@in...> - 2002-01-13 19:46:38
|
Hi,
I tried to install OpenInteract with Postgres instead of MySQL as the
backend RDBMS. everything went fine. I followed the steps in INSTALL.website.
oi_manage test_db
returns ok.
oi_manage --driver=SPOPS::DBI::Pg change_spops_driver
also ok.
now, running
oi_manage --package=INITIAL install_sql
gives me headaches. it seams postgres truncates the columnnames
to 31 characters.
I get
Error: DBD::Pg::st execute failed: ERROR: ExecAppend:
Fail to add null value in not null attribute content_type_id at /usr/local/libdata
/perl5/site_perl/SPOPS/SQLInterface.pm line 309.
List of relations
Name | Type | Owner
---------------------------------+----------+--------
content_type | table | oiuser
content_type_content_type_i_seq | sequence | oiuser
^<- HERE
object_keys | table | oiuser
object_track | table | oiuser
object_track_objtrack_id_seq | sequence | oiuser
page | table | oiuser
page_content | table | oiuser
sessions | table | oiuser
sys_error | table | oiuser
sys_group | table | oiuser
sys_group_group_id_seq | sequence | oiuser
sys_group_user | table | oiuser
sys_security | table | oiuser
sys_security_sid_seq | sequence | oiuser
sys_user | table | oiuser
sys_user_user_id_seq | sequence | oiuser
template | table | oiuser
template_template_id_seq | sequence | oiuser
theme | table | oiuser
theme_prop | table | oiuser
theme_prop_themeprop_id_seq | sequence | oiuser
theme_theme_id_seq | sequence | oiuser
(22 rows)
because there is no sequence content_type_content_type_id_seq (=32 character).
when i do
opensci=# create table content_type_content_type_id_seq (test int);
NOTICE: identifier "content_type_content_type_id_seq" will be truncated to "content_type_content_type_id_se"
CREATE
opensci=#
it will be truncated.
anyone who knows how to fix this?
is there a tweak to let postgres accept longer columnnames?
OpenInteract ist not running without it.
grateful for any hints,
sincerly Andreas
|
|
From: Chris W. <ch...@cw...> - 2002-01-08 15:10:51
|
On Tue, 2002-01-08 at 09:38, Chris McDaniel wrote: > I'd like to upgrade my OpenInteract installation (1.21, SPOPS 1.41). I am > nervous as I'm working in a production environment and the company would be > less than pleased if the site went down for a day because I tried to upgrade > and broke it. So, my questions are, if I upgrade what will break? How can > I minimize breakage? Hmm hah, good question. To start off with, check out the 'Changes' files in both OI and SPOPS to get a sense of what's different. With SPOPS, I don't think there are any backward-incompatible changes, so you should be ok with this part. An easy way to test it is to install the newest version to a local lib directory, 'use lib' the dir, create an $R object using OI::Setup->setup_static_environment() and do some data fetching, relationship fetching, etc. With OI, there are quite a few changes. It might be useful to do the following: - Install the latest version to a local lib directory - Create a new base installation. - Create a new website from that base installation - Edit the config file (I recommend the INI version, but YMMV) with your existing values, including the existing database - In conf/httpd_modperl.conf, put a 'use lib' statement for your local lib directory - Install any custom packages you have created to the new site - Try and startup OI Off the top of my head, you may have problems with static pages since that's done through a new package (base_page) and database setup. You can continue to use the 'static_page' package if you like though, with just a couple of server configuration modifications. And the 'base_page' package comes with a migration script. Once you've plowed through any problems and the new server looks just like the old one, you can shutdown the old server, install OI and SPOPS to the Perl installation, remove the 'use lib' from conf/httpd_modperl.conf, modify your root Apache setup as necessary (e.g., change the 'Include' statement) and fire it back up. I think the key is to first setup a parallel server and modify it so the rollover time is minimal. I did this fairly recently, from an older version of OI (1.1) and it worked very well. It wasn't a flip-the-switch rollover because a number of items had changed, but it worked fine with minimal impact. Chris -- Chris Winters (ch...@cw...) Building enterprise-capable snack solutions since 1988. |
|
From: Chris M. <Chr...@te...> - 2002-01-08 14:44:25
|
Hi, I'd like to upgrade my OpenInteract installation (1.21, SPOPS 1.41). I am nervous as I'm working in a production environment and the company would be less than pleased if the site went down for a day because I tried to upgrade and broke it. So, my questions are, if I upgrade what will break? How can I minimize breakage? Thanks, Chris McDaniel |
|
From: Habib HAIBI<ha...@fr...> - 2002-01-05 19:12:29
|
Meilleurs Voeux pour 2002 : année de mémoire, de mobilisation, d'action, de justice et de sérénité - Appel au soutien moral et financier ======================== M. Habib HAIBI, 7, Aguesseau St. 69007 LYON - France Tél. 00 33 4 72 73 19 08 - Fax 00 33 4 78 61 39 27 Email : ha...@fr... http://haibi.free.fr Je suis qualifié pour exprimer mes voeux pour le Nouvel An à tous les survivants et les familles des victimes des attaques terroristes, au peuple américain, ses dirigeants, ses institutions, son président et tous les combattants de la liberté, loin de leurs foyers, tout autour du monde! Je suis fier de vous dire avec gratitude combien Les USA sont puissants, démocratiques et qualifiés pour défendre la liberté et la démocratie avec humanisme et sérénité. L'ennemi du progrès du genre humain peut encore frapper. La liberté et la démocratie peuvent être encore sous attaques! Personne ne s'imaginait que cela pouvait arriver et c'est arrivé en ce jour pacifique du 11 septembre 2001 Personne ne s'imaginait que cela pouvait arriver en France et c'est arrivé le 26 février 2001 quand les magistrats du parquet de Lyon, par impulsion suicidaire et préméditée, ont eu recours à l'arbitraire pour entraver l'action Publique mise en Mouvement : ils ont requis l'expertise psychiatrique de la Partie Civile par l'action avant de l'entendre dans ses accusations ! Cette dérive obscurantiste a dépassé tout entendement C'est arrivé un jour pacifique pour moi et pour les institutions de la République en France. Le réquisitoire aux fins de l'expertise psychiatrique de la partie civile par l'action, avant de l'entendre dans ses accusations, constitue une atteinte obscurantiste à l'intégrité de la personne de la partie civile et surtout un attentat aux valeurs fondamentales de la société civilisée et une infamie assénée à la République et ses Institutions: - à tous les martyrs de la liberté qui ont payé de leur vie la défense des personnes et des biens et des valeurs fondamentales et universelles de la République. - à tous ceux qui dans l'exercice de leurs fonctions, au nom du devoir de servir, exposeraient leurs vies, sans hésitation, pour la défense de ces mêmes valeurs - à tous les hommes ou femmes de bonne volonté, citoyens anonymes, élevés sur la foi en une société pacifiée par l'avènement de la République, la crainte des lois et l'indéfectibilité de l'Etat, de la Justice et des Institutions en Démocratie. J'étais, longtemps avant le WTC l'autre "point zéro" de la planète qui a subit les premières vagues d'attaque contre les institutions de la République, la liberté et les droits de l'homme en France ! Il y a eu trois autres attaques avec la même détermination, diabolique et suicidaire, de stopper l'action publique régulièrement mise en mouvement ! J'ai fait face à l'adversité en mettant en accusation 15 magistrats, saisis par la foudre de l'action publique en colère, nominativement impliqués, des deux juridictions de Lyon tout rôle et rang confondus pour abus d'autorité aggravé et trafic d'influence aggravé. Une fois que vous avez pris la mesure de l'attaque contre les valeurs universelles de la liberté et la justice en démocratie en France et assimilé la grandeur de la querelle qui m'anime Votre réaction sera vivement souhaitée et sollicitée ! Je recevrai vos contributions morales et financières comme une juste consolation pour le grand préjudice moral que je subis dans l'attente de la réparation de la faute lourde par la justice et l'Etat. Souvenez-vous que la paix civile fut conquise au prix de feu, de sang et de sacrifices avec pour objectif le règne absolu et égalitaire de la loi. Imaginez les victimes du 11 septembre 2001 dans un monde sans liberté, sans justice et sans démocratie Imaginez tous les sacrifices de tous les combattants de la liberté, depuis deux siècles et plus, laissés pour compte et discrédités en une seule journée d'attaques perpétrées par les forces diaboliques de l'arbitraire et de l'obscurantisme dans le pays qui a donné naissance au reigne de la loi, l'avènement de la République et les droits de l'homme. Une nouvelle ère a commencé où le grand pays que sont les Etats Unis vont guider et pour longtemps l'impulsion de l'alerte et de la réaction pour perpétuer la liberté et la justice en démocraties. C'est aussi votre combat et le combat de tous les hommes libres. Merci au président des Etats Unis pour son leadership, l'immense puissance de son pays et sa sérénité. Merci à tous d'avoir lu et compris ce message. Merci pour vos réactions et vos contributions. ========================== Ces contributions sont souhaitées à la hauteur de 500 $ ou euros et plus pour tous les représentants élus des peuples, sénateurs et députés, quelque soit leur pays et quelque soit le moyen utilisé pour les alerter des attaques contre la démocratie et de la colère de l'action Publique en mouvement : "ma tristesse s'est muée en colère et la colère en résolution "! (ma conviction est que si de tels actes ont pu se produire c'est à cause d'un climat de permissivité qui a pu s'installer par l'absence du contrôle de l'exécutif par le pouvoir législatif ). ======= vous pouvez verser directement vos contributions financières sur le compte : RIP RELEVE D'IDENTITE BANCAIRE 20041 01007 1112632 F038 69 IBAN IDENTIFIANT INTERNATIONAL FR 53 20041 01007 1112632 F 038 69 Ou envoyer un mandat cash à mon nom et à mon adresse. ================================ Les contributions seront libres et bienvenues de la part de tout autre citoyen sensible à l'idée de vivre dans une société pacifiée par la crainte des lois et la crédibilité des institutions démocratiques. ============ Mon objectif est de réunir 10 000 réactions à 100 $ ou euros chacune : vous pouvez m'aider à atteindre ce but. Je serai, à coup sûr, un homme riche! Mais je ne recouvrerai la paix intérieure avant que justice soit faite! 'J'ai un rêve"! La justice sera faite ! ============ Le site où est publié l'ensemble du dossier est en français, vous pouvez vous aider pour la traduction par un moteur de traduction sur internet. http://haibi.free.fr ============ Cette mailing liste, non exhaustive, est composée de 30 000 emails : des représentants élus, les représentants de l'Etat, hauts fonctionnaires, magistrats, avocats, journalistes, chefs d'entreprise, président ou membre d'association, profession libérale ou tout autre simple citoyen intéressé par la vie sociale, administrative et judiciaire. ======================= Vous pourrez discuter en circuit interne non publié sur le net en vous abonnant au groupe créé pour cet objet "Il n'y a pas d'alternative à la justice en république en france" Coordonnées du groupe : Email du groupe : lec...@sm... Email du gestionnaire : lec...@sm... Pour devenir membre : lec...@sm... Pour ne plus être membre : lec...@sm... Accueil du groupe : http://smartgroups.wanadoo.fr/groups/lecitoyen.laloi.larepubliqu e ====================== Si vous ne vous sentez pas concerné, vous pouvez demander à ce que votre email soit effacer en exprimant votre volonté à l'adresse email : ha...@fr... Merci encore de participer à l'alerte et au suivi de l'action publique en mouvement, et au soutien moral et financier de la partie civile par l'action. ================================ =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =============================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== =================================================== ================================================== Vous pourrez recevoir une autre version en anglais. Ceci n'est pas un spam Merci! NEVER SEND SPAM. IT IS BAD. |
|
From: Chris W. <ch...@cw...> - 2002-01-03 03:38:56
|
On Wed, 2001-12-12 at 09:02, And...@Be... wrote: > .. and search_results is missing... >=20 > -----Urspr=FCngliche Nachricht----- > Von: Nolte, Andreas, D22K-MSN=20 > Gesendet: Mittwoch, 12. Dezember 2001 14:59 > An: 'Chris Winters' > Cc: ope...@li... > Betreff: AW: [Openinteract-help] base_page and mime types >=20 >=20 > .. OK, scrapping static_page did it. Though I found s.th. else: you forgo= t > to override MY_SEARCH_FORM_TEMPLATE to return page_search_form instead of > search_form. Going through unanswered emails... I didn't mention it in my email of 27-Dec-2001, but the latest version of base_page on the SF site (and in CVS) also has a search page, search results, etc. Chris --=20 Chris Winters (ch...@cw...) Building enterprise-capable snack solutions since 1988. |
|
From: Chris W. <ch...@cw...> - 2002-01-01 03:32:30
|
On Mon, 2001-12-31 at 17:33, Chris McDaniel wrote:
> Making my own package and having some issues with a DB query... Hope someone
> can help.
I really, really didn't expect to be answering email at this time of the
evening, but so it goes :-)
> The code from the handler:
> $params->{host_list} = $R->host->fetch_iterator({
> DEBUG => 5,
> where => "customer_id =
> $R->{auth}{user}{customer_id}",
> order => 'monitored_hosts.monitored_host_id' });
BTW, this should probably be '$params->{host_iterator}' rather than
'$params->{host_list}' since you're fetching an iterator.
> the SPOPS def for this object:
> 'host' => {
> 'object_name' => 'Host',
> 'no_update' => [
> 'monitored_host_id'
> ],
> 'isa' => [
> 'OpenInteract::SPOPS',
> 'SPOPS::Secure',
> 'SPOPS::DBI::MySQL',
> 'SPOPS::DBI'
> ],
Change 'OpenInteract::SPOPS' to 'OpenInteract::SPOPS::DBI' and see what
happens. This changed in version 1.30 or so, IIRC.
The problem is almost certainly that SPOPS::SQLInterface doesn't have
access to your database handle, since this function moved to
OI::SPOPS::DBI. This would have been much easier to pinpoint if the
error message were better -- working on that.
Happy new year!
Chris
--
Chris Winters (ch...@cw...)
Building enterprise-capable snack solutions since 1988.
|
|
From: Chris M. <Chr...@te...> - 2001-12-31 22:39:22
|
Hello,
Making my own package and having some issues with a DB query... Hope someone
can help.
The code from the handler:
$params->{host_list} = $R->host->fetch_iterator({
DEBUG => 5,
where => "customer_id =
$R->{auth}{user}{customer_id}",
order => 'monitored_hosts.monitored_host_id' });
the SPOPS def for this object:
'host' => {
'object_name' => 'Host',
'no_update' => [
'monitored_host_id'
],
'isa' => [
'OpenInteract::SPOPS',
'SPOPS::Secure',
'SPOPS::DBI::MySQL',
'SPOPS::DBI'
],
'has_a' => {
'testsite::User' => [
'user_id'
]
},
'class' => 'testsite::Monitoring',
'no_insert' => [
'monitored_host_id'
],
'id_field' => 'monitored_host_id',
'base_table' => 'monitored_hosts',
'field' => [
'monitored_host_id',
'customer_id',
'host',
'ping_type',
'is_alive',
'email',
'pager_number',
'paging_configuration_id'
],
'links_to' => {
'testsite::PagingConfig' => 'paging_configurations',
'testsite::PingLog' => 'ping_log'
}
},
.... (there are other objects)
the error log:
SPOPS::SQLInterface::db_select (78) >> Entering db_select with $VAR1 = {
'from' => [
'monitored_hosts'
],
'fields' => [
'monitored_host_id',
'customer_id',
'host',
'ping_type',
'is_alive',
'email',
'pager_number',
'paging_configuration_id'
],
'select' => [
'monitored_hosts.monitored_host_id',
'monitored_hosts.customer_id',
'monitored_hosts.host',
'monitored_hosts.ping_type',
'monitored_hosts.is_alive',
'monitored_hosts.email',
'monitored_hosts.pager_number',
'monitored_hosts.paging_configuration_id'
],
'DEBUG' => 5,
'return' => 'sth',
'where' => 'customer_id = 1',
'order' => 'monitored_hosts.monitored_host_id',
'class' => 'testsite::Monitoring',
'offset' => 0,
'max' => 0
};
SPOPS::SQLInterface::db_select (86) >> No SQL passed in to execute directly;
building.
SPOPS::SQLInterface::db_select (107) >> SQL for select:
SELECT monitored_hosts.monitored_host_id,
monitored_hosts.customer_id, monitored_hosts.host, monitored_hosts.ping_
type, monitored_hosts.is_alive, monitored_hosts.email,
monitored_hosts.pager_number, monitored_hosts.paging_configuration_id
FROM monitored_hosts
WHERE customer_id = 1
ORDER BY monitored_hosts.monitored_host_id
OpenInteract::UI::Main::handler (42) >> Action died. Here is what it left:
SELECT failed; cannot retrieve records
SELECT monitored_hosts.monitored_host_id,
monitored_hosts.customer_id, monitored_hosts.host, monitored_hosts.ping_
type, monitored_hosts.is_alive, monitored_hosts.email,
monitored_hosts.pager_number, monitored_hosts.paging_configuration_id
FROM monitored_hosts
WHERE customer_id = 1
ORDER BY monitored_hosts.monitored_host_id
at /usr/local/lib/perl5/site_perl/5.6.1/SPOPS/SQLInterface.pm line
119.
Anyway, any assistance would be much appreciated.
Note that the above query (from the error log) works if I paste it into the
mysql console (and add a semicolon)
Thanks!
Chris McDaniel
|
|
From: brian m. <bc...@ma...> - 2001-12-31 15:20:46
|
On 31 Dec 2001, Chris Winters wrote: > Yes -- try installing Data::UUID and re-run the tests. I > didn't include Data::UUID as a dependency in Makefile.PL > and neglected to add it to the list of optional tests to > run, since it doesn't seem to compile on Win32. /usr/bin/make install UNINST=1 -- OK thanks :) |
|
From: Chris W. <ch...@cw...> - 2001-12-31 15:18:10
|
On Mon, 2001-12-31 at 09:35, brian moseley wrote: > > hiya. i got several failures when trying to install spops > from the cpan shell. any pointers? > ... > t/03_uuid_key..........Test header seen twice! > t/03_uuid_key..........NOK 2# Failed test > (t/03_uuid_key.t at line 33) > t/03_uuid_key..........NOK 3# Failed test > (t/03_uuid_key.t at line 34) > # got: undef > # expected: 'LoopbackTest' > ... Yes -- try installing Data::UUID and re-run the tests. I didn't include Data::UUID as a dependency in Makefile.PL and neglected to add it to the list of optional tests to run, since it doesn't seem to compile on Win32. Thanks for the report, Chris -- Chris Winters (ch...@cw...) Building enterprise-capable snack solutions since 1988. |
|
From: brian m. <bc...@ma...> - 2001-12-31 14:35:27
|
hiya. i got several failures when trying to install spops from the cpan shell. any pointers? cpan> install SPOPS Running install for module SPOPS Running make for C/CW/CWINTERS/SPOPS-0.55.tar.gz Is already unwrapped into directory /home/bcm/work/src/cpan/build/SPOPS-0.55 Has already been processed within this session Running make test PERL_DL_NONLAZY=1 /home/bcm/work/bin/perl -Iblib/arch -Iblib/lib -I/home/bcm/work/lib/perl5/5.6.1/i686-linux -I/home/bcm/work/lib/perl5/5.6.1 -e 'use Test::Harness qw(&runtests $verbose); $verbose=0; runtests @ARGV;' t/*.t t/01_tie...............ok t/02_tie_strict........ok t/03_uuid_key..........Test header seen twice! t/03_uuid_key..........NOK 2# Failed test (t/03_uuid_key.t at line 33) t/03_uuid_key..........NOK 3# Failed test (t/03_uuid_key.t at line 34) # got: undef # expected: 'LoopbackTest' Can't locate package SPOPS::Loopback for @LoopbackTest::ISA at t/03_uuid_key.t line 40. Can't locate package SPOPS::Loopback for @LoopbackTest::ISA at t/03_uuid_key.t line 40. t/03_uuid_key..........NOK 4# Failed test (t/03_uuid_key.t at line 41) Can't call method "save" on an undefined value at t/03_uuid_key.t line 45. # Looks like you planned 6 tests but only ran 4. # Looks like your test died just after 4. t/03_uuid_key..........dubious Test returned status 255 (wstat 65280, 0xff00) DIED. FAILED tests 2-6 Failed 5/6 tests, 16.67% okay t/04_random_key........ok t/10_hash_file.........ok t/20_gdbm..............skipped test on this platform t/30_dbi...............ok t/31_dbi_multifield....ok t/40_ldap..............skipped test on this platform Failed Test Stat Wstat Total Fail Failed List of Failed ------------------------------------------------------------------------------- t/03_uuid_key.t 255 65280 6 5 83.33% 2-6 2 tests skipped. Failed 1/9 test scripts, 88.89% okay. 5/83 subtests failed, 93.98% okay. make: *** [test_dynamic] Error 9 /usr/bin/make test -- NOT OK Running make install make test had returned bad status, won't install without force |
|
From: Chris W. <ch...@cw...> - 2001-12-22 14:43:22
|
On Fri, 2001-12-21 at 14:08, Chris McDaniel wrote:
> I have:
> $params->{host_list} = $R->host->fetch_iterator({
> where => "customer_id = ?",
> value => [ $R->{auth}{user}{customer_id} ],
> order => 'monitored_host_id' });
>
> in a package I'm writing. I have extended the user object, and
> $R->{auth}{user}{customer_id} returns a value. Anyway, I get this:
>
> SELECT failed; cannot retrieve records SELECT
> ...
> customer_id = ? ORDER BY monitored_host_id at
> /usr/local/lib/perl5/site_perl/5.6.1/SPOPS/SQLInterface.pm line 119.
>
> So I'm assuming the placeholder is not getting replaced. Do I have to do
> anything special to make this happen?
No, it should happen automatically. One problem is that the error
message is not detailed enough to be helpful.
I can tell you that the particular error you got (at line 119) means
that we didn't even get to the ->execute() statement where we would have
sent the values to be bound to the placeholders. So there's something
else wrong with the stateement. Try pasting the SELECT statement
generated into whatever shell your db uses.
Also, in the fetch_iterator() call, try passing a DEBUG => 1 (or 2) and
watch your error log. This will tell you what values it's binding to the
placeholders.
Chris
--
Chris Winters (ch...@cw...)
Building enterprise-capable snack solutions since 1988.
|
|
From: Chris M. <Chr...@te...> - 2001-12-21 19:18:27
|
Sorry if this is a duplicate. My mail program is a bit temperamental
today...
Hi,
I have:
$params->{host_list} = $R->host->fetch_iterator({
where => "customer_id = ?",
value => [ $R->{auth}{user}{customer_id} ],
order => 'monitored_host_id' });
in a package I'm writing. I have extended the user object, and
$R->{auth}{user}{customer_id} returns a value. Anyway, I get this:
SELECT failed; cannot retrieve records SELECT
monitored_hosts.monitored_host_id, monitored_hosts.customer_id,
monitored_hosts.host, monitored_hosts.ping_type, monitored_hosts.is_alive,
monitored_hosts.email, monitored_hosts.pager_number,
monitored_hosts.pager_configuration_id FROM monitored_hosts WHERE
customer_id = ? ORDER BY monitored_host_id at
/usr/local/lib/perl5/site_perl/5.6.1/SPOPS/SQLInterface.pm line 119.
So I'm assuming the placeholder is not getting replaced. Do I have to do
anything special to make this happen?
Thanks,
Chris McDaniel
|
|
From: Chris M. <Chr...@te...> - 2001-12-21 18:16:01
|
Hi,
I have:
$params->{host_list} = $R->host->fetch_iterator({
where => "customer_id = ?",
value => [ $R->{auth}{user}{customer_id} ],
order => 'monitored_host_id' });
in a package I'm writing. I have extended the user object, and
$R->{auth}{user}{customer_id} returns a value. Anyway, I get this:
SELECT failed; cannot retrieve records SELECT
monitored_hosts.monitored_host_id, monitored_hosts.customer_id,
monitored_hosts.host, monitored_hosts.ping_type, monitored_hosts.is_alive,
monitored_hosts.email, monitored_hosts.pager_number,
monitored_hosts.pager_configuration_id FROM monitored_hosts WHERE
customer_id = ? ORDER BY monitored_host_id at
/usr/local/lib/perl5/site_perl/5.6.1/SPOPS/SQLInterface.pm line 119.
So I'm assuming the placeholder is not getting replaced. Do I have to do
anything special to make this happen?
Thanks,
Chris McDaniel
|