I am a newbie MachII user, I've just instaled MachII 1.9 on railo
3.3.3 and coldfusion 9; but I am having a hard time figuring out why i
get a blank screen when I add a listener in the skeleton. even with
sampleListener inthe skeleton, when i uncomment it in mach-ii.xml i
get the blank screen. when I comment the listener I get the view for
the default event correcty.
here is some data from my xml config file (i put here just what used
and not commented):
** the problem occure when i add the ligne <listener
name="LoginListener" type="listeners.LoginListener" /> or <listener
name="SampleListener" type="listeners.SampleListener">
Coud you please help me with that? thank you in advance
On Sun, May 13, 2012 at 6:24 AM, Amine Sadry <amine.sa...@gmail.com> wrote:
> here is some data from my xml config file (i put here just what used
> and not commented):
> ** the problem occure when i add the ligne <listener
> name="LoginListener" type="listeners.LoginListener" /> or <listener
> name="SampleListener" type="listeners.SampleListener">
Sorry to ask the obvious, but do either of those listeners actually exist?
And just so I'm sure I understand, you're saying even if you don't actually
have any <notify listener .../> stuff in your XML, just having the listener
declared in the <listeners> block causes there to be a white screen with no
additional information?
Does your exception view have anything in it?
Typically if there's problem with the listener (doesn't exist or has syntax
errors) you'd see an error related to not being able to load the listener.
Thank you for taking time to help me with that. Actually it's very
strange, I get the blank just by adding the listener declaration
without having any <notify.., at first i thought maybe it's a bug on
railo or something and i tested with coldfusion...but it doesnt work
to answer your question, yes the exception view has the default code
of skeleton
i have just tried again with a very basic application, and restarting
CFML engine:
=== FIRST TEST ===
1) I copy the skeleton from MachII 1.9 folder and rename it helloMach
2) I change xml config property :
<property name="applicationRoot" value="/" />
3) and i test it, it works i have the default home view of skeleton
saying "Skeleton Installation Success!..."
=== SECOND TEST ====
1) I add a listener declation to the one existing in skeleton
listeners folder,
so I change :
<!--
<listener name="yourListenerName"
type="fully.Qualified.Dot.Delimited.Path.To.CFC">
<parameters>
<parameter name="yourParameterName" value="yourParameterValue" />
</parameters>
</listener>
-->
To:
<listener name="SampleListener"
type="listeners.SampleListener">
<!--<parameters>
<parameter name="yourParameterName" value="yourParameterValue" />
</parameters>-->
</listener>
2)I test again, and i get the blank screen, without any error message
( i checked again the exception view and it content some code inside
to display variables.exception stuff)
I don't see what i did wrong to have a blank screen without any error
message, it's quite bizzard :)
Thanks again for your help
Amine
On 13 mai, 21:52, Matthew Woodward <m...@mattwoodward.com> wrote:
> On Sun, May 13, 2012 at 6:24 AM, Amine Sadry <amine.sa...@gmail.com> wrote:
> > here is some data from my xml config file (i put here just what used
> > and not commented):
> > ** the problem occure when i add the ligne <listener
> > name="LoginListener" type="listeners.LoginListener" /> or <listener
> > name="SampleListener" type="listeners.SampleListener">
> Sorry to ask the obvious, but do either of those listeners actually exist?
> And just so I'm sure I understand, you're saying even if you don't actually
> have any <notify listener .../> stuff in your XML, just having the listener
> declared in the <listeners> block causes there to be a white screen with no
> additional information?
> Does your exception view have anything in it?
> Typically if there's problem with the listener (doesn't exist or has syntax
> errors) you'd see an error related to not being able to load the listener.
On Sun, May 13, 2012 at 1:27 PM, Amine Sadry <amine.sa...@gmail.com> wrote:
> === SECOND TEST ====
> <listener name="SampleListener"
> type="listeners.SampleListener">
> <!--<parameters>
> <parameter name="yourParameterName"
> value="yourParameterValue" />
> </parameters>-->
> </listener>
Well, you shouldn't get a blank screen even if this is the case, but does
that listener exist and is its syntax valid?
Also this shouldn't matter but try deleting the parameters block altogether
as well as the closing listener tag and see if just this works:
<listener name="SampleListener" type="listeners.SampleListener" />
And again just to eliminate this possibility, make sure the listener exists.
The only other thing I can think to check is your application name in
Application.cfc in the skeleton. Change that to something unique, and
restart everything (your entire servlet container) after you do that to
make sure everything's cleared out.
Kinda grasping at straws here without knowing more about your setup but see
if any of these suggestions get you any further.
Another thing to consider is how you have your virtual hosts configured. Is
'/' the correct value for your host's root, or do you have a context path
in the mix (e.g. http://localhost:8080/railo for example)?
On Sunday, May 13, 2012 10:39:17 PM UTC+2, Matt Woodward wrote:
> Another thing to consider is how you have your virtual hosts configured. > Is '/' the correct value for your host's root, or do you have a context > path in the mix (e.g. http://localhost:8080/railo for example)?
On Sun, May 13, 2012 at 2:00 PM, Amine Sadry <amine.sa...@gmail.com> wrote:
> no context for my virtual host, the url is
> http://localhost:8888/helloMach/
I have no idea what all you have set up on your machine, but the root of
that application would be /helloMach not /
Actually i put my apps in webapps folder of tomcat (D:\dev\bin\railo\tomcat\webapps) and with this configuration it works with* "/"* as root not " /helloMach "
I moved the app to ROOT folder (D:\dev\bin\railo\tomcat\webapps\ROOT\helloMachBis) and with this configuration it works with "*/helloMachBi**s*" as root not "/" *AND I have no more Blank screen, Yeaaaaaah :) *
it's seems working correctly without any change, just put the app folder in ROOT folder
I didnt get why my app doesnt work correctly in webapps folder but anyway i will investigate this point and understand more MachII config
On Sun, May 13, 2012 at 3:16 PM, Amine Sadry <amine.sa...@gmail.com> wrote:
> Actually i put my apps in webapps folder of tomcat
> (D:\dev\bin\railo\tomcat\webapps) and with this configuration it works with
> * "/"* as root not " /helloMach "
But if you don't do any additional configuration, and you're not running in
the ROOT context, then you're definitely going to have a context in the mix.
> I moved the app to ROOT folder
> (D:\dev\bin\railo\tomcat\webapps\ROOT\helloMachBis) and with this
> configuration it works with "*/helloMachBi**s*" as root not "/"
> *AND I have no more Blank screen, Yeaaaaaah :) *
Right, that makes sense. If it wasn't in ROOT you'd have to do
http://localhost:8888/context/helloMach and adjust your root in the config
files accordingly.
I didnt get why my app doesnt work correctly in webapps folder but anyway i
> will investigate this point and understand more MachII config
It's because (from what you're saying) you had a context path in the mix.
That's why it works from ROOT.
On Monday, May 14, 2012 12:24:45 AM UTC+2, Matt Woodward wrote:
> On Sun, May 13, 2012 at 3:16 PM, Amine Sadry <amine.sa...@gmail.com>wrote:
>> Actually i put my apps in webapps folder of tomcat >> (D:\dev\bin\railo\tomcat\webapps) and with this configuration it works with >> * "/"* as root not " /helloMach "
> But if you don't do any additional configuration, and you're not running > in the ROOT context, then you're definitely going to have a context in the > mix.
>> I moved the app to ROOT folder >> (D:\dev\bin\railo\tomcat\webapps\ROOT\helloMachBis) and with this >> configuration it works with "*/helloMachBi**s*" as root not "/" >> *AND I have no more Blank screen, Yeaaaaaah :) *
> Right, that makes sense. If it wasn't in ROOT you'd have to do > http://localhost:8888/context/helloMach and adjust your root in the > config files accordingly.
> I didnt get why my app doesnt work correctly in webapps folder but anyway >> i will investigate this point and understand more MachII config
> It's because (from what you're saying) you had a context path in the mix. > That's why it works from ROOT.
We have our Listeners call our Managers and our Managers call the Gateways,Dao's or Cruds.
To simplify this i'll just refer to Gateways.
So if we have a AccountManager, BillManager and the respective AccountGateway and BillGateway .
The question is, if the AccountManager needs to call a method in the BillGateway should the AccountManager call the Billgateway directly
or should the AccountManager call the proper method in the BillManager and have the BillManger call the BillGateway?
Call the manager not the gateway. This way if you gateway stuff
changes...everything is done via the manager. One one place to fix.
Otherwise you have to hunt for any external calls to gateways.
On May 15, 2012 10:09 AM, "Nicholas Dee" <nicholas...@hotmail.com> wrote:
> We have our Listeners call our Managers and our Managers call the
> Gateways,Dao's or Cruds.
> To simplify this i'll just refer to Gateways.
> So if we have a AccountManager, BillManager and the respective
> AccountGateway and BillGateway .
> The question is, if the AccountManager needs to call a method in the
> BillGateway should the AccountManager call the Billgateway directly
> or should the AccountManager call the proper method in the BillManager and
> have the BillManger call the BillGateway?
As an architectural practice, though....if the AccountManager has a reason
to know about the Bill entity (table, whatever) ... IMHO the AccountManager
should have a reference to the BillGateway so it can call it "natively",
and you may not even need a BillManager ... this way your service/manager
layer is acting as a better API for the "outside" world (i.e., Mach-ii or
other clients) to understand how the data is actually organized. If you
have services/managers calling each other, then managing those dependencies
could get tough quickly. Instead, if you simply have one service/manager
for one OR MORE related DAOs/tables/whatever, then to the outside world
accessing your data becomes simpler, and your service/manager layer is a
bit more purposeful.
On Tue, May 15, 2012 at 2:02 PM, Peter Farrell <pe...@mach-ii.com> wrote:
> Call the manager not the gateway. This way if you gateway stuff
> changes...everything is done via the manager. One one place to fix.
> Otherwise you have to hunt for any external calls to gateways.
> On May 15, 2012 10:09 AM, "Nicholas Dee" <nicholas...@hotmail.com> wrote:
>> We have our Listeners call our Managers and our Managers call the
>> Gateways,Dao's or Cruds.
>> To simplify this i'll just refer to Gateways.
>> So if we have a AccountManager, BillManager and the respective
>> AccountGateway and BillGateway .
>> The question is, if the AccountManager needs to call a method in the
>> BillGateway should the AccountManager call the Billgateway directly
>> or should the AccountManager call the proper method in the BillManager
>> and have the BillManger call the BillGateway?