tracker issue : CF-3592789

select a category, or use search below
(searches all categories and all time range)
Title:

Ability to class load via createobject(java, class, jars/class array) and new function to class load

| View in Tracker

Status/Resolution/Reason: To Fix//

Reporter/Name(from Bugbase): Luis Majano / Luis Majano (Luis Majano)

Created: 07/10/2013

Components: Language, CF Component

Versions: 10.0

Failure Type: Enhancement Request

Found In Build/Fixed In Build: Final /

Priority/Frequency: Trivial / Unknown

Locale/System: English / Platforms All

Vote Count: 3

Can createobject be enhanced for java so we can pass a list or array as the third argument for jar or class locations?

createObject("java", "class", [ "path/lib.jar", "otherpath/lib.jar" ])

This way we can class load those paths instead of touching Application.cfc. Also maybe having another function that can do class loading would be helpful.  Relying on Application.cfc is great for static loading, but sometimes we need the ability to class load dynamically or on demand.  Obviously this can be done outside of the core CF via network class loaders or the java loader project.  But why not complete was what started in cf10?

javaLoadPaths( paths, cfclassLoader )??

----------------------------- Additional Watson Details -----------------------------

Watson Bug ID:	3592789

External Customer Info:
External Company:  
External Customer Name: LuisMajano
External Customer Email:  
External Test Config: My Hardware and Environment details:

Attachments:

Comments:

I would use this heavily.
Vote by External U.
15016 | July 10, 2013 10:32:24 AM GMT
Sounds like a great idea.
Vote by External U.
15017 | July 10, 2013 10:40:45 AM GMT
Like this idea! just curious, should some of the other options for Application.cfc related to class loading in this.javaSettings be considered as well like reloadOnChange, watchInterval or is the intention that it reloads the jar every time before instantiating the object and the user is responsible for ensuring the instance is placed in an appropriate scope like Application?
Vote by External U.
15018 | July 10, 2013 12:36:39 PM GMT