Monday, August 31, 2020

Re: Is there any way to use GWT 2.9 with Java 11 using Eclipse GWT plugin?

Yeah, we realized that chrome debugger and SDBG are the same, but it's a different world when your debug session is like a desktop application, you don't notice it's a Web application.
I checked the video how to separate the projects but unfortunately we cannot move to maven. 
We are very happy that GWT is not going to die. GWT is a miracle, in compare to other JS libraries. 

Thanks for your response and time.


On Mon, Aug 31, 2020 at 1:43 PM lofid...@gmail.com <lofidewanto@gmail.com> wrote:
... and for development: it is wise to separate your GWT UI project from your server part:
  • Separate the Maven modules: one for server and one for client GWT UI, don't mixed both modules.
  • Develop both modules independently, mock your server to be able to make a fast turn around time for your UI development.
  • Take the result of your client module which are HTML, CSS, JS and put it on the server module to have it deployed. 
So if you are doing this, you could just use the Jetty server which are standard in GWT libs and later you put your result on your "real server" which could be Tomcat or whatever...

I have some examples which use the mechanism above. But for this you should move to Maven: https://github.com/gwtboot/domino-rest-enum-date

IMHO no other way, you need Maven 😉

Hope this helps.
shahra...@gmail.com schrieb am Montag, 31. August 2020 um 03:25:08 UTC+2:
Thanks Thomas for your prompt response, I loaded the old project and added the old jars one by one and after apache commons it started working, I mean it stopped using the gwt-dev.jar libraries.
Now I'm able to load the application with
1)   Eclipse plugin, using the integrated Server jetty-9.2.z-SNAPSHOT, 
2)   AdoptOpenJdk Java 8 
3)   GWT 2.9
4)   SDBG debugger stops at breakpoints, it's interesting that it shows the real variable names like the old times legacy Dev Mode however, it doesn't show the function names :-(
       is there any solution for that because we don't want to use the chrome debugger.

Oh my Goodness,  GWT 2.9 compiler is extremely serious and much faster. We need to add null checks in lots of places because NullPointerException was not a problem for 2.7
it could internally handle it but 2.9 is killing us. It was a great success that we reached this point. The next step is DB migration to oracle 19c.

I would appreciate a solution for SDBG. Another question is how to find and manipulate the CodeServer parameters, we are thinking about replacing Jetty with Tomcat for development.

I appreciate it in advance.
Shahram...





On Fri, Aug 28, 2020 at 7:35 AM Thomas Broyer <t.br...@gmail.com> wrote:
That one's "easy": don't use the embedded Jetty of DevMode; run your own servlet container instead, along with either DevMode in -noserver mode, or CodeServer.

On Thursday, August 27, 2020 at 8:30:45 PM UTC+2, Shahram Zadeh wrote:
after a long time and hard work we were able to make it work up to the successful compilation, now there is a conflict between the integrated apache  xerces in gwt-dev.jar and java 8.
is there any way to force the GWT in dev mode not to use tools in the gwt-dev.jar?

any help would be greatly appreciated.


org.apache.xerces.parsers.XIncludeAwareParserConfiguration cannot be cast to org.apache.xerces.xni.parser.XMLParserConfiguration



java.lang.ClassCastException: org.apache.xerces.parsers.XIncludeAwareParserConfiguration cannot be cast to org.apache.xerces.xni.parser.XMLParserConfiguration
at org.apache.xerces.parsers.SAXParser.<init>(Unknown Source)
at org.apache.xerces.parsers.SAXParser.<init>(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.<init>(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl.<init>(Unknown Source)
at org.apache.xerces.jaxp.SAXParserFactoryImpl.newSAXParser(Unknown Source)
at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.getXMLReader(UnmarshallerImpl.java:144)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:157)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:162)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:171)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:189)
at com.soflytics.rguroo.server.util.ServerUtility.readGUIComponents(ServerUtility.java:175)

On Saturday, August 8, 2020 at 7:11:54 AM UTC-7 frank.h...@web.de wrote:
Use this to generate a multi module artifact:

shahra...@gmail.com schrieb am Freitag, 7. August 2020 um 18:23:52 UTC+2:
is there any documentation for how to set it up, we are not maven oriented. I appreciate a link or document...

On Thu, Aug 6, 2020 at 2:57 PM lofid...@gmail.com <lofid...@gmail.com> wrote:
GWT Eclipse plugin is not maintained anymore... So to use the newest one you could move to pure Maven or Gradle... I only use Maven sofar and it works well...

shahra...@gmail.com schrieb am Dienstag, 28. Juli 2020 um 00:11:58 UTC+2:

We have a huge GWT project (GWT 2.7, JDK 1.7, Eclipse) everything works perfect. We are planning to upgrade to Java 11 and GWT 2.9 which has been recently released. However Java 1.7 is retiring and getting obsolete we have to move on and upgrade. Since last week we are trying to create a development environment like the existing one but there is no success. I was wondering whether anyone out there is struggling with the same issue, any hint, solution or hacking the eclipse plugin would be greatly appreciated.

Eclipse plugin comes with GWT (2.7 and 2.8.1)

--
You received this message because you are subscribed to a topic in the Google Groups "GWT Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-web-toolkit/l_E1Y8XKg7k/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-web-tool...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/c9461274-510c-4661-8a73-28ad39fc35ecn%40googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "GWT Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-web-toolkit/l_E1Y8XKg7k/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-web-tool...@googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "GWT Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-web-toolkit/l_E1Y8XKg7k/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/8839a771-01b9-4bc0-b2da-2a03e8edb9f2n%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/CAGcWJ-cpq4b4kJoQLKBJkNXEoiOttKTSFA2uTAp4hVUyvZsigQ%40mail.gmail.com.

Re: Experiences using event bus

My favorite for EventBus is this framework: https://github.com/google/gwteventbinder 

In combination with the video, IMHO is the easiest framework for EventBus: Google I/O 2013 - Demystifying MVP and EventBus in GWT

