Re: [Zope] Hiding a Zope object from URL accesses

2001-01-24 Thread Dimitris Andrakakis

Gerald Gutierrez wrote:
 If I have a Z SQL method set up as /query on my Zope site, how is it
 possible for me to disallow direct accesses to it via a URL (like
 http://localhost/query) ? If I cannot, then what is the convention people
 use to store objects which are not supposed to be visible directly?

I think its as simple as revoking the access rights for anonymous (or other)
users. I.e. it's not invisible, but rather not allowed (pardon my english).

Dimitris
http://atlas.central.ntua.gr:8000


___
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )




Re: [Zope] Shut down zope from python script

2001-01-19 Thread Dimitris Andrakakis

Richard wrote:
 I'm a newbie, running zope and apache on my win98 box, trying to 
 learn enough to start using zope in a production environment. Windows 
 slows down dramatically if I leave it running more than a couple of 
 days

I can't really help you, but I'd consider it much wiser to
try and find the _reason_ that causes the slowdown.
Start by tracking the memory usage, CPU usage etc.
Check the list archives -I've watched many threads on
this issue.
Another thing: I'd consider running Zope+Apache on
NT workstation or 2000 professional, even for test
purposes. You'll find the NT task manager (among 
others) very handy.

Dimitris
http://atlas.central.ntua.gr:8000


___
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )




Re: [Zope] High Performance Zope

2001-01-16 Thread Dimitris Andrakakis

Vincent wrote:
 How does Zope respond under heavy load? can Zserver handle
 serving out 200-300 zope pages per day on a busy website?

As others have already said, that's not busy at all. An easy
way to identify busy websites is hits per second.  Say, if you
get more than 2-3 hits/sec ON A CONSTANT BASIS, then
you might need:
-A real server (not a $1000 commodity box).
-ZEO.
-Serious work on optimization.

Of course, this 3 hits/sec is a number that depends *very*
much on the complexity on your pages. It may easily be somewhat
more or less, but you get the idea.

Dimitris
http://atlas.central.ntua.gr:8000


___
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )




Re: [Zope] How do I get the size of an item ?

2001-01-12 Thread Dimitris Andrakakis

ethan mindlace fremen [EMAIL PROTECTED] wrote:
 dtml-with files
 dtml-var "_.get_size(_['file01.pdf'])"
 /dtml-with

Thanks ethan ( dieter too). I'm terribly sorry about requesting
a receipt (I had the option on OE forgotten), it will not happen again.

I have tried your suggestion, and indeed it works. Now, how does 
this work when the "file.pdf" is given as a DTML-VAR ?

The situation is, I retrieve the file names from MySQL, so
what I actually have is a dtml-var "path[12:]". "Path" is
something like "06-01-2001/file.pdf". So I try this, but it
won't work (it won't parse, actually).

dtml-with files
   dtml-var "_.get_size(_['dtml-var "path[11:]"'])"
/dtml-with

I guess my question is actually about nested DTML, isn't it ?

Dimitris
http://atlas.central.ntua.gr:8000


___
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )




Re: [Zope] How do I get the size of an item ?

2001-01-12 Thread Dimitris Andrakakis

Daniel wrote:
 You don't need the dtml-var inside another dtml-var i.e once you are in
 dtml you are in it. try something like this

 dtml-with files
 dtml-var "_.get_size(_['path[11:]'])"
  /dtml-with

Your advice was truly enlightning ! It didn't work exactly like this,
but this one did exactly as shown (remeber path is like
"06-01-2001/file.pdf"):

dtml-with files
  dtml-with "_[path[:10]]" --- this gets me into the "06-01-2001" dir
dtml-with "_[path[11:]]" --- this gives me the variable space for
file.pdf
  dtml-var size
/dtml-with
  /dtml-with
/dtml-with

I'll write a HOW-TO for this in my page, I think it's worth it. Thanks
for your help all of your guys !

Dimitris
http://atlas.central.ntua.gr:8000


___
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )




[Zope] How do I get the size of an item ?

2001-01-11 Thread Dimitris Andrakakis

...anyone ?

Say I have these folders:
/
/news
/news/files
What I need is, from a dtml method in /news, to get 
the size of an object (a file, say /news/files/file01.pdf) 
in /news/files.

Thanks in advance,
Dimitris


___
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )




Re: [Zope] Memory problems

2001-01-10 Thread Dimitris Andrakakis

Dieter wrote:
 "ps" is still a bit stupid and does not visualize that
 they are threads rather than normal (full blown) processes.

ps -axf ?

Dimitris
http://atlas.central.ntua.gr:8000


___
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )




[Zope] Zope under Irix 5.3 ?

2000-12-26 Thread Dimitris Andrakakis

Merry Xmas everybody !
I'm trying to get zope to work on an SGI, Irix 5.3.
Python isn't available, so I have to compile it my own
being a normal user, not root, with quota and all...
anyway.

I compile Python (1.5.2), in my home dir with threads and all
(as I've read in tyhe how-to's). Then I untar zope (2.2.4)
run the -wo_pcgi (I'll be working with ZServer only, so
it should be fine), set the superuser password and make
the ./start script as follows:

reldir=`dirname $0`
PYTHONHOME=`cd $reldir; pwd`
export PYTHONHOME
exec /path-to-my-python-installation/bin/python \
 $PYTHONHOME/z2.py \
 -w 8000 "$@"

Then go to my zope dir and ./start... but it doesn't work :-(
That's what I get:

Traceback (innermost last):
  File "/my-home-dir/zope/z2.py", line 554, in ?
exec "import "+MODULE in {}
  File "string", line 1, in ?
  File "/my-home-dir/zope/lib/python/Zope/__init__.py", line 94, in ?
import ZODB, ZODB.ZApplication, imp
  File "/my-home-dir/zope/lib/python/ZODB/__init__.py", line 85, in ?
import sys, ExtensionClass, TimeStamp, cPersistence, Persistence
ImportError: No module named ExtensionClass

Is it something I've missed when I compiled python ? Or a specific
irix issue ? or something else ?

Have the best of times,
Dimitris


___
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )




Re: [Zope] How best to restart Zope?

2000-09-19 Thread Dimitris Andrakakis

Jørgen wrote:
 There is an article on www.zope.org that describes the
 daemontools package .. do a search on the zope website for
 "daemontools" .. and you should be redirected to some
 "lightwerk" website in germany i think..

A vote from me too, daemontools is a great tool in general -not
only for Zope. We use it to monitor Apache as well.

Dimitris
http://atlas.central.ntua.gr:8000/~mc94068



___
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )




Re: [Zope] Folder and SQL security

2000-09-03 Thread Dimitris Andrakakis

Hi George !

Please check what Chris wrote too but I can answer this:

 Security in ZOPE is very puzzling. If I have certain rules set for the
 root folder, can I set something different for the sub folders? 

It's as simple as having a separate Acl_users in those folders that
you need to have different security for. Say your site is:

/ (root)
  /department1
  /department2
 /subdept1
 /subdept2
  /department3

...and you want a common security model except for subdept2. So
you tweak the acl_users in the / (root) as you want and *only in subdept2*
you create another acl_users and tweak that as well.

Hope this helps,
Dimitris
http://www.zope.org/Members/dandraka



___
Zope maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )