I have a site that is posting XML and using the 200 ok to verify
acceptance of the post. I use the response.setHeader("status","500 Internal Server Error"); this works great. but if I don't put this in, then there is an automatic 200 OK return by ofbiz. xxx.xxx.xxx.xxx - - [18/Jul/2006:23:51:11 -0800] "POST /yahoo/control/realtimeorders HTTP/1.0" 200 986 "-" "curl/7.12.1 (i386-portbld-freebsd4.3) libcurl/7.12.1 OpenSSL/0.9.6g zlib/1.1.4 libidn/0.5.4" The second problem is when I change the Post to https, it does not get to the controller, and has no log entry, but on the other end says it was received OK. Any thoughts. |
I have found that the status 200 is entered into the access log file
even if I set the header status to 500. is this by design? BJ Freeman sent the following on 7/19/2006 4:40 AM: > I have a site that is posting XML and using the 200 ok to verify > acceptance of the post. > > I use the > response.setHeader("status","500 Internal Server Error"); > > this works great. > > but if I don't put this in, then there is an automatic 200 OK return by > ofbiz. > xxx.xxx.xxx.xxx - - [18/Jul/2006:23:51:11 -0800] "POST > /yahoo/control/realtimeorders HTTP/1.0" 200 986 "-" "curl/7.12.1 > (i386-portbld-freebsd4.3) libcurl/7.12.1 OpenSSL/0.9.6g zlib/1.1.4 > libidn/0.5.4" > > The second problem is when I change the Post to https, it does not get > to the controller, and has no log entry, but on the other end says it > was received OK. > > Any thoughts. > |
This probably has nothing to do with OFBiz. Try looking in the Tomcat docs. -David BJ Freeman wrote: > I have found that the status 200 is entered into the access log file > even if I set the header status to 500. > > is this by design? > > > BJ Freeman sent the following on 7/19/2006 4:40 AM: >> I have a site that is posting XML and using the 200 ok to verify >> acceptance of the post. >> >> I use the >> response.setHeader("status","500 Internal Server Error"); >> >> this works great. >> >> but if I don't put this in, then there is an automatic 200 OK return by >> ofbiz. >> xxx.xxx.xxx.xxx - - [18/Jul/2006:23:51:11 -0800] "POST >> /yahoo/control/realtimeorders HTTP/1.0" 200 986 "-" "curl/7.12.1 >> (i386-portbld-freebsd4.3) libcurl/7.12.1 OpenSSL/0.9.6g zlib/1.1.4 >> libidn/0.5.4" >> >> The second problem is when I change the Post to https, it does not get >> to the controller, and has no log entry, but on the other end says it >> was received OK. >> >> Any thoughts. >> smime.p7s (4K) Download Attachment |
Ok you answered my question.
ofbiz does not take in to account the actual source of the information, just that it gets it from an upper layer, processes it, and returns it to the upper layer. so there is a boundary. thanks. David E. Jones sent the following on 7/19/2006 7:03 AM: > > This probably has nothing to do with OFBiz. Try looking in the Tomcat docs. > > -David > > > BJ Freeman wrote: >> I have found that the status 200 is entered into the access log file >> even if I set the header status to 500. >> >> is this by design? >> >> >> BJ Freeman sent the following on 7/19/2006 4:40 AM: >>> I have a site that is posting XML and using the 200 ok to verify >>> acceptance of the post. >>> >>> I use the >>> response.setHeader("status","500 Internal Server Error"); >>> >>> this works great. >>> >>> but if I don't put this in, then there is an automatic 200 OK return by >>> ofbiz. >>> xxx.xxx.xxx.xxx - - [18/Jul/2006:23:51:11 -0800] "POST >>> /yahoo/control/realtimeorders HTTP/1.0" 200 986 "-" "curl/7.12.1 >>> (i386-portbld-freebsd4.3) libcurl/7.12.1 OpenSSL/0.9.6g zlib/1.1.4 >>> libidn/0.5.4" >>> >>> The second problem is when I change the Post to https, it does not >>> get to the controller, and has no log entry, but on the other end >>> says it was received OK. >>> >>> Any thoughts. >>> |
I am back to ofbiz after talking to tomcat forum on chat.
I believe the answer is somewhere in the Base code handling url connections and others that interface to tomcat. BJ Freeman sent the following on 7/19/2006 8:55 AM: > Ok you answered my question. > ofbiz does not take in to account the actual source of the information, > just that it gets it from an upper layer, processes it, and returns it > to the upper layer. > so there is a boundary. > > thanks. > > David E. Jones sent the following on 7/19/2006 7:03 AM: >> >> This probably has nothing to do with OFBiz. Try looking in the Tomcat >> docs. >> >> -David >> >> >> BJ Freeman wrote: >>> I have found that the status 200 is entered into the access log file >>> even if I set the header status to 500. >>> >>> is this by design? >>> >>> >>> BJ Freeman sent the following on 7/19/2006 4:40 AM: >>>> I have a site that is posting XML and using the 200 ok to verify >>>> acceptance of the post. >>>> >>>> I use the >>>> response.setHeader("status","500 Internal Server Error"); >>>> >>>> this works great. >>>> >>>> but if I don't put this in, then there is an automatic 200 OK return by >>>> ofbiz. >>>> xxx.xxx.xxx.xxx - - [18/Jul/2006:23:51:11 -0800] "POST >>>> /yahoo/control/realtimeorders HTTP/1.0" 200 986 "-" "curl/7.12.1 >>>> (i386-portbld-freebsd4.3) libcurl/7.12.1 OpenSSL/0.9.6g zlib/1.1.4 >>>> libidn/0.5.4" >>>> >>>> The second problem is when I change the Post to https, it does not >>>> get to the controller, and has no log entry, but on the other end >>>> says it was received OK. >>>> >>>> Any thoughts. >>>> > |
Hello,
I want to remove all the records relating to a party. I have entries in user_login, server_hit and visit tables. I was able to remove all the records from all the entities till I hit server_hit and visit problem. First, I delete all the records of Server_Hit table having userLoginId as 'test'. Notice below that 10150 and 10151 record remains in Server_Hit table. Now, I delete all the records of Visit table having userLoginId as 'test'. This gives me a foreign key constraint to Server Hit (Visit Ids - 10150 and 10151), which is right. Also, notice that 10150 in Visit table has a different party than 10150 in Server_Hit. Visit Table Visit Id User Login Id Party Id 10150 test 10070 10151 test 10070 10152 <NULL> <NULL> Server Hit Table Visit Id Content Id User Login Id Party Id 10150 admin.logout manager 10050 10151 admin.login <NULL> <NULL> 10151 admin.ListOrders test 10070 10151 admin.processOrder test 10070 10152 admin.logout test 10070 I dont know if this is a bug or this is how it is supposed to work. I just need to remove anything related to a party especially user_login, Server_Hit and Visit records. I tried to look for a delete service but couldnt find one. How should I go about deleting records of a party from Server_Hit and Visit table? Thanks in advance for your help and suggestions. Amit Shinde -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.394 / Virus Database: 268.10.1/390 - Release Date: 7/17/2006 |
In reply to this post by BJ Freeman
Hello,
I want to remove all the records relating to a party. I have entries in user_login, server_hit and visit tables. I was able to remove all the records from all the entities till I hit server_hit and visit problem. First, I delete all the records of Server_Hit table having userLoginId as 'test'. Notice below that 10150 and 10151 record remains in Server_Hit table. Now, I delete all the records of Visit table having userLoginId as 'test'. This gives me a foreign key constraint to Server Hit (Visit Ids - 10150 and 10151), which is right. Also, notice that 10150 in Visit table has a different party than 10150 in Server_Hit. Visit Table Visit Id User Login Id Party Id 10150 test 10070 10151 test 10070 10152 <NULL> <NULL> Server Hit Table Visit Id Content Id User Login Id Party Id 10150 admin.logout manager 10050 10151 admin.login <NULL> <NULL> 10151 admin.ListOrders test 10070 10151 admin.processOrder test 10070 10152 admin.logout test 10070 I dont know if this is a bug or this is how it is supposed to work. I just need to remove anything related to a party especially user_login, Server_Hit and Visit records. I tried to look for a delete service but couldnt find one. How should I go about deleting records of a party from Server_Hit and Visit table? Thanks in advance for your help and suggestions. Amit Shinde |
In reply to this post by Amit Shinde
A snippet from some of my code where parties with a certain prefix are
deleted, perhaps this helps: // delete history EntityExpr exprParty = new EntityExpr("partyId", EntityOperator.LIKE, prefix.concat("%")); EntityExpr exprContent = new EntityExpr("contentId", EntityOperator.LIKE, prefix.concat("%")); // delete all serverHits related to the visits to be deleted List visits = delegator.findByCondition("Visit", exprParty,null,null); if (visits != null && visits.size() > 0) { Iterator h = (Iterator) visits.iterator(); while(h.hasNext()) { GenericValue visit = (GenericValue) h.next(); List serverHits = visit.getRelated("ServerHit"); if (serverHits != null && serverHits.size() > 0) { Iterator s = serverHits.iterator(); while (s.hasNext()) { ((GenericValue) s.next()).remove(); } } visit.remove(); // delete visit } } delegator.removeByCondition( "Visitor", exprParty ); // delegator.removeByCondition( "UserLoginSession", exprUserLogin ); delegator.removeByCondition( "UserLoginHistory", exprParty ); delegator.removeByCondition( "ServerHitBin", exprContent ); On Friday 21 July 2006 01:29, Amit Shinde wrote: > Hello, > I want to remove all the records relating to a party. I have entries in > user_login, server_hit and visit tables. I was able to remove all the > records from all the entities till I hit server_hit and visit problem. > > First, I delete all the records of Server_Hit table having userLoginId as > 'test'. Notice below that 10150 and 10151 record remains in Server_Hit > table. > Now, I delete all the records of Visit table having userLoginId as 'test'. > This gives me a foreign key constraint to Server Hit (Visit Ids - 10150 and > 10151), which is right. > Also, notice that 10150 in Visit table has a different party than 10150 in > Server_Hit. > > > Visit Table > > Visit Id User Login Id Party Id > 10150 test 10070 > 10151 test 10070 > 10152 <NULL> <NULL> > > > Server Hit Table > > Visit Id Content Id User Login Id Party Id > 10150 admin.logout manager 10050 > 10151 admin.login <NULL> <NULL> > 10151 admin.ListOrders test 10070 > 10151 admin.processOrder test 10070 > 10152 admin.logout test 10070 > > > I dont know if this is a bug or this is how it is supposed to work. I just > need to remove anything related to a party especially user_login, > Server_Hit and Visit records. I tried to look for a delete service but > couldnt find one. How should I go about deleting records of a party from > Server_Hit and Visit table? > > Thanks in advance for your help and suggestions. > > > Amit Shinde > -- > No virus found in this outgoing message. > Checked by AVG Free Edition. > Version: 7.1.394 / Virus Database: 268.10.1/390 - Release Date: 7/17/2006 Regards, Hans Bakker ANT Websystems Co.,Ltd (http://www.antwebsystems.com) If you want to verify that this message really originates from from the above person, download the public key from: http://www.antwebsystems.com/hbakkerAntwebsystems.asc attachment0 (196 bytes) Download Attachment |
Free forum by Nabble | Edit this page |