Gordan Krešić schrieb am Samstag, 29. August 2020 um 11:21:03 UTC+2:
I would like to ask for any advice/idea on how to use event buses in GWT. So
far I'm using GWT's own com.google.gwt.event.shared.EventBus, but wouldn't
have issues migrating to other implementations.

My concern goes to very cumbersome and error prone handling when to
unregister subscribers to allow them to be garbage collected. I'm aware of
ResettableEventBus, but it doesn't solve problems when I don't have clear
events to unregister whole classes of subscribers (if I'm not mistaken, it
was designed to be used inside single Activity and unregister all
subscribers when activity stops, but that flow doesn't work for me, because
I need subscribers active even when they are not in current activity).

When possible, I'm subscribing to events in "onLoad" event and unsubscribing
in "onUnload", but that also doesn't work in not-that-uncommon corner cases
when I need subscribers active even when detached from DOM.

Only "solution" that works is manually unregistering when I'm sure
subscriber is going away, but as I said, that is very error prone (and beats
the purpose of having a garbage collected language).

WeakReference(s) are not supported. Is there any implementation trying to
utilize JS's WeakMap?

Any other ideas?

-gkresic.

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/0fc1ad95-3d46-4d58-88f2-0acc27cb005an%40googlegroups.com.

Re: Is there any way to use GWT 2.9 with Java 11 using Eclipse GWT plugin?

... and for development: it is wise to separate your GWT UI project from your server part:
  • Separate the Maven modules: one for server and one for client GWT UI, don't mixed both modules.
  • Develop both modules independently, mock your server to be able to make a fast turn around time for your UI development.
  • Take the result of your client module which are HTML, CSS, JS and put it on the server module to have it deployed. 
So if you are doing this, you could just use the Jetty server which are standard in GWT libs and later you put your result on your "real server" which could be Tomcat or whatever...

I have some examples which use the mechanism above. But for this you should move to Maven: https://github.com/gwtboot/domino-rest-enum-date

IMHO no other way, you need Maven 😉

Hope this helps.
shahra...@gmail.com schrieb am Montag, 31. August 2020 um 03:25:08 UTC+2:
Thanks Thomas for your prompt response, I loaded the old project and added the old jars one by one and after apache commons it started working, I mean it stopped using the gwt-dev.jar libraries.
Now I'm able to load the application with
1)   Eclipse plugin, using the integrated Server jetty-9.2.z-SNAPSHOT, 
2)   AdoptOpenJdk Java 8 
3)   GWT 2.9
4)   SDBG debugger stops at breakpoints, it's interesting that it shows the real variable names like the old times legacy Dev Mode however, it doesn't show the function names :-(
       is there any solution for that because we don't want to use the chrome debugger.

Oh my Goodness,  GWT 2.9 compiler is extremely serious and much faster. We need to add null checks in lots of places because NullPointerException was not a problem for 2.7
it could internally handle it but 2.9 is killing us. It was a great success that we reached this point. The next step is DB migration to oracle 19c.

I would appreciate a solution for SDBG. Another question is how to find and manipulate the CodeServer parameters, we are thinking about replacing Jetty with Tomcat for development.

I appreciate it in advance.
Shahram...





On Fri, Aug 28, 2020 at 7:35 AM Thomas Broyer <t.br...@gmail.com> wrote:
That one's "easy": don't use the embedded Jetty of DevMode; run your own servlet container instead, along with either DevMode in -noserver mode, or CodeServer.

On Thursday, August 27, 2020 at 8:30:45 PM UTC+2, Shahram Zadeh wrote:
after a long time and hard work we were able to make it work up to the successful compilation, now there is a conflict between the integrated apache  xerces in gwt-dev.jar and java 8.
is there any way to force the GWT in dev mode not to use tools in the gwt-dev.jar?

any help would be greatly appreciated.


org.apache.xerces.parsers.XIncludeAwareParserConfiguration cannot be cast to org.apache.xerces.xni.parser.XMLParserConfiguration



java.lang.ClassCastException: org.apache.xerces.parsers.XIncludeAwareParserConfiguration cannot be cast to org.apache.xerces.xni.parser.XMLParserConfiguration
at org.apache.xerces.parsers.SAXParser.<init>(Unknown Source)
at org.apache.xerces.parsers.SAXParser.<init>(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.<init>(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl.<init>(Unknown Source)
at org.apache.xerces.jaxp.SAXParserFactoryImpl.newSAXParser(Unknown Source)
at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.getXMLReader(UnmarshallerImpl.java:144)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:157)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:162)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:171)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:189)
at com.soflytics.rguroo.server.util.ServerUtility.readGUIComponents(ServerUtility.java:175)

On Saturday, August 8, 2020 at 7:11:54 AM UTC-7 frank.h...@web.de wrote:
Use this to generate a multi module artifact:

shahra...@gmail.com schrieb am Freitag, 7. August 2020 um 18:23:52 UTC+2:
is there any documentation for how to set it up, we are not maven oriented. I appreciate a link or document...

On Thu, Aug 6, 2020 at 2:57 PM lofid...@gmail.com <lofid...@gmail.com> wrote:
GWT Eclipse plugin is not maintained anymore... So to use the newest one you could move to pure Maven or Gradle... I only use Maven sofar and it works well...

shahra...@gmail.com schrieb am Dienstag, 28. Juli 2020 um 00:11:58 UTC+2:

We have a huge GWT project (GWT 2.7, JDK 1.7, Eclipse) everything works perfect. We are planning to upgrade to Java 11 and GWT 2.9 which has been recently released. However Java 1.7 is retiring and getting obsolete we have to move on and upgrade. Since last week we are trying to create a development environment like the existing one but there is no success. I was wondering whether anyone out there is struggling with the same issue, any hint, solution or hacking the eclipse plugin would be greatly appreciated.

Eclipse plugin comes with GWT (2.7 and 2.8.1)

