Re: Maven and eclipse #2 - problem with missing bundle? null mainBundleName()

2016-10-16 Thread Paul Hoadley
On 17 Oct 2016, at 7:16 AM, Mark Wardle  wrote:

> Paul, you’re a better man than me! I really will do this now you’ve proven it 
> is possible….  probably next week… maybe!

Getting me through the migration process was 95% Hugi, though I will take 
credit for this particular find. Assuming it works for you. Otherwise I will 
disown it.


-- 
Paul Hoadley
http://logicsquad.net/



 ___
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

Re: Maven and eclipse #2 - problem with missing bundle? null mainBundleName()

2016-10-16 Thread Mark Wardle
Paul, you’re a better man than me! I really will do this now you’ve proven it 
is possible….  probably next week… maybe!

Mark

> On 16 Oct 2016, at 01:05, Paul Hoadley  wrote:
> 
> Hi Mark,
> 
> On 6 Sep 2016, at 10:04 PM, Mark Wardle  > wrote:
> 
>> It isn’t quite right from eclipse. I can run a newly created application 
>> from within eclipse, but when I try to run a migrated application, I get 
>> this error:
>> 
>>  java.lang.ExceptionInInitializerError
>>  at 
>> com.webobjects.appserver.WOResourceManager.__getJavaWebObjectsResourceAsStream(WOResourceManager.java:116)
>>  at 
>> com.webobjects.appserver._private.WOProperties.initUserDefaultsKeys(WOProperties.java:317)
>>  at 
>> com.webobjects.appserver.WOApplication._initWOApp(WOApplication.java:5743)
>>  at com.webobjects.appserver.WOApplication.(WOApplication.java:779)
>>  at 
>> er.extensions.appserver.ajax.ERXAjaxApplication.(ERXAjaxApplication.java:30)
>>  at 
>> er.extensions.appserver.ERXApplication.(ERXApplication.java:1135)
>>  at com.eldrix.news.app.Application.(Application.java:66)
>>  at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
>>  at 
>> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
>>  at 
>> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
>>  at java.lang.reflect.Constructor.newInstance(Constructor.java:408)
>>  at java.lang.Class.newInstance(Class.java:438)
>>  at com.webobjects.appserver.WOApplication.main(WOApplication.java:547)
>>  at er.extensions.appserver.ERXApplication.main(ERXApplication.java:890)
>>  at com.eldrix.news.app.Application.main(Application.java:63)
>> Caused by: java.lang.NullPointerException
>>  at 
>> er.extensions.appserver.ERXApplication$Loader.collectMainProps(ERXApplication.java:757)
>>  at 
>> er.extensions.appserver.ERXApplication$Loader.bundleDidLoad(ERXApplication.java:682)
>>  at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
>>  at 
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>>  at java.lang.reflect.Method.invoke(Method.java:483)
>>  at 
>> com.webobjects.foundation.NSSelector._safeInvokeMethod(NSSelector.java:122)
>>  at 
>> com.webobjects.foundation.NSNotificationCenter$_Entry.invokeMethod(NSNotificationCenter.java:588)
>>  at 
>> com.webobjects.foundation.NSNotificationCenter.postNotification(NSNotificationCenter.java:532)
>>  at 
>> com.webobjects.foundation.NSNotificationCenter.postNotification(NSNotificationCenter.java:562)
>>  at 
>> com.webobjects.foundation.NSBundle.postNotification(NSBundle.java:2546)
>>  at 
>> com.webobjects.foundation.NSBundle.LoadBundlesFromJars(NSBundle.java:735)
>>  at com.webobjects.foundation.NSBundle.(NSBundle.java:345)
>>  ... 15 more
>> 
>> java.lang.NullPointerException
>>  at 
>> er.extensions.appserver.ERXShutdownHook$1.run(ERXShutdownHook.java:64)
> 
> I just hit this exact issue. You know what it turned out to be? Stale 
> patternsets under woproject—I was migrating a Fluffy Bunny project, and 
> forgot that step. Fixed the patternsets, fixed the NPE.
> 
> 
> -- 
> Paul Hoadley
> http://logicsquad.net/ 
> 
> 
> 

 ___
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

Re: Maven and eclipse #2 - problem with missing bundle? null mainBundleName()

2016-10-15 Thread Paul Hoadley
Hi Mark,

On 6 Sep 2016, at 10:04 PM, Mark Wardle  wrote:

> It isn’t quite right from eclipse. I can run a newly created application from 
> within eclipse, but when I try to run a migrated application, I get this 
> error:
> 
>  java.lang.ExceptionInInitializerError
>   at 
> com.webobjects.appserver.WOResourceManager.__getJavaWebObjectsResourceAsStream(WOResourceManager.java:116)
>   at 
> com.webobjects.appserver._private.WOProperties.initUserDefaultsKeys(WOProperties.java:317)
>   at 
> com.webobjects.appserver.WOApplication._initWOApp(WOApplication.java:5743)
>   at com.webobjects.appserver.WOApplication.(WOApplication.java:779)
>   at 
> er.extensions.appserver.ajax.ERXAjaxApplication.(ERXAjaxApplication.java:30)
>   at 
> er.extensions.appserver.ERXApplication.(ERXApplication.java:1135)
>   at com.eldrix.news.app.Application.(Application.java:66)
>   at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
>   at 
> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
>   at 
> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
>   at java.lang.reflect.Constructor.newInstance(Constructor.java:408)
>   at java.lang.Class.newInstance(Class.java:438)
>   at com.webobjects.appserver.WOApplication.main(WOApplication.java:547)
>   at er.extensions.appserver.ERXApplication.main(ERXApplication.java:890)
>   at com.eldrix.news.app.Application.main(Application.java:63)
> Caused by: java.lang.NullPointerException
>   at 
> er.extensions.appserver.ERXApplication$Loader.collectMainProps(ERXApplication.java:757)
>   at 
> er.extensions.appserver.ERXApplication$Loader.bundleDidLoad(ERXApplication.java:682)
>   at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
>   at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>   at java.lang.reflect.Method.invoke(Method.java:483)
>   at 
> com.webobjects.foundation.NSSelector._safeInvokeMethod(NSSelector.java:122)
>   at 
> com.webobjects.foundation.NSNotificationCenter$_Entry.invokeMethod(NSNotificationCenter.java:588)
>   at 
> com.webobjects.foundation.NSNotificationCenter.postNotification(NSNotificationCenter.java:532)
>   at 
> com.webobjects.foundation.NSNotificationCenter.postNotification(NSNotificationCenter.java:562)
>   at 
> com.webobjects.foundation.NSBundle.postNotification(NSBundle.java:2546)
>   at 
> com.webobjects.foundation.NSBundle.LoadBundlesFromJars(NSBundle.java:735)
>   at com.webobjects.foundation.NSBundle.(NSBundle.java:345)
>   ... 15 more
> 
> java.lang.NullPointerException
>   at 
> er.extensions.appserver.ERXShutdownHook$1.run(ERXShutdownHook.java:64)

I just hit this exact issue. You know what it turned out to be? Stale 
patternsets under woproject—I was migrating a Fluffy Bunny project, and forgot 
that step. Fixed the patternsets, fixed the NPE.


-- 
Paul Hoadley
http://logicsquad.net/



 ___
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

Re: Maven and eclipse #2 - problem with missing bundle? null mainBundleName()

2016-09-08 Thread Mark Wardle
Thank you! 

I really think eclipse got muddled. When I started clearing everything and 
switching back to using ant, eclipse’s filesystem cache thought that there were 
files around that weren’t and hence I deleted all workspaces, eclipse itself 
and started again with a freshly cleared source code tree. I’m tempted to try 
another migration at the weekend - probably aided by beer - which in my 
experience usually helps considerably…

Mark

> On 8 Sep 2016, at 21:06, Hugi Thordarson  wrote:
> 
> I feel your pain, the migration was a chore at first. I’ve ported ~30 
> projects and they all made it in the end. Don’t hesitate to ask if you’d like 
> more hands on assistance—I love helping people migrate to Maven :).
> 
> - hugi
> 
> 
> 
>> On 8. sep. 2016, at 19:55, Mark Wardle  wrote:
>> 
>> Thank you! I did try this and it just wouldn't work with different errors 
>> running from eclipse (as above) and at command-line (odd JDBC no connection 
>> errors as if no connection dictionary was present). I have temporarily given 
>> up and will try again for a new project. I have also upgraded to eclipse 
>> neon and wolips which seems to have less odd errors with opening eomodel 
>> files than before. 
>> 
>> Mark
>> On Tue, 6 Sep 2016 at 14:26, Hugi Thordarson  wrote:
>> Compare your .project and build.properties with those of a new Maven 
>> project. Specifically make sure build.properties has:
>> 
>> classes.dir=target/classes
>> 
>> …and then make sure your .project file contains the maven builder. In fact, 
>> your .project should probably look exactly like this, apart from the project 
>> name:
>> 
>> https://gist.github.com/hugith/6612765b2449b4ab98ec64ea54fd433c
>> 
>> - hugi
>> 
>> 
>> 
>> 
>>> On 6. sep. 2016, at 13:19, Mark Wardle  wrote:
>>> 
>>> Definitely!
>>> 
>>> As a potential solution, I am going to create a new empty application and 
>>> copy across the code and components and other resources and see what 
>>> happens.
>>> 
>>> Mark
>>> 
>>> 
 On 6 Sep 2016, at 14:08, Hugi Thordarson  wrote:
 
 This was exactly what happened when the old  was missing.You’re 
 sure it’s in place?
 
 - hugi
 
 
 
