Hello again,

On 14/08/15 08:20, Dennis Bliefernicht wrote:
Oh dear, down the NSBundle rabbit hole ;-)

On 13 Aug 2015, at 15:41, Yoann Canal <yca...@sophiacom.fr <mailto:yca...@sophiacom.fr>> wrote:

On 12/08/15 09:12, Dennis Bliefernicht wrote:
HI,

- download woproject.jar only once instead of once per framework
- remove reference tonexus.xyrality.net <http://nexus.xyrality.net/>
- remove postgres dependencies
- allow setting webobjectsVersion / wonderVersion before applying the plugin since automatically added frameworks will use the default versions otherwise

Feel absolutely free to submit pull requests, preferable separate ones for this :-) Generally we're not that happy either yet with the default dependency mechanism; while "fine" for most projects sometimes you want to switch out some dependency which is not that easy to do afterwards in Gradle.

Will do :)
Our only trouble with dependencies has been with WOUnit that get outdated dependencies so our fork contains
testCompile(group: 'com.wounit', name: 'wounit', version: '1.2.1') {
    transitive = false
}
and we manually add the required dependencies afterward.

If transitive dependencies are the issue, you should always be able to override them with newer versions, even if transitive = false has not been specified. Another pitfall though with WO/Wonder is the possibility of some libraries being completely included into other libraries (e.g. JavaXML contains a copy of log4j, XML parsers, commons-logging, ...). This can really trip you up add a newer version of the library and get weird MethodNotFoundException because some new class mixes up with some old class.

Then I suspect our problem was a bit more than transitive dependencies, maybe classpath ordering ? :/
That's the scenario we tried. We use eclipse 4.5 (I think Antoine tried on 4.4), gradle 2.4 and our fork of the gradle-plugin. The projects were imported using the "import existing project" menu, not the gradle import. .project file contains org.objectstyle.wolips.incrementalbuilder and org.objectstyle.wolips.incrementalframeworknature :(

Too bad, that would have been an easy one :-) Could you try importing it as proper Gradle project using the Eclipse Gradle Plugin? We had success with https://marketplace.eclipse.org/content/gradle-ide-pack (only need the IDE pack). Then Import -> Gradle -> Gradle Project -> Select root project folder -> Build Model -> Select projects -> Import.
Using this import it works for both of my colleagues but not for me :'(

Linking to the JavaWebObjects library instead of the .jar gives another exception but I'm not sure this can help:
[...]
[2015-8-13 14:59:24 CEST] <main> NSBundle is unable to find "ExtensionsForResources.plist" in the main bundle. Ignoring optional configuration file. [2015-8-13 14:59:24 CEST] <main> Cannot use rapid turnaround. Please start Xcode and open the project for this application. [2015-8-13 14:59:24 CEST] <main> <WOProjectBundle>: Warning - Unable to find project at path /Users/ycanal/ - Ignoring project. [2015-8-13 14:59:24 CEST] <main> java.lang.StringIndexOutOfBoundsException: String index out of range: 18
    at java.lang.String.substring(String.java:1951)
at com.webobjects._ideservices._WOAntProject.antProjectAtPath(_WOAntProject.java:62) at com.webobjects._ideservices._WOProject.ideProjectAtPath(_WOProject.java:106)

Looks like it did not properly recognize the project as Eclipse project, which is why it tries to use the Ant loader. Is the project being built properly by eclipse in build/YourApp.woa?

I'm not sure what to expect in build/YourApp.woa. After an eclipse build it only contains Content, not the run script or WOBootstrap.jar but it still works for my colleagues.
[2015-8-13 14:59:24 CEST] <main> A fatal exception occurred: ERXExtensions have not been initialized. Debugging information can be enabled by adding the JVM argument: '-Der.extensions.appserver.projectBundleLoading=DEBUG'. Please report the classpath and the rest of the bundles to the Wonder mailing list: Remaining frameworks: [JavaFoundation, ERModernLook, ERCoreBusinessLogic, ERTaggable, JavaJDBCAdaptor, ERRest, JavaXML, WOLips, ERCoolComponents, ERPrototypes, ExcelGenerator, JavaWOExtensions, JavaDTWGeneration, ERAttachment, JavaEOControl, Ajax, MySQLPlugIn, JavaEOAccess, GoogleChart, JavaDirectToWeb, ERCoreBusinessLogicDTW, ERJavaMail, ERExcelLook, JavaEOProject, JavaMemoryAdaptor, ERModernDefaultSkin, ERDirectToWeb, ERQuartzScheduler, ERExtensions, WOOgnl, ERModernDirectToWeb]
Classpath: [...]

Actually how does the classpath look like? Especially: is ERExtensions from wonder still in front of other WO libraries?
The .classpath looks correct after a 'gradle eclipse' but after an import in eclipse it's empty:
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
    <classpathentry kind="src" path="Resources"/>
    <classpathentry kind="src" path="Sources"/>
    <classpathentry kind="src" path="Components"/>
    <classpathentry kind="src" path="WebServerResources"/>
<classpathentry exported="true" kind="con" path="org.springsource.ide.eclipse.gradle.classpathcontainer"/> <classpathentry exported="true" kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
    <classpathentry kind="output" path="bin"/>
</classpath>
Not sure what causes this.

Greetings
Dennis
--




-----------------------------------------------------
*Dennis Bliefernicht* • Backend Development
*T* +49 40 357 3001 62
dennis.blieferni...@xyrality.com <mailto:dennis.blieferni...@xyrality.com>
_
_
XYRALITY GmbH•Friedensallee 290 • 22763 Hamburg
www.xyrality.com <http://www.xyrality.com>
Registergericht: Hamburg HRB 115332
Geschäftsführer: Sven Ossenbrüggen
-----------------------------------------------------


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (Webobjects-dev@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to