--
You received this message because you are subscribed to a topic in the Google Groups "GWT Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-web-toolkit/l_E1Y8XKg7k/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-web-tool...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/c9461274-510c-4661-8a73-28ad39fc35ecn%40googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "GWT Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-web-toolkit/l_E1Y8XKg7k/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-web-tool...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/8839a771-01b9-4bc0-b2da-2a03e8edb9f2n%40googlegroups.com.

Re: Is there any way to use GWT 2.9 with Java 11 using Eclipse GWT plugin?

Hi, great to hear that you managed to move to GWT 2.9...

AFAIK, SDBG is implemented based on Chrome, so actually it is the same whether you use Chrome or SDBG in Eclipse, only it looks more integrated in Eclipse 😀 

shahra...@gmail.com schrieb am Montag, 31. August 2020 um 03:25:08 UTC+2:
Thanks Thomas for your prompt response, I loaded the old project and added the old jars one by one and after apache commons it started working, I mean it stopped using the gwt-dev.jar libraries.
Now I'm able to load the application with
1)   Eclipse plugin, using the integrated Server jetty-9.2.z-SNAPSHOT, 
2)   AdoptOpenJdk Java 8 
3)   GWT 2.9
4)   SDBG debugger stops at breakpoints, it's interesting that it shows the real variable names like the old times legacy Dev Mode however, it doesn't show the function names :-(
       is there any solution for that because we don't want to use the chrome debugger.

Oh my Goodness,  GWT 2.9 compiler is extremely serious and much faster. We need to add null checks in lots of places because NullPointerException was not a problem for 2.7
it could internally handle it but 2.9 is killing us. It was a great success that we reached this point. The next step is DB migration to oracle 19c.

I would appreciate a solution for SDBG. Another question is how to find and manipulate the CodeServer parameters, we are thinking about replacing Jetty with Tomcat for development.

I appreciate it in advance.
Shahram...





On Fri, Aug 28, 2020 at 7:35 AM Thomas Broyer <t.br...@gmail.com> wrote:
That one's "easy": don't use the embedded Jetty of DevMode; run your own servlet container instead, along with either DevMode in -noserver mode, or CodeServer.

On Thursday, August 27, 2020 at 8:30:45 PM UTC+2, Shahram Zadeh wrote:
after a long time and hard work we were able to make it work up to the successful compilation, now there is a conflict between the integrated apache  xerces in gwt-dev.jar and java 8.
is there any way to force the GWT in dev mode not to use tools in the gwt-dev.jar?

any help would be greatly appreciated.


org.apache.xerces.parsers.XIncludeAwareParserConfiguration cannot be cast to org.apache.xerces.xni.parser.XMLParserConfiguration



java.lang.ClassCastException: org.apache.xerces.parsers.XIncludeAwareParserConfiguration cannot be cast to org.apache.xerces.xni.parser.XMLParserConfiguration
at org.apache.xerces.parsers.SAXParser.<init>(Unknown Source)
at org.apache.xerces.parsers.SAXParser.<init>(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.<init>(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl.<init>(Unknown Source)
at org.apache.xerces.jaxp.SAXParserFactoryImpl.newSAXParser(Unknown Source)
at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.getXMLReader(UnmarshallerImpl.java:144)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:157)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:162)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:171)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:189)
at com.soflytics.rguroo.server.util.ServerUtility.readGUIComponents(ServerUtility.java:175)

On Saturday, August 8, 2020 at 7:11:54 AM UTC-7 frank.h...@web.de wrote:
Use this to generate a multi module artifact:

shahra...@gmail.com schrieb am Freitag, 7. August 2020 um 18:23:52 UTC+2:
is there any documentation for how to set it up, we are not maven oriented. I appreciate a link or document...

On Thu, Aug 6, 2020 at 2:57 PM lofid...@gmail.com <lofid...@gmail.com> wrote:
GWT Eclipse plugin is not maintained anymore... So to use the newest one you could move to pure Maven or Gradle... I only use Maven sofar and it works well...

shahra...@gmail.com schrieb am Dienstag, 28. Juli 2020 um 00:11:58 UTC+2:

We have a huge GWT project (GWT 2.7, JDK 1.7, Eclipse) everything works perfect. We are planning to upgrade to Java 11 and GWT 2.9 which has been recently released. However Java 1.7 is retiring and getting obsolete we have to move on and upgrade. Since last week we are trying to create a development environment like the existing one but there is no success. I was wondering whether anyone out there is struggling with the same issue, any hint, solution or hacking the eclipse plugin would be greatly appreciated.

Eclipse plugin comes with GWT (2.7 and 2.8.1)

--
You received this message because you are subscribed to a topic in the Google Groups "GWT Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-web-toolkit/l_E1Y8XKg7k/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-web-tool...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/c9461274-510c-4661-8a73-28ad39fc35ecn%40googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "GWT Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-web-toolkit/l_E1Y8XKg7k/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-web-tool...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/0b26a3d4-103c-47b8-abd5-4360b00ebafbn%40googlegroups.com.

Re: CustomEvent examples

On 28. 08. 2020. 23:28, Thomas Broyer wrote:
>
> https://developer.mozilla.org/en-US/docs/Web/Guide/Events/Creating_and_triggering_events
>
> The second example would be coded as:
>
> CustomEventInit<Double>eventInit =CustomEventInit.create();
> eventInit.setDetail(time);
> CustomEventevent=newCustomEvent("build",eventInit);

With the exception of CustomEventInit not being generic, this code works,
thanks Thomas.

In an example of event to signal that particular user is saved, this is what
I got working:

Declarations:

public static final String SavedEventType = "saved";

Init:

addEventListener(SavedEventType, this::onSaved);

Dispatch:

public void save(User user) {
CustomEventInit eventInit = CustomEventInit.create();
eventInit.setDetail(user);
eventInit.setBubbles(false);
CustomEvent event = new CustomEvent(SavedEventType, eventInit);
dispatchEvent(event);
}

