One of the topics on my mind recently, as we consider refactoring the core container, is how we ensure that when we introduce internal dependencies, such as possibly the Amara libraries for XML processing, what secondary constraints we might be introducing.
For example, Amara represents a very pythonic and therefore simple to read and use approach to developing XML processing, such as our very own XML application configuration parsers. So from that perspective, things are very attractive. But then you ask the question, "can I run this on another python platform, such as IronPython and Jython?" and things get more constraining.
However, my question is "is this important, in this case?" It's a general question for the Spring Python community really. Should we attempt to support the execution of SP applications on other platforms than CPython?
My first gut reaction to this is "Yes!", but after thinking about things a bit more I'm not so sure. Takes these following three scenarios (the first 2 are dead straight and simple, the third is more interesting):
1) I'm a Java developer and I need to create a Spring application. Now, am I really going to pick up Spring Python... probably not. My tool of choice is Java so I'll leap for Spring Java. If I need to add in python 'beans', then I can do that using the lang namespace that's supported in the Spring Framework for Java.
2) I'm a .NET developer and I need to create a Spring application. Now, am I really going to pick up Spring Python... probably not. My tool of choice is C#, or maybe VB, so I'll leap for Spring .NET. IF I want to feploy python 'objects' then I can either do that manually over IronPython, or I can wait for the lang namespace support...
In either of these cases, the onus is on the developer to think about the platform and tools they want to use for their job, including choice of language, and to go ahead and apply thew Spring approach in that environment. If the developer wants to use a python component, then it's their responsibility to understand that it is running on Jython or IronPython respectively. Although it's made simple in Spring to do that, using the lang namespace, the details are not hidden to the point where anything nasty, like a piece of C code barfing, is likely to happen.
Now consider a third case:
3) I'm a Python, notable a CPython, developer and I need to create a Spring application. Now, am I really going to pick up Spring Python... probably! My tool of choice is Python so I'll leap for Spring Python, makes sense. If I need to run my application on a different platform, like Java and the JVM... would I attempt to take across my existing application as it stands, or would it be more likely that I reconstruct the pertinent pieces in Spring Java (a relatively trivial task) so that I could reuse my own components (as hosted using Jython) and take advantage of all the strong integration with the Java platform inherent in the Spring framework for Java? (for the .NET equivalent, just substitute Java for .NET in the prior sentence).
My feelings right now are that it is unlikely that a Spring Python application developer would expect to take their entire application as is and expect to run it on a different platform, such as .NET or Jython in the JVM. If I was going to do that, I would want to take advantage of the bits and pieces that are there in the .NET and Java worlds, and that would mean a port. It's also unlikely that I would necessarily get a business requirement to shift platforms like that... but I'm open to arguments there.
My take is that Spring.NET provides Spring for the .NET community. Spring Java, well, it does the same for the Java community. Spring Python is doing the same for the Python community. The programming model and approach is portable, but it's not expected that the actual codebase is. Think of this as the concepts are the same, but exactly how you implement them would take full advantage of the platform you are on.
So is this fair? This is where I need the community to chime in. Are my assumptions here wrong? Is there a defined need, special to the Python community, to come up with a framework that is truly portable at the implementation level, or is the goal really to create a framework that helps us use Spring concepts in the Python world. It's a BIG question, because it informs many of the core containers development choices, hence I thought it was time to get it out there for everyone to have their say.
So, any thoughts?


Reply With Quote
.
