Re: How to open a URL in WO

2011-07-13 Thread Michael Sharp
On 14/07/2011, at 11:17 AM, Pascal Robert wrote:

> 
> Le 2011-07-13 à 15:23, Calven Eggert a écrit :
> 
>> Just checked out that link.  this looks pretty cool.   Anyone else in the WO 
>> community use it?  If so, what are your impressions?
>> 
>>> http://hc.apache.org/httpcomponents-client-ga/
> 
> I'm using HTTP Client 3.1 and it's great! Sadly, I can't say about 4.x, they 
> changed a lot of things, so I need to change some code.
> 


I went down this path a couple of weeks ago with the attitude of - hey it's 
just some minor API tweaks, and I don't use it in that many places.

Half a day in saw me realise I use it everywhere and the differences are far 
from minor API tweaks. It was worth it though, particularly for flexibility wrt 
auth schemes.

Sharpy..

 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: "You backtracked too far" error after closing AjaxModalDialog and clicking on a link on the page

2011-07-13 Thread John & Kim Larson
At some point shoulda's become needta's after you've done them that way enough 
I guess. :-/

Even if you were going from an ID of 22 to 8, things should be okay since that 
is within the bounds of the backtrack cache of 30 that your error is 
complaining about. Is it possible you've corrupted your page by changing some 
variable a la the classic repetition with a checkbox gotcha?  I mean it seems 
like a page cache issue, but it also seems like of those "WebObjects is broken! 
... No wait, I'm broken." issues. 

John A. Larson
President
Precision Instruments, Inc.
Ph: 847-824-4194
Fax: 866-240-7104

Sent from my iPhone

On Jul 13, 2011, at 5:24 PM, Chuck Hill  wrote:

> They don't need to be, it is good style IMO to make them void if they don't 
> need to return anything.
> 
> Chuck
> 
> 
> 
> On 2011-07-13, at 4:58 PM, John & Kim Larson wrote:
> 
>> I thought your action methods had to be void methods for Ajax actions, 
>> otherwise this happens. ?
>> 
>> jal
>> 
>> Sent from my iPhone
>> 
>> On Jul 12, 2011, at 10:58 PM, Chuck Hill  wrote:
>> 
>>> On Jul 12, 2011, at 4:29 PM, Ricardo J. Parada wrote:
 On Jul 12, 2011, at 5:53 PM, Chuck Hill wrote:
> On Jul 12, 2011, at 2:45 PM, Ricardo J. Parada wrote:
>> On Jul 12, 2011, at 4:52 PM, Chuck Hill wrote:
>> 
>>> Hi Ricardo,
>>> 
>>> On Jul 12, 2011, at 1:35 PM, Ricardo J. Parada wrote:
 
 Does anybody have an idea what could be causing this problem?  The 
 user clicks on an AjaxModalDialogOpener which opens the dialog.  Then 
 the user does a whole bunch of stuff in the dialog that involves many 
 clicks
>>> 
>>> Does it still happen if they don't make so many clicks?
>> 
>> If they make a few clicks then it works okay.
>> 
>> 
 then finally clicks a DONE link to close the dialog.
>>> 
>>> Are all of these links and clicks Ajax actions?
>>> 
>> 
>> Yes, they are clicking on links generated by AjaxSubmitButton components 
>> to be exact.  :-)
> 
> And you are certain that there are no /wo/ or /wa/ requests mixed in here?
 
 I set this property in my Properties.dev:
 
 log4j.logger.er.extensions.ERXApplication.RequestHandling=DEBUG
 
 and then I looked at all the uri's of the requests coming in.  They have 
 /ajax/ in there and when the dialog first comes up I see a few /_wr_/ and 
 I guess the browser caches those since I don't see requests for those 
 anymore on subsequent requests after the dialog is displayed.
>>> 
>>> Those should be OK, they won't affect the page caches.
>>> 
>>> 
 All the requests for the "many clicks" I mentioned have /ajax/ in them.  I 
 don't see any /wo/ requests mixed in.
 
 Also I set a breakpoint in ERXAjaxSession.java at the only place it calls 
 super.savePage() where I assume the current page would be saved but I 
 never hit the breakpoint.  I would think that regular component requests 
 would be generating new context IDs and therefore saving the page in the 
 cache for those context IDs.  But I don't see the page getting saved.  :-/
>>> 
>>> Yeah, that is what I would expect too.
>>> 
>>> 
 The dialog has a closeUpdateContainerID bound with the id of an ajax 
 update container to refresh, which it does refresh upon closing the 
 dialog.  But then the user clicks on a link on the page that is 
 outside the refreshed AjaxUpdateContainer and the app displays the 
 error "You backtracked too far.  The application backtracking limit of 
 30 has been exceeded."
>>> 
>>> Ajax links or regular component actions links?  I do what seems to be 
>>> the same thing (except maybe the "does a whole bunch of stuff in the 
>>> dialog") and have not had any problems.
>>> 
>> 
>> They are regular component action links.  The context ID for which the 
>> page is being restored is 22.
> 
> The original URL is 21?
> 
 
 Well, I just put in there a  and by 
 inspecting that link after I close the ajax modal dialog and the update 
 container refreshes the href for the link is:
 
 http://192.168.1.9:53295/cgi-bin/WebObjects/Phynance.woa/wo/EmqPpwSYBiOiS7PPSLDXzw/8.0.0.9.1.1.13.1.5.1.2.1.1.3.51
 
 and clicking that generates the "You backtracked too far" error.
>>> 
>>> What is the context ID shown in the browser's location URL?
>>> 
>>> 
>>> The key to tracking this down is to know if it is the Ajax or the 
>>> regular page cache that is missing the component.
>>> 
>> 
>> I'm stepping through the restorePageForContextID() in 
>> ERXAjaxSession.java but I'm not sure what to look for.
> 
> 
> Sorry, I just meant if the URL that caused the error was a /ajax/ or /wo/ 
> URL.  It sounds like a /wo/ URL so that suggests to me that something in 
> your dialog is generating /wo/ or /wa/ reques

Re: "You backtracked too far" error after closing AjaxModalDialog and clicking on a link on the page

2011-07-13 Thread Alexis Tual
Hi,

have you tried to raise the er.extensions.maxPageReplacementCacheSize (default 
is 30) ? It should delay the page restauration error, not fixing the real 
issue... and if you have few users and enough memory, it might be the cheapest 
way to get it done. 
Anyway, I filled a jira for this a year ago 
http://issues.objectstyle.org/jira/browse/WONDER-545 (Don't try the attached 
patch though, it's worse :))

Still in Quebec, back to Poutine free area soon

Alex

Le 12 juil. 2011 à 19:29, Ricardo J. Parada a écrit :

> 
> On Jul 12, 2011, at 5:53 PM, Chuck Hill wrote:
> 
>> 
>> On Jul 12, 2011, at 2:45 PM, Ricardo J. Parada wrote:
>> 
>>> 
>>> On Jul 12, 2011, at 4:52 PM, Chuck Hill wrote:
>>> 
 Hi Ricardo,
 
 On Jul 12, 2011, at 1:35 PM, Ricardo J. Parada wrote:
> 
> Does anybody have an idea what could be causing this problem?  The user 
> clicks on an AjaxModalDialogOpener which opens the dialog.  Then the user 
> does a whole bunch of stuff in the dialog that involves many clicks
 
 Does it still happen if they don't make so many clicks?
>>> 
>>> If they make a few clicks then it works okay.
>>> 
>>> 
> then finally clicks a DONE link to close the dialog.
 
 Are all of these links and clicks Ajax actions?
 
>>> 
>>> Yes, they are clicking on links generated by AjaxSubmitButton components to 
>>> be exact.  :-)
>> 
>> And you are certain that there are no /wo/ or /wa/ requests mixed in here?
> 
> I set this property in my Properties.dev:
> 
> log4j.logger.er.extensions.ERXApplication.RequestHandling=DEBUG
> 
> and then I looked at all the uri's of the requests coming in.  They have 
> /ajax/ in there and when the dialog first comes up I see a few /_wr_/ and I 
> guess the browser caches those since I don't see requests for those anymore 
> on subsequent requests after the dialog is displayed.
> 
> All the requests for the "many clicks" I mentioned have /ajax/ in them.  I 
> don't see any /wo/ requests mixed in.
> 
> Also I set a breakpoint in ERXAjaxSession.java at the only place it calls 
> super.savePage() where I assume the current page would be saved but I never 
> hit the breakpoint.  I would think that regular component requests would be 
> generating new context IDs and therefore saving the page in the cache for 
> those context IDs.  But I don't see the page getting saved.  :-/
> 
>  
>> 
> The dialog has a closeUpdateContainerID bound with the id of an ajax 
> update container to refresh, which it does refresh upon closing the 
> dialog.  But then the user clicks on a link on the page that is outside 
> the refreshed AjaxUpdateContainer and the app displays the error "You 
> backtracked too far.  The application backtracking limit of 30 has been 
> exceeded."
 
 Ajax links or regular component actions links?  I do what seems to be the 
 same thing (except maybe the "does a whole bunch of stuff in the dialog") 
 and have not had any problems.
 
>>> 
>>> They are regular component action links.  The context ID for which the page 
>>> is being restored is 22.
>> 
>> The original URL is 21?
>> 
> 
> Well, I just put in there a  and by 
> inspecting that link after I close the ajax modal dialog and the update 
> container refreshes the href for the link is:
> 
> http://192.168.1.9:53295/cgi-bin/WebObjects/Phynance.woa/wo/EmqPpwSYBiOiS7PPSLDXzw/8.0.0.9.1.1.13.1.5.1.2.1.1.3.51
> 
> and clicking that generates the "You backtracked too far" error.
> 
> 
>> 
>> 
 The key to tracking this down is to know if it is the Ajax or the regular 
 page cache that is missing the component.
 
>>> 
>>> I'm stepping through the restorePageForContextID() in ERXAjaxSession.java 
>>> but I'm not sure what to look for.
>> 
>> 
>> Sorry, I just meant if the URL that caused the error was a /ajax/ or /wo/ 
>> URL.  It sounds like a /wo/ URL so that suggests to me that something in 
>> your dialog is generating /wo/ or /wa/ requests that are pushing the page 
>> out of the standard page cache.
> 
> I did not see any /wo/ nor /wa/ requests.  They are all /ajax/ requests.
> 
> Maybe I'll try to create a test Wonder app with an ajax modal dialog with a 
> single ajax link in it that displays the current time when clicked... Then I 
> can click it many many times.  Then close the dialog and then click on a link 
> on the page afterwards to see if I can reproduce.
> 
> 
> 
> 
>> Chuck
>> 
>> -- 
>> Chuck Hill Senior Consultant / VP Development
>> 
>> Come to WOWODC this July for unparalleled WO learning opportunities and real 
>> peer to peer problem solving!  Network, socialize, and enjoy a great 
>> cosmopolitan city.  See you there!  http://www.wocommunity.org/wowodc11/
>> 
> 
> ___
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
> Help/Unsubscribe/Update your Subscription:
> http://

