axis-c-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From damitha kumarage <dami...@opensource.lk>
Subject Re: Axis2Transport does not build on windows
Date Fri, 03 Dec 2004 11:17:13 GMT
Hi Samisa,

On Fri, 2004-12-03 at 16:24, Samisa Abeysinghe wrote:
> Hi Damitha,
> 
> --- damitha kumarage <damitha@opensource.lk> wrote:
> 
> > Hi Samisa,John, Fred,
> > 
> > On Wed, 2004-12-01 at 13:28, Samisa Abeysinghe wrote:
> > > Hi Damitha,
> > >  
> > > > I think SSLChannel.hpp is for that. I have given just one
> > > implementation for
> > > > that. Others could give an different impl. If this interface is not
> > > flexible
> > > > enough suggestions are accepted
> > > 
> > > I have a differnt view. I think SecureChannle.hpp is for that. And SSL
> > > stuff should be in ssl folder. And SSLChannel should inherit from the
> > > secure channel. That would give us a more clearner hierarchy.
> > 
> > I too agree SecureChannel.hpp is for that. So I have changes to keep the
> > SecureChannel.hpp as the base class. I completely removed SSLChannel
> > class. Fred has already put required methods in SecureChannel.hpp
> > ie. readSecureSocket, writeSecureSocket etc.
> > 
> > So I have my library implemenation in ssl folder. I have
> > OpesSSLChannel.hpp derived from SecureChannel.hpp. Earlier it is
> > deriving from SSLChannel.hpp.
> 
> Cool. Thanks for the new cleaner design. (I hope you will commit this after alpha release)

I'll commit this after the code freeze if over

> 
> 
> > 
> > >  
> > > The fact that we need to have SSLChannelFactory in the Axis2Transport
> > > project does not sound correct to me. That should be in a seperate
> > > project - say SSLTransport project. (Please have a look at how the
> > > coplilation problem was solved for windows)
> > 
> > Here I have a suggestion. 
> > In Axis2Transport class on setEndpointUri method  we have
> >        m_pChannel = (Channel *) new SecureChannel ();
> > 
> > This where SecureChannel class is instantiated depending on the url
> > is https or http.
> > I suggest to have this code instead of the above.(I have implemented
> > this in my new version)
> > 
> >        m_pChannel = m_pFactory->getSecureChannelObject();
> > 
> > m_pFactory is an instance of ChannelFactory. Note that I have changed
> > the name SecureChannelFactory to ChannelFactory. We can have another
> > method in SecureChannelFactory called 
> > getChannelObject() which return a norman Channel object. So we can have
> > a normal channel pluggable as well(Like different business need
> > their own secure channel implemenations they might also need their own
> > normal channel implemenation)
> > So instead of
> > m_pChannel = new Channel ();
> > we hae
> > m_pChannel = m_pFactory->getChannelObject();
> > 
> > What do you think?
> 
> It is a good idea to apply factory pattern here. However, we would have only two possibilities
> here, either http or https. Given that, do we need to make things complex here?
> IMHO, keeping the current structure is good for the sake of KISS.

There is more here than just applying factory pattern.

If we provide this we can have a different implemenation of normal
channel than the default channel implemenation provided by us.

In getChannelObject we may have something like this

Channel* ChannelFactory::getChannelObject()
{
    Channel* pChannel = 0;

    if(useDefaultChannel)
    {
        pChannel = new Channel();
    }
    else
    {   
        if (m_Create) m_Create(&pChannel);
        return pChannel;
    }
}


regds
damitha


> 
> Thanks,
> Samisa...
> 
> > 
> > thanks
> > damitha
> > >  
> > > Thanks,
> > > Samisa...
> > > 
> > > Damitha Kumarage <damitha@opensource.lk> wrote:
> > >         Hi John,
> > >         On Tue, 30 Nov 2004 13:02:05 +0000, John Hawkins wrote
> > >         > +1 loose coupling for compile time pls.
> > >         I don't think that there is such comile time tight coupling.
> > >         Once the existing
> > >         window problem solved this should be ok
> > >         
> > >         > 
> > >         > IBM has its own implementation of ssl so we don't want to
> > >         confuse 
> > >         > the two
> > >         > (I can imagine some other software shops might also want to
> > >         use 
> > >         > their own impl.)
> > >         I think SSLChannel.hpp is for that. I have given just one
> > >         implementation for
> > >         that. Others could give an different impl. If this interface
> > >         is not flexible
> > >         enough suggestions are accepted
> > >         
> > >         thanks
> > >         damitha
> > >         > 
> > >         > John Hawkins
> > >         > 
> > >         > Samisa Abeysinghe 
> > >         > > e@yahoo.com> 
> > >         > To Apache AXIS 
> > >         > C Developers List 30/11/2004 12:44 > c-dev@ws.apache.org>