Listener:

public void onSaved(Event event) {
CustomEvent customEvent = (CustomEvent) event;
User user = (User) customEvent.detail;
Log.info("User is " + user.getId());
}

Looks very fragile, especially if I decide to use complex details in which
case I'll have to expose internal structure of that field.

IMHO, best solution would be to extend CustomEvent, but I didn't find a way
to do so (as least not in a way to be able to *receive* instances of that
descended class, not even using Js.uncheckedCast, which, to my understanding
of JsInterop, is not even possible), so this is best I got:

public class SavedEvent {

public static final String Type = SavedEvent.class.getName();

@JsType(isNative = true, name = "CustomEventInit", namespace =
JsPackage.GLOBAL)
public static interface Init extends CustomEventInit {

@JsOverlay
static SavedEvent.Init create() {
SavedEvent.Init init = Js.uncheckedCast(CustomEventInit.create());
init.setBubbles(false);
return init;
}

@JsOverlay
default User getUser() {
return (User) getDetail();
}

@JsOverlay
default SavedEvent.Init setUser(User user) {
setDetail(user);
return this;
}

@JsOverlay
default CustomEvent event() {
return new CustomEvent(SavedEvent.Type, this);
}

}

public interface Listener extends EventListener {
default void handleEvent(Event event) {
handleEvent(new SavedEvent(event));
}
void handleEvent(SavedEvent event);
}

public SavedEvent(Event nativeEvent) {

// add at least some safety...
if (!(nativeEvent instanceof CustomEvent) || !Type.equals(nativeEvent.type))
throw new IllegalArgumentException();

this.nativeEvent = (CustomEvent) nativeEvent;

}

public CustomEvent getNativeEvent() {
return nativeEvent;
}

public User getUser() {
return (User) nativeEvent.detail;
}

private final CustomEvent nativeEvent;

}

Which contains a lot of boilerplate wrappers, but at least now dispatchers
and listeners (which are exposed to users) looks more decent:

addEventListener(SavedEvent.Type, this::onSaved);

public void save(User user) {
dispatchEvent(SavedEvent.Init.create().setUser(user).event());
}

public void onSaved(SavedEvent event) {
Log.info("Saved user is " + event.getUser().getId());
}

Any suggestions for further simplifications when working with specialized
events?

-gkresic.

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/20399da1-6fbe-d6a0-2514-26414a8e40a8%40steatoda.com.

Sunday, August 30, 2020

Re: Is there any way to use GWT 2.9 with Java 11 using Eclipse GWT plugin?

Thanks Thomas for your prompt response, I loaded the old project and added the old jars one by one and after apache commons it started working, I mean it stopped using the gwt-dev.jar libraries.
Now I'm able to load the application with
1)   Eclipse plugin, using the integrated Server jetty-9.2.z-SNAPSHOT, 
2)   AdoptOpenJdk Java 8 
3)   GWT 2.9
4)   SDBG debugger stops at breakpoints, it's interesting that it shows the real variable names like the old times legacy Dev Mode however, it doesn't show the function names :-(
       is there any solution for that because we don't want to use the chrome debugger.

Oh my Goodness,  GWT 2.9 compiler is extremely serious and much faster. We need to add null checks in lots of places because NullPointerException was not a problem for 2.7
it could internally handle it but 2.9 is killing us. It was a great success that we reached this point. The next step is DB migration to oracle 19c.

I would appreciate a solution for SDBG. Another question is how to find and manipulate the CodeServer parameters, we are thinking about replacing Jetty with Tomcat for development.

I appreciate it in advance.
Shahram...





On Fri, Aug 28, 2020 at 7:35 AM Thomas Broyer <t.broyer@gmail.com> wrote:
That one's "easy": don't use the embedded Jetty of DevMode; run your own servlet container instead, along with either DevMode in -noserver mode, or CodeServer.

On Thursday, August 27, 2020 at 8:30:45 PM UTC+2, Shahram Zadeh wrote:
after a long time and hard work we were able to make it work up to the successful compilation, now there is a conflict between the integrated apache  xerces in gwt-dev.jar and java 8.
is there any way to force the GWT in dev mode not to use tools in the gwt-dev.jar?

any help would be greatly appreciated.


org.apache.xerces.parsers.XIncludeAwareParserConfiguration cannot be cast to org.apache.xerces.xni.parser.XMLParserConfiguration



java.lang.ClassCastException: org.apache.xerces.parsers.XIncludeAwareParserConfiguration cannot be cast to org.apache.xerces.xni.parser.XMLParserConfiguration
at org.apache.xerces.parsers.SAXParser.<init>(Unknown Source)
at org.apache.xerces.parsers.SAXParser.<init>(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.<init>(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl.<init>(Unknown Source)
at org.apache.xerces.jaxp.SAXParserFactoryImpl.newSAXParser(Unknown Source)
at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.getXMLReader(UnmarshallerImpl.java:144)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:157)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:162)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:171)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:189)
at com.soflytics.rguroo.server.util.ServerUtility.readGUIComponents(ServerUtility.java:175)

On Saturday, August 8, 2020 at 7:11:54 AM UTC-7 frank.h...@web.de wrote:
Use this to generate a multi module artifact:

shahra...@gmail.com schrieb am Freitag, 7. August 2020 um 18:23:52 UTC+2:
is there any documentation for how to set it up, we are not maven oriented. I appreciate a link or document...

On Thu, Aug 6, 2020 at 2:57 PM lofid...@gmail.com <lofid...@gmail.com> wrote:
GWT Eclipse plugin is not maintained anymore... So to use the newest one you could move to pure Maven or Gradle... I only use Maven sofar and it works well...

shahra...@gmail.com schrieb am Dienstag, 28. Juli 2020 um 00:11:58 UTC+2:

We have a huge GWT project (GWT 2.7, JDK 1.7, Eclipse) everything works perfect. We are planning to upgrade to Java 11 and GWT 2.9 which has been recently released. However Java 1.7 is retiring and getting obsolete we have to move on and upgrade. Since last week we are trying to create a development environment like the existing one but there is no success. I was wondering whether anyone out there is struggling with the same issue, any hint, solution or hacking the eclipse plugin would be greatly appreciated.

Eclipse plugin comes with GWT (2.7 and 2.8.1)

--
You received this message because you are subscribed to a topic in the Google Groups "GWT Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-web-toolkit/l_E1Y8XKg7k/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-web-tool...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/c9461274-510c-4661-8a73-28ad39fc35ecn%40googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "GWT Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-web-toolkit/l_E1Y8XKg7k/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/177cdccf-afc9-4f61-a82a-3eec44074bd9o%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/CAGcWJ-cDk8iMDtbqBB_4AveCCV-M5qkEayuPi5cZXtpjr%3DDpKg%40mail.gmail.com.

Re: Experiences using event bus

On 30. 08. 2020. 02:19, Thomas Broyer wrote:
>
> A WeakRef would be the only way, other than implementing explicit
> reference-counting.

Bump, didn't even know for WeakRef, tnx.

Support isn't great:

https://caniuse.com/#search=WeakRef

but at least it opens a door for better bus implementation in (hopefully)
not-too-distant future.

-gkresic.

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/b4c499fa-c826-d1f1-bf07-dc20f2fbaa33%40steatoda.com.

Saturday, August 29, 2020

Re: Experiences using event bus

WeakMap and WeakSet aren't iterable, you cannot discover what they contain, you have to know and can only check if it's in the map/set and for a map get its associated value. This is of no use for an event bus wanting to keep weak references to its handlers.

A WeakRef would be the only way, other than implementing explicit reference-counting.

On Saturday, August 29, 2020 at 11:21:03 AM UTC+2, Gordan Krešić wrote:
I would like to ask for any advice/idea on how to use event buses in GWT. So
far I'm using GWT's own com.google.gwt.event.shared.EventBus, but wouldn't
have issues migrating to other implementations.

My concern goes to very cumbersome and error prone handling when to
unregister subscribers to allow them to be garbage collected. I'm aware of
ResettableEventBus, but it doesn't solve problems when I don't have clear
events to unregister whole classes of subscribers (if I'm not mistaken, it
was designed to be used inside single Activity and unregister all
subscribers when activity stops, but that flow doesn't work for me, because
I need subscribers active even when they are not in current activity).

When possible, I'm subscribing to events in "onLoad" event and unsubscribing
in "onUnload", but that also doesn't work in not-that-uncommon corner cases
when I need subscribers active even when detached from DOM.

Only "solution" that works is manually unregistering when I'm sure
subscriber is going away, but as I said, that is very error prone (and beats
the purpose of having a garbage collected language).

WeakReference(s) are not supported. Is there any implementation trying to
utilize JS's WeakMap?

Any other ideas?

        -gkresic.

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/320e677e-41d8-4a89-bd5d-9554bbb8b936o%40googlegroups.com.

Experiences using event bus

I would like to ask for any advice/idea on how to use event buses in GWT. So
far I'm using GWT's own com.google.gwt.event.shared.EventBus, but wouldn't
have issues migrating to other implementations.

My concern goes to very cumbersome and error prone handling when to
unregister subscribers to allow them to be garbage collected. I'm aware of
ResettableEventBus, but it doesn't solve problems when I don't have clear
events to unregister whole classes of subscribers (if I'm not mistaken, it
was designed to be used inside single Activity and unregister all
subscribers when activity stops, but that flow doesn't work for me, because
I need subscribers active even when they are not in current activity).

When possible, I'm subscribing to events in "onLoad" event and unsubscribing
in "onUnload", but that also doesn't work in not-that-uncommon corner cases
when I need subscribers active even when detached from DOM.

Only "solution" that works is manually unregistering when I'm sure
subscriber is going away, but as I said, that is very error prone (and beats
the purpose of having a garbage collected language).

WeakReference(s) are not supported. Is there any implementation trying to
utilize JS's WeakMap?

Any other ideas?

-gkresic.

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/f10fc578-8096-0109-9b7b-a27cdd3fac8f%40steatoda.com.

Friday, August 28, 2020

Re: CustomEvent examples



On Friday, August 28, 2020 at 7:29:37 PM UTC+2, Gordan Krešić wrote:
Are there any examples/best cases of using elemental2.dom.CustomEvent in GWT
2.9?

https://developer.mozilla.org/en-US/docs/Web/Guide/Events/Creating_and_triggering_events

The second example would be coded as:

CustomEventInit<Double> eventInit = CustomEventInit.create();
eventInit
.setDetail(time);
CustomEvent event = new CustomEvent("build", eventInit);


--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/247ae12b-6576-4eb3-a043-dd6f6b543894o%40googlegroups.com.

CustomEvent examples

Are there any examples/best cases of using elemental2.dom.CustomEvent in GWT
2.9?

My primary use case is to use it as a replacement for GwtEvent in elemental2
components.

-gkresic.

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/2967a73c-5840-0b49-fa92-05395cb236dc%40steatoda.com.

Re: Is there any way to use GWT 2.9 with Java 11 using Eclipse GWT plugin?

That one's "easy": don't use the embedded Jetty of DevMode; run your own servlet container instead, along with either DevMode in -noserver mode, or CodeServer.

On Thursday, August 27, 2020 at 8:30:45 PM UTC+2, Shahram Zadeh wrote:
after a long time and hard work we were able to make it work up to the successful compilation, now there is a conflict between the integrated apache  xerces in gwt-dev.jar and java 8.
is there any way to force the GWT in dev mode not to use tools in the gwt-dev.jar?

any help would be greatly appreciated.


org.apache.xerces.parsers.XIncludeAwareParserConfiguration cannot be cast to org.apache.xerces.xni.parser.XMLParserConfiguration