Re: How to open a URL in WO

2011-07-13 Thread Pascal Robert

Le 2011-07-13 à 15:23, Calven Eggert a écrit :

> Just checked out that link.  this looks pretty cool.   Anyone else in the WO 
> community use it?  If so, what are your impressions?
> 
>> http://hc.apache.org/httpcomponents-client-ga/

I'm using HTTP Client 3.1 and it's great! Sadly, I can't say about 4.x, they 
changed a lot of things, so I need to change some code.

> On 2011-07-13, at 2:14 PM, Chuck Hill wrote:
> 
>> 
>> On Jul 13, 2011, at 10:54 AM, Calven Eggert wrote:
>> 
>>> Geesh, after reading this I've realized that I missed a 'minor' detail.  
>>> hehe  
>> 
>> :-)
>> 
>> 
>>> My task is for a current WO application to import data from a new source, 
>>> which happens to be a given URL.  Far as I know it's read-only. (I can't 
>>> imagine having to rewrite all my WO apps of over 10 years work.  yikes, 
>>> that would be scary)
>> 
>> OK, that should be a lot less scary.  You will need them to provide some 
>> documentation on what exactly that URL returns.  Then use something like 
>> this:
>> http://hc.apache.org/httpcomponents-client-ga/
>> 
>> to get the content.  Parsing / handling the content depends on what the are 
>> sending back.
>> 
>> 
>>> one reply to this subject talked about REST.  is this my solution?
>> 
>> I thought that ERRest was mostly on the production, not consumption side.  I 
>> could be wrong.  It may be of some use in parsing the response in any case.
>> 
>> 
>> Chuck
>> 
>> 
>> 
>> 
>>> On 2011-07-13, at 1:12 PM, Chuck Hill wrote:
>>> 
 
 On Jul 13, 2011, at 6:57 AM, Calven Eggert wrote:
 
> I've just been told that instead of getting data from a database within 
> my organization that I should be opening a URL and get the data that way. 
>  I have no clue how that would be done in Webobjects.  Can someone please 
> gently lead me in the right direction? 
 
 
 Read only?  Full CRUD?
 
 If you still want the result in EOs, then you need to write an EOF adaptor 
 (e.g. like the JDBCAdaptor and the JNDIAdaptor).  That is going to be a 
 good bit of work.  Maybe a lot of work.  They want to replace what EOF 
 does with an HTTP service that will (most probably) be slower.  Unless you 
 are using D2W, you might find that something other than WO is a better 
 option.
 
 If you just want dictionaries of read-only data, that can be considerably 
 easier.
 
 Chuck
 
 
 -- 
 Chuck Hill Senior Consultant / VP Development
 
 Practical WebObjects - for developers who want to increase their overall 
 knowledge of WebObjects or who are trying to solve specific problems.
 http://www.global-village.net/products/practical_webobjects
 
 
 
 
 
 
 
>>> 
>>> 
>> 
>> -- 
>> Chuck Hill Senior Consultant / VP Development
>> 
>> Practical WebObjects - for developers who want to increase their overall 
>> knowledge of WebObjects or who are trying to solve specific problems.
>> http://www.global-village.net/products/practical_webobjects
>> 
>> 
>> 
>> 
>> 
>> 
>> 
> 
> 
> ___
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
> Help/Unsubscribe/Update your Subscription:
> http://lists.apple.com/mailman/options/webobjects-dev/probert%40macti.ca
> 
> This email sent to prob...@macti.ca

 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: Occasional hang loading a particular large page

2011-07-13 Thread Kevin

On Jul 13, 2011, at 5:31 PM, Chuck Hill wrote:

> 
> On 2011-07-13, at 5:21 PM, Kevin wrote:
> 
>> I have an app that tends to lock up when a particular page is loaded. This 
>> page fetches and accesses over 1500 records from a FrontBase DB.
> 
> As long as it is not a lot over 1,500 that should not cause a delay as 
> significant at this.  Turn on SQL logging and check the log.  It could be 
> that it is fetching those rows and then firing off many single row faults.  
> Or you might have a corrupt index or a unoptimizable query against a large 
> table / complex joins.
> 
> 
> 
>> When the problem happens I typically see a broken socket in the webobjects 
>> log file, and if I look in the FB manager the state column shows "tb swp" 
>> where the others show only "swp".
> 
> t means Open Transaction
> b means Busy
> 
> So FrontBase is evaluating a query to return the result.  That suggests a 
> corrupt index or a unoptimizable query.
> 
> 
>> Also CPU usage is quite high when in this state.
> 
> App or database usage?
> 
> 
>> It will stay this way until I kill it, or the app dies. If I kill that 
>> transaction and try again, most of the time it will work fine. Sometimes I 
>> have to restart the app.
>> 
>> Any ideas how I can track this problem down. And does anyone know what the 
>> letters indicate in the state field. I think there is a clue there, but I 
>> can't find those letters in the docs so I don't know what they indicate.
> 
> 
> Check the SQL issued from the app first.  Then try the same SQL directly in 
> FB.

Thanks Chuck. I will try your suggestions and see where that leads.

- Kevin

 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: Occasional hang loading a particular large page

2011-07-13 Thread Kevin

On Jul 13, 2011, at 5:26 PM, Paul D Yu wrote:

> Have you tried using ERXBatchFetching stuff?
> 
> I use ERXBatchingDisplayGroup for large pages and it has worked well.

No I haven't. When it works, the page loads pretty quickly, faster than I would 
have expected. If I can just track down what causes the occasional hang and fix 
that, then everyone will be happy.

- Kevin ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: Question about 1-to-many relationship

2011-07-13 Thread Chuck Hill
Please let us know what you find out.

Chuck

On 2011-07-13, at 4:39 PM, Ricardo J. Parada wrote:

> 
> Well I'm not so sure yet... :-)  I'm backed out my change today.  After more 
> testing another case was found were EOF was misbehaving and I was able to fix 
> it today by backing this out.  The weird thing is that the other bug that 
> this was supposed to fix is not reproducible.  But other things in the UI of 
> the app changed.  So who knows.  I'm seriously questioning whether this code 
> was really needed.  I really don't have any scientific proof.  :-)
> 
> So I'm just gonna wait and see how it goes on the testing.  :-)
> 
> Thanks
> 
> 
> On Jul 13, 2011, at 6:41 PM, Chuck Hill wrote:
> 
>> Hi Richardo,
>> 
>> On 2011-07-07, at 7:09 PM, Ricardo J. Parada wrote:
>> 
>>> Hi Ramsey,
>>> 
>>> I did not know about ERXEOControlUtilities.editableInstanceOfObject().  It 
>>> seems to be doing some interesting stuff.  :-)  But it's not doing an 
>>> insertObject() if the eo is a new object.  So if I try using 
>>> ERXEOControlUtilities.editableInstanceOfObject() then the problem comes 
>>> back and it is 100% reproducible in my app.  Then I put my code back and 
>>> things work like a champ.  So I'm sticking with my code for now.  
>>> 
>>> Maybe someone with a better understanding of the EOF internals can comment 
>>> on this and if I'm right that the insertObject() is needed then maybe we 
>>> should patch ERXEOControlUtilities.editableInstanceOfObject() to do an 
>>> insertObject() and I would be glad to use it.
>>> 
>>> Here's a revised version of my code that local instances the object:
>>> 
>>> // Copy document to child editing context
>>> +++ boolean isNewObject = document.isNewObject();
>>> document = document.localInstanceIn(childEditingContext);
>>> +++ if (isNewObject) {
>>> +++ childEditingContext.insertObject(document);
>>> +++ }
>>> 
>>> 
>>> ---
>>> The question is: When local instancing a new eo (that's never been saved to 
>>> the database) into a child editing context, does the local instance of the 
>>> eo need to be inserted into the child editing context?
>>> 
>>> Answer: ??? Mike do you know??  ;-)
>>> 
>> 
>> Generally the answer is No.  Or should be no.  I think you have found a bug 
>> in EOF with how it handles new objects in child ECs and new objects related 
>> in that EC.
>> 
>> 
>>> See, when I asked the child editing context for the insertedObjects() and 
>>> noticed that the eo was missing from there it occurred to me that I was 
>>> violating an EOF commandment that says that you have to insert the eo 
>>> before you start using it.  It has been inserted into the parent editing 
>>> context but not in the child editing context.  So we all know that when we 
>>> violate EOF commandments then weird things happen at random.  Which is what 
>>> seemed to be happening here. 
>>> Anyways, I'll leave the question open to see if somebody has the answer to 
>>> it.
>> 
>> I'd need to do more research to give you a definitive answer.  What you are 
>> doing sounds like it is working around a bug in EOF.  I don't know if your 
>> work around could cause other problems or not.
>> 
>> 
>> Chuck
>> 
>> 
>> 
>>> On Jul 7, 2011, at 7:12 PM, Ramsey Gurley wrote:
>>> 
 Hi Ricardo,
 
 I've never had the problem you are seeing, but it sounds interesting. I 
 see in ERXEOControlUtilities.editableInstanceOfObject that willRead() is 
 called on the EO immediately after localInstance... it would be 
 interesting to know if this solves the problem as well.
 
 Ramsey
 
 On Jul 7, 2011, at 4:02 PM, Ricardo J. Parada wrote:
 
> I have the to-many delete rule set to "Cascade".  I changed it to "No 
> Action" but it was still misbehaving.
> 
> BUT, I think I figured it out.  Let me tell the whole story.  :-)
> 
> I inserted the document object into an editing context.  This document 
> has no children in the to-many relationship yet and it has never been 
> saved to the database.  The user then clicks a link to open an 
> AjaxModalDialog (AMD).  When this happens the document object is 
> localInstanced into a child editing context.  So I then add two children 
> to the to-many and then removed one of them.  Then when the user clicks 
> DONE in the AMD I then save the changes to the parent editing context, 
> the AMD closes and the user may continue editing other aspects of the 
> document there.  Then the user saves there and changes are saved to the 
> database.
> 
> Well, it turns out that when I local instanced the document into the 
> child editing context I also need to call insertObject on the child 
> editing context to insert the document there.  I noticed this as the 
> possible culprit because when I asked the child editing context for the 
> insertedObjects() the document o