> > >         > cc
> > >         > 
> > >         > Please respond to 
> > >         > Subject "Apache AXIS C Re: Axis2Transport 
> > >         > does not build Developers List" on windows
> > >         > 
> > >         > Hi Damitha,
> > >         > Can we move all the SSL specific stuff into ssl sub folder?
> > >         > I got the feeling that there is some level of tight coupling
> > >         > here with the non-SSL stuff. (It is annoying that I cannot
> > >         compile a 
> > >         > module because of something that I am not going to use)
> > >         > 
> > >         > Re PlatformAutoSense.hpp: This can be a reason, as I
> > >         mentioned 
> > >         > in an early mail. If so, does any one know how to override
> > >         an 
> > >         > already included file so that we could override winsock.h
> > >         with 
> > >         > winsock2.h (or does it sound silly :( ? ) In other words, is
> > >         there 
> > >         > any way to enfoce the Win platform header to include
> > >         winsock2.h all 
> > >         > the time?
> > >         > 
> > >         > Thanks,
> > >         > Samisa...
> > >         > 
> > >         > Damitha Kumarage wrote:
> > >         > Hi Samisa,
> > >         > The only different with the older ones is that now it does
> > >         not 
> > >         > contain ssl speicfic header files. Using a SSLChannelFactory
> > >         it 
> > >         > dyanmically load the ssl channel library and call its
> > >         methods. The 
> > >         > problem causing could be from including
> > >         PlatformAutoSense.hpp in
> > >         SSLChannelFactory.hpp
> > >         > 
> > >         > damitha
> > >         > 
> > >         > On Tue, 30 Nov 2004 03:49:54 -0800 (PST), Samisa Abeysinghe
> > >         wrote
> > >         > > > Was the vc project for Axis2Transport changed to include
> > >         the new
> > >         > files? If
> > >         > > > not what are the files that need to be included in this
> > >         project?
> > >         > >
> > >         > > I have no idea on this. I think the files have not been
> > >         added.
> > >         > >
> > >         > > Just to let you know:
> > >         > > To help find a solution, I copied older versions of
> > >         > > SecureChannel.cpp and SecureChannel.h into the folder and
> > >         built 
> > >         > the > project and the build was successful. > > I am
n! ot
> > >         sure why 
> > >         > the latest SecureChannel.cpp and SecureChannel.h > are
> > >         causing problems.
> > >         > >
> > >         > > Samisa...
> > >         > >
> > >         > > sanjaya singharage wrote:
> > >         > > Was the vc project for Axis2Transport changed to include
> > >         the new
> > >         > > files? If not what are the files that need to be included
> > >         in this
> > >         > project?
> > >         > >
> > >         > > sanjaya.
> > >         > > ----- Original Message -----
> > >         > > From: "Samisa Abeysinghe"
> > >         > > To: "Apache AXIS C Developers List"
> > >         > > Sent: Tuesday, November 30, 2004 5:32 PM
> > >         > > Subject: Re: Axis2Transport does not build on windows
> > >         > >
> > >         > > > Yes; AxisSocketUtils is not used anywhere.
> > >         > > >
> > >         > > > Looking at the email list, if I say changes to
> > >         SecureChannel has
> > >         > started
> > >         > > causing problems, am I
> > >         > > > correct? If so I could revert back and try.
> > >         > > >
> > >         > > > Thanks,
> > >         > > > Samisa...
> > >         > > >
> > >         > > > --- sanjaya singharage wrote:
> > >         > > >
> > >         > > > > win! sock.h is included in xisSocketUtils.cpp,
but
> > >         this 
> > >         > doesn't seem to be > > > used anywhere. > > >
> > > sanjaya.
> > >         > > > > 
> > >         > > > ----- Original Message ----- > > > From: "Samisa
> > >         Abeysinghe" > > 
> > >         > > To: "Apache AXIS C Developers List" > > > Sent:
Tuesday,
> > >         November 
> > >         > 30, 2004 5:02 PM > > > Subject: Re: Axis2Transport does
not
> > >         build on 
> > >         > windows > > > > > > > > > > None
of the source files include
> > >         > winsock.h but winsock2.h. > > > > However, windows.h
> > >         included in > > 
> > >         > > src/platforms/windows/PlatformSpecificWindows.hpp seems to
> > >         make 
> > >         > the > > > > compiler run into confusion. > >
> > I still
> > >         could not 
> > >         > find a solution. > > > > > > > > Waht
are we doing wrong
> > >         here? I 
> > 
> === message truncated ===
> 
> 
> 
> 		
> __________________________________ 
> Do you Yahoo!? 
> Send a seasonal email greeting and help others. Do good.
> http://celebrity.mail.yahoo.com


Mime
View raw message