java.lang.ClassCastException: org.apache.xerces.parsers.XIncludeAwareParserConfiguration cannot be cast to org.apache.xerces.xni.parser.XMLParserConfiguration
at org.apache.xerces.parsers.SAXParser.<init>(Unknown Source)
at org.apache.xerces.parsers.SAXParser.<init>(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.<init>(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl.<init>(Unknown Source)
at org.apache.xerces.jaxp.SAXParserFactoryImpl.newSAXParser(Unknown Source)
at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.getXMLReader(UnmarshallerImpl.java:144)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:157)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:162)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:171)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:189)
at com.soflytics.rguroo.server.util.ServerUtility.readGUIComponents(ServerUtility.java:175)

On Saturday, August 8, 2020 at 7:11:54 AM UTC-7 frank.h...@web.de wrote:
Use this to generate a multi module artifact:

shahra...@gmail.com schrieb am Freitag, 7. August 2020 um 18:23:52 UTC+2:
is there any documentation for how to set it up, we are not maven oriented. I appreciate a link or document...

On Thu, Aug 6, 2020 at 2:57 PM lofid...@gmail.com <lofid...@gmail.com> wrote:
GWT Eclipse plugin is not maintained anymore... So to use the newest one you could move to pure Maven or Gradle... I only use Maven sofar and it works well...

shahra...@gmail.com schrieb am Dienstag, 28. Juli 2020 um 00:11:58 UTC+2:

We have a huge GWT project (GWT 2.7, JDK 1.7, Eclipse) everything works perfect. We are planning to upgrade to Java 11 and GWT 2.9 which has been recently released. However Java 1.7 is retiring and getting obsolete we have to move on and upgrade. Since last week we are trying to create a development environment like the existing one but there is no success. I was wondering whether anyone out there is struggling with the same issue, any hint, solution or hacking the eclipse plugin would be greatly appreciated.

Eclipse plugin comes with GWT (2.7 and 2.8.1)

--
You received this message because you are subscribed to a topic in the Google Groups "GWT Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-web-toolkit/l_E1Y8XKg7k/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-web-tool...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/c9461274-510c-4661-8a73-28ad39fc35ecn%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/177cdccf-afc9-4f61-a82a-3eec44074bd9o%40googlegroups.com.

Experiences using event bus

I would like to ask for any advice/idea on how to use event buses in GWT. So
far I'm using GWT's own com.google.gwt.event.shared.EventBus, but wouldn't
have issues migrating to other implementations.

My concern goes to very cumbersome and error prone handling when to
unregister subscribers to allow them to be garbage collected. I'm aware of
ResettableEventBus, but it doesn't solve problems when I don't have clear
events to unregister whole classes of subscribers (if I'm not mistaken, it
was designed to be used inside single Activity and unregister all
subscribers when activity stops, but that flow doesn't work for me, because
I need subscribers active even when they are not in current activity).

When possible, I'm subscribing to events in "onLoad" event and unsubscribing
in "onUnload", but that also doesn't work in not-that-uncommon corner cases
when I need subscribers active even when detached from DOM.

Only "solution" that works is manually unregistering when I'm sure
subscriber is going away, but as I said, that is very error prone (and beats
the purpose of having a garbage collected language).

WeakReference(s) are not supported. Is there any implementation trying to
utilize JS's WeakMap?

Any other ideas?

--
Gordan Krešić
Steatoda d.o.o.
mailto:gordan.kresic@steatoda.com
tel:// +385 1 38 32 456
mob:// +385 91 514 9112

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/a4327ce5-011d-c85a-1028-641028e2fad1%40steatoda.com.

Thursday, August 27, 2020

Re: Is there any way to use GWT 2.9 with Java 11 using Eclipse GWT plugin?

after a long time and hard work we were able to make it work up to the successful compilation, now there is a conflict between the integrated apache  xerces in gwt-dev.jar and java 8.
is there any way to force the GWT in dev mode not to use tools in the gwt-dev.jar?

any help would be greatly appreciated.


org.apache.xerces.parsers.XIncludeAwareParserConfiguration cannot be cast to org.apache.xerces.xni.parser.XMLParserConfiguration



java.lang.ClassCastException: org.apache.xerces.parsers.XIncludeAwareParserConfiguration cannot be cast to org.apache.xerces.xni.parser.XMLParserConfiguration
at org.apache.xerces.parsers.SAXParser.<init>(Unknown Source)
at org.apache.xerces.parsers.SAXParser.<init>(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.<init>(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl.<init>(Unknown Source)
at org.apache.xerces.jaxp.SAXParserFactoryImpl.newSAXParser(Unknown Source)
at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.getXMLReader(UnmarshallerImpl.java:144)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:157)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:162)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:171)
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:189)
at com.soflytics.rguroo.server.util.ServerUtility.readGUIComponents(ServerUtility.java:175)

On Saturday, August 8, 2020 at 7:11:54 AM UTC-7 frank.h...@web.de wrote:
Use this to generate a multi module artifact:

shahra...@gmail.com schrieb am Freitag, 7. August 2020 um 18:23:52 UTC+2:
is there any documentation for how to set it up, we are not maven oriented. I appreciate a link or document...

On Thu, Aug 6, 2020 at 2:57 PM lofid...@gmail.com <lofid...@gmail.com> wrote:
GWT Eclipse plugin is not maintained anymore... So to use the newest one you could move to pure Maven or Gradle... I only use Maven sofar and it works well...

shahra...@gmail.com schrieb am Dienstag, 28. Juli 2020 um 00:11:58 UTC+2:

We have a huge GWT project (GWT 2.7, JDK 1.7, Eclipse) everything works perfect. We are planning to upgrade to Java 11 and GWT 2.9 which has been recently released. However Java 1.7 is retiring and getting obsolete we have to move on and upgrade. Since last week we are trying to create a development environment like the existing one but there is no success. I was wondering whether anyone out there is struggling with the same issue, any hint, solution or hacking the eclipse plugin would be greatly appreciated.