> On 6. sep. 2016, at 12:34, Mark Wardle  wrote:
> 
> I can now build my application on the command-line using maven and it is 
> packaged beautifully!
> 
> It isn’t quite right from eclipse. I can run a newly created application 
> from within eclipse, but when I try to run a migrated application, I get 
> this error:
> 
>  java.lang.ExceptionInInitializerError
>at 
> com.webobjects.appserver.WOResourceManager.__getJavaWebObjectsResourceAsStream(WOResourceManager.java:116)
>at 
> com.webobjects.appserver._private.WOProperties.initUserDefaultsKeys(WOProperties.java:317)
>at 
> com.webobjects.appserver.WOApplication._initWOApp(WOApplication.java:5743)
>at 
> com.webobjects.appserver.WOApplication.(WOApplication.java:779)
>at 
> er.extensions.appserver.ajax.ERXAjaxApplication.(ERXAjaxApplication.java:30)
>at 
> er.extensions.appserver.ERXApplication.(ERXApplication.java:1135)
>at com.eldrix.news.app.Application.(Application.java:66)
>at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native 
> Method)
>at 
> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
>at 
> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
>at java.lang.reflect.Constructor.newInstance(Constructor.java:408)
>at java.lang.Class.newInstance(Class.java:438)
>at com.webobjects.appserver.WOApplication.main(WOApplication.java:547)
>at er.extensions.appserver.ERXApplication.main(ERXApplication.java:890)
>at com.eldrix.news.app.Application.main(Application.java:63)
> Caused by: java.lang.NullPointerException
>at 
> er.extensions.appserver.ERXApplication$Loader.collectMainProps(ERXApplication.java:757)
>at 
> er.extensions.appserver.ERXApplication$Loader.bundleDidLoad(ERXApplication.java:682)
>at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
>at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>at java.lang.reflect.Method.invoke(Method.java:483)
>at 
> com.webobjects.foundation.NSSelector._safeInvokeMethod(NSSelector.java:122)
>at 
> com.webobjects.foundation.NSNotificationCenter$_Entry.invokeMethod(NSNotificationCenter.java:588)
>at 
> com.webobjects.foundation.NSNotificationCenter.postNotification(NSNotificationCenter.java:532)
>at 
> com.webobjects.foundation.NSNotificationCenter.postNotification(NSNotificationCenter.java:562)
>at 
> com.webobjects.foundation.NSBundle.postNotification(NSBundle.java:2546)
>at 
> com.webobjects.foundati

Re: Maven and eclipse #2 - problem with missing bundle? null mainBundleName()

2016-09-08 Thread Hugi Thordarson
I feel your pain, the migration was a chore at first. I’ve ported ~30 projects 
and they all made it in the end. Don’t hesitate to ask if you’d like more hands 
on assistance—I love helping people migrate to Maven :).

- hugi