Re: Question about 1-to-many relationship

2011-07-13 Thread Ricardo J. Parada

Well I'm not so sure yet... :-)  I'm backed out my change today.  After more 
testing another case was found were EOF was misbehaving and I was able to fix 
it today by backing this out.  The weird thing is that the other bug that this 
was supposed to fix is not reproducible.  But other things in the UI of the app 
changed.  So who knows.  I'm seriously questioning whether this code was really 
needed.  I really don't have any scientific proof.  :-)

So I'm just gonna wait and see how it goes on the testing.  :-)

Thanks


On Jul 13, 2011, at 6:41 PM, Chuck Hill wrote:

> Hi Richardo,
> 
> On 2011-07-07, at 7:09 PM, Ricardo J. Parada wrote:
> 
>> Hi Ramsey,
>> 
>> I did not know about ERXEOControlUtilities.editableInstanceOfObject().  It 
>> seems to be doing some interesting stuff.  :-)  But it's not doing an 
>> insertObject() if the eo is a new object.  So if I try using 
>> ERXEOControlUtilities.editableInstanceOfObject() then the problem comes back 
>> and it is 100% reproducible in my app.  Then I put my code back and things 
>> work like a champ.  So I'm sticking with my code for now.  
>> 
>> Maybe someone with a better understanding of the EOF internals can comment 
>> on this and if I'm right that the insertObject() is needed then maybe we 
>> should patch ERXEOControlUtilities.editableInstanceOfObject() to do an 
>> insertObject() and I would be glad to use it.
>> 
>> Here's a revised version of my code that local instances the object:
>> 
>>  // Copy document to child editing context
>> +++  boolean isNewObject = document.isNewObject();
>>  document = document.localInstanceIn(childEditingContext);
>> +++  if (isNewObject) {
>> +++  childEditingContext.insertObject(document);
>> +++  }
>> 
>> 
>> ---
>> The question is: When local instancing a new eo (that's never been saved to 
>> the database) into a child editing context, does the local instance of the 
>> eo need to be inserted into the child editing context?
>> 
>> Answer: ??? Mike do you know??  ;-)
>> 
> 
> Generally the answer is No.  Or should be no.  I think you have found a bug 
> in EOF with how it handles new objects in child ECs and new objects related 
> in that EC.
> 
> 
>> See, when I asked the child editing context for the insertedObjects() and 
>> noticed that the eo was missing from there it occurred to me that I was 
>> violating an EOF commandment that says that you have to insert the eo before 
>> you start using it.  It has been inserted into the parent editing context 
>> but not in the child editing context.  So we all know that when we violate 
>> EOF commandments then weird things happen at random.  Which is what seemed 
>> to be happening here. 
>> Anyways, I'll leave the question open to see if somebody has the answer to 
>> it.
> 
> I'd need to do more research to give you a definitive answer.  What you are 
> doing sounds like it is working around a bug in EOF.  I don't know if your 
> work around could cause other problems or not.
> 
> 
> Chuck
> 
> 
> 
>> On Jul 7, 2011, at 7:12 PM, Ramsey Gurley wrote:
>> 
>>> Hi Ricardo,
>>> 
>>> I've never had the problem you are seeing, but it sounds interesting. I see 
>>> in ERXEOControlUtilities.editableInstanceOfObject that willRead() is called 
>>> on the EO immediately after localInstance... it would be interesting to 
>>> know if this solves the problem as well.
>>> 
>>> Ramsey
>>> 
>>> On Jul 7, 2011, at 4:02 PM, Ricardo J. Parada wrote:
>>> 
 I have the to-many delete rule set to "Cascade".  I changed it to "No 
 Action" but it was still misbehaving.
 
 BUT, I think I figured it out.  Let me tell the whole story.  :-)
 
 I inserted the document object into an editing context.  This document has 
 no children in the to-many relationship yet and it has never been saved to 
 the database.  The user then clicks a link to open an AjaxModalDialog 
 (AMD).  When this happens the document object is localInstanced into a 
 child editing context.  So I then add two children to the to-many and then 
 removed one of them.  Then when the user clicks DONE in the AMD I then 
 save the changes to the parent editing context, the AMD closes and the 
 user may continue editing other aspects of the document there.  Then the 
 user saves there and changes are saved to the database.
 
 Well, it turns out that when I local instanced the document into the child 
 editing context I also need to call insertObject on the child editing 
 context to insert the document there.  I noticed this as the possible 
 culprit because when I asked the child editing context for the 
 insertedObjects() the document object did not appear in the list.  So 
 basically I changed my code that local instances the document to something 
 like this:
 
// Copy document to child editing context
documen

Re: Occasional hang loading a particular large page

2011-07-13 Thread David Holt

On 2011-07-13, at 3:26 PM, Paul D Yu wrote:

> Have you tried using ERXBatchFetching stuff?
> 
> I use ERXBatchingDisplayGroup for large pages and it has worked well.

Speaking of ERXBatchingDisplayGroup, I just discovered there is rule support 
for it in ERD2WList pages but it is not turned on by default. Can I use this as 
a default for my list page so long as my datasource for the page is an 
EODatabaseDataSource? Are there any other gotchas?

David

> 
> Paul
> On Jul 13, 2011, at 6:21 PM, Kevin wrote:
> 
>> I have an app that tends to lock up when a particular page is loaded. This 
>> page fetches and accesses over 1500 records from a FrontBase DB. When the 
>> problem happens I typically see a broken socket in the webobjects log file, 
>> and if I look in the FB manager the state column shows "tb swp" where the 
>> others show only "swp". Also CPU usage is quite high when in this state. It 
>> will stay this way until I kill it, or the app dies. If I kill that 
>> transaction and try again, most of the time it will work fine. Sometimes I 
>> have to restart the app.
>> 
>> Any ideas how I can track this problem down. And does anyone know what the 
>> letters indicate in the state field. I think there is a clue there, but I 
>> can't find those letters in the docs so I don't know what they indicate.
>> 
>> Thanks,
>> Kevin ___
>> Do not post admin requests to the list. They will be ignored.
>> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
>> Help/Unsubscribe/Update your Subscription:
>> http://lists.apple.com/mailman/options/webobjects-dev/pyu%40mac.com
>> 
>> This email sent to p...@mac.com
> 
> ___
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
> Help/Unsubscribe/Update your Subscription:
> http://lists.apple.com/mailman/options/webobjects-dev/programmingosx%40mac.com
> 
> This email sent to programming...@mac.com

 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: Question about 1-to-many relationship

2011-07-13 Thread Chuck Hill
Hi Richardo,

On 2011-07-07, at 7:09 PM, Ricardo J. Parada wrote:

> Hi Ramsey,
> 
> I did not know about ERXEOControlUtilities.editableInstanceOfObject().  It 
> seems to be doing some interesting stuff.  :-)  But it's not doing an 
> insertObject() if the eo is a new object.  So if I try using 
> ERXEOControlUtilities.editableInstanceOfObject() then the problem comes back 
> and it is 100% reproducible in my app.  Then I put my code back and things 
> work like a champ.  So I'm sticking with my code for now.  
> 
> Maybe someone with a better understanding of the EOF internals can comment on 
> this and if I'm right that the insertObject() is needed then maybe we should 
> patch ERXEOControlUtilities.editableInstanceOfObject() to do an 
> insertObject() and I would be glad to use it.
> 
> Here's a revised version of my code that local instances the object:
> 
>   // Copy document to child editing context
> +++   boolean isNewObject = document.isNewObject();
>   document = document.localInstanceIn(childEditingContext);
> +++   if (isNewObject) {
> +++   childEditingContext.insertObject(document);
> +++   }
> 
> 
> ---
> The question is: When local instancing a new eo (that's never been saved to 
> the database) into a child editing context, does the local instance of the eo 
> need to be inserted into the child editing context?
> 
> Answer: ??? Mike do you know??  ;-)
> 

Generally the answer is No.  Or should be no.  I think you have found a bug in 
EOF with how it handles new objects in child ECs and new objects related in 
that EC.


> See, when I asked the child editing context for the insertedObjects() and 
> noticed that the eo was missing from there it occurred to me that I was 
> violating an EOF commandment that says that you have to insert the eo before 
> you start using it.  It has been inserted into the parent editing context but 
> not in the child editing context.  So we all know that when we violate EOF 
> commandments then weird things happen at random.  Which is what seemed to be 
> happening here. 
> Anyways, I'll leave the question open to see if somebody has the answer to it.

I'd need to do more research to give you a definitive answer.  What you are 
doing sounds like it is working around a bug in EOF.  I don't know if your work 
around could cause other problems or not.


Chuck



> On Jul 7, 2011, at 7:12 PM, Ramsey Gurley wrote:
> 
>> Hi Ricardo,
>> 
>> I've never had the problem you are seeing, but it sounds interesting. I see 
>> in ERXEOControlUtilities.editableInstanceOfObject that willRead() is called 
>> on the EO immediately after localInstance... it would be interesting to know 
>> if this solves the problem as well.
>> 
>> Ramsey
>> 
>> On Jul 7, 2011, at 4:02 PM, Ricardo J. Parada wrote:
>> 
>>> I have the to-many delete rule set to "Cascade".  I changed it to "No 
>>> Action" but it was still misbehaving.
>>> 
>>> BUT, I think I figured it out.  Let me tell the whole story.  :-)
>>> 
>>> I inserted the document object into an editing context.  This document has 
>>> no children in the to-many relationship yet and it has never been saved to 
>>> the database.  The user then clicks a link to open an AjaxModalDialog 
>>> (AMD).  When this happens the document object is localInstanced into a 
>>> child editing context.  So I then add two children to the to-many and then 
>>> removed one of them.  Then when the user clicks DONE in the AMD I then save 
>>> the changes to the parent editing context, the AMD closes and the user may 
>>> continue editing other aspects of the document there.  Then the user saves 
>>> there and changes are saved to the database.
>>> 
>>> Well, it turns out that when I local instanced the document into the child 
>>> editing context I also need to call insertObject on the child editing 
>>> context to insert the document there.  I noticed this as the possible 
>>> culprit because when I asked the child editing context for the 
>>> insertedObjects() the document object did not appear in the list.  So 
>>> basically I changed my code that local instances the document to something 
>>> like this:
>>> 
>>> // Copy document to child editing context
>>> document = document.localInstanceIn(childEditingContext);
>>> +++ if (document.isNewObject()) {
>>> +++ childEditingContext.insertObject(document);
>>> +++ }
>>> 
>>> Now EOF behaves as expected!!  That seems to be the fix.  So I guess that 
>>> if a newly created object that's never been saved to the database is local 
>>> instanced into an editing context then it needs to be inserted into the 
>>> child editing context for EOF to work properly.  
>>> 
>>> I may have learned something new today!!   :-)
>>> 
>>> 
>>> 
>>> 
>>> On Jul 7, 2011, at 5:43 PM, Chuck Hill wrote:
>>> 
 Hi Ricardo,
 
 
 On 2011-07-07, at 1:52 PM, Ricardo J. Parada wrot