Eclipse plugin comes with GWT (2.7 and 2.8.1)

--
You received this message because you are subscribed to a topic in the Google Groups "GWT Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-web-toolkit/l_E1Y8XKg7k/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-web-tool...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/c9461274-510c-4661-8a73-28ad39fc35ecn%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/6752e676-39d1-48e7-b156-4049ab254c54n%40googlegroups.com.

Re: EMF with GWT and serialize problems


Thanks for your help. I don't understand this sentence " Also if you do not transfer RequirementImpl directly but instead an interface that RequirementImpl implements, then GWT Compiler needs to see the class+source of RequirementImpl so it can treat RequirementImpl as a possible concrete type that might be transferred. " What do you understand?

What I meant is that you might not use RequirementImpl directly as a field type if RequirementImpl implements an interface. For example it you have 

interface Requirement extends Serializable {

}

class RequirementImpl implements Requirement {
 
...
}

class SomeClassToTransferWithGWT implements Serializable {
 
private Requirement requirement;

 
....
}



then RequirementImpl must be visible to the GWT compiler.

 
I had also read stuff on whiteList but I don't understand what means this WhiteList? Do you know this?

Whitelist is just the list of classes that GWT-RPC allows to transfer. It is generated by GWT by looking at the classes reachable from your GWT-RPC service. To add something explicitly to the "whitelist" you need to add a new dummy method to your GWT-RPC service that uses the classes you want to add to the whitelist as parameter or return type.


-- J. 

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/c5559280-75ee-44e7-ac3f-38f838dc2b4do%40googlegroups.com.

Wednesday, August 26, 2020

Re: How to start with GWT upgrade from version 2.1.0 to 2.9.0, (java 1.6 to java 1.8)

If its ok for you to stay with GXT2, then just use gxt 2.3.1a.jar which usually should work out of the box also with 2.8 and 2.9. 
For me(fairly complex project) with 2.8 and 2.9 I had some minor problems which I change my self directly inside the source and recompiled the jar.

Hope this helps!

p.s moving to gxt3 or gxt4 would be a lot of rewrite!!

On Tuesday, August 25, 2020 at 6:24:15 PM UTC+2 t.br...@gmail.com wrote:


On Tuesday, August 25, 2020 at 5:49:38 PM UTC+2, Hari wrote:
Thank you all for the quick response, from all the responses its general that it will not be complete re-write, which is a relief for sure. 

Also I forgot to mention we were using GXT 2.2.1 and as per this doc https://docs.sencha.com/gxt/4.x/guides/getting_started/Versions.html in order to use GWT 2.9 i will have to use GXT4.x, so i made the SDK changes and tried to build the application, with minimal changes to *.GWT.xml file, i am running into below build error.

Updating GXT is another matter, AFAICT this is not easy, as they made a lot of breaking changes. Also, it's likely that the app will change visually. Oh, and licensing.
(I've never used GXT, so can't really help)

But if your goal is only/primarily to update to Java 8, have you tried whether it's possible without bumping GWT at all? or possibly not all the way to 2.8/2.9? (e.g. 2.6, which is still compatible with GXT 2, as of 2.3.1a)
 

[java]    [ERROR] Hint: Check that your module inherits 'com.google.gwt.core.Core' either directly or indirectly (most often by inheriting module 'com.google.gwt.user.User')

Googling around on this error for some time now, but no luck. can anyone here please help me with this.
Also are there any other things that need to be taken care of when upgrading to gxt to 4.x? 

Thanks
Hari

On Tuesday, August 25, 2020 at 7:44:36 PM UTC+5:30 t.br...@gmail.com wrote:


On Tuesday, August 25, 2020 at 1:01:47 PM UTC+2, Hari wrote:
Hi Team,

(Apologies if the answers to my question are based on individuals opinion based, but i am in dire need of your help)

I am currently stuck with an old GWT 2.1.0 application written in Java 1.6 which needs to be updated to java 1.8, so we are planning to upgrade to latest GWT version 2.9.0. There are no changes to the application code or any new enhancement request in last 5 years, considering this our client is expecting no changes to look and feel of the application but from the compliance perspective we are required to upgrade to at least Java 1.8.

But i have no experience and never used GWT, and there are very few guides out there on upgrade from 2.1.0 to 2.9.0 (I know its a big jump). Can someone help me understand, how to start the upgrade process, and how much code changes would i need to make the application compatible with the new version, will it be complete re-wright of the UI component of the application? or will it be minor changes to existing code ? Finally, if the upgrade requires complete re writing of UI component, is it worth it for me to lean GWT (considering recent slow down in upgrades to GWT) and uses it in the upgrade instead of complete rewrite of UI in React.

It depends on your dependencies.
GWT 2.2 had a breaking change for some third-party libraries (using GWT generators, by turning some abstract classes into interfaces), so make sure you also update your third-party libraries.
Otherwise, things should work without too much breakage AFAICT, and should also look the same (again, depending on the additional libraries the project uses).
See http://www.gwtproject.org/release-notes.html (and yes, the breaking change in 2.2 is not documented there ¯\_(ツ)_/¯ )

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/736c071e-31f6-46bb-a7d7-bd71f0443f0dn%40googlegroups.com.

Re: EMF with GWT and serialize problems

HI Jens,

Thanks for your help. I don't understand this sentence " Also if you do not transfer RequirementImpl directly but instead an interface that RequirementImpl implements, then GWT Compiler needs to see the class+source of RequirementImpl so it can treat RequirementImpl as a possible concrete type that might be transferred. " What do you understand?
I had also read stuff on whiteList but I don't understand what means this WhiteList? Do you know this?

Regards
Antonio