> On 8. sep. 2016, at 19:55, Mark Wardle  wrote:
> 
> Thank you! I did try this and it just wouldn't work with different errors 
> running from eclipse (as above) and at command-line (odd JDBC no connection 
> errors as if no connection dictionary was present). I have temporarily given 
> up and will try again for a new project. I have also upgraded to eclipse neon 
> and wolips which seems to have less odd errors with opening eomodel files 
> than before. 
> 
> Mark
> On Tue, 6 Sep 2016 at 14:26, Hugi Thordarson  wrote:
> Compare your .project and build.properties with those of a new Maven project. 
> Specifically make sure build.properties has:
> 
> classes.dir=target/classes
> 
> …and then make sure your .project file contains the maven builder. In fact, 
> your .project should probably look exactly like this, apart from the project 
> name:
> 
> https://gist.github.com/hugith/6612765b2449b4ab98ec64ea54fd433c
> 
> - hugi
> 
> 
> 
> 
> > On 6. sep. 2016, at 13:19, Mark Wardle  wrote:
> >
> > Definitely!
> >
> > As a potential solution, I am going to create a new empty application and 
> > copy across the code and components and other resources and see what 
> > happens.
> >
> > Mark
> >
> >
> >> On 6 Sep 2016, at 14:08, Hugi Thordarson  wrote:
> >>
> >> This was exactly what happened when the old  was missing.You’re 
> >> sure it’s in place?
> >>
> >> - hugi
> >>
> >>
> >>
> >>> On 6. sep. 2016, at 12:34, Mark Wardle  wrote:
> >>>
> >>> I can now build my application on the command-line using maven and it is 
> >>> packaged beautifully!
> >>>
> >>> It isn’t quite right from eclipse. I can run a newly created application 
> >>> from within eclipse, but when I try to run a migrated application, I get 
> >>> this error:
> >>>
> >>>  java.lang.ExceptionInInitializerError
> >>> at 
> >>> com.webobjects.appserver.WOResourceManager.__getJavaWebObjectsResourceAsStream(WOResourceManager.java:116)
> >>> at 
> >>> com.webobjects.appserver._private.WOProperties.initUserDefaultsKeys(WOProperties.java:317)
> >>> at 
> >>> com.webobjects.appserver.WOApplication._initWOApp(WOApplication.java:5743)
> >>> at 
> >>> com.webobjects.appserver.WOApplication.(WOApplication.java:779)
> >>> at 
> >>> er.extensions.appserver.ajax.ERXAjaxApplication.(ERXAjaxApplication.java:30)
> >>> at 
> >>> er.extensions.appserver.ERXApplication.(ERXApplication.java:1135)
> >>> at com.eldrix.news.app.Application.(Application.java:66)
> >>> at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native 
> >>> Method)
> >>> at 
> >>> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
> >>> at 
> >>> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
> >>> at java.lang.reflect.Constructor.newInstance(Constructor.java:408)
> >>> at java.lang.Class.newInstance(Class.java:438)
> >>> at com.webobjects.appserver.WOApplication.main(WOApplication.java:547)
> >>> at 
> >>> er.extensions.appserver.ERXApplication.main(ERXApplication.java:890)
> >>> at com.eldrix.news.app.Application.main(Application.java:63)
> >>> Caused by: java.lang.NullPointerException
> >>> at 
> >>> er.extensions.appserver.ERXApplication$Loader.collectMainProps(ERXApplication.java:757)
> >>> at 
> >>> er.extensions.appserver.ERXApplication$Loader.bundleDidLoad(ERXApplication.java:682)
> >>> at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
> >>> at 
> >>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> >>> at java.lang.reflect.Method.invoke(Method.java:483)
> >>> at 
> >>> com.webobjects.foundation.NSSelector._safeInvokeMethod(NSSelector.java:122)
> >>> at 
> >>> com.webobjects.foundation.NSNotificationCenter$_Entry.invokeMethod(NSNotificationCenter.java:588)
> >>> at 
> >>> com.webobjects.foundation.NSNotificationCenter.postNotification(NSNotificationCenter.java:532)
> >>> at 
> >>> com.webobjects.foundation.NSNotificationCenter.postNotification(NSNotificationCenter.java:562)
> >>> at 
> >>> com.webobjects.foundation.NSBundle.postNotification(NSBundle.java:2546)
> >>> at 
> >>> com.webobjects.foundation.NSBundle.LoadBundlesFromJars(NSBundle.java:735)
> >>> at com.webobjects.foundation.NSBundle.(NSBundle.java:345)
> >>> ... 15 more
> >>>
> >>> java.lang.NullPointerException
> >>> at 
> >>> er.extensions.appserver.ERXShutdownHook$1.run(ERXShutdownHook.java:64)
> >>>
> >>> I have ensured that I have the correct .project file. It looks as if 
> >>> NSProperties._mainBundleName(); is returning null.
> >>>
> >>> This doesn’t occur when building and running from the command-line. I 
> >>> have tried a clean, 

Re: Maven and eclipse #2 - problem with missing bundle? null mainBundleName()

2016-09-08 Thread Mark Wardle
Thank you! I did try this and it just wouldn't work with different errors
running from eclipse (as above) and at command-line (odd JDBC no connection
errors as if no connection dictionary was present). I have temporarily
given up and will try again for a new project. I have also upgraded to
eclipse neon and wolips which seems to have less odd errors with opening
eomodel files than before.

Mark
On Tue, 6 Sep 2016 at 14:26, Hugi Thordarson  wrote:

> Compare your .project and build.properties with those of a new Maven
> project. Specifically make sure build.properties has:
>
> classes.dir=target/classes
>
> …and then make sure your .project file contains the maven builder. In
> fact, your .project should probably look exactly like this, apart from the
> project name:
>
> https://gist.github.com/hugith/6612765b2449b4ab98ec64ea54fd433c
>
> - hugi
>
>
>
>
> > On 6. sep. 2016, at 13:19, Mark Wardle  wrote:
> >
> > Definitely!
> >
> > As a potential solution, I am going to create a new empty application
> and copy across the code and components and other resources and see what
> happens.
> >
> > Mark
> >
> >
> >> On 6 Sep 2016, at 14:08, Hugi Thordarson  wrote:
> >>
> >> This was exactly what happened when the old  was missing.You’re
> sure it’s in place?
> >>
> >> - hugi
> >>
> >>
> >>
> >>> On 6. sep. 2016, at 12:34, Mark Wardle  wrote:
> >>>
> >>> I can now build my application on the command-line using maven and it
> is packaged beautifully!
> >>>
> >>> It isn’t quite right from eclipse. I can run a newly created
> application from within eclipse, but when I try to run a migrated
> application, I get this error:
> >>>
> >>>  java.lang.ExceptionInInitializerError
> >>> at
> com.webobjects.appserver.WOResourceManager.__getJavaWebObjectsResourceAsStream(WOResourceManager.java:116)
> >>> at
> com.webobjects.appserver._private.WOProperties.initUserDefaultsKeys(WOProperties.java:317)
> >>> at
> com.webobjects.appserver.WOApplication._initWOApp(WOApplication.java:5743)
> >>> at
> com.webobjects.appserver.WOApplication.(WOApplication.java:779)
> >>> at
> er.extensions.appserver.ajax.ERXAjaxApplication.(ERXAjaxApplication.java:30)
> >>> at
> er.extensions.appserver.ERXApplication.(ERXApplication.java:1135)
> >>> at com.eldrix.news.app.Application.(Application.java:66)
> >>> at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
> Method)
> >>> at
> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
> >>> at
> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
> >>> at java.lang.reflect.Constructor.newInstance(Constructor.java:408)
> >>> at java.lang.Class.newInstance(Class.java:438)
> >>> at
> com.webobjects.appserver.WOApplication.main(WOApplication.java:547)
> >>> at
> er.extensions.appserver.ERXApplication.main(ERXApplication.java:890)
> >>> at com.eldrix.news.app.Application.main(Application.java:63)
> >>> Caused by: java.lang.NullPointerException
> >>> at
> er.extensions.appserver.ERXApplication$Loader.collectMainProps(ERXApplication.java:757)
> >>> at
> er.extensions.appserver.ERXApplication$Loader.bundleDidLoad(ERXApplication.java:682)
> >>> at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
> >>> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> >>> at java.lang.reflect.Method.invoke(Method.java:483)
> >>> at
> com.webobjects.foundation.NSSelector._safeInvokeMethod(NSSelector.java:122)
> >>> at
> com.webobjects.foundation.NSNotificationCenter$_Entry.invokeMethod(NSNotificationCenter.java:588)
> >>> at
> com.webobjects.foundation.NSNotificationCenter.postNotification(NSNotificationCenter.java:532)
> >>> at
> com.webobjects.foundation.NSNotificationCenter.postNotification(NSNotificationCenter.java:562)
> >>> at
> com.webobjects.foundation.NSBundle.postNotification(NSBundle.java:2546)
> >>> at
> com.webobjects.foundation.NSBundle.LoadBundlesFromJars(NSBundle.java:735)
> >>> at com.webobjects.foundation.NSBundle.(NSBundle.java:345)
> >>> ... 15 more
> >>>
> >>> java.lang.NullPointerException
> >>> at
> er.extensions.appserver.ERXShutdownHook$1.run(ERXShutdownHook.java:64)
> >>>
> >>> I have ensured that I have the correct .project file. It looks as if
> NSProperties._mainBundleName(); is returning null.
> >>>
> >>> This doesn’t occur when building and running from the command-line. I
> have tried a clean, refresh and maven refresh with no fix.
> >>>
> >>> Mark
> >>>
> >>> ___
> >>> 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/hugi%40karlmenn.is
> >>>
> >>> This email sent to h...@karlmenn.is
> >>
> >
>
>

Re: Maven and eclipse #2 - problem with missing bundle? null mainBundleName()

2016-09-06 Thread Hugi Thordarson
Compare your .project and build.properties with those of a new Maven project. 
Specifically make sure build.properties has:

classes.dir=target/classes

…and then make sure your .project file contains the maven builder. In fact, 
your .project should probably look exactly like this, apart from the project 
name:

https://gist.github.com/hugith/6612765b2449b4ab98ec64ea54fd433c

- hugi