Re: Occasional hang loading a particular large page

2011-07-13 Thread Chuck Hill

On 2011-07-13, at 5:21 PM, Kevin wrote:

> I have an app that tends to lock up when a particular page is loaded. This 
> page fetches and accesses over 1500 records from a FrontBase DB.

As long as it is not a lot over 1,500 that should not cause a delay as 
significant at this.  Turn on SQL logging and check the log.  It could be that 
it is fetching those rows and then firing off many single row faults.  Or you 
might have a corrupt index or a unoptimizable query against a large table / 
complex joins.



> When the problem happens I typically see a broken socket in the webobjects 
> log file, and if I look in the FB manager the state column shows "tb swp" 
> where the others show only "swp".

t means Open Transaction
b means Busy

So FrontBase is evaluating a query to return the result.  That suggests a 
corrupt index or a unoptimizable query.


> Also CPU usage is quite high when in this state.

App or database usage?


> It will stay this way until I kill it, or the app dies. If I kill that 
> transaction and try again, most of the time it will work fine. Sometimes I 
> have to restart the app.
> 
> Any ideas how I can track this problem down. And does anyone know what the 
> letters indicate in the state field. I think there is a clue there, but I 
> can't find those letters in the docs so I don't know what they indicate.


Check the SQL issued from the app first.  Then try the same SQL directly in FB.


Chuck

-- 
Chuck Hill Senior Consultant / VP Development

Practical WebObjects - for developers who want to increase their overall 
knowledge of WebObjects or who are trying to solve specific problems.
http://www.global-village.net/products/practical_webobjects







 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: Occasional hang loading a particular large page

2011-07-13 Thread Paul D Yu
Have you tried using ERXBatchFetching stuff?

I use ERXBatchingDisplayGroup for large pages and it has worked well.

Paul
On Jul 13, 2011, at 6:21 PM, Kevin wrote:

> I have an app that tends to lock up when a particular page is loaded. This 
> page fetches and accesses over 1500 records from a FrontBase DB. When the 
> problem happens I typically see a broken socket in the webobjects log file, 
> and if I look in the FB manager the state column shows "tb swp" where the 
> others show only "swp". Also CPU usage is quite high when in this state. It 
> will stay this way until I kill it, or the app dies. If I kill that 
> transaction and try again, most of the time it will work fine. Sometimes I 
> have to restart the app.
> 
> Any ideas how I can track this problem down. And does anyone know what the 
> letters indicate in the state field. I think there is a clue there, but I 
> can't find those letters in the docs so I don't know what they indicate.
> 
> Thanks,
> Kevin ___
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
> Help/Unsubscribe/Update your Subscription:
> http://lists.apple.com/mailman/options/webobjects-dev/pyu%40mac.com
> 
> This email sent to p...@mac.com

 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: "You backtracked too far" error after closing AjaxModalDialog and clicking on a link on the page

2011-07-13 Thread Chuck Hill
They don't need to be, it is good style IMO to make them void if they don't 
need to return anything.

Chuck



On 2011-07-13, at 4:58 PM, John & Kim Larson wrote:

> I thought your action methods had to be void methods for Ajax actions, 
> otherwise this happens. ?
> 
> jal
> 
> Sent from my iPhone
> 
> On Jul 12, 2011, at 10:58 PM, Chuck Hill  wrote:
> 
>> On Jul 12, 2011, at 4:29 PM, Ricardo J. Parada wrote:
>>> On Jul 12, 2011, at 5:53 PM, Chuck Hill wrote:
 On Jul 12, 2011, at 2:45 PM, Ricardo J. Parada wrote:
> On Jul 12, 2011, at 4:52 PM, Chuck Hill wrote:
> 
>> Hi Ricardo,
>> 
>> On Jul 12, 2011, at 1:35 PM, Ricardo J. Parada wrote:
>>> 
>>> Does anybody have an idea what could be causing this problem?  The user 
>>> clicks on an AjaxModalDialogOpener which opens the dialog.  Then the 
>>> user does a whole bunch of stuff in the dialog that involves many clicks
>> 
>> Does it still happen if they don't make so many clicks?
> 
> If they make a few clicks then it works okay.
> 
> 
>>> then finally clicks a DONE link to close the dialog.
>> 
>> Are all of these links and clicks Ajax actions?
>> 
> 
> Yes, they are clicking on links generated by AjaxSubmitButton components 
> to be exact.  :-)
 
 And you are certain that there are no /wo/ or /wa/ requests mixed in here?
>>> 
>>> I set this property in my Properties.dev:
>>> 
>>> log4j.logger.er.extensions.ERXApplication.RequestHandling=DEBUG
>>> 
>>> and then I looked at all the uri's of the requests coming in.  They have 
>>> /ajax/ in there and when the dialog first comes up I see a few /_wr_/ and I 
>>> guess the browser caches those since I don't see requests for those anymore 
>>> on subsequent requests after the dialog is displayed.
>> 
>> Those should be OK, they won't affect the page caches.
>> 
>> 
>>> All the requests for the "many clicks" I mentioned have /ajax/ in them.  I 
>>> don't see any /wo/ requests mixed in.
>>> 
>>> Also I set a breakpoint in ERXAjaxSession.java at the only place it calls 
>>> super.savePage() where I assume the current page would be saved but I never 
>>> hit the breakpoint.  I would think that regular component requests would be 
>>> generating new context IDs and therefore saving the page in the cache for 
>>> those context IDs.  But I don't see the page getting saved.  :-/
>> 
>> Yeah, that is what I would expect too.
>> 
>> 
>>> The dialog has a closeUpdateContainerID bound with the id of an ajax 
>>> update container to refresh, which it does refresh upon closing the 
>>> dialog.  But then the user clicks on a link on the page that is outside 
>>> the refreshed AjaxUpdateContainer and the app displays the error "You 
>>> backtracked too far.  The application backtracking limit of 30 has been 
>>> exceeded."
>> 
>> Ajax links or regular component actions links?  I do what seems to be 
>> the same thing (except maybe the "does a whole bunch of stuff in the 
>> dialog") and have not had any problems.
>> 
> 
> They are regular component action links.  The context ID for which the 
> page is being restored is 22.
 
 The original URL is 21?
 
>>> 
>>> Well, I just put in there a  and by 
>>> inspecting that link after I close the ajax modal dialog and the update 
>>> container refreshes the href for the link is:
>>> 
>>> http://192.168.1.9:53295/cgi-bin/WebObjects/Phynance.woa/wo/EmqPpwSYBiOiS7PPSLDXzw/8.0.0.9.1.1.13.1.5.1.2.1.1.3.51
>>> 
>>> and clicking that generates the "You backtracked too far" error.
>> 
>> What is the context ID shown in the browser's location URL?
>> 
>> 
>> The key to tracking this down is to know if it is the Ajax or the 
>> regular page cache that is missing the component.
>> 
> 
> I'm stepping through the restorePageForContextID() in ERXAjaxSession.java 
> but I'm not sure what to look for.
 
 
 Sorry, I just meant if the URL that caused the error was a /ajax/ or /wo/ 
 URL.  It sounds like a /wo/ URL so that suggests to me that something in 
 your dialog is generating /wo/ or /wa/ requests that are pushing the page 
 out of the standard page cache.
>>> 
>>> I did not see any /wo/ nor /wa/ requests.  They are all /ajax/ requests.
>>> 
>>> Maybe I'll try to create a test Wonder app with an ajax modal dialog with a 
>>> single ajax link in it that displays the current time when clicked... Then 
>>> I can click it many many times.  Then close the dialog and then click on a 
>>> link on the page afterwards to see if I can reproduce.
>> 
>> I'd be interested if you can reproduce it.  The only think that I can think 
>> of is that the Ajax code is getting confused and using the regular page 
>> cache.  But then I would expect to see calls to super.savePage.
>> 
>> The only other thing that I can think of is that the session is getting 
>> switched, but with the session in the URL t

Occasional hang loading a particular large page

2011-07-13 Thread Kevin
I have an app that tends to lock up when a particular page is loaded. This page 
fetches and accesses over 1500 records from a FrontBase DB. When the problem 
happens I typically see a broken socket in the webobjects log file, and if I 
look in the FB manager the state column shows "tb swp" where the others show 
only "swp". Also CPU usage is quite high when in this state. It will stay this 
way until I kill it, or the app dies. If I kill that transaction and try again, 
most of the time it will work fine. Sometimes I have to restart the app.

Any ideas how I can track this problem down. And does anyone know what the 
letters indicate in the state field. I think there is a clue there, but I can't 
find those letters in the docs so I don't know what they indicate.

Thanks,
Kevin ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: "You backtracked too far" error after closing AjaxModalDialog and clicking on a link on the page

2011-07-13 Thread John & Kim Larson
I thought your action methods had to be void methods for Ajax actions, 
otherwise this happens. ?

jal

Sent from my iPhone

On Jul 12, 2011, at 10:58 PM, Chuck Hill  wrote:

> On Jul 12, 2011, at 4:29 PM, Ricardo J. Parada wrote:
>> On Jul 12, 2011, at 5:53 PM, Chuck Hill wrote:
>>> On Jul 12, 2011, at 2:45 PM, Ricardo J. Parada wrote:
 On Jul 12, 2011, at 4:52 PM, Chuck Hill wrote:
 
> Hi Ricardo,
> 
> On Jul 12, 2011, at 1:35 PM, Ricardo J. Parada wrote:
>> 
>> Does anybody have an idea what could be causing this problem?  The user 
>> clicks on an AjaxModalDialogOpener which opens the dialog.  Then the 
>> user does a whole bunch of stuff in the dialog that involves many clicks
> 
> Does it still happen if they don't make so many clicks?
 
 If they make a few clicks then it works okay.
 
 
>> then finally clicks a DONE link to close the dialog.
> 
> Are all of these links and clicks Ajax actions?
> 
 
 Yes, they are clicking on links generated by AjaxSubmitButton components 
 to be exact.  :-)