Le mercredi 26 août 2020 à 09:29:33 UTC+2, Jens a écrit :
RequirementImpl must implement serializable, needs to have a default constructor (visibility does not matter), no final fields and there must be at least one serializable type found for each field that can be assigned to that field (which must meet the same requirements). Also if you do not transfer RequirementImpl directly but instead an interface that RequirementImpl implements, then GWT Compiler needs to see the class+source of RequirementImpl so it can treat RequirementImpl as a possible concrete type that might be transferred. 

Have you double checked these requirements? 

-- J.


Am Dienstag, 25. August 2020 17:11:53 UTC+2 schrieb Guillen Antonio:
HI all,

I use GWT 2.81 and EMF (Eclipse Modeling Framework) when i want send from the server to the client an object of my model, I obtain this final error:
com.google.gwt.user.client.rpc.SerializationException: Type 'com.lacen.organisation.impl.RequirementImpl' was not included in the set of types which can be serialized by this SerializationPolicy or its Class object could not be loaded. For security purposes, this type will not be serialized.: instance = com.lacen.organisation.impl.RequirementImpl@2fa144e7 (name: Fkygrdphgf)

I have tried to understand how to use serializationWhitelist but I have no clear example.  The class RequirementImpl contains List, so I tried to create ArrayList with the good type, but same pb.

Can you help me, at least give me where found a claer explanation.

Tanks a lot
Antonio Guillen

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/11cc2432-8e51-4921-84c6-af035a12c17dn%40googlegroups.com.

Re: EMF with GWT and serialize problems

RequirementImpl must implement serializable, needs to have a default constructor (visibility does not matter), no final fields and there must be at least one serializable type found for each field that can be assigned to that field (which must meet the same requirements). Also if you do not transfer RequirementImpl directly but instead an interface that RequirementImpl implements, then GWT Compiler needs to see the class+source of RequirementImpl so it can treat RequirementImpl as a possible concrete type that might be transferred. 

Have you double checked these requirements? 

-- J.


Am Dienstag, 25. August 2020 17:11:53 UTC+2 schrieb Guillen Antonio:
HI all,

I use GWT 2.81 and EMF (Eclipse Modeling Framework) when i want send from the server to the client an object of my model, I obtain this final error:
com.google.gwt.user.client.rpc.SerializationException: Type 'com.lacen.organisation.impl.RequirementImpl' was not included in the set of types which can be serialized by this SerializationPolicy or its Class object could not be loaded. For security purposes, this type will not be serialized.: instance = com.lacen.organisation.impl.RequirementImpl@2fa144e7 (name: Fkygrdphgf)

I have tried to understand how to use serializationWhitelist but I have no clear example.  The class RequirementImpl contains List, so I tried to create ArrayList with the good type, but same pb.

Can you help me, at least give me where found a claer explanation.

Tanks a lot
Antonio Guillen

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/a9d2d1f0-8352-4b8c-a59d-60f743ddbbaao%40googlegroups.com.

Tuesday, August 25, 2020

Re: How to start with GWT upgrade from version 2.1.0 to 2.9.0, (java 1.6 to java 1.8)



On Tuesday, August 25, 2020 at 5:49:38 PM UTC+2, Hari wrote:
Thank you all for the quick response, from all the responses its general that it will not be complete re-write, which is a relief for sure. 

Also I forgot to mention we were using GXT 2.2.1 and as per this doc https://docs.sencha.com/gxt/4.x/guides/getting_started/Versions.html in order to use GWT 2.9 i will have to use GXT4.x, so i made the SDK changes and tried to build the application, with minimal changes to *.GWT.xml file, i am running into below build error.

Updating GXT is another matter, AFAICT this is not easy, as they made a lot of breaking changes. Also, it's likely that the app will change visually. Oh, and licensing.
(I've never used GXT, so can't really help)

But if your goal is only/primarily to update to Java 8, have you tried whether it's possible without bumping GWT at all? or possibly not all the way to 2.8/2.9? (e.g. 2.6, which is still compatible with GXT 2, as of 2.3.1a)
 

[java]    [ERROR] Hint: Check that your module inherits 'com.google.gwt.core.Core' either directly or indirectly (most often by inheriting module 'com.google.gwt.user.User')

Googling around on this error for some time now, but no luck. can anyone here please help me with this.
Also are there any other things that need to be taken care of when upgrading to gxt to 4.x? 

Thanks
Hari

On Tuesday, August 25, 2020 at 7:44:36 PM UTC+5:30 t.br...@gmail.com wrote:


On Tuesday, August 25, 2020 at 1:01:47 PM UTC+2, Hari wrote:
Hi Team,

(Apologies if the answers to my question are based on individuals opinion based, but i am in dire need of your help)

I am currently stuck with an old GWT 2.1.0 application written in Java 1.6 which needs to be updated to java 1.8, so we are planning to upgrade to latest GWT version 2.9.0. There are no changes to the application code or any new enhancement request in last 5 years, considering this our client is expecting no changes to look and feel of the application but from the compliance perspective we are required to upgrade to at least Java 1.8.

But i have no experience and never used GWT, and there are very few guides out there on upgrade from 2.1.0 to 2.9.0 (I know its a big jump). Can someone help me understand, how to start the upgrade process, and how much code changes would i need to make the application compatible with the new version, will it be complete re-wright of the UI component of the application? or will it be minor changes to existing code ? Finally, if the upgrade requires complete re writing of UI component, is it worth it for me to lean GWT (considering recent slow down in upgrades to GWT) and uses it in the upgrade instead of complete rewrite of UI in React.

It depends on your dependencies.
GWT 2.2 had a breaking change for some third-party libraries (using GWT generators, by turning some abstract classes into interfaces), so make sure you also update your third-party libraries.
Otherwise, things should work without too much breakage AFAICT, and should also look the same (again, depending on the additional libraries the project uses).
See http://www.gwtproject.org/release-notes.html (and yes, the breaking change in 2.2 is not documented there ¯\_(ツ)_/¯ )

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-web-toolkit/02d5b2bc-b700-4ca2-b712-74a6f29a16aeo%40googlegroups.com.