> On 6. sep. 2016, at 13:19, Mark Wardle  wrote:
> 
> Definitely! 
> 
> As a potential solution, I am going to create a new empty application and 
> copy across the code and components and other resources and see what happens.
> 
> Mark
> 
> 
>> On 6 Sep 2016, at 14:08, Hugi Thordarson  wrote:
>> 
>> This was exactly what happened when the old  was missing.You’re sure 
>> it’s in place?
>> 
>> - hugi
>> 
>> 
>> 
>>> On 6. sep. 2016, at 12:34, Mark Wardle  wrote:
>>> 
>>> I can now build my application on the command-line using maven and it is 
>>> packaged beautifully! 
>>> 
>>> It isn’t quite right from eclipse. I can run a newly created application 
>>> from within eclipse, but when I try to run a migrated application, I get 
>>> this error:
>>> 
>>>  java.lang.ExceptionInInitializerError
>>> at 
>>> com.webobjects.appserver.WOResourceManager.__getJavaWebObjectsResourceAsStream(WOResourceManager.java:116)
>>> at 
>>> com.webobjects.appserver._private.WOProperties.initUserDefaultsKeys(WOProperties.java:317)
>>> at 
>>> com.webobjects.appserver.WOApplication._initWOApp(WOApplication.java:5743)
>>> at com.webobjects.appserver.WOApplication.(WOApplication.java:779)
>>> at 
>>> er.extensions.appserver.ajax.ERXAjaxApplication.(ERXAjaxApplication.java:30)
>>> at 
>>> er.extensions.appserver.ERXApplication.(ERXApplication.java:1135)
>>> at com.eldrix.news.app.Application.(Application.java:66)
>>> at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
>>> at 
>>> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
>>> at 
>>> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
>>> at java.lang.reflect.Constructor.newInstance(Constructor.java:408)
>>> at java.lang.Class.newInstance(Class.java:438)
>>> at com.webobjects.appserver.WOApplication.main(WOApplication.java:547)
>>> at er.extensions.appserver.ERXApplication.main(ERXApplication.java:890)
>>> at com.eldrix.news.app.Application.main(Application.java:63)
>>> Caused by: java.lang.NullPointerException
>>> at 
>>> er.extensions.appserver.ERXApplication$Loader.collectMainProps(ERXApplication.java:757)
>>> at 
>>> er.extensions.appserver.ERXApplication$Loader.bundleDidLoad(ERXApplication.java:682)
>>> at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
>>> at 
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>>> at java.lang.reflect.Method.invoke(Method.java:483)
>>> at 
>>> com.webobjects.foundation.NSSelector._safeInvokeMethod(NSSelector.java:122)
>>> at 
>>> com.webobjects.foundation.NSNotificationCenter$_Entry.invokeMethod(NSNotificationCenter.java:588)
>>> at 
>>> com.webobjects.foundation.NSNotificationCenter.postNotification(NSNotificationCenter.java:532)
>>> at 
>>> com.webobjects.foundation.NSNotificationCenter.postNotification(NSNotificationCenter.java:562)
>>> at 
>>> com.webobjects.foundation.NSBundle.postNotification(NSBundle.java:2546)
>>> at 
>>> com.webobjects.foundation.NSBundle.LoadBundlesFromJars(NSBundle.java:735)
>>> at com.webobjects.foundation.NSBundle.(NSBundle.java:345)
>>> ... 15 more
>>> 
>>> java.lang.NullPointerException
>>> at 
>>> er.extensions.appserver.ERXShutdownHook$1.run(ERXShutdownHook.java:64)
>>> 
>>> I have ensured that I have the correct .project file. It looks as if 
>>> NSProperties._mainBundleName(); is returning null.
>>> 
>>> This doesn’t occur when building and running from the command-line. I have 
>>> tried a clean, refresh and maven refresh with no fix.
>>> 
>>> Mark
>>> 
>>> ___
>>> 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/hugi%40karlmenn.is
>>> 
>>> This email sent to h...@karlmenn.is
>> 
> 


 ___
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

Re: Maven and eclipse #2 - problem with missing bundle? null mainBundleName()

2016-09-06 Thread Mark Wardle
Definitely! 

As a potential solution, I am going to create a new empty application and copy 
across the code and components and other resources and see what happens.

Mark