>>> 
>>> And you are certain that there are no /wo/ or /wa/ requests mixed in here?
>> 
>> I set this property in my Properties.dev:
>> 
>> log4j.logger.er.extensions.ERXApplication.RequestHandling=DEBUG
>> 
>> and then I looked at all the uri's of the requests coming in.  They have 
>> /ajax/ in there and when the dialog first comes up I see a few /_wr_/ and I 
>> guess the browser caches those since I don't see requests for those anymore 
>> on subsequent requests after the dialog is displayed.
> 
> Those should be OK, they won't affect the page caches.
> 
> 
>> All the requests for the "many clicks" I mentioned have /ajax/ in them.  I 
>> don't see any /wo/ requests mixed in.
>> 
>> Also I set a breakpoint in ERXAjaxSession.java at the only place it calls 
>> super.savePage() where I assume the current page would be saved but I never 
>> hit the breakpoint.  I would think that regular component requests would be 
>> generating new context IDs and therefore saving the page in the cache for 
>> those context IDs.  But I don't see the page getting saved.  :-/
> 
> Yeah, that is what I would expect too.
> 
> 
>> The dialog has a closeUpdateContainerID bound with the id of an ajax 
>> update container to refresh, which it does refresh upon closing the 
>> dialog.  But then the user clicks on a link on the page that is outside 
>> the refreshed AjaxUpdateContainer and the app displays the error "You 
>> backtracked too far.  The application backtracking limit of 30 has been 
>> exceeded."
> 
> Ajax links or regular component actions links?  I do what seems to be the 
> same thing (except maybe the "does a whole bunch of stuff in the dialog") 
> and have not had any problems.
> 
 
 They are regular component action links.  The context ID for which the 
 page is being restored is 22.
>>> 
>>> The original URL is 21?
>>> 
>> 
>> Well, I just put in there a  and by 
>> inspecting that link after I close the ajax modal dialog and the update 
>> container refreshes the href for the link is:
>> 
>> http://192.168.1.9:53295/cgi-bin/WebObjects/Phynance.woa/wo/EmqPpwSYBiOiS7PPSLDXzw/8.0.0.9.1.1.13.1.5.1.2.1.1.3.51
>> 
>> and clicking that generates the "You backtracked too far" error.
> 
> What is the context ID shown in the browser's location URL?
> 
> 
> The key to tracking this down is to know if it is the Ajax or the regular 
> page cache that is missing the component.
> 
 
 I'm stepping through the restorePageForContextID() in ERXAjaxSession.java 
 but I'm not sure what to look for.
>>> 
>>> 
>>> Sorry, I just meant if the URL that caused the error was a /ajax/ or /wo/ 
>>> URL.  It sounds like a /wo/ URL so that suggests to me that something in 
>>> your dialog is generating /wo/ or /wa/ requests that are pushing the page 
>>> out of the standard page cache.
>> 
>> I did not see any /wo/ nor /wa/ requests.  They are all /ajax/ requests.
>> 
>> Maybe I'll try to create a test Wonder app with an ajax modal dialog with a 
>> single ajax link in it that displays the current time when clicked... Then I 
>> can click it many many times.  Then close the dialog and then click on a 
>> link on the page afterwards to see if I can reproduce.
> 
> I'd be interested if you can reproduce it.  The only think that I can think 
> of is that the Ajax code is getting confused and using the regular page 
> cache.  But then I would expect to see calls to super.savePage.
> 
> The only other thing that I can think of is that the session is getting 
> switched, but with the session in the URL that should not happen.
> 
> 
> Chuck
> 
> -- 
> Chuck Hill Senior Consultant / VP Development
> 
> Practical WebObjects - for developers who want to increase their overall 
> knowledge of WebObjects or who are trying to solve specific problems.
> http://www.global-village.n

Re: EOQualifier from object array

2011-07-13 Thread Chuck Hill

On 2011-07-13, at 3:19 PM, Steve Peery wrote:

> Does anybody talk code on this list anymore ;-)

No, but there might be a committee for that.  :-P


> I have an array of EO objects and I want to fetch an array with all EO 
> objects that are not in the array.
> If I were using SQL, it would look something like this:
> 
> SELECT oid FROM MyEOObject WHERE oid != 1 AND oid != 3 AND oid != 5;
>   
> I can do it using EOQualifier.qualifierWithQualifierFormat and a format 
> string or I can fetch them all and make the array by comparing them. Is there 
> a better way?


Using Wonder, right?  Right?

See the classes in package er.extensions.eof.qualifiers.  Specifically 
ERXInQualifier, ERXPrimaryKeyListQualifier, and ERXQualifierInSubquery.  Along 
with the standard EONotQualifier.

Chuck


-- 
Chuck Hill Senior Consultant / VP Development

Practical WebObjects - for developers who want to increase their overall 
knowledge of WebObjects or who are trying to solve specific problems.
http://www.global-village.net/products/practical_webobjects







 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


EOQualifier from object array

2011-07-13 Thread Steve Peery
Does anybody talk code on this list anymore ;-)

I have an array of EO objects and I want to fetch an array with all EO objects 
that are not in the array.
If I were using SQL, it would look something like this:

SELECT oid FROM MyEOObject WHERE oid != 1 AND oid != 3 AND oid != 5;

I can do it using EOQualifier.qualifierWithQualifierFormat and a format string 
or I can fetch them all and make the array by comparing them. Is there a better 
way?

Thanks,
Steve
 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: Let's find a new name for the Community

2011-07-13 Thread David Holt

On 2011-07-13, at 1:01 PM, Ray Kiddy wrote:

> 
>> On Jul 13, 2011, at 10:32 AM, Jesse Tayler wrote:
>> 
>>> where's the support for fluffy bunny?
>>> 
>>> I feel that's the only change I could really get behind.
>>> 
>>> 
>>> I thought we'd decided on: FGP  (Foie Gras Poutine).
>> 
>> Can combine the two: Foie Gras Poutine: it's a Wonder that David H. 
>> did have a heart attack
> 
> Are "WObernate" and "WOpestry" taken? :-)
 
>> Well then let's better call it WOStruts or WOJSP and WOEJB … :->>
> 
> WOBOL?
 
 Great! I am all the rage for it. Because that is some real sarcasm. And 
 everybody understands it (not just us WO-folks).
> 
> 
> Does anybody else see that picking a name based on an arcane inside (either 
> Silicon Valley or Quebec flavored) joke might not be the best move? :-) 
> WOBOL. Just wow.

Um yeah, that WAS a joke.

> 
> Nobody likes my suggestion? I suggested wouzuri. This is from "WO" + "uziri", 
> which is the Swahili word for beauty. No? Isn't beauty, in some way, exactly 
> what we are trying to create and enourage?
> 
> - ray
> 
> ___
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
> Help/Unsubscribe/Update your Subscription:
> http://lists.apple.com/mailman/options/webobjects-dev/programmingosx%40mac.com
> 
> This email sent to programming...@mac.com

 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: Let's find a new name for the Community

2011-07-13 Thread Ray Kiddy

> On Jul 13, 2011, at 10:32 AM, Jesse Tayler wrote:
> 
>> where's the support for fluffy bunny?
>> 
>> I feel that's the only change I could really get behind.
>> 
>> 
>> I thought we'd decided on: FGP  (Foie Gras Poutine).
> 
> Can combine the two: Foie Gras Poutine: it's a Wonder that David H. 
> did have a heart attack
 
 Are "WObernate" and "WOpestry" taken? :-)
>>> 
> Well then let's better call it WOStruts or WOJSP and WOEJB … :->>
 
 WOBOL?
>>> 
>>> Great! I am all the rage for it. Because that is some real sarcasm. And 
>>> everybody understands it (not just us WO-folks).


Does anybody else see that picking a name based on an arcane inside (either 
Silicon Valley or Quebec flavored) joke might not be the best move? :-) WOBOL. 
Just wow.

Nobody likes my suggestion? I suggested wouzuri. This is from "WO" + "uziri", 
which is the Swahili word for beauty. No? Isn't beauty, in some way, exactly 
what we are trying to create and enourage?

- ray

 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: How to open a URL in WO

2011-07-13 Thread Calven Eggert
Just checked out that link.  this looks pretty cool.   Anyone else in the WO 
community use it?  If so, what are your impressions?

> http://hc.apache.org/httpcomponents-client-ga/

On 2011-07-13, at 2:14 PM, Chuck Hill wrote:

> 
> On Jul 13, 2011, at 10:54 AM, Calven Eggert wrote:
> 
>> Geesh, after reading this I've realized that I missed a 'minor' detail.  
>> hehe  
> 
> :-)
> 
> 
>> My task is for a current WO application to import data from a new source, 
>> which happens to be a given URL.  Far as I know it's read-only. (I can't 
>> imagine having to rewrite all my WO apps of over 10 years work.  yikes, that 
>> would be scary)
> 
> OK, that should be a lot less scary.  You will need them to provide some 
> documentation on what exactly that URL returns.  Then use something like this:
> http://hc.apache.org/httpcomponents-client-ga/
> 
> to get the content.  Parsing / handling the content depends on what the are 
> sending back.
> 
> 
>> one reply to this subject talked about REST.  is this my solution?
> 
> I thought that ERRest was mostly on the production, not consumption side.  I 
> could be wrong.  It may be of some use in parsing the response in any case.
> 
> 
> Chuck
> 
> 
> 
> 
>> On 2011-07-13, at 1:12 PM, Chuck Hill wrote:
>> 
>>> 
>>> On Jul 13, 2011, at 6:57 AM, Calven Eggert wrote:
>>> 
 I've just been told that instead of getting data from a database within my 
 organization that I should be opening a URL and get the data that way.  I 
 have no clue how that would be done in Webobjects.  Can someone please 
 gently lead me in the right direction? 
>>> 
>>> 
>>> Read only?  Full CRUD?
>>> 
>>> If you still want the result in EOs, then you need to write an EOF adaptor 
>>> (e.g. like the JDBCAdaptor and the JNDIAdaptor).  That is going to be a 
>>> good bit of work.  Maybe a lot of work.  They want to replace what EOF does 
>>> with an HTTP service that will (most probably) be slower.  Unless you are 
>>> using D2W, you might find that something other than WO is a better option.
>>> 
>>> If you just want dictionaries of read-only data, that can be considerably 
>>> easier.
>>> 
>>> Chuck
>>> 
>>> 
>>> -- 
>>> Chuck Hill Senior Consultant / VP Development
>>> 
>>> Practical WebObjects - for developers who want to increase their overall 
>>> knowledge of WebObjects or who are trying to solve specific problems.
>>> http://www.global-village.net/products/practical_webobjects
>>> 
>>> 
>>> 
>>> 
>>> 
>>> 
>>> 
>> 
>> 
> 
> -- 
> Chuck Hill Senior Consultant / VP Development
> 
> Practical WebObjects - for developers who want to increase their overall 
> knowledge of WebObjects or who are trying to solve specific problems.
> http://www.global-village.net/products/practical_webobjects
> 
> 
> 
> 
> 
> 
> 


 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: How to open a URL in WO

