[transfer-dev] Re: Transfer/Railo error: The structure of your configuration file causes an infinite loop

2009-05-26 Thread Shawn

For the benefit of the thread, Luis Majano replied to this issue here:

http://groups.google.com/group/transfer-dev/browse_thread/thread/73b159bb8a736aee?pli=1

On May 18, 4:27 pm, Shawn shawn.grig...@gmail.com wrote:
 I'm the one who posted the original link you mentioned.  Same issues
 as I posted before re: Railo 3.0.  There are composition issues with
 config options that validate just fine under CF8 providing unexpected
 behavior.  I'm unclear yet how much of this is Railo's fault, and how
 much of this is Transfer being untested against Railo 3.1 (or 3.0
 either, from my experience).

 It is this more than anything that has prevented me from making the
 jump to Railo.  Too many things in Transfer ORM (other frameworks are
 fine) that just 'work' in CF8 break horribly when ported to Railo
 3.1.  I'm to the point where I either need to dig into the Transfer
 ORM source code and see if there's something that needs to be done on
 that end.  The reason I suspect Transfer and not Railo is at fault is
 primarily because the validation of the XML is actually /different/
 between CF8 and Railo.  Also, column prefixes are passed along with
 order property=property conditions when called via CF8, but the
 columns are not prefixed when called via Railo 3.1.  I'm wondering if
 Transfer is being parsed through some non-CF8 custom validator for BD
 or an old version of Railo or something.

 I'd love someone who has looked into this issue a bit more to get me
 some answers for this.

 On Apr 23, 4:10 pm, Jamie Krug jamiek...@gmail.com wrote:

  I receive the following error, with Railo only (3.1.0.012), when my
  code calls something like #transfer.get(user.UserFront, idUserFront)
  # -- a simplified version of my transfer.xml file is also below.

  Error Message -- The structure of your configuration file causes an
  infinite loop
  Error Detail -- The object 'location.UsState' has a recursive link
  back to itself through composition 'UsState'. You will need to set one
  of the elements in this chain to lazy='true' for it to work.

  This application has been running in production on CF8 for months
  without issue. I'm just testing it out on Railo 3.1 and this is the
  only error I've come across in the entire app. I Google'd around quite
  a bit and this older post is the only related one I've found (and it
  doesn't seem to suggest any 
  answers):http://groups.google.com/group/transfer-dev/browse_thread/thread/95a5...

  My UserFront object has a manytoone for UsState and a onetomany for
  FooCriteria; FooCriteria also has a manytoone for UsState, but
  UserFront.UsState is not necessarily the same key/id as that of
  UserFront.FooCriteria.UsState.

  Again, works fine on CF8, above error on Railo 3.1. Does my
  configuration go against a better practice? Is there a known Transfer
  bug? A known Railo bug? The above thread link suggests that Gert Franz
  and/or Luis Majano had already tested Transfer ORM against Railo
  3.0.1.x. Should I give it a whirl on the latest Railo 3.0 instead of
  the 3.1 beta?

  FWIW, the database is PostgreSQL 8.3, I have the latest stable
  Transfer ORM (1.1 final) and this is all running on Ubuntu 8.04.

  Thanks!
  Jamie Krug

  transfer.xml:

  ?xml version=1.0 encoding=UTF-8?
  transfer xsi:noNamespaceSchemaLocation=../../../transfer/resources/
  xsd/transfer.xsd xmlns:xsi=http://www.w3.org/2001/XMLSchema-
  instance
          objectCache
                  scopes
                          server key=transfer_myapp /
                  /scopes
                  defaultcache
                          scope type=server /
                  /defaultcache
          /objectCache
          objectDefinitions
                  package name=foo
                          object name=FooCriteria table=foocriteria
  decorator=model.foo.FooCriteria
                                  id name=idFooCriteria type=UUID 
  generate=true
  column=idfoocriteria /
                                  property name=myPropOne type=numeric 
  column=mypropone /
                                  property name=myPropTwo type=numeric 
  column=myproptwo
  nullable=true /
                                  property name=dateTimeCreated type=date
  column=datetimecreated /
                                  !-- Link between a FooCriteria and its 
  UsState --
                                  manytoone name=UsState
                                          !-- FooCriteria foreign key column 
  that links to UsState primary
  key --
                                          link to=location.UsState 
  column=statecode/
                                  /manytoone
                          /object
                  /package
                  package name=location
                          object name=UsState table=usstate
  decorator=model.location.UsState
                                  id name=stateCode type=string 
  column=abbreviation /
                                  property name=stateName type=string 
  