> On 6 Sep 2016, at 14:08, Hugi Thordarson  wrote:
> 
> This was exactly what happened when the old  was missing.You’re sure 
> it’s in place?
> 
> - hugi
> 
> 
> 
>> On 6. sep. 2016, at 12:34, Mark Wardle  wrote:
>> 
>> I can now build my application on the command-line using maven and it is 
>> packaged beautifully! 
>> 
>> It isn’t quite right from eclipse. I can run a newly created application 
>> from within eclipse, but when I try to run a migrated application, I get 
>> this error:
>> 
>>  java.lang.ExceptionInInitializerError
>>  at 
>> com.webobjects.appserver.WOResourceManager.__getJavaWebObjectsResourceAsStream(WOResourceManager.java:116)
>>  at 
>> com.webobjects.appserver._private.WOProperties.initUserDefaultsKeys(WOProperties.java:317)
>>  at 
>> com.webobjects.appserver.WOApplication._initWOApp(WOApplication.java:5743)
>>  at com.webobjects.appserver.WOApplication.(WOApplication.java:779)
>>  at 
>> er.extensions.appserver.ajax.ERXAjaxApplication.(ERXAjaxApplication.java:30)
>>  at 
>> er.extensions.appserver.ERXApplication.(ERXApplication.java:1135)
>>  at com.eldrix.news.app.Application.(Application.java:66)
>>  at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
>>  at 
>> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
>>  at 
>> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
>>  at java.lang.reflect.Constructor.newInstance(Constructor.java:408)
>>  at java.lang.Class.newInstance(Class.java:438)
>>  at com.webobjects.appserver.WOApplication.main(WOApplication.java:547)
>>  at er.extensions.appserver.ERXApplication.main(ERXApplication.java:890)
>>  at com.eldrix.news.app.Application.main(Application.java:63)
>> Caused by: java.lang.NullPointerException
>>  at 
>> er.extensions.appserver.ERXApplication$Loader.collectMainProps(ERXApplication.java:757)
>>  at 
>> er.extensions.appserver.ERXApplication$Loader.bundleDidLoad(ERXApplication.java:682)
>>  at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
>>  at 
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>>  at java.lang.reflect.Method.invoke(Method.java:483)
>>  at 
>> com.webobjects.foundation.NSSelector._safeInvokeMethod(NSSelector.java:122)
>>  at 
>> com.webobjects.foundation.NSNotificationCenter$_Entry.invokeMethod(NSNotificationCenter.java:588)
>>  at 
>> com.webobjects.foundation.NSNotificationCenter.postNotification(NSNotificationCenter.java:532)
>>  at 
>> com.webobjects.foundation.NSNotificationCenter.postNotification(NSNotificationCenter.java:562)
>>  at 
>> com.webobjects.foundation.NSBundle.postNotification(NSBundle.java:2546)
>>  at 
>> com.webobjects.foundation.NSBundle.LoadBundlesFromJars(NSBundle.java:735)
>>  at com.webobjects.foundation.NSBundle.(NSBundle.java:345)
>>  ... 15 more
>> 
>> java.lang.NullPointerException
>>  at 
>> er.extensions.appserver.ERXShutdownHook$1.run(ERXShutdownHook.java:64)
>> 
>> I have ensured that I have the correct .project file. It looks as if 
>> NSProperties._mainBundleName(); is returning null.
>> 
>> This doesn’t occur when building and running from the command-line. I have 
>> tried a clean, refresh and maven refresh with no fix.
>> 
>> Mark
>> 
>> ___
>> 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/hugi%40karlmenn.is
>> 
>> This email sent to h...@karlmenn.is
> 


 ___
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

Re: Maven and eclipse #2 - problem with missing bundle? null mainBundleName()

2016-09-06 Thread Hugi Thordarson
This was exactly what happened when the old  was missing.You’re sure 
it’s in place?

- hugi