2011-07-13 Thread Pascal Robert

Le 2011-07-13 à 14:14, Chuck Hill a écrit :

> 
> On Jul 13, 2011, at 10:54 AM, Calven Eggert wrote:
> 
>> Geesh, after reading this I've realized that I missed a 'minor' detail.  
>> hehe  
> 
> :-)
> 
> 
>> My task is for a current WO application to import data from a new source, 
>> which happens to be a given URL.  Far as I know it's read-only. (I can't 
>> imagine having to rewrite all my WO apps of over 10 years work.  yikes, that 
>> would be scary)
> 
> OK, that should be a lot less scary.  You will need them to provide some 
> documentation on what exactly that URL returns.  Then use something like this:
> http://hc.apache.org/httpcomponents-client-ga/
> 
> to get the content.  Parsing / handling the content depends on what the are 
> sending back.
> 
> 
>> one reply to this subject talked about REST.  is this my solution?
> 
> I thought that ERRest was mostly on the production, not consumption side.  

Exact. In fact, this is something that we could add later. 

> I could be wrong.  It may be of some use in parsing the response in any case.

Jakarta httpClient + the parsers in ERRest should do the job. JBoss' RestEasy 
is another option.

> 
> Chuck
> 
> 
> 
> 
>> On 2011-07-13, at 1:12 PM, Chuck Hill wrote:
>> 
>>> 
>>> On Jul 13, 2011, at 6:57 AM, Calven Eggert wrote:
>>> 
 I've just been told that instead of getting data from a database within my 
 organization that I should be opening a URL and get the data that way.  I 
 have no clue how that would be done in Webobjects.  Can someone please 
 gently lead me in the right direction? 
>>> 
>>> 
>>> Read only?  Full CRUD?
>>> 
>>> If you still want the result in EOs, then you need to write an EOF adaptor 
>>> (e.g. like the JDBCAdaptor and the JNDIAdaptor).  That is going to be a 
>>> good bit of work.  Maybe a lot of work.  They want to replace what EOF does 
>>> with an HTTP service that will (most probably) be slower.  Unless you are 
>>> using D2W, you might find that something other than WO is a better option.
>>> 
>>> If you just want dictionaries of read-only data, that can be considerably 
>>> easier.
>>> 
>>> Chuck
>>> 
>>> 
>>> -- 
>>> Chuck Hill Senior Consultant / VP Development
>>> 
>>> Practical WebObjects - for developers who want to increase their overall 
>>> knowledge of WebObjects or who are trying to solve specific problems.
>>> http://www.global-village.net/products/practical_webobjects
>>> 
>>> 
>>> 
>>> 
>>> 
>>> 
>>> 
>> 
>> 
> 
> -- 
> Chuck Hill Senior Consultant / VP Development
> 
> Practical WebObjects - for developers who want to increase their overall 
> knowledge of WebObjects or who are trying to solve specific problems.
> http://www.global-village.net/products/practical_webobjects
> 
> 
> 
> 
> 
> 
> 
> ___
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
> Help/Unsubscribe/Update your Subscription:
> http://lists.apple.com/mailman/options/webobjects-dev/probert%40macti.ca
> 
> This email sent to prob...@macti.ca

 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: How to open a URL in WO

2011-07-13 Thread Chuck Hill

On Jul 13, 2011, at 10:54 AM, Calven Eggert wrote:

> Geesh, after reading this I've realized that I missed a 'minor' detail.  hehe 
>  

:-)


> My task is for a current WO application to import data from a new source, 
> which happens to be a given URL.  Far as I know it's read-only. (I can't 
> imagine having to rewrite all my WO apps of over 10 years work.  yikes, that 
> would be scary)

OK, that should be a lot less scary.  You will need them to provide some 
documentation on what exactly that URL returns.  Then use something like this:
http://hc.apache.org/httpcomponents-client-ga/

to get the content.  Parsing / handling the content depends on what the are 
sending back.


> one reply to this subject talked about REST.  is this my solution?

I thought that ERRest was mostly on the production, not consumption side.  I 
could be wrong.  It may be of some use in parsing the response in any case.


Chuck




> On 2011-07-13, at 1:12 PM, Chuck Hill wrote:
> 
>> 
>> On Jul 13, 2011, at 6:57 AM, Calven Eggert wrote:
>> 
>>> I've just been told that instead of getting data from a database within my 
>>> organization that I should be opening a URL and get the data that way.  I 
>>> have no clue how that would be done in Webobjects.  Can someone please 
>>> gently lead me in the right direction? 
>> 
>> 
>> Read only?  Full CRUD?
>> 
>> If you still want the result in EOs, then you need to write an EOF adaptor 
>> (e.g. like the JDBCAdaptor and the JNDIAdaptor).  That is going to be a good 
>> bit of work.  Maybe a lot of work.  They want to replace what EOF does with 
>> an HTTP service that will (most probably) be slower.  Unless you are using 
>> D2W, you might find that something other than WO is a better option.
>> 
>> If you just want dictionaries of read-only data, that can be considerably 
>> easier.
>> 
>> Chuck
>> 
>> 
>> -- 
>> Chuck Hill Senior Consultant / VP Development
>> 
>> Practical WebObjects - for developers who want to increase their overall 
>> knowledge of WebObjects or who are trying to solve specific problems.
>> http://www.global-village.net/products/practical_webobjects
>> 
>> 
>> 
>> 
>> 
>> 
>> 
> 
> 

-- 
Chuck Hill Senior Consultant / VP Development

Practical WebObjects - for developers who want to increase their overall 
knowledge of WebObjects or who are trying to solve specific problems.
http://www.global-village.net/products/practical_webobjects









smime.p7s
Description: S/MIME cryptographic signature
 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: How to open a URL in WO

2011-07-13 Thread Jesse Tayler
don't listen to chuck! he's mischievous by nature! 

get the darn URL and you'll see if it's just some JSON feed or whatever - 
sounds like it would be.

or perhaps the feed is in an lost ancient binary machine language based on 
a six bit encoding you'll have to translate from a partially destroyed stone 
that matches it to an early non-linear form of EBCIDIC, but that's only if 
someone actually hexed your project.

you'll have to know what you're reading and parse it, I'm sure there are 
further examples once you know your protocol.

I'm sure it's not hard to make an EO to read a simple feed and store it in your 
database or whatever you need.



On Jul 13, 2011, at 1:57 PM, Chuck Hill wrote:

> With Calven's luck?  Not likely.  :-P
> 
> 
> On Jul 13, 2011, at 10:15 AM, David Holt wrote:
> 
>> Could they be talking about something like REST?
>> 
>> 
>> On 2011-07-13, at 6:57 AM, Calven Eggert wrote:
>> 
>>> I've just been told that instead of getting data from a database within my 
>>> organization that I should be opening a URL and get the data that way.  I 
>>> have no clue how that would be done in Webobjects.  Can someone please 
>>> gently lead me in the right direction? 
>>> 
>>> Thanks,
>>> Calven
>>> ___
>>> Do not post admin requests to the list. They will be ignored.
>>> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
>>> Help/Unsubscribe/Update your Subscription:
>>> http://lists.apple.com/mailman/options/webobjects-dev/programmingosx%40mac.com
>>> 
>>> This email sent to programming...@mac.com
>> 
>> ___
>> Do not post admin requests to the list. They will be ignored.
>> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
>> Help/Unsubscribe/Update your Subscription:
>> http://lists.apple.com/mailman/options/webobjects-dev/chill%40global-village.net
>> 
>> This email sent to ch...@global-village.net
> 
> -- 
> Chuck Hill Senior Consultant / VP Development
> 
> Practical WebObjects - for developers who want to increase their overall 
> knowledge of WebObjects or who are trying to solve specific problems.
> http://www.global-village.net/products/practical_webobjects
> 
> 
> 
> 
> 
> 
> 
> ___
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
> Help/Unsubscribe/Update your Subscription:
> http://lists.apple.com/mailman/options/webobjects-dev/jtayler%40oeinc.com
> 
> This email sent to jtay...@oeinc.com

 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: Let's find a new name for the Community

2011-07-13 Thread Chuck Hill
There hasn't been support for anything else for years now.


On Jul 13, 2011, at 10:32 AM, Jesse Tayler wrote:

> where's the support for fluffy bunny?
> 
> I feel that's the only change I could really get behind.
> 
> 
> On Jul 13, 2011, at 1:29 PM, Lars Sonchocky-Helldorf wrote:
> 
>> 
>> Am 13.07.2011 um 00:51 schrieb David Holt:
>> 
>>> 
>>> On 2011-07-12, at 3:50 PM, Lars Sonchocky-Helldorf wrote:
>>> 
 
 Am 12.07.2011 um 22:10 schrieb Tim Worman:
 
> On Jul 11, 2011, at 10:47 PM, Lars Sonchocky-Helldorf wrote:
> 
>> 
>> Am 12.07.2011 um 02:49 schrieb Tim Worman:
>> 
>>> On Jul 11, 2011, at 11:09 AM, Pascal Robert wrote:
>>> 
 
>> 
>> Thanks!
> 
> I thought we'd decided on: FGP  (Foie Gras Poutine).
 
 Can combine the two: Foie Gras Poutine: it's a Wonder that David H. 
 did have a heart attack
>>> 
>>> Are "WObernate" and "WOpestry" taken? :-)
>> 
>> Why compare with inferior stuff?
>> 
>> cheers,
>> 
>>  Lars
> 
> See, that's why it's funny - at least it was supposed to be. :-)
 
 Well then let's better call it WOStruts or WOJSP and WOEJB … :->>
>>> 
>>> WOBOL?
>> 
>> Great! I am all the rage for it. Because that is some real sarcasm. And 
>> everybody understands it (not just us WO-folks).
>> 
>> cheers,
>> 
>>  Lars ___
>> Do not post admin requests to the list. They will be ignored.
>> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
>> Help/Unsubscribe/Update your Subscription:
>> http://lists.apple.com/mailman/options/webobjects-dev/jtayler%40oeinc.com
>> 
>> This email sent to jtay...@oeinc.com
>> 
> 
> ___
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
> Help/Unsubscribe/Update your Subscription:
> http://lists.apple.com/mailman/options/webobjects-dev/chill%40global-village.net
> 
> This email sent to ch...@global-village.net

