You can subscribe to this list here.
2001 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(21) |
Aug
(39) |
Sep
(13) |
Oct
(1) |
Nov
|
Dec
|
---|
From: Alex B. <en...@tu...> - 2001-08-16 20:46:13
|
agh, just spent an hour hunting a stupid bug.... but, finally, I can go eat lunch. and Module caching works. so, now you can cache page output by request uri and variable value, and cache module output by name, optionally uri, and variable value. I'll do a sync now. _a |
From: Andreas A. <a.a...@th...> - 2001-08-15 22:25:50
|
Hi Alex, > Here's the trick: that syntax is available from _anywhere_. You can put it > in masters, layouts, module templates, includes, whatever! :) Cooooooooooooooooool. :-D > > above. I think this breaks xml conformance. But as I said, nice to have. > > Especially for small "just-presentation" pages. > In this case I'm not so concerned with xml conformance, if you were big on > that you could make sure your page defs used xhtml, and validated > as xml... > that would be fine. And for the ones who want to be strict they can use the "non-static-pages"-bcp syntax. I like that bc has this flexiblity. Be strict, be lax, be bc ;-) > long as a month before the first revs are in the system. I've > been focusing on other things for my business recently, > so I don't have the > kind of time Iwould like to devote to r2. But it will all happen... Ok, Fine :-) Andi |
From: alex b. <en...@tu...> - 2001-08-15 17:36:37
|
> Cool. This ebedding syntax will also be availabel for the layouts and > masters templates, I guess? So that acutally a "real" template system (xslt, > smarty etc) is only required in the modules itself 'caus in layouts/ and > masters/ are only module outputs embedded that are translated to php calls > ($Page->output[...]) on compile time? Here's the trick: that syntax is available from _anywhere_. You can put it in masters, layouts, module templates, includes, whatever! :) > > Why is this worthwhile? > > > > It means you can forego using layouts and module lists if you > > don't need the advanced features page offers (load/init ordering, etc) - > and > > it's obviously convenient for embedding modules _anywhere_ (yes, you could > > embed one module's output in another module's output!) > Groovy. > > > I'm sure there will be questions on this, fire away! > I think this feauture is nice to have but might be a bit confusing. > Especially if one embedds html markup in the xml page definition like shown > above. I think this breaks xml conformance. But as I said, nice to have. > Especially for small "just-presentation" pages. In this case I'm not so concerned with xml conformance, if you were big on that you could make sure your page defs used xhtml, and validated as xml... that would be fine. then again it would also be fine if they didn't within <markup> > BTW: How far are you with the Query/Entity Manager stuff? I expect there to be a bit of delay integrating that stuff, it could be as long as a month before the first revs are in the system. I've been focusing on other things for my business recently, so I don't have the kind of time I would like to devote to r2. But it will all happen... best, _alex |
From: Andreas A. <a.a...@th...> - 2001-08-15 15:06:54
|
Hi Alex, > I like this syntax because it allows non-programmer users to define pages > and embed modules without worrying about php syntax - they use > familiar tags > to call in modules that programmers provide. Cool. This ebedding syntax will also be availabel for the layouts and masters templates, I guess? So that acutally a "real" template system (xslt, smarty etc) is only required in the modules itself 'caus in layouts/ and masters/ are only module outputs embedded that are translated to php calls ($Page->output[...]) on compile time? > Why is this worthwhile? > > It means you can forego using layouts and module lists if you > don't need the advanced features page offers (load/init ordering, etc) - and > it's obviously convenient for embedding modules _anywhere_ (yes, you could > embed one module's output in another module's output!) Groovy. > I'm sure there will be questions on this, fire away! I think this feauture is nice to have but might be a bit confusing. Especially if one embedds html markup in the xml page definition like shown above. I think this breaks xml conformance. But as I said, nice to have. Especially for small "just-presentation" pages. BTW: How far are you with the Query/Entity Manager stuff? Andi |
From: Phillip S. <te...@al...> - 2001-08-15 14:49:16
|
Greetings. I've been lurking on this list for awhile now, and have an interest in BC's capabilities. I consider myself to be an intermediate PHP developer, and am contemplating the possibility of using r2 as the framework for a project. Specifically, there is an existing open source project [ Ministry of Truth - http://mot.sourceforge.net ] that is no longer being actively maintained. I am giving serious thought to picking up development because I've not found any other software that fills the same niche, and because I've spoken with the original author who has encouraged me to do so. The problem with this is that I am not comfortable with the way its idea/essence is currently implemented, and would really want to rebuild it from the ground up (the TODO and feature list is long, and it seems pointless to try re-inventing the wheel with what's there). For those that don't care to visit the website, MOT currently allows one to group db tables/fields relationally into larger more useful things (e.g project tracking, hardware/software inventory, etc.), all without having to know anything about html/php/sql (given that it was originally written in 1998 and includes its own built-in XML parser, it's still an impressive and usable piece of software). r2 would appear to be a candidate for a new MOT framework (other possibilites might be Horde [ http://www.horde.org/ ]), but I have concerns about how to create a distributable "product" based on it (MOT will continue to be strictly GPL, of course). I'm having difficulty envisoning how I would incorporate it in such a way as to minimize the setup requirements for my user base. For some, getting Apache and PHP installed is enough of a hurdle (not everyone uses .rpm or .deb based systems). Would I say "you need Apache, PHP (plus all it's special dependencies), and r2 .. after you fight with that, you use MOT as a plug-in", or is there a recommended way I could easily encapsulate r2's overhead into my configuration system? I would like to be able to say "Here's MOT. Run the installer." once they have met the Apache/PHP requirement. Second, how viable is r2 as a development platform right now? Obviously it's still under heavy development, but is it becoming mature enough to start building production-quality applications? I expect that it will take me a few weeks to spec out what I will include as part of the initial rewrite of MOT (its existing functionality plus a subset of the TODO), so my question is more focused on the "stable" parts of r2. In other words, which components of MOT can I concentrate on re-implementing now using the least changing parts of r2? The website/documentation doesn't give a clear indication of what's complete and what's not.. guess I can always dive in and find out though. Looking at the mailing list archives, I see that some of my questions are answered (lots of recommendations from Alex to use r2 over r1 at this point). The recent "BC quick-start guide" thread is helpful, but I don't see anyone trying to use BC for something like this (most uses seem to be for custom website projects rather than a self-contained, portable web application). Correct me if I'm wrong. Just to be clear, I'm not in a major hurry here. If I was, then I would go ahead and consider r1 and worry about the conversion issues later. I get the feeling though that I will be able to plan my goals around r2's development cycle, and that enough of r2 is complete now. It would be helpful to have some idea on the overall status and usability of specific r2 sections (documentation on all this once r2 is finished is great, but I would still like to start developing now), and I would appreciate general feedback from anyone who is currently using it to do productive things. Thanks in advance. -phillip ----------------------------------------------------------------- UNIX Systems Administrator *windowmaker.org site maintainer ----------------------------------------------------------------- |
From: Alex B. <en...@tu...> - 2001-08-15 01:38:38
|
hi all, I just commited and will soon sync to sf cvs: -The Page class can now do "static" module output. Ok, what the hell are you talking about? :) static module output is an embedded call in markup that loads and outputs the given modules. My intent is for users to be able to define binarycloud pages in xml like this: <page> <init> ... </init> <templates> ... </templates> <markup> <p align="right"> <bc:module name="HelloWorld" package="hello_world" id="module_id"> <param:any_api_param>value</param:any_api_param> </bc:module> <table border="0" cellpadding="0" cellspacing="0" width="100%"> <tr> <td valign="top"> <bc:module name="Example" package="example_package" id="module_id"> <param:any_api_param>value</param:any_api_param> </bc:module> </td> <td valign="top"> <bc:module name="OtherWorld" package="hello_world" id="module_id"> <param:any_api_param>value</param:any_api_param> </bc:module> </td> </tr> </table> <hr> </markup> </page> or like this: <page> <init> <ini>true</ini> <auth>false</auth> <perm>false</perm> <sess>true</sess> <lang>true</lang> <cache>true</cache> </init> <templates> <default> <name>exmaple_master</name> <package>html.masters</package> <type>html</type> </default> </templates> <modules> <content> <layout> <name>exmaple_layout</name> <package>html.layouts</package> </layout> <load> <module> <id>product_list</id> <name>ProductLister</name> <package>user.mod.products</package> <load_order>1</load_order> <params> <example>this is an option value</example> <another>1</another> </params> </module> <module> <id>product_delete</id> <name>DeleteProduct</name> <package>user.mod.products</package> <load_order>2</load_order> </module> </load> </content> </modules> </page> In the first example, you'll see there there is still a basic page definition: core components, a master template, etc - but notice that there is no modules array, and there is _markup_ in the page definition. Then, have a look at <bc:module> tags - these will be interpreted (I say will, because I haven't done that yet) at make-time into this: <? $Page->BuildModule(array('name' => 'HelloWorld','package' => 'hello_world','id' => 'first_one')); ?> etc. You can have a look at user/htdocs/static_module.php for an idea. I like this syntax because it allows non-programmer users to define pages and embed modules without worrying about php syntax - they use familiar tags to call in modules that programmers provide. Why is this worthwhile? It means you can forego using layouts and module lists if you don't need the advanced features page offers (load/init ordering, etc) - and it's obviously convenient for embedding modules _anywhere_ (yes, you could embed one module's output in another module's output!) Oh yeah, I also made sure that these "new style pages" are cacheable (user/htdocs/static_module.php is cached, for example) I'm sure there will be questions on this, fire away! :) _alex -- alex black, ceo en...@tu... the turing studio, inc. http://www.turingstudio.com vox+510.666.0074 fax+510.666.0093 |
From: Alex B. <en...@tu...> - 2001-08-13 18:46:22
|
> I've moved this from dev since its a "duh" question. I've seen this type of > structure all over r2 and can't seem to grasp the > logic: > >>>>> > $modXSettings = array( > "foo" => array( > "name" => "Peter", > "other" => "Pan" > ), > perms => "god" > ); >>>>> > > Would someone be willing to explain what's going on here and why? An array > within an array, I can see the usefulness in that I *think*, but a such a > complex matrix hardly seems ubiquitously useful as this structure is > referenced in r2. It's a nested hierarchy. Think of it as xml: <modXSettings> <foo> <name>Peter</name> <other>other</other> </foo> <perms>god</perms> </modXSettings> It is the most efficient way to store a set of data, i.e. in one variable that has some defined structure. You reference it with: $modXSettings['foo']['name'] etc best, _alex |
From: Alby L. <al...@th...> - 2001-08-13 18:11:31
|
I've moved this from dev since its a "duh" question. I've seen this type of structure all over r2 and can't seem to grasp the logic: >>>> $modXSettings = array( "foo" => array( "name" => "Peter", "other" => "Pan" ), perms => "god" ); >>>> Would someone be willing to explain what's going on here and why? An array within an array, I can see the usefulness in that I *think*, but a such a complex matrix hardly seems ubiquitously useful as this structure is referenced in r2. Alby |
From: alex b. <en...@tu...> - 2001-08-12 20:40:39
|
> Well, the BC_PATH and BUILD_PATH that live in build/en/htdocs/prepend.php > were set to /u02/home/odysseas/r2/binarycloud after running make even though > I had $BCHOME set. Once I set them by hand things worked okay. Also having > the php short tag '<?' turned off causes pretty much everything to break but > thats not really a bug I guess. If you did a make, that shouldn't be the case. I'll look into it. I'll add the short tag warning in install. > > But if I do go down that path I run the risk of having to retool everything > down road anyway right? Yes. _but_ if you have a functioning system (which r1 auth/perm is) you can choose when to do that re-write or if you'd like to do it at all. > What's the nature of the applications that are being built with BC? The site > Im working on will be used to manage some *very* large catalogs of data. > Interface-wise there won't be much to it in the beginning. I've built mostly complex web applications, not dealing with huge amounts of data, but I have no reason to believe that metabase isn't up to it. Nothing in binarycloud will present you any with any problems, that I can think of. It's all up to you re: how you write modules. > > > >I'm working on something that will simplify page authoring for those that > >don't need tight control over load order, etc. But authoring pages in XML > >will be really easy anyway :) > > But doesn't that work against me if Im relying on another person who only > groks html to do the page layouts? Not really. They can write the layouts and you can insert the module calls. Or you can pass them html-only templates, which they work on, and pass back to you. > That's another question I have. When does the conversion from xml to php > take place? When I run make? Will I have to 'remake' my whole site when I > change just one xml file? No, there's a makefile in nearly every directory, and we're probably going do add automake to insetr makefiles down to every dir in the source tree, so if you modify 2 files in a dir, you can do a make in 3 seconds. > >Also, remember: the system is a set of tools, the only "requirements" > >really are associated with Module method naming. > > Which is really what we need. :_) > > > >One of the things I will do later is build a series of "variant" pages and > >applications to give users a feel for the flexibility of the system. Other > >things first, though :) > > This would make things much clearer and lower the learning curve quite a > bit. Agreed. Because the system isn't cmoplete yet, I want to avoid spending time on that stuff and get it working, but believe me when I say I have every intention of documenting the s*it out of this system, and making very clear how it can be used. As always I'm happy to answer any questions. > >I lead two projects of similar size, one with bc and one without. The > >project without bc was much harder to deal with because I didn't have a > >good > >mechanism for controlling the condebase my contractors were generating. The > >second project, with binarycloud r1, took ~half the time to complete, with > >much higher quality code when the project was done. > > Did the problems arise because the first team was having to implement alot > of features already present in R1? Given that, I would expect the code from > team 2 to be better because the could spend more time on the core instead of > the support services. But that is just what you said :) Correct, and binarycloud _does_ enforce a _little_ structure on your code, and provides you with a great system for maintaining code and comment standards. > >I haven't done a production cycle with R2, but I can tell you that many of > >the ideas in R1 have been refined based on experiences with the system, and > >it will save you time if you're willing to be disciplined (i.e. maintaining > >coding standards, phpDoc, etc etc.) > > I've already documented my classes using PHPDoc. After having been immersed > in JavaDoc I understand the power of systems like it. Yes, I love it. It keeps system documentation in context, instead of in some other stupid file that you always forget to edit :) > >The page render pipeline in r2 is quite mature and powerful, building > >modules is fast and efficient (and obviously serves to break up your > >application into useable, easily debuggable components) > > This is an approach Ive already started using so migrating my current code > to BC won't be terribly painful. But once I start down that path I don't > want to have to revert so it's that first leap of faith that Im having > trouble with at the moment. Ok, so first: if you have a functioning system _now_ you can only gain by converting to bc. If you want to use some of the new tools down the road, then feel free to do rewrites as needed. But BC doesn't force a thing on you, so if you don't like metabase, don't use it. I will ask that any conributed modules that would be distributsed with the system adhere to certain standards, but there is _nothing_ in the system that will enforce those rules. > >However, as you have pointed out, r2 isn't done. Though simple, the r1 > >auth/perm system is quite robust, I'm using it in production now. You could > >probably get them working in a day. > > So hypothetically if I decide to just go with R1 and wait for R2 to bake a > little longer what's the migration path? Should I even bother? Pros and > Cons? Don't bother. I strongly encourage you to get r1 auth/perm working with r1 instead of using r1. R1 is Procedural code (well, 90% of it anyway) and it does work well, but for obvious reasons a pure OO system is far more maintanable and architecturally clean. by all means use R1 as a reference, but don't use it in production: r2 even at this stage is more mature. > > > >The remaining tasks are related to EntityManager and the make system: > > I happen to have written an EntityManager class for my stuff. This will > cause problems no? Nope. Just put it in user/lib and run a make, you'll have access to it with import('user.lib.YourEntityManagername'); :) _alex > James > > _________________________________________________________________ > Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp > > > _______________________________________________ > binarycloud-general mailing list > bin...@li... > http://lists.sourceforge.net/lists/listinfo/binarycloud-general > |
From: alex b. <en...@tu...> - 2001-08-12 20:24:42
|
> So after getting through the make process I have a working index page. w00t! cool! > Now I would like to better understand how R2 uses metabase and thus > understand how I can use it. Ive read through the tutorial but it's not BC At the moment, r2 doens't "use it" per se - because QueryManager hasn't been integrated into the system. There is nothing that would prevent you from using the PEAR DB abstraction layer, actually. Metabase is what all of the r1 code uses, and what QueryManager will use when it is integrate into the system. For the moment, metabase is importable from the binarycloud/ext/ tree. > specific. There are files in build/en/ext/metabase and > build/en/user/db/schema that suggest there is a process in place to create > the tables that BC needs but I can't find the entry point. Is the glue for > this not yet written? Correct: the schemas are from r1 and aren't used at the moment - though again you could use them to create a functioning r1-style auth/perm system. > Should I be posting to binarycloud-dev instead? general is fine, but I think -dev is better :_) _a |
From: Andreas A. <a.a...@th...> - 2001-08-12 11:27:42
|
Hi James, > Now I would like to better understand how R2 uses metabase and thus > understand how I can use it. How I currently deal with it: [1] I have libs that are dealing with the database interfacing. e.g. a manager class for managing resources (doing queries, file operations). This class imports metabase stuff at the very beginning. e.g.: r2/binarycloud/user/lib/MgrResources.php: // {{{ import('user.lib.Exception'); import('user.conf.datasources'); import('ext.metabase.metabase_database'); import('ext.metabase.metabase_interface'); import('ext.metabase.metabase_mcrypt'); class MgrResources { function MgrResources() { MetabaseSetup etc like described in docs } function Lister() {} function ListById() {} function Add() {} function Set() {} ... }; // }}} [2] I wrote a module package for managing resources: r2/binarycloud/user/mod/manage_resources/ consisting of 4 atomic modules ListResources, DeleteResource, AddResource, EditResource. Those modules are importing my manager in the constructor and using smarty to generate the html output. e.g. (simplified for better illustration) // {{{ class ListResources { var $mgr; //my manager var $tpl; // my template function ListResources($_params) { import('user.lib.MgrResources'); import('user.lib.Template'); // includes ext.smarty.stuff // doing other stuff, switch(action) or something else // aggregation $this->mgr =& new MgrResources(); $this->tpl =& new Template(); $this->tpl->SetPath(BC_PATH_MOD.'manage_resources/html'); $result =& $this->mgr->Lister(); $this->tpl->assign('RESULT', $result); return true; } function Output() { $this->tpl->display('list.xhtml'); return true; } }; // }}} And that works very good. No, wait: most excellent :-) Andi |
From: James M. <foo...@ho...> - 2001-08-12 06:28:32
|
So after getting through the make process I have a working index page. w00t! Now I would like to better understand how R2 uses metabase and thus understand how I can use it. Ive read through the tutorial but it's not BC specific. There are files in build/en/ext/metabase and build/en/user/db/schema that suggest there is a process in place to create the tables that BC needs but I can't find the entry point. Is the glue for this not yet written? Should I be posting to binarycloud-dev instead? -James _________________________________________________________________ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp |
From: James M. <foo...@ho...> - 2001-08-12 06:17:02
|
> > Okay after rooting through things I've got it all working although the > > install process is a bit buggy. Im running against the current CVS BTW. > >Can you define "a bit buggy?" - assuming you do a make it should be happy. Well, the BC_PATH and BUILD_PATH that live in build/en/htdocs/prepend.php were set to /u02/home/odysseas/r2/binarycloud after running make even though I had $BCHOME set. Once I set them by hand things worked okay. Also having the php short tag '<?' turned off causes pretty much everything to break but thats not really a bug I guess. > >> What's "missing": > >> -A second generation authentication system. If you _really_ need >one, > >> you could probably get R1 Auth/Perm (which are quite effective, and > >> production tested - but 'simple') working with R2. > > > > Are you suggesting I use R1 or just cut out that piece and graft it to >R2? > >The latter, though I would encourage you to wait just a little, because the >new auth/perm stuff is a hell of a lot more advanced. > >But, note that Auth.php and Perm.php are "classified" already from R1, so >you could probably get them running pretty fast. But if I do go down that path I run the risk of having to retool everything down road anyway right? > > Also, Im wondering if we need the fine grain abstraction that BC >provides. > > We need some of BC's services but Im concerned that the overhead of the >page > > abstraction is going to be too high to develop our pages rapidly. > >I've built huge applications with it, and it speeds everything up. Because >you need to be organized about using modules, nothing gets "lost" in >include-land. What's the nature of the applications that are being built with BC? The site Im working on will be used to manage some *very* large catalogs of data. Interface-wise there won't be much to it in the beginning. > >I'm working on something that will simplify page authoring for those that >don't need tight control over load order, etc. But authoring pages in XML >will be really easy anyway :) But doesn't that work against me if Im relying on another person who only groks html to do the page layouts? That's another question I have. When does the conversion from xml to php take place? When I run make? Will I have to 'remake' my whole site when I change just one xml file? > >Also, remember: the system is a set of tools, the only "requirements" >really are associated with Module method naming. Which is really what we need. > >One of the things I will do later is build a series of "variant" pages and >applications to give users a feel for the flexibility of the system. Other >things first, though :) This would make things much clearer and lower the learning curve quite a bit. >I lead two projects of similar size, one with bc and one without. The >project without bc was much harder to deal with because I didn't have a >good >mechanism for controlling the condebase my contractors were generating. The >second project, with binarycloud r1, took ~half the time to complete, with >much higher quality code when the project was done. Did the problems arise because the first team was having to implement alot of features already present in R1? Given that, I would expect the code from team 2 to be better because the could spend more time on the core instead of the support services. But that is just what you said :) >I haven't done a production cycle with R2, but I can tell you that many of >the ideas in R1 have been refined based on experiences with the system, and >it will save you time if you're willing to be disciplined (i.e. maintaining >coding standards, phpDoc, etc etc.) I've already documented my classes using PHPDoc. After having been immersed in JavaDoc I understand the power of systems like it. >The page render pipeline in r2 is quite mature and powerful, building >modules is fast and efficient (and obviously serves to break up your >application into useable, easily debuggable components) This is an approach Ive already started using so migrating my current code to BC won't be terribly painful. But once I start down that path I don't want to have to revert so it's that first leap of faith that Im having trouble with at the moment. >However, as you have pointed out, r2 isn't done. Though simple, the r1 >auth/perm system is quite robust, I'm using it in production now. You could >probably get them working in a day. So hypothetically if I decide to just go with R1 and wait for R2 to bake a little longer what's the migration path? Should I even bother? Pros and Cons? > >The remaining tasks are related to EntityManager and the make system: I happen to have written an EntityManager class for my stuff. This will cause problems no? James _________________________________________________________________ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp |
From: Alex B. <en...@tu...> - 2001-08-12 05:01:04
|
>> You're building pages, and modules to use in those pages. Have a look at >> index.php, note that it's a definition of a series of modules, and >> templates. you can find all of those files in user/mod/, >> user/tmpl/html/layouts and user/tmpl/html/masters > > Okay after rooting through things I've got it all working although the > install process is a bit buggy. Im running against the current CVS BTW. Can you define "a bit buggy?" - assuming you do a make it should be happy. >> What's "missing": >> -A second generation authentication system. If you _really_ need one, >> you could probably get R1 Auth/Perm (which are quite effective, and >> production tested - but 'simple') working with R2. > > Are you suggesting I use R1 or just cut out that piece and graft it to R2? The latter, though I would encourage you to wait just a little, because the new auth/perm stuff is a hell of a lot more advanced. But, note that Auth.php and Perm.php are "classified" already from R1, so you could probably get them running pretty fast. >> -Some miscellany: I haven't started using Andreas' Request Class >> (that's >> actually next on the list) > > I was looking at writing something just like this myself. Oh, it's in CVS and as far as I can tell it's extremely groovy code. We're going to "enforce" the use of Request for all binarycloud-distro modules. >> -Some things are still moving targets - I'm sure we'll com across >> things >> we have to change, etc as development progresses. >> >> _but_ and I canot stress this enough: >> -The module structure and method naming scheme is now written in >> stone: >> Constructor called to 'init' the module, Output() called to >> (you >> guessed it) generate output. >> > > So your advice is to start using R2? My group has set a loose deadline of > the 31st to bring a beta of our site up and the missing auth and perm stuff > is a show stopper. Is there a roadmap for these things on your TODO list? If you're looking for the 31st, I suggest you use R1 Auth/Perm. There is a TODO, but I don't have a project schedule outlined because it would fluctuate as I have more and less time because of projects. > Also, Im wondering if we need the fine grain abstraction that BC provides. > We need some of BC's services but Im concerned that the overhead of the page > abstraction is going to be too high to develop our pages rapidly. I've built huge applications with it, and it speeds everything up. Because you need to be organized about using modules, nothing gets "lost" in include-land. I'm working on something that will simplify page authoring for those that don't need tight control over load order, etc. But authoring pages in XML will be really easy anyway :) Also, remember: the system is a set of tools, the only "requirements" really are associated with Module method naming. You can do all kinds of crazy things: if you don't like master templates use includes in a prepend, or use a module to output header and footer, or etc.... My point is that the system can be turned to do things very differently from what you see in the "default" cvs version. One of the things I will do later is build a series of "variant" pages and applications to give users a feel for the flexibility of the system. Other things first, though :) > I would love to hear from other people that have gone though a full > development cycle with BC. I can give you my experience, biased though it is: I lead two projects of similar size, one with bc and one without. The project without bc was much harder to deal with because I didn't have a good mechanism for controlling the condebase my contractors were generating. The second project, with binarycloud r1, took ~half the time to complete, with much higher quality code when the project was done. I haven't done a production cycle with R2, but I can tell you that many of the ideas in R1 have been refined based on experiences with the system, and it will save you time if you're willing to be disciplined (i.e. maintaining coding standards, phpDoc, etc etc.) The page render pipeline in r2 is quite mature and powerful, building modules is fast and efficient (and obviously serves to break up your application into useable, easily debuggable components) However, as you have pointed out, r2 isn't done. Though simple, the r1 auth/perm system is quite robust, I'm using it in production now. You could probably get them working in a day. The remaining tasks are related to EntityManager and the make system: -"multi site" make -Authentication system, PolicyManager -Pemissions -Managers: Entity, Query, Template, etc. -"default" module associations with master templates -Integrate PHPDoc into the make process -Test PEAR_Error further (note that pear error is up and running with the current system, PEAR is imported as part of the init process for r2.. but we might extend it to do some stacking, etc. -Use the Request class throughout the system (this is relatively simple) -Get xml2php running for page definitions, language defs, datasources, etc. -Get LanguageKeyer working with xml string repositories (language selection and path setting works fine right now, but there's no language keyer for abstracting "application" strings. best, _alex |
From: James M. <foo...@ho...> - 2001-08-12 04:30:06
|
>You're building pages, and modules to use in those pages. Have a look at >index.php, note that it's a definition of a series of modules, and >templates. you can find all of those files in user/mod/, >user/tmpl/html/layouts and user/tmpl/html/masters Okay after rooting through things I've got it all working although the install process is a bit buggy. Im running against the current CVS BTW. >What's "missing": > -A second generation authentication system. If you _really_ need one, >you could probably get R1 Auth/Perm (which are quite effective, and >production tested - but 'simple') working with R2. Are you suggesting I use R1 or just cut out that piece and graft it to R2? > -Some miscellany: I haven't started using Andreas' Request Class >(that's >actually next on the list) I was looking at writing something just like this myself. > -Some things are still moving targets - I'm sure we'll com across >things >we have to change, etc as development progresses. > >_but_ and I canot stress this enough: > -The module structure and method naming scheme is now written in >stone: > Constructor called to 'init' the module, Output() called to >(you >guessed it) generate output. > So your advice is to start using R2? My group has set a loose deadline of the 31st to bring a beta of our site up and the missing auth and perm stuff is a show stopper. Is there a roadmap for these things on your TODO list? Also, Im wondering if we need the fine grain abstraction that BC provides. We need some of BC's services but Im concerned that the overhead of the page abstraction is going to be too high to develop our pages rapidly. I would love to hear from other people that have gone though a full development cycle with BC. Thanks, -James- _________________________________________________________________ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp |
From: alex b. <en...@tu...> - 2001-08-12 01:22:43
|
> I recently began building what will become a very large PHP-powered site. > I've got most of the core objects and managers built but there are two that > I need badly right now namely auth.(and a permission system) and db > abstraction. I would just start using PEAR but there is no auth mechanisms For DB Abstraction, you can use metabase, which you can import directly now with ext.metabase.whatever the metabase core file is called, can't remember :) That will work fine for "direct" queries. > yet. I hacked on PHPLIB about 2 years ago and remember it being kind of > painful and ungainly to work with plus it doesn't appear to have any PHP4 > clue still. I would not recommend PHPLib at this point, the whole thing is in flux, and yes still no php4. > So here I am with BC. I looked at R2 and it's really not clear to me how to > get started with it. Is there a quick-start guide anywhere? Should I even be You're building pages, and modules to use in those pages. Have a look at index.php, note that it's a definition of a series of modules, and templates. you can find all of those files in user/mod/, user/tmpl/html/layouts and user/tmpl/html/masters > messing with R2? MetBase looks really cool but again Im a bit lost as to how The r2 page pipeline is basically done, I'm going to add module caching shortly but those are advances features you can use without modifying any of your module code. What's "missing": -You can't 'make' xml into php yet, you'll have to hand code page definitions. -Some "secondary" modifications I intend to make to the page render pipeline (including the ability to insert an XML module definition for 'static' rendering in a page, and almost competely forego a page definition -The entityManager and most of its support infrastrucutre -A second generation authentication system. If you _really_ need one, you could probably get R1 Auth/Perm (which are quite effective, and production tested - but 'simple') working with R2. -Some miscellany: I haven't started using Andreas' Request Class (that's actually next on the list) -Some things are still moving targets - I'm sure we'll com across things we have to change, etc as development progresses. _but_ and I canot stress this enough: -The module structure and method naming scheme is now written in stone: Constructor called to 'init' the module, Output() called to (you guessed it) generate output. > to get started with it. IF there's a FM and I need to read it, please point > me in that direction. http://www.binarycloud.com/documentation/r1/metabase_docs.phtml is the metabase documentation. it's quite complete. Obviously I've had requests to build documentation for bc, which I am doing - but I'm loth to spend time on that instead of development time to get the system fully operational. Once that's done I intend to do full DocBook docs for the project (with some people's help, I'm sure :):) If you have any questions after the above, I an others are happy to help as much as we can. best, _alex |
From: james m. <foo...@ho...> - 2001-08-11 20:42:36
|
I recently began building what will become a very large PHP-powered site. I've got most of the core objects and managers built but there are two that I need badly right now namely auth.(and a permission system) and db abstraction. I would just start using PEAR but there is no auth mechanisms yet. I hacked on PHPLIB about 2 years ago and remember it being kind of painful and ungainly to work with plus it doesn't appear to have any PHP4 clue still. So here I am with BC. I looked at R2 and it's really not clear to me how to get started with it. Is there a quick-start guide anywhere? Should I even be messing with R2? MetBase looks really cool but again Im a bit lost as to how to get started with it. IF there's a FM and I need to read it, please point me in that direction. _________________________________________________________________ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp |
From: Bruce D. <br...@ap...> - 2001-08-10 15:20:25
|
I have just installed the latest r2 from cvs onto a Linux server. I am trying to run bc_edit Parse error: parse error in /usr/home/cs/web/staging/binarycloud/resources/bc_edit/example.html on line 12 I assume this is the line with the error <?import namespace="cms" implementation="bc_edit.htc" /> Please let me know what I am missing. Also when I try to run graph.php Warning: Failed opening '/usr/home/cs/web/r2/binarycloud/build/en/user/mod/set_lang_example/Set_Lang_Example.php' for inclusion (include_path='/usr/home/cs/web/r2/binarycloud/build/en/ext/pear') in /usr/home/cs/web/staging/binarycloud/prepend.php on line 33 Fatal error: Cannot instantiate non-existent class: set_lang_example in /usr/home/cs/web/r2/binarycloud/build/en/binarycloud/core/Page.php on line 147 The file is actually there but the include_path seems to be screwing things up. Thanks Bruce |
From: Alex B. <en...@tu...> - 2001-08-08 20:56:11
|
http://www.securereality.com.au/studyinscarlet.txt And... here we go :) 3. Global Variables --------------------- "The problem is that the code incorrectly assumes that the variable $auth will be empty unless it sets it. Remembering that an attacker can create variables in the global namespace, a url like 'http://server/test.php?auth=1' will fail the password check but the script will still believe the attacker has successfully authenticated." First: under no circumstances should you assume that a variable is set to "what you expect". Second, and more importantly, this is the reason there's a request class in r2: for explicitly requesting values from the "user space" instead of having register_globals on in php.ini and opening up your application to attack. register_globals is convenient, but it is dangerous, as this article points out. 4. Remote Files --------------------- This is actually not different from "Global Variables" above, and obviously you should never take entire paths from the user for inclusion. You should also, (of course) make sure that your webserver is running as a user in a group by itself, and ensure that permissions in your fs are properly set. Best is to chroot apache. 5. File Upload --------------------- Uh, notice a trend here? turn _off_ register_globals, and all is well :) 6. Library Files --------------------- Heh, don't include your library files in htdocs where thy can be served?! (duh!?! :) 7. Session Files --------------------- Again, global variables. 8. Loose Typing And Associative Arrays --------------------- I agree with this, though I don't think (including the above) that it poses a security risk. This is an extremely simple expression of the idea that an application needs "central" validation logic which is used everywhere.. the complex version is... entities! 9. Target Functions --------------------- I don't think there is a good place for eval() in a well written application. It is of course a security risk, unless you're _really_ sure of the content of the string you are evaling. In general, executing apps "on the command line" though php is a no-no, and a security risk. Of course if you're careful about how you do it, and you do really need to do it, it's fine. 10. Protecting PHP --------------------- heheh: * = Mostly painless ** = Vaguely painful *** = Seriously hurts **** = Chinese Water Torture **** - Set register_globals off (thus, the request class :) *** - Set safe_mode on (ick, this is a pain in the ass) ** - Set display_errors off, log_errors on (Agreed, this is a part of the error handling infrastructure in bc) 11. Responsibility - Language Vs Programmer --------------------- "I contend that it is very hard to write a secure PHP application (in the default configuration of PHP), even if you try." Bullshit. You do have to think about what you are doing, but really, in most cases all you have to do is use a little common sense. Don't use global variables to set include paths, don't blindly use values from globals, etc etc. All of this stuff has to do with globals! If you solve the globals problem, everything else is no big deal. ASP's 'Request' class (*cough*, yes I know MS n' all) - is the right idea. "Web designers and other non coders end up writing PHP applications." I'm part web designer, but I get the point. Of course this is sort of like saying stupid people don't drive well and it's the car's fault :) "In its search for the ultimate functionality PHP has undermined the programmer's ability to understand the workings of their code in all situations." Again, bullshit. I think proper namespaces would be nice, but php code (even if it's spaghetti) is almost _always_ easy to read. Anyone ever try debugging complex perl? Give me a razor! :) --------- With three commands I can turn an apache install into a blaring invitation to hack. I do agree that registering globals is bad. At the same time, that's what the config is there for. _a > Hello All: > I think the article link below is useful... depending on your php > experience/knowledge > it may/not be... > But what I want to know since I haven't thoroughly perused BC's yet > morphing codebase... How does BC cope with such potential security attacks? > -WD > > <-- snip --> > With the recent code red activity it has gotten me thinking about any > vulnerabilities within phpwebsite. I ran across this article > <http://www.securereality.com.au/studyinscarlet.txt> that details some > common problems with php based scripts. It makes for some really good > reading. There is some good supporting material that breaks down specific > scripts. How much has the development team looked into fixed security > holes? > > Thanks, > Eric > <-- snip --> > > __________________________________________________ > FREE voicemail, email, and fax...all in one place. > Sign Up Now! http://www.onebox.com > > > _______________________________________________ > binarycloud-dev mailing list > bin...@li... > http://lists.sourceforge.net/lists/listinfo/binarycloud-dev > -- alex black, ceo en...@tu... the turing studio, inc. http://www.turingstudio.com vox+510.666.0074 fax+510.666.0093 |
From: Alex B. <en...@tu...> - 2001-08-07 18:44:17
|
hi all, I'm building a list of packages we need from cygwin, and I think it's complete. The download I did was 7.7MB: Autoconf Automake Bash Binutils Clear Cygwin (both packages) Diff File Fileutils Findutils Grep gZip Inetutils Less Lynx Make Perl Readline Reges Rsync Sed Sh-Utils Tar Textutils Time Unzip w32API wGet Which (Ronald, I've "pasted" this list into your WIN32 file.) Note that the above is _much_ more that binarycloud actually needs, but it's all good stuff that's nice to have around. The _full_ cygwin download is pretty serious: Postgres, CVS, etc. No wonder the whole shebang is 50M, I'm actually surprised it's that small :) _alex -- alex black, ceo en...@tu... the turing studio, inc. http://www.turingstudio.com vox+510.666.0074 fax+510.666.0093 |
From: Alex B. <en...@tu...> - 2001-08-06 19:33:56
|
> Only a guess as I had no intention to be online for more that a hour - > arround 50-60MB. I don't know because the stupid setup.exe had no intention > to show how many MB there are. > > Andris Spruds That sounds a bit extreme... Ronald, is it really ~60mb? _a -- alex black, ceo en...@tu... the turing studio, inc. http://www.turingstudio.com vox+510.666.0074 fax+510.666.0093 |
From: alex b. <en...@tu...> - 2001-08-04 18:59:55
|
> Where do I put resources that are required by modules? > > I'm a bit courious. One possibility for each site: > > /resources/css > /resources/js > /resources/images/general/* < used by masters, layouts > /resources/images/binarycloud/* < by stuff > /resources/images/module_foo/* < module specific > /resources/images/module_bar/* I like "by project" - so something like: resources/css/binarycloud.css resources/css/project_name.css resources/images/project_name/arbitrary_hierarchy/foo.gif resources/js/project_name_lib.js etc. One of the things on my list is to publish a "spec" on where things should go in resources. I think images, js, and css will end up being module specific like: resources/css/module_name/file.css resources/js/module_name/file.js resources/images/module_name/image.gif resources/images/project_name/your_images.gif So I'd stick with module name for the moment. _a |
From: Andreas A. <a.a...@th...> - 2001-08-04 15:25:35
|
Hi, Im not quite sure how to organize the resources wihtin the bc tree. Is there a "standard" way to go? Where do I put resources that are required by modules? I'm a bit courious. One possibility for each site: /resources/css /resources/js /resources/images/general/* < used by masters, layouts /resources/images/binarycloud/* < by stuff /resources/images/module_foo/* < module specific /resources/images/module_bar/* What do you think? Andi |
From: Alex B. <en...@tu...> - 2001-08-03 16:34:55
|
> Hi Alex, > >>> Hmm. What about POST parameters and sessions? So if a >>> resultpage for sess1 >>> is diferent from one of sess2 because it depends on userdata >>> AND post data. >> >> Well, the idea being that you don't want to cache pages that are session >> specific, or post specific. You could end up with a _huge_ set of cache >> files :) > > Hmm, that's right. But what is with the areas of a sessioned page that are > "static" navigation etc. that depends not on session/post data? I guess the > per module cache applies here? Module "navigation_bar" (static, cached), > module "signup_process" (dynamic, !cached) ? Am I right? Exactly: for things like that, you'd cache the module output, not the page output. I think people will end up caching module output more than "entire" page output - it's more useful. >> This isn't intended for form pages, session specific stuff, etc, as the > files are stored > in the filesystem, unencrypted. > Indeed, would be a HUGE security risk. > > Ok, I got it now :-) > >> This cache has nothing to do with zend's caching - it only caches page >> output - so if you have cached bc php, you'll see even _more_ of a >> performance jump. Zend cache does the actual bytecode... Actually >> - andi, do >> you have performance numbers for r2 on a zend cache-enabled box? >> I'd love to >> see 'em :) > There is a benchmark utility shipped with Zcache. I just run the standard > page of current bc cvs through it. And yeees, I am very surprised. > My average performance boost of my projects (with or without db access) is > around 200%, for bc... > > HARR HARR HARR MORE POWER! (see second mail) heheheheh cool! >> So there isn't really anything like "turn it off" because it isn't "on" >> unless you specifically request it :) > Very fine :-) > > So for a big sime on your face, read the post about "Zend Cache". k :) _a -- alex black, ceo en...@tu... the turing studio, inc. http://www.turingstudio.com vox+510.666.0074 fax+510.666.0093 |
From: Andreas A. <a.a...@th...> - 2001-08-03 10:37:08
|
Hi Alex, > > Hmm. What about POST parameters and sessions? So if a >> resultpage for sess1 > > is diferent from one of sess2 because it depends on userdata >> AND post data. > > Well, the idea being that you don't want to cache pages that are session > specific, or post specific. You could end up with a _huge_ set of cache > files :) Hmm, that's right. But what is with the areas of a sessioned page that are "static" navigation etc. that depends not on session/post data? I guess the per module cache applies here? Module "navigation_bar" (static, cached), module "signup_process" (dynamic, !cached) ? Am I right? > This isn't intended for form pages, session specific stuff, etc, as the files are stored > in the filesystem, unencrypted. Indeed, would be a HUGE security risk. Ok, I got it now :-) > This cache has nothing to do with zend's caching - it only caches page > output - so if you have cached bc php, you'll see even _more_ of a > performance jump. Zend cache does the actual bytecode... Actually > - andi, do > you have performance numbers for r2 on a zend cache-enabled box? > I'd love to > see 'em :) There is a benchmark utility shipped with Zcache. I just run the standard page of current bc cvs through it. And yeees, I am very surprised. My average performance boost of my projects (with or without db access) is around 200%, for bc... HARR HARR HARR MORE POWER! (see second mail) > So there isn't really anything like "turn it off" because it isn't "on" > unless you specifically request it :) Very fine :-) So for a big sime on your face, read the post about "Zend Cache". andi |