November 21, 2008

Pages


Search Site


Topics



Archives

Tweets

Entries Tagged as 'CFUnited'

CFUnited: Adam Lehman — Writing your first RIA with CF and Flex

June 20 2008 by Adam

Having never done anything with Flex before, I hope to get a fairly basic intro — how to get started — but at the same time, see an overview of the neat stuff you can do with Flex, in order to get some inspiration to learn it. We'll see how it goes…

  • Adam says that the hardest part was just getting up and getting here this early (8:30am). It should all be downhill from here.
  • "Flex is just a framework for writing ActionScript."
  • Rather than HTML, we use MXML (Macromedia XML Markup Language — they really though that one through!) and ActionScript.
  • Can communicate via SOAP, HHTP/S, AMF/S (Flash Remoting), RTMP/S. AMF is binary, so really fast.
  • Flex SDK is the compiler: command line, free. 
  • Flex Builder: Nice UI for Flex SDK. Professional eddition for charting, advanced data grid/OLAP, and performance profiling. Very nominally priced at $250-$700! 
  • LiveCycle Data Services seems like ADO.NET data management. Enables their equivalent of "disconnected mode" with offline work & re-sync when you come back online — but somehow, seems even easier! 
  • BlazeDS: is a free, open source product, very similar but not as full featured as LCDS. Offers real time data push to clients!
  • Data Services is not required for Flex.
  • Flash Remoting is baked in and has been available since CF 7.01.
  • Flex uses {} as CF uses ##.
  • Use <mx:RemoteObject …> to create an object that will communicate with CF.
  • Flex's <mx:Application applicationComplete=""> is like HTML's <body onLoad=""> "mate" (pronounced "mah-tay") is Adam's recommended Flex Framework.

Posted in CFUnited |

CFUnited: (LiveBlog) Joe Rinehart — What's New in Model-Glue 3

June 19 2008 by Adam

Start at the bottom of this post and work your way up.

3:44: I just realized that I got the numbering different from Joe's presentation. I don't know what, if anything, I missed. Whoops!

3:40: #8: Remoting. Available for Flex, etc. Not all requests have to come in from index.cfm, they can come through the remote CFC. I guess this would make more sense to me if I ever did anything with Flex.

3:36: #7: Formats! Various view-styles (HTML, XML, JSON, partial pages, etc) without duplicating events. All within one event-handler tag! Building web services within an MVC application in CF has never been so easy.

3:27: #6: Content cache. <event-handler name="page.home" cache="true"> I asked if you can setup the cache to be "disabled" in development mode even with caching turned on in the XML (so this doesn't have to be changed between production and dev environments) Joe says no (but interesting idea!), but a workaround would be to set the cache timeout to 0 in development. Programatic access to the cache manager is available, but the cache adapter provided is intended to be dead simple. If you need more than time-based caching, you're encouraged to implement your own.

3:25: Bean Injection! Yay! Auto-wiring without all of the manual labor. <cfcomponent beans="someDAO">

3:21: #5: Helpers. Works for both .cfm and .cfc. Easy way to inject UDFs or a library of them into your application, in a special scope (variable) called "helpers." Usage: #helpers.dateLib.daysTilXmas(now())#

3:15: #4: SES Urls baked in and a URL Manager. The component that handles this is wired in with ColdSpring, so it's easily replaceable if you don't like the default URL format or need something custom. URL manager now means linking is as simple as: #event.linkTo("myEvent")#

3:12: Third new feature? Application.cfc integration: onSessionStart/End, onApplicationStart, etc.

3:10: Second new feature? Event Types. This was discussed on the Model-Glue mailing list a bit, and some folks were unhappy about the implementation being in CFCs, as it is kind of configuration information; and then we'd have config in both XML and CFCs. Several people chimed in and asked for an implementation as XML. Joe says that it was committed yesterday (no documentation yet) so now we have either option. Awesome! Event types are almost like AOP, but more like decorators; you can add a before or after set of code for any event type. Cool stuff, I can't wait to play with this!

3:02: First new feature? Streamlined Workflow. Wiring is necessary, but predictable. When running in development mode, with the feature explicitly enabled, Model Glue will generate events for you. This is somewhat old news, but still just as exciting. Event Generation will also add CFCUnit/CFUnit test stubs. Cool!

2:57: Looks like we're almost through the history of Model-Glue, and about ready to get into new features. I seem to remember Joe writing somewhere that he would announce something as of yet unannounced here at CFUnited. I hope I'm right. :)

2:53: Joe asked if there were any Mach-II developers in the room, and decided he wasn't at too much risk of being hurt for things he would say. Snicker.