[transfer-dev] Re: Transfer/Railo error: The structure of your configuration file causes an infinite loop

2009-04-23 Thread Mark Mandel
Luis, you around? You're the one who has done the most testing on Railo,
I've not actually gotten around to running the unit tests on Railo (remiss
of me I know), so I'm not 100% sure if the claims that Transfer actually
works on Railo is true.

Mark

On Fri, Apr 24, 2009 at 7:10 AM, Jamie Krug jamiek...@gmail.com wrote:


 I receive the following error, with Railo only (3.1.0.012), when my
 code calls something like #transfer.get(user.UserFront, idUserFront)
 # -- a simplified version of my transfer.xml file is also below.

 Error Message -- The structure of your configuration file causes an
 infinite loop
 Error Detail -- The object 'location.UsState' has a recursive link
 back to itself through composition 'UsState'. You will need to set one
 of the elements in this chain to lazy='true' for it to work.

 This application has been running in production on CF8 for months
 without issue. I'm just testing it out on Railo 3.1 and this is the
 only error I've come across in the entire app. I Google'd around quite
 a bit and this older post is the only related one I've found (and it
 doesn't seem to suggest any answers):

 http://groups.google.com/group/transfer-dev/browse_thread/thread/95a519fb53c0f504

 My UserFront object has a manytoone for UsState and a onetomany for
 FooCriteria; FooCriteria also has a manytoone for UsState, but
 UserFront.UsState is not necessarily the same key/id as that of
 UserFront.FooCriteria.UsState.

 Again, works fine on CF8, above error on Railo 3.1. Does my
 configuration go against a better practice? Is there a known Transfer
 bug? A known Railo bug? The above thread link suggests that Gert Franz
 and/or Luis Majano had already tested Transfer ORM against Railo
 3.0.1.x. Should I give it a whirl on the latest Railo 3.0 instead of
 the 3.1 beta?

 FWIW, the database is PostgreSQL 8.3, I have the latest stable
 Transfer ORM (1.1 final) and this is all running on Ubuntu 8.04.

 Thanks!
 Jamie Krug

 transfer.xml:

 ?xml version=1.0 encoding=UTF-8?
 transfer xsi:noNamespaceSchemaLocation=../../../transfer/resources/
 xsd/transfer.xsd xmlns:xsi=http://www.w3.org/2001/XMLSchema-
 instance
objectCache
scopes
server key=transfer_myapp /
/scopes
defaultcache
scope type=server /
/defaultcache
/objectCache
objectDefinitions
package name=foo
object name=FooCriteria table=foocriteria
 decorator=model.foo.FooCriteria
id name=idFooCriteria type=UUID
 generate=true
 column=idfoocriteria /
property name=myPropOne type=numeric
 column=mypropone /
property name=myPropTwo type=numeric
 column=myproptwo
 nullable=true /
property name=dateTimeCreated type=date
 column=datetimecreated /
!-- Link between a FooCriteria and its
 UsState --
manytoone name=UsState
!-- FooCriteria foreign key column
 that links to UsState primary
 key --
link to=location.UsState
 column=statecode/
/manytoone
/object
/package
package name=location
object name=UsState table=usstate
 decorator=model.location.UsState
id name=stateCode type=string
 column=abbreviation /
property name=stateName type=string
 column=statename /
property name=stateType type=numeric
 column=statetype /
property name=stateAlias type=string
 column=statealias /
/object
/package
package name=user
object name=UserFront table=userfront
 decorator=model.user.UserFront
id name=idUserFront type=UUID
 generate=true
 column=iduserfront /
property name=email type=string
 column=email /
property name=dateTimeCreated type=date
 column=datetimecreated /
!-- Link between a UserFront and its
 UsState --
manytoone name=UsState
!-- UserFront foreign key column
 that links to UsState primary
 key --
link to=location.UsState
 column=statecode/
/manytoone
!-- Link between UserFront and its array of
 FooCriteria objects --
 
onetomany name=FooCriteria
!-- The column on the FooCriteria
 table that links back to the
 UserFront table. --

[transfer-dev] Re: Transfer/Railo error: The structure of your configuration file causes an infinite loop

2009-04-23 Thread Jamie Krug

A lot of Transfer is working for my app, on Railo 3.1, but I have just
one event that bombs with the error I included in my first post here.
I have numerous other events that use a good bit of Transfer
successfully.