-- 
Chuck Hill Senior Consultant / VP Development

Practical WebObjects - for developers who want to increase their overall 
knowledge of WebObjects or who are trying to solve specific problems.
http://www.global-village.net/products/practical_webobjects









smime.p7s
Description: S/MIME cryptographic signature
 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: How to open a URL in WO

2011-07-13 Thread Chuck Hill
With Calven's luck?  Not likely.  :-P


On Jul 13, 2011, at 10:15 AM, David Holt wrote:

> Could they be talking about something like REST?
> 
> 
> On 2011-07-13, at 6:57 AM, Calven Eggert wrote:
> 
>> I've just been told that instead of getting data from a database within my 
>> organization that I should be opening a URL and get the data that way.  I 
>> have no clue how that would be done in Webobjects.  Can someone please 
>> gently lead me in the right direction? 
>> 
>> Thanks,
>> Calven
>> ___
>> Do not post admin requests to the list. They will be ignored.
>> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
>> Help/Unsubscribe/Update your Subscription:
>> http://lists.apple.com/mailman/options/webobjects-dev/programmingosx%40mac.com
>> 
>> This email sent to programming...@mac.com
> 
> ___
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
> Help/Unsubscribe/Update your Subscription:
> http://lists.apple.com/mailman/options/webobjects-dev/chill%40global-village.net
> 
> This email sent to ch...@global-village.net

-- 
Chuck Hill Senior Consultant / VP Development

Practical WebObjects - for developers who want to increase their overall 
knowledge of WebObjects or who are trying to solve specific problems.
http://www.global-village.net/products/practical_webobjects









smime.p7s
Description: S/MIME cryptographic signature
 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: How to open a URL in WO

2011-07-13 Thread Calven Eggert
Geesh, after reading this I've realized that I missed a 'minor' detail.  hehe  

My task is for a current WO application to import data from a new source, which 
happens to be a given URL.  Far as I know it's read-only. (I can't imagine 
having to rewrite all my WO apps of over 10 years work.  yikes, that would be 
scary)

one reply to this subject talked about REST.  is this my solution?


On 2011-07-13, at 1:12 PM, Chuck Hill wrote:

> 
> On Jul 13, 2011, at 6:57 AM, Calven Eggert wrote:
> 
>> I've just been told that instead of getting data from a database within my 
>> organization that I should be opening a URL and get the data that way.  I 
>> have no clue how that would be done in Webobjects.  Can someone please 
>> gently lead me in the right direction? 
> 
> 
> Read only?  Full CRUD?
> 
> If you still want the result in EOs, then you need to write an EOF adaptor 
> (e.g. like the JDBCAdaptor and the JNDIAdaptor).  That is going to be a good 
> bit of work.  Maybe a lot of work.  They want to replace what EOF does with 
> an HTTP service that will (most probably) be slower.  Unless you are using 
> D2W, you might find that something other than WO is a better option.
> 
> If you just want dictionaries of read-only data, that can be considerably 
> easier.
> 
> Chuck
> 
> 
> -- 
> Chuck Hill Senior Consultant / VP Development
> 
> Practical WebObjects - for developers who want to increase their overall 
> knowledge of WebObjects or who are trying to solve specific problems.
> http://www.global-village.net/products/practical_webobjects
> 
> 
> 
> 
> 
> 
> 


 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: Let's find a new name for the Community

2011-07-13 Thread Jesse Tayler
where's the support for fluffy bunny?

I feel that's the only change I could really get behind.


On Jul 13, 2011, at 1:29 PM, Lars Sonchocky-Helldorf wrote:

> 
> Am 13.07.2011 um 00:51 schrieb David Holt:
> 
>> 
>> On 2011-07-12, at 3:50 PM, Lars Sonchocky-Helldorf wrote:
>> 
>>> 
>>> Am 12.07.2011 um 22:10 schrieb Tim Worman:
>>> 
 On Jul 11, 2011, at 10:47 PM, Lars Sonchocky-Helldorf wrote:
 
> 
> Am 12.07.2011 um 02:49 schrieb Tim Worman:
> 
>> On Jul 11, 2011, at 11:09 AM, Pascal Robert wrote:
>> 
>>> 
> 
> Thanks!
 
 I thought we'd decided on: FGP  (Foie Gras Poutine).
>>> 
>>> Can combine the two: Foie Gras Poutine: it's a Wonder that David H. did 
>>> have a heart attack
>> 
>> Are "WObernate" and "WOpestry" taken? :-)
> 
> Why compare with inferior stuff?
> 
> cheers,
> 
>   Lars
 
 See, that's why it's funny - at least it was supposed to be. :-)
>>> 
>>> Well then let's better call it WOStruts or WOJSP and WOEJB … :->>
>> 
>> WOBOL?
> 
> Great! I am all the rage for it. Because that is some real sarcasm. And 
> everybody understands it (not just us WO-folks).
> 
> cheers,
> 
>   Lars ___
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
> Help/Unsubscribe/Update your Subscription:
> http://lists.apple.com/mailman/options/webobjects-dev/jtayler%40oeinc.com
> 
> This email sent to jtay...@oeinc.com
> 

 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: Let's find a new name for the Community

2011-07-13 Thread Lars Sonchocky-Helldorf

Am 13.07.2011 um 00:51 schrieb David Holt:

> 
> On 2011-07-12, at 3:50 PM, Lars Sonchocky-Helldorf wrote:
> 
>> 
>> Am 12.07.2011 um 22:10 schrieb Tim Worman:
>> 
>>> On Jul 11, 2011, at 10:47 PM, Lars Sonchocky-Helldorf wrote:
>>> 
 
 Am 12.07.2011 um 02:49 schrieb Tim Worman:
 
> On Jul 11, 2011, at 11:09 AM, Pascal Robert wrote:
> 
>> 
 
 Thanks!
>>> 
>>> I thought we'd decided on: FGP  (Foie Gras Poutine).
>> 
>> Can combine the two: Foie Gras Poutine: it's a Wonder that David H. did 
>> have a heart attack
> 
> Are "WObernate" and "WOpestry" taken? :-)
 
 Why compare with inferior stuff?
 
 cheers,
 
Lars
>>> 
>>> See, that's why it's funny - at least it was supposed to be. :-)
>> 
>> Well then let's better call it WOStruts or WOJSP and WOEJB … :->>
> 
> WOBOL?

Great! I am all the rage for it. Because that is some real sarcasm. And 
everybody understands it (not just us WO-folks).

cheers,

Lars ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: How to open a URL in WO

2011-07-13 Thread Jesse Tayler
I don't know what kind of database you are using or what kind of url data you 
might want to accept but...

apps connect to databases because apps put the logic on the database so that 
others can safely use an application or API of some sort - are you working on 
application logic that does something with the database already?

Some REST api vs. an sql database seem like such different worlds of potential 
and purpose, that I wonder if there's miscommunication.

I mean, shouldn't you already know this answer if you are going to program 
something?

Maybe just tell us specifically what it is that you have now, and what you need 
to do, and include links and someone can advise you I'm sure.



On Jul 13, 2011, at 1:12 PM, Chuck Hill wrote:

> 
> On Jul 13, 2011, at 6:57 AM, Calven Eggert wrote:
> 
>> I've just been told that instead of getting data from a database within my 
>> organization that I should be opening a URL and get the data that way.  I 
>> have no clue how that would be done in Webobjects.  Can someone please 
>> gently lead me in the right direction? 
> 
> 
> Read only?  Full CRUD?
> 
> If you still want the result in EOs, then you need to write an EOF adaptor 
> (e.g. like the JDBCAdaptor and the JNDIAdaptor).  That is going to be a good 
> bit of work.  Maybe a lot of work.  They want to replace what EOF does with 
> an HTTP service that will (most probably) be slower.  Unless you are using 
> D2W, you might find that something other than WO is a better option.
> 
> If you just want dictionaries of read-only data, that can be considerably 
> easier.
> 
> Chuck
> 
> 
> -- 
> Chuck Hill Senior Consultant / VP Development
> 
> Practical WebObjects - for developers who want to increase their overall 
> knowledge of WebObjects or who are trying to solve specific problems.
> http://www.global-village.net/products/practical_webobjects
> 
> 
> 
> 
> 
> 
> 
> ___
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
> Help/Unsubscribe/Update your Subscription:
> http://lists.apple.com/mailman/options/webobjects-dev/jtayler%40oeinc.com
> 
> This email sent to jtay...@oeinc.com

 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: How to open a URL in WO

2011-07-13 Thread Pascal Robert

Le 2011-07-13 à 13:15, David Holt a écrit :

> Could they be talking about something like REST?

+1

> 
> On 2011-07-13, at 6:57 AM, Calven Eggert wrote:
> 
>> I've just been told that instead of getting data from a database within my 
>> organization that I should be opening a URL and get the data that way.  I 
>> have no clue how that would be done in Webobjects.  Can someone please 
>> gently lead me in the right direction? 
>> 
>> Thanks,
>> Calven
>> ___
>> Do not post admin requests to the list. They will be ignored.
>> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
>> Help/Unsubscribe/Update your Subscription:
>> http://lists.apple.com/mailman/options/webobjects-dev/programmingosx%40mac.com
>> 
>> This email sent to programming...@mac.com
> 
> ___
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
> Help/Unsubscribe/Update your Subscription:
> http://lists.apple.com/mailman/options/webobjects-dev/probert%40macti.ca
> 
> This email sent to prob...@macti.ca

 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: How to open a URL in WO

2011-07-13 Thread David Holt
Could they be talking about something like REST?


On 2011-07-13, at 6:57 AM, Calven Eggert wrote:

> I've just been told that instead of getting data from a database within my 
> organization that I should be opening a URL and get the data that way.  I 
> have no clue how that would be done in Webobjects.  Can someone please gently 
> lead me in the right direction? 
> 
> Thanks,
> Calven
> ___
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
> Help/Unsubscribe/Update your Subscription:
> http://lists.apple.com/mailman/options/webobjects-dev/programmingosx%40mac.com
> 
> This email sent to programming...@mac.com

 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: How to open a URL in WO

2011-07-13 Thread Chuck Hill

On Jul 13, 2011, at 6:57 AM, Calven Eggert wrote:

> I've just been told that instead of getting data from a database within my 
> organization that I should be opening a URL and get the data that way.  I 
> have no clue how that would be done in Webobjects.  Can someone please gently 
> lead me in the right direction? 