2:50: It looks like his preso will be mostly building on the "Roadshow" PDF that comes packaged with the v3 release candidates.

2:47: Here we go! (Can you tell I'm a little excited about this one?)

2:40: I thought Michael Dinowitz would never shut up! I'm pretty sure he went way-over his time for his Google Webmaster Tools preso. He's out now though, and folks are starting to pile in for Joe's Model-Glue preso.

Posted in CFUnited |

CFUnited: Rachel Lehman — AJAX Usability

June 19 2008 by Adam

This session isn't just about AJAX, it also applies to using DHTML to change pages — More appropriately: Non-Flash RIA's. Just like OO, design patterns can apply with usability too. UI design patters are starting to emerge.

Top AJAX Usability issues:

  • Breaks the back-button
  • Use fragments (#) to change URLs as actions are taken (See: Gmail url's changing while you navigate around your email)
  • Use a library with history management
  • Offer an undo option

"New-Fangled Web" – Brand new conventions

  • It takes years for a nidea to become a convention
  • Follow established design patterns: shift-select (traditionally found in lists) can be used for checkboxes and possibly elsewhere.
  • Provide contextual guidance: use icons, hover elements, etc, to indicate in-place editing available.
  • Provide a traditional alternative (in addition to neat things like sliders or date choosers, allow standard text input as well)

"Whats this thingamajig?" – use things people are familiar with.

  • Users may struggle with: sliders,
  • Provide a standard input in addition
  • Use a large hit area

"Did that just work?"

  • Give the user visual feedback
  • When there's a wait (progress bars, spinner, etc)
  • When something changes (can be too fast!)
  • Judiciously use animation
  • Add contrast, color, and highlighting
  • The "yellow fade technique" – draw attention to changed information or messages, and then fade back to normal (I hear this should be a piece of cake with jQuery!)

Distratction vs. Frustration

  • Don't distract the users focus with too much too fast
  • Don't frustrate the user with slow response times
  • Watch auto-suggest/type ahead delay
  • Give generous delays on hover menus
  • Optimize performance, load smart

It's not you, it's the site!

  • Think out the interactions and test, test, test!
  • Compensate for different environments (other browsers, resolutions, etc)
  • Use a tried and tested framework
  • If you can't do it right, don't do it! (Don't reinvent the wheel)

I'm not seeing it…

  • AJAX may be heavily mouse-dependent and visual
  • Non-standard controls aren't supported by assistive devices
  • Screen readers can't tell when a page changes
  • Use semantic markup with progressive enhancement
  • Alternative content may be necessary
  • Screen readers are getting better (W3C-ARIA)

Good, Better, Best

  • Make it work without AJAX first
  • Then add AJAX enhancements – unobtrusive design: add JS functionality with JS so that non-JS supporting browsers and devices still function
  • have keyboard-navigable alternatives to rich controls
  • keep mobile in mind!

Avoid AJAX as an afterthought

  • Make rich interaction a key part of the design process
  • Add it to solve problems, not just to add "sizzle"
  • AJAX changes traditional design paradigms

Designing for Rich Interaction Applications vs. Sites Websites: The user's primary task is to move around an information space and read its content.

Applications: The user's primary task is to change … (She moved too fast through this slide and I couldn't get all of it…)

Great example: Flickr — browsing someone's photos acts like a website, managing/organizing your photos acts like an application Using AJAX to improve usability

  • Eliminate circular flow
  • Provide instant feedback for errors and validation
  • Auto-save (sometimes — use drafts where appropriate. Examples: GMail, WordPress)
  • Show contextual help/menus
  • Streamline data entry (auto-suggest, type-ahead)
  • Enable direct manipulation
  • Look up the pattern!

More information:

Posted in CFUnited |

CFUnited: Mark Drew — ColdSpring: Better Living Through Configuration

June 18 2008 by Adam

I'll be updating this post with notes from the presentation as it goes on…

Welcome, all, to Spaghetti Coder's Anonymous. ColdSpring is an IoC framework. (Inversion of Control) aka Dependency Injection Framework. It has a component factory (bean factory) built in.

Without ColdSpring, you need to wire together your dependencies. This causes coupling, which is in theory, a bad practice. When one of your dependencies needs to change, you have to change it in every location it's used. This is less maintainable code. With ColdSpring, you have "separation of concerns." Components don't have to do things that are not related to their function. They don't have to do anything except their own function.

Another benefit is that it's easier to create testing stubs, you can see all of your components and how they relate in once place (xml config).

  • Bean = Component
  • Bean Factory = ColdSpring – holder of the beans
  • Singleton = there is only one
  • Lazy load = only loaded when needed.

Properties and constructor arguments can be more than just simple value and ref bean's. Can also be a list or array, or a structure (map).

A singleton is a bean that only gets created once, and the same instance is passed to anything that requests it; whereas a non-singleton is recreated any time it is requested. Ssingletons are persisted inside the bean factory; so wherever you store your bean factory, you're also storing singletons. (Application scope is generally the default)

Mark also showed how AOP can be used to do some pretty neat stuff with Accessors and Interceptors.

And said something about actually being a woman.

Posted in CFUnited |

CFUnited: Adobe Keynote

June 18 2008 by Adam

This session is over, and I'll come back and update the formatting of this post when time permits.

Ben says that Adobe has a long history of cool announcements at CFUnited; and hopefully this year won't buck the trend. Adam Lehman is helping present technical aspects, while Ben will be talking at a higher level.

CF8 adoption is doing very well. Adobe is strict about discussing numbers, but he admits that CF sales are the best they've been since Adobe took the reigns, possibly ever. Ben says that ColdFusion 8.01 is an important release for library additions, enhancements, and security improvements.

Coming soon: Public bug tracker, public enhancement request system! (I say: about time [or] awesome!)

Adobe has has already begun working on version 9 ("Centaur"): Advancing CFML, Improving Integration, Improving developer experience. (Everyone thinks that this means an official IDE)

The biggest problem facing ColdFusion customers today is the lack of available developers. (how true!) This is good for existing developers (because they can charge more) but bad for (Adobe's) business and the wider CF community, as it will force more companies who are currently using CF to switch away from CF. Adobe doesn't want that to happen, so they are going to be working to spread the reach of CF and lower or remove some of the barriers to getting involved…

…ColdFusion will be freely available for students and faculty for academic use. It will have a similar model to Flex Builder's free license for Education. (Licensee must provide verification of student/education status), and what they get will be the full unrestricted version. The goal is to make CF easily and freely available (for educational purposes), and they hope that it will come with documentation, and a curriculum. Ben jokes that if we have free time due to more developers being available, we can teach CF part time.

"Over the years, CFML has become fragmented and inconsistent." This must mean a sort of language overhaul? Maybe a CFML language steering committee that Open Source engines can be a part of? I was right!

CFML Language Advisory Committee: Will help define the rules and guidelines around the use and evolution of CFML. Will initially consist of Sean Corfield (Lead), Ben Forta (Adobe), Sanjeev Kumar (Adobe), Gert Franz (Railo), Ray Camden (CF Jedi), and Rob Brooks-Bilson

"Centaur" Sneak Peek: The focus is Building A Better ColdFusion. Adam notes that, of course, the lawyers have to get their $0.02 in: What we see here may or may not make it into the final release. Most of it is only conceptual, not an implementation. Language enhancements: Create UDFs and CFC methods (entire CFCs!) using scripting syntax.

  • argument definition and validation
  • roles
  • write full component syntax in cfscript

component name="CF" extends="adobePlatform"{
   public string function welcome(){
      //...
      return "Welcome!";
   }
}

More CFScript enhancements:

  • Explicit LOCAL scope keeps local variables local: No more need to use <cfset var local = StructNew() />!!
  • No need to declare all variables at the top of the function. (And the crowd goes wild!)
  • New CFSetting option to set a default scope for variables!
  • <CFFinally> and <CFContinue> to do improved try-catch processing. Goes after catches, inside try's. CFFinally will always run, CFContinue will work like a continue in C: In the middle of a processing loop, it will skip the rest of the loop and start at the top with the next iteration.
  • They're planning on adding new and import keywords!
  • <cfcomponent init=""> will allow us to define the constructor, which will run automatically? (How does this affect constructor arguments? Can we have multiple constructors?) CF will also look for function named like the component, like a classic C or Java style constructor.
  • Implicit getters and setters for CFProperty settings. The will not override your defined getters and setters.
  • New Server.cfc file: Will work per instance of ColdFusion, and all Application.cfc's will "sort of" inherit from it. It will be useful to pre-load application stuff (ie: Model-Glue framework stuff) as the server loads, and before the first user hits the site… and have it ready for them! Excellent! Adam specifically mentions: OnServerStart() and OnServerEnd()
  • Centaur will make CF AIR integration easy. (Easier?!)
  • LiveCycleDS will make offline/online data sync almost seamless. Not a whole lot of detail was given, but it sounds awesome.
  • Another huge announcement that sends the crowd into a frenzy: ORM will be baked in 100% with Hibernate. The details of this is way over my head at this point, but holy crap it looks awesome! With all of this data being persisted as cfc objects, the idea has come up that so many functions and tags are based on a query object and would need to be modified for this new system. Ben assures us that they'll be working hard to make changes that will abstract this all so that we can continue to use these things just as easily.

Q&A:

Q: Talk more about the free version for education. Flex is available to staff and faculty
A: Wording is still intentionally ambiguous because they're nailing down the details. They want it to be free and available for EDUCATIONAL use. Lower the barrier for teachers to teach CF in the classroom. Also need a curriculum. CF Team plans on (at least helping) develop curriculum.

Q: Will JRun continue to come as part of the CF Stack?
A: Maybe, maybe not. JRun should support everything they need, but they reserve the right to change it. Plan to keep the install as simple as possible.

Q: Will CFScript be able to do everything that CF Tags can do?
A: The visited it in development of CF8 and couldn't do it without half-assing it, so didn't do it at all. Would revisit it if they thought they could accomplish something. UDF wrappers are available for every tag, anyway.

Q: Will version of Hibernate that ships with CF be stuck in, or can we plug and play?
A: They hope it will be interchangeable, but of course, no promises.
(Hopefully they learned their lesson from the whole Ext 1.0 fiasco?)

Q: Will there be an Official IDE?
A: "Come to MAX." (Sounds an awful lot like, "Yes, but I'm not allowed to even answer that until MAX" to me!)

Q: Why are some companies not represented in the CFML committee? (Of course referring to Open Blue Dragon)
A: (Ben is careful with his wording here. Obviously a sore subject.) His brutal honesty: Group is made of people who have demonstrated a committment to the wider CFML community. List can and will grow, but only in the interests of the businesses involved and the community.

Q: Someone asks about pricing for the new version.
A: … (Do we really need to revisit this? Again?!)

Q: Will there be changes to the server administrator, making it easier to administer multiple servers?
A: Adam says, "Yes." Of course they are always looking to improve everything. They are always looking for recommendations, feel free to submit them!

Q: Will the "this" scope be kept?
A: Of course they will not break existing code. It will stay.

Q: Will there be more examples and tutorials on LiveCycle Data Services?
A: Yes, yes, yes!

Q: Will there be official CF Administration training? (I assume something to do with clustering, tuning, etc)
A: Some partners offer it, they are considering adding some official training. No specific plans yet.

Q: Is KTML editor gone?
A: There are some licensing issues that preclude them from doing what they want to with it. Still trying to work that out.

Q: Any plans to allow CFQueryParam outside of CFQuery?
A: See: CFscript problems! One of the biggest problems of CFML in CFScript. They would like to solve this, but of course no official word yet.

Q: Anything new with Share Point integration?
A: Nobody is clear on what exactly is needed. Need more use cases, so if Share Point is important to you, figure out how you would use it, and tell them!

Q: Better support for memcache or other caching capabilities?
A: Yes, actively being researched.

Q: What additional tooling will be available for ColdFusion?
A: Ben says, "That would fall into improving the developer experience. See you at Max."

Q: Will speed and performance improve at leaps and bounds for between versions 8 and 9 like they did between versions 7 and 8?
A: It won't get slower, and they'd always like it to go faster. Adam says the rule of thumb is that if adding something or making a change will cause CF to run slower, they just don't do it. Period.

Q: Is CFML language grammar published?
A: That's a question for the CFML Language Advisory Committee.

Q: iCal and Imap integration?
A: Ben is a big fan. Thinks they are important, and it's on the wish list, but no promises.

Q: Someone requested a custom tag for working with Java Resource Files
A: Noted.

Q: Will it have virtualization-friendly licensing?
A: They plan to keep the current licensing scheme: Licensed by physical CPUs — very friendly to virtualization!

Q: Dynamic PDF Form generation without LiveCycle?
A: Creating forms from scratch is probably doable, but you would lose some of the benefits of PDF in the first place. Need more use cases and more research.

Q: Word document generation? Not RTF.
A: Noted for wishlist.

Q: Staging licensing: shared instance, which you can't do with a developer license; but not used in production so it doesn't need to be as powerful?
A: One way is to use separate virtual machines on the same box; but they are looking at other options.

Q: Multiple filled PDFs into a single merged PDF?
A: Engineering team is looking into this.

Q: Anything new in the roadmap for CFReport?
A: Ben would like to think there is. If there are things you want, please tell them! There are some known issues, but beyond those, submit requests!

Posted in CFUnited |