I tried running the unit tests on Railo 3.1.0.12. I just grabbed the
latest transfer svn trunk, as well as the latest transfer/cfunittest/
trunk (which needed to be renamed to test in a webroot to work) and
a copy of cfunit. I created the required transfer_unit_mysql data
source and pointed it to a MySQL database with tables created by /test/
resources/sql/mysql.sql. For every test suite I tried (all links at /
test/index.cfm) I received the same error:

Railo 3.1.0.012 Error (Java.lang.noclassdeffounderror)
Message coldfusion/runtime/UDFMethod
Stacktrace  The Error Occurred in
/home/jkrug/www/transfer-r652/test/index.cfm: line 125

123:
124:
125: testRunner = createObject(component,
net.sourceforge.cfunit.framework.TestRunner);
126:
127: testSuite = createObject(component, url.testSuite).suite();

Java Stacktrace

coldfusion/runtime/UDFMethod
at railo.commons.lang.PhysicalClassLoader.findClass
(PhysicalClassLoader.java:108):108
at railo.commons.lang.PhysicalClassLoader.loadClass
(PhysicalClassLoader.java:85):85
at railo.commons.lang.PhysicalClassLoader.loadClass
(PhysicalClassLoader.java:48):48
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320):320
at java.lang.ClassLoader.defineClass1(Native Method):-2
at java.lang.ClassLoader.defineClass(ClassLoader.java:621):621
at java.lang.ClassLoader.defineClass(ClassLoader.java:401):401
at railo.commons.lang.PhysicalClassLoader.loadClass
(PhysicalClassLoader.java:116):116
at railo.runtime.PageSourceImpl.compile(PageSourceImpl.java:225):225
at railo.runtime.PageSourceImpl.loadPhysical(PageSourceImpl.java:192):
192
at railo.runtime.PageSourceImpl.loadPage(PageSourceImpl.java:121):121
at railo.runtime.component.ComponentLoader.getPage
(ComponentLoader.java:81):81
at railo.runtime.component.ComponentLoader.loadComponentImpl
(ComponentLoader.java:28):28
at railo.runtime.PageContextImpl.loadComponent(PageContextImpl.java:
2215):2215
at railo.runtime.functions.other.CreateObject.doComponent
(CreateObject.java:111):111
at railo.runtime.functions.other.CreateObject.call(CreateObject.java:
49):49
at railo.runtime.functions.other.CreateObject.call(CreateObject.java:
29):29
at test.index_cfm$cf.call(/home/jkrug/www/transfer-r652/test/
index.cfm:125):125
at railo.runtime.PageContextImpl.doInclude(PageContextImpl.java:597):
597
at railo.runtime.listener.ModernAppListener._onRequest
(ModernAppListener.java:109):109
at railo.runtime.listener.MixedAppListener.onRequest
(MixedAppListener.java:23):23
at railo.runtime.PageContextImpl.execute(PageContextImpl.java:1638):
1638
at railo.runtime.engine.CFMLEngineImpl.serviceCFML
(CFMLEngineImpl.java:235):235
at railo.loader.servlet.CFMLServlet.service(CFMLServlet.java:32):32
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717):717
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter
(ApplicationFilterChain.java:290):290
at org.apache.catalina.core.ApplicationFilterChain.doFilter
(ApplicationFilterChain.java:206):206
at org.apache.catalina.core.StandardWrapperValve.invoke
(StandardWrapperValve.java:233):233
at org.apache.catalina.core.StandardContextValve.invoke
(StandardContextValve.java:191):191
at org.apache.catalina.core.StandardHostValve.invoke
(StandardHostValve.java:128):128
at org.apache.catalina.valves.ErrorReportValve.invoke
(ErrorReportValve.java:102):102
at org.apache.catalina.core.StandardEngineValve.invoke
(StandardEngineValve.java:109):109
at org.apache.catalina.connector.CoyoteAdapter.service
(CoyoteAdapter.java:286):286
at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:
190):190
at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:
283):283
at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:767):
767
at org.apache.jk.common.ChannelSocket.processConnection
(ChannelSocket.java:697):697
at org.apache.jk.common.ChannelSocket$SocketConnection.runIt
(ChannelSocket.java:889):889
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run
(ThreadPool.java:690):690
at java.lang.Thread.run(Thread.java:619):619
at java.lang.ClassLoader.defineClass1(Native Method):-2
at java.lang.ClassLoader.defineClass(ClassLoader.java:621):621
at java.lang.ClassLoader.defineClass(ClassLoader.java:401):401
at railo.commons.lang.PhysicalClassLoader.loadClass
(PhysicalClassLoader.java:116):116
at railo.runtime.PageSourceImpl.compile(PageSourceImpl.java:225):225