> On 6. sep. 2016, at 12:34, Mark Wardle  wrote:
> 
> I can now build my application on the command-line using maven and it is 
> packaged beautifully! 
> 
> It isn’t quite right from eclipse. I can run a newly created application from 
> within eclipse, but when I try to run a migrated application, I get this 
> error:
> 
>  java.lang.ExceptionInInitializerError
>   at 
> com.webobjects.appserver.WOResourceManager.__getJavaWebObjectsResourceAsStream(WOResourceManager.java:116)
>   at 
> com.webobjects.appserver._private.WOProperties.initUserDefaultsKeys(WOProperties.java:317)
>   at 
> com.webobjects.appserver.WOApplication._initWOApp(WOApplication.java:5743)
>   at com.webobjects.appserver.WOApplication.(WOApplication.java:779)
>   at 
> er.extensions.appserver.ajax.ERXAjaxApplication.(ERXAjaxApplication.java:30)
>   at 
> er.extensions.appserver.ERXApplication.(ERXApplication.java:1135)
>   at com.eldrix.news.app.Application.(Application.java:66)
>   at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
>   at 
> sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
>   at 
> sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
>   at java.lang.reflect.Constructor.newInstance(Constructor.java:408)
>   at java.lang.Class.newInstance(Class.java:438)
>   at com.webobjects.appserver.WOApplication.main(WOApplication.java:547)
>   at er.extensions.appserver.ERXApplication.main(ERXApplication.java:890)
>   at com.eldrix.news.app.Application.main(Application.java:63)
> Caused by: java.lang.NullPointerException
>   at 
> er.extensions.appserver.ERXApplication$Loader.collectMainProps(ERXApplication.java:757)
>   at 
> er.extensions.appserver.ERXApplication$Loader.bundleDidLoad(ERXApplication.java:682)
>   at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
>   at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>   at java.lang.reflect.Method.invoke(Method.java:483)
>   at 
> com.webobjects.foundation.NSSelector._safeInvokeMethod(NSSelector.java:122)
>   at 
> com.webobjects.foundation.NSNotificationCenter$_Entry.invokeMethod(NSNotificationCenter.java:588)
>   at 
> com.webobjects.foundation.NSNotificationCenter.postNotification(NSNotificationCenter.java:532)
>   at 
> com.webobjects.foundation.NSNotificationCenter.postNotification(NSNotificationCenter.java:562)
>   at 
> com.webobjects.foundation.NSBundle.postNotification(NSBundle.java:2546)
>   at 
> com.webobjects.foundation.NSBundle.LoadBundlesFromJars(NSBundle.java:735)
>   at com.webobjects.foundation.NSBundle.(NSBundle.java:345)
>   ... 15 more
> 
> java.lang.NullPointerException
>   at 
> er.extensions.appserver.ERXShutdownHook$1.run(ERXShutdownHook.java:64)
> 
> I have ensured that I have the correct .project file. It looks as if 
> NSProperties._mainBundleName(); is returning null.
> 
> This doesn’t occur when building and running from the command-line. I have 
> tried a clean, refresh and maven refresh with no fix.
> 
> Mark
> 
> ___
> 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/hugi%40karlmenn.is
> 
> This email sent to h...@karlmenn.is


 ___
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

Maven and eclipse #2 - problem with missing bundle? null mainBundleName()

2016-09-06 Thread Mark Wardle
I can now build my application on the command-line using maven and it is 
packaged beautifully! 

It isn’t quite right from eclipse. I can run a newly created application from 
within eclipse, but when I try to run a migrated application, I get this error:

 java.lang.ExceptionInInitializerError
at 
com.webobjects.appserver.WOResourceManager.__getJavaWebObjectsResourceAsStream(WOResourceManager.java:116)
at 
com.webobjects.appserver._private.WOProperties.initUserDefaultsKeys(WOProperties.java:317)
at 
com.webobjects.appserver.WOApplication._initWOApp(WOApplication.java:5743)
at com.webobjects.appserver.WOApplication.(WOApplication.java:779)
at 
er.extensions.appserver.ajax.ERXAjaxApplication.(ERXAjaxApplication.java:30)
at 
er.extensions.appserver.ERXApplication.(ERXApplication.java:1135)
at com.eldrix.news.app.Application.(Application.java:66)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at 
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at 
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:408)
at java.lang.Class.newInstance(Class.java:438)
at com.webobjects.appserver.WOApplication.main(WOApplication.java:547)
at er.extensions.appserver.ERXApplication.main(ERXApplication.java:890)
at com.eldrix.news.app.Application.main(Application.java:63)
Caused by: java.lang.NullPointerException
at 
er.extensions.appserver.ERXApplication$Loader.collectMainProps(ERXApplication.java:757)
at 
er.extensions.appserver.ERXApplication$Loader.bundleDidLoad(ERXApplication.java:682)
at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:483)
at 
com.webobjects.foundation.NSSelector._safeInvokeMethod(NSSelector.java:122)
at 
com.webobjects.foundation.NSNotificationCenter$_Entry.invokeMethod(NSNotificationCenter.java:588)
at 
com.webobjects.foundation.NSNotificationCenter.postNotification(NSNotificationCenter.java:532)
at 
com.webobjects.foundation.NSNotificationCenter.postNotification(NSNotificationCenter.java:562)
at 
com.webobjects.foundation.NSBundle.postNotification(NSBundle.java:2546)
at 
com.webobjects.foundation.NSBundle.LoadBundlesFromJars(NSBundle.java:735)
at com.webobjects.foundation.NSBundle.(NSBundle.java:345)
... 15 more

java.lang.NullPointerException
at 
er.extensions.appserver.ERXShutdownHook$1.run(ERXShutdownHook.java:64)

I have ensured that I have the correct .project file. It looks as if 
NSProperties._mainBundleName(); is returning null.

This doesn’t occur when building and running from the command-line. I have 
tried a clean, refresh and maven refresh with no fix.

Mark

 ___
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