Read only?  Full CRUD?

If you still want the result in EOs, then you need to write an EOF adaptor 
(e.g. like the JDBCAdaptor and the JNDIAdaptor).  That is going to be a good 
bit of work.  Maybe a lot of work.  They want to replace what EOF does with an 
HTTP service that will (most probably) be slower.  Unless you are using D2W, 
you might find that something other than WO is a better option.

If you just want dictionaries of read-only data, that can be considerably 
easier.

Chuck


-- 
Chuck Hill Senior Consultant / VP Development

Practical WebObjects - for developers who want to increase their overall 
knowledge of WebObjects or who are trying to solve specific problems.
http://www.global-village.net/products/practical_webobjects









smime.p7s
Description: S/MIME cryptographic signature
 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: WebObjects vulnerabilities?

2011-07-13 Thread Dov Rosenberg
It is all java based and has nothing to do with WebObjects or Project
Wonder. We didn¹t try to integrate it that deeply. I suppose someone could
tie it into the WOContext and inspect the incoming request parameters in a
generic fashion or integrate it into some base WOComponents that know how
to validate its params via a whitelist or provide methods to safely encode
user input but we didn¹t do any of those things.

Our usage was with our JSP application that uses our custom JSP tag lib
built against EOF. We are in the process of integrating it into our web
services as well (also built using EOF).

It is very easy to use and has a bunch of configuration options for
intrusion detection and logging that are pretty useful

Dov 

On 7/13/11 12:32 AM, "Simon"  wrote:

>this sounds really interesting. is there any code you can share back
>with wonder around this stuff ?
>
>simoin
>
>On 13 July 2011 05:24, Dov Rosenberg  wrote:
>> the general idea behind the OWASP approach is to provide encoders that
>> will make your user input strings safe so that they wont activate some
>> malicious scripting. The other thing it provides is the ability to
>>define
>> parameter specific whitelists that can be validated using REGEX
>> expressions to ensure that the values that are provided are within an
>> acceptable domain range. Of course it is very to come up with an unsafe
>> REGEX expression that allows all sorts of bad behavior to come thru.
>>
>> We use both capabilities in our application. The REGEX portion is nice
>> because it allows you perform good data validation which is essential to
>> avoid cross site scripting errors.
>>
>> The encoders provide the ability to properly encode strings for various
>> uses like SQL, HTML, URLs, CSS, javascripts, LDAP
>>
>> In your example below, the onfocus parameter would use the ESAPI
>> encodeForJavascript() to convert the write(1) autofocus into HTML
>>encoded
>> text that would not be executable.
>>
>> Dov
>>
>> On 7/12/11 4:01 PM, "Ramsey Gurley"  wrote:
>>
>>>That's two votes for owasp it seems How does it handle new
>>>techniques
>>>introduced by html5?  Will it catch stuff like:
>>>
>>>
>>>
>>>Found a rather large list of these at html5sec.org
>>>
>>>Ramsey
>>>
>>>On Jul 12, 2011, at 5:05 AM, Josef Burzler wrote:
>>>
 WO-Applications are indeed vulnerable to cross-site-scripting if
end-users are allowed to submit HTML.
 An example would be an Online-HTML-editor which allows users to edit
formatted text in their browsers.

 In order to remove unwanted and malicious code from the submitted HTML
and avoid cross-site-Scripting issues one has to filter the submitted
content on server side.
 For this task I have found AntiSamy to be a useful solution
  https://www.owasp.org/index.php/Category:OWASP_AntiSamy_Project

 Josef


 Am 12.07.2011 um 09:36 schrieb Simon:

> i think core WO is still plagued with the wosid cross-scripting issue
>too. we patch it in ERXRequest - not sure if the patch ever made it
>into wonder though...
>
> simon
>
>
> On 12 July 2011 02:43, Mike Schrag  wrote:
> You have to be mindful of ever rendering any tainted strings ... Any
>string that came from user input should be considered a risk for cross
>site scripting, so that's any field editable by a user, or any query
>parameter, etc. If you append those strings to response or 
>render them, make sure to escape HTML or strip HTML.
>
> ms
>
> On Jul 11, 2011, at 9:41 PM, Mai Nguyen wrote:
>
> > Do you mean the issue of malicious HTML tags?
> >
> > I wonder what would be the best way to prevent those?
> >
> > thanks,
> >
> > mai
> >
> >
> > On Jul 11, 2011, at 6:36 PM, George Domurot wrote:
> >
> >> If you output strings with escapeHTML=false, you could have an
>issue.
> >> You may want to consider stripping all potential tags from strings
>prior to rendering, or at the time of entry.
> >>
> >> -G
> >>
> >> On Jul 11, 2011, at 6:01 PM, Mai Nguyen wrote:
> >>
> >>> Hello,
> >>> I have found some good information about WebObjects and security
>at the following wiki link:
> >>>
> >>>
>http://en.wikibooks.org/wiki/WebObjects/Web_Applications/Development/A
>ut
>hentication_and_Security
> >>>
> >>> However, there is no mention about SQL injections which seems to
>be an active subject lately. Is WebObjects pretty safe, as there is no
>need to generate SQL directly and access to the DB is going through
>the
>EOs normally?
> >>> Are there any other loopholes that I am not aware of?
> >>> About the following article:
> >>> http://support.apple.com/kb/TA26730?viewlocale=en_US
> >>> Would the normal WebObjects behavior be pretty safe if one does
>not allow the user to enter HTML tags? Does Project Wonder do
>something

How to open a URL in WO

2011-07-13 Thread Calven Eggert
I've just been told that instead of getting data from a database within my 
organization that I should be opening a URL and get the data that way.  I have 
no clue how that would be done in Webobjects.  Can someone please gently lead 
me in the right direction? 

Thanks,
Calven
 ___
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list  (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


Re: WebObjects vulnerabilities?

2011-07-13 Thread Simon
this sounds really interesting. is there any code you can share back
with wonder around this stuff ?

simoin

On 13 July 2011 05:24, Dov Rosenberg  wrote:
> the general idea behind the OWASP approach is to provide encoders that
> will make your user input strings safe so that they wont activate some
> malicious scripting. The other thing it provides is the ability to define
> parameter specific whitelists that can be validated using REGEX
> expressions to ensure that the values that are provided are within an
> acceptable domain range. Of course it is very to come up with an unsafe
> REGEX expression that allows all sorts of bad behavior to come thru.
>
> We use both capabilities in our application. The REGEX portion is nice
> because it allows you perform good data validation which is essential to
> avoid cross site scripting errors.
>
> The encoders provide the ability to properly encode strings for various
> uses like SQL, HTML, URLs, CSS, javascripts, LDAP
>
> In your example below, the onfocus parameter would use the ESAPI
> encodeForJavascript() to convert the write(1) autofocus into HTML encoded
> text that would not be executable.
>
> Dov
>
> On 7/12/11 4:01 PM, "Ramsey Gurley"  wrote:
>
>>That's two votes for owasp it seems How does it handle new techniques
>>introduced by html5?  Will it catch stuff like:
>>
>>
>>
>>Found a rather large list of these at html5sec.org
>>
>>Ramsey
>>
>>On Jul 12, 2011, at 5:05 AM, Josef Burzler wrote:
>>
>>> WO-Applications are indeed vulnerable to cross-site-scripting if
>>>end-users are allowed to submit HTML.
>>> An example would be an Online-HTML-editor which allows users to edit
>>>formatted text in their browsers.
>>>
>>> In order to remove unwanted and malicious code from the submitted HTML
>>>and avoid cross-site-Scripting issues one has to filter the submitted
>>>content on server side.
>>> For this task I have found AntiSamy to be a useful solution
>>>      https://www.owasp.org/index.php/Category:OWASP_AntiSamy_Project
>>>
>>> Josef
>>>
>>>
>>> Am 12.07.2011 um 09:36 schrieb Simon:
>>>
 i think core WO is still plagued with the wosid cross-scripting issue
too. we patch it in ERXRequest - not sure if the patch ever made it
into wonder though...

 simon


 On 12 July 2011 02:43, Mike Schrag  wrote:
 You have to be mindful of ever rendering any tainted strings ... Any
string that came from user input should be considered a risk for cross
site scripting, so that's any field editable by a user, or any query
parameter, etc. If you append those strings to response or 
render them, make sure to escape HTML or strip HTML.

 ms

 On Jul 11, 2011, at 9:41 PM, Mai Nguyen wrote:

 > Do you mean the issue of malicious HTML tags?
 >
 > I wonder what would be the best way to prevent those?
 >
 > thanks,
 >
 > mai
 >
 >
 > On Jul 11, 2011, at 6:36 PM, George Domurot wrote:
 >
 >> If you output strings with escapeHTML=false, you could have an
issue.
 >> You may want to consider stripping all potential tags from strings
prior to rendering, or at the time of entry.
 >>
 >> -G
 >>
 >> On Jul 11, 2011, at 6:01 PM, Mai Nguyen wrote:
 >>
 >>> Hello,
 >>> I have found some good information about WebObjects and security
at the following wiki link:
 >>>
 >>>
http://en.wikibooks.org/wiki/WebObjects/Web_Applications/Development/Aut
hentication_and_Security
 >>>
 >>> However, there is no mention about SQL injections which seems to
be an active subject lately. Is WebObjects pretty safe, as there is no
need to generate SQL directly and access to the DB is going through the
EOs normally?
 >>> Are there any other loopholes that I am not aware of?
 >>> About the following article:
 >>> http://support.apple.com/kb/TA26730?viewlocale=en_US
 >>> Would the normal WebObjects behavior be pretty safe if one does
not allow the user to enter HTML tags? Does Project Wonder do something
in this area?
 >>>
 >>> Many thanks for your advice,
 >>>
 >>> -mai ___
 >>> Do not post admin requests to the list. They will be ignored.
 >>> Webobjects-dev mailing list      (Webobjects-dev@lists.apple.com)
 >>> Help/Unsubscribe/Update your Subscription:
 >>>
http://lists.apple.com/mailman/options/webobjects-dev/george%40boxoffice
tickets.com
 >>>
 >>> This email sent to geo...@boxofficetickets.com
 >>
 >
 > ___
 > Do not post admin requests to the list. They will be ignored.
 > Webobjects-dev mailing list      (Webobjects-dev@lists.apple.com)
 > Help/Unsubscribe/Update your Subscription:
 >
http://lists.apple.com/mailman/options/webobjects-dev/mschrag%40pobox.co
m
 >
 > This email sent to msch...@pobox.com

>>