Ast Lavond

Greenhorn
+ Follow
since Mar 02, 2010
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Ast Lavond

hello together,

can anyone tell me, why i can't run this code in jboss 5.1.
the same code works for jboss 5.0 and locally as java application, but in jboss 5.1. there is no log output.






so i think my logger extension is correct and something have changed in jboss 5.1 (this code also doesn't run on jboss 6.0).
maybe my log4j.properties file is in conflict with some jboss settings?




i'm thankful for any ideas!
12 years ago
Hi Cesar,

that was the mistake, now all runs great.
Thanks a lot for your help!

Best Regards
Ast
12 years ago
JSF
Hello Cesar,

thanks for your reply. I found the Problem:

In Eclipse you can build web and enterprise archive projects by adding them to server (right click on the project -> run as -> run on server -> now you can choose the specific server instance -> the archive will be generated in your deploy folder).

So now the strange thing:
In my case the WAR archive will be generated (with all packages), but the java files in the source folder will not be considered. I’ve tried to build the archive again: Now in the server view -> I stated an incremental / full publish of the project -> without success.
But If I run an POJO with a main methode in the same Package, all other POJOs will be compiled and updated to the archive.

-> In future I will build my applications with ant ;)

Unfortunately my Applications runs only with the User.java as Managed Bean (with Annotations or defined in faces-config.xml):

...Managed Bean with Annotations:


...or Managed Bean defined in faces-config.xml:




Injection doesn’t work (javax.el.PropertyNotFoundException):



12 years ago
JSF
Hello together,

I want to run a very simple JSF 2 example, but it ends always in this error:
javax.el.PropertyNotFoundException: /index.xhtml @12,39 value="#{user.name}": Target Unreachable, identifier 'user' resolved to null

After searching I found a lot of links with similar problems. For example:

https://coderanch.com/t/505989/JSF/java/Error#2284390
https://coderanch.com/t/502157/JSF/java/JSF-Spring-managing-beans#2264029

But in my case it doesn't help.

I’ve created a Dynamic Web Project in Eclipse Helios based on the Target runtime “JBoss 6.0 Runtime” and with the JSF 2.0 Configuration.
The Java Build Path contains the following libraries:
- JBoss 6.0 Runtime (with all needed jars provided by jBoss)
- JRE System Library [JVM 1.6.0]


After that I've created these files:

User.java:


index.xhtml:


greet.xhtml


web.xml


I also tested the user.java class with the @ManagedBean annotation and with the corresponding faces-config.xml settings. -> with no success.
Do you have a solution?
12 years ago
JSF
…Many thanks for the information.
I use the reference implementation from jBoss as persistence provider.
A seam application runs on this Application Server. It’s a CRUD Application and users have the option to search for data in the database schema “xy”.

Now I would like to implement an extended search → user can also search for archived data on schema “xyHistory”. This is done at runtime.
The results are two Lists. List A contains the data from schema “xy” and List B contains the data from “xyHistory”.
In JDBC I would open two database connections….

Unfortunately I’m not as well familiar with JPA.

You could use two different persistence units and use XML for both or one to change the schema.



Can I switch to the other schema with persistence units at runtime?
It’s not enough to use a second entity manager?

There is a default schema in the orm.xml, potentially you could use the same annotation and just give a mostly empty orm.xml with a different default schema.



Sorry, I don’t understand this. At the moment there isn’t a orm.xml in my Project.
An example code would be very helpful.
Hi,

is it possible to use the same Entity for two Database Schemas?
Both Schemas ("schema" and "schemaHistory") are identical. The Database Schema "schema" contains all current data and "schemaHistory" all the data, which were archived.

Width JDBC, it’s no problem. But I like to use the defined Entities.
Can you tell the Entity Manager which Schema and DataSource he should use?
The @Table(schema=”…”) annotation is probably not needed?

Thanks!
lanvond

Hi,

Is it possible to set an different style for each ui:define tag?
I would like to have a class or style attribute to set the width of an element:

For example:

Or another attempt:

In both cases, the style can not be set.
Maybe it’s possible to set the style with an <ui:param> tag?
13 years ago
JSF
many thanks for the replys.

Simran Dass wrote:
Because we need to implement the interface from out of the package also.



That's why i'm confused, because the default access (which is provided for classes and interfaces) allows only package visibility. So why not a protected access?

Larry Olson wrote:
Sometimes it seems like we have to accept things blindly without questioning them...unfortunately.



You're right. Either public access or default access, a in-between is not needed.
Hello together,

you can declare an Interface public and with default acces (accessed only if the class is in the same package).
Why isn't it possible to declare an Interface protected, so that only classes and interfaces in the same package or interfaces which extends other interfaces, can use the members of the protected interface?

kind regards
lavond
sorry for the posting error:

Caller method:


The method which will be called:


perhaps also interesting, i get the following warning:

...
09:34:42,278 INFO [STDOUT] 4. close report
09:34:42,294 INFO [STDOUT] nex Report...
09:34:45,341 WARN [arjLoggerI18N] [com.arjuna.ats.arjuna.coordinator.TransactionReaper_18] - TransactionReaper::check timeout for TX a0d3507:860:4ba9cc70:81 in state RUN
09:34:45,372 WARN [arjLoggerI18N] [com.arjuna.ats.arjuna.coordinator.BasicAction_58] - Abort of action id a0d3507:860:4ba9cc70:81 invoked while multiple threads active within it.
09:34:45,372 WARN [arjLoggerI18N] [com.arjuna.ats.arjuna.coordinator.CheckedAction_2] - CheckedAction::check - atomic action a0d3507:860:4ba9cc70:81 aborting with 1 threads active!
09:34:45,372 WARN [arjLoggerI18N] [com.arjuna.ats.arjuna.coordinator.TransactionReaper_7] - TransactionReaper::doCancellations worker Thread[Thread-12,5,jboss] successfully canceled TX a0d3507:860:4ba9cc70:81

Is it possible that the transaction get an timeout or something like that?
hello forum,

i have an application which generates at least one report. If more reports should be generated the method "execute" will be called in a loop.
Only the values of the parameters are variable.

Caller method:


The method which will be called:


The first report will always generated without any problems. But if i try to generate the second report, nothing happened -> the application server (JBoss) stops and the gui get no response. I have to kill the eclipse/java process.
The curious thing is, this issue occurs after the generation of the first report.
And also in the birt log is no error:

23.03.2010 16:33:05 org.eclipse.birt.data.engine.impl.DataEngineImpl shutdown
FEINER: ENTRY
23.03.2010 16:33:05 org.eclipse.birt.data.engine.odaconsumer close
FEINER: ENTRY
23.03.2010 16:33:05 org.eclipse.birt.report.data.oda.jdbc.Connection close
FEIN: Connection closed.
23.03.2010 16:33:05 org.eclipse.birt.data.engine.odaconsumer close
FEINER: RETURN
23.03.2010 16:33:05 org.eclipse.birt.data.engine.odaconsumer close
FEINER: ENTRY
23.03.2010 16:33:05 org.eclipse.birt.report.data.oda.jdbc.Connection close
FEIN: Connection closed.
23.03.2010 16:33:05 org.eclipse.birt.data.engine.odaconsumer close
FEINER: RETURN
23.03.2010 16:33:06 org.eclipse.birt.data.engine.impl.DataEngineImpl shutdown
FEIN: Data engine shuts down
23.03.2010 16:33:09 org.eclipse.birt.data.engine.impl.DataEngineImpl shutdown
FEINER: RETURN

Why is the process stoped?
And why is not the source code completely processed?

Is that a functional requirement? It's obviously possible technically.


Yes, it's a functional requirement.

You mean "LiveConnect" with JavaScript?
Yes.



So far I have not tried the LiveConnect with JavaScript.

JMF supports playback of Flash version 2 files


Do you mean SWF files, which were created with Flash CS2?


It is not so easy to integrate a Flash movie in an applet.
Thanks for your help!
13 years ago

Flash is generally embedded in HTML, but the "is placed to the applet" part is unclear - do you mean the Flash movie is located visually next to the applet?


No. The Java applet containing Swing components, and I mean that it may be possible to use a Swing component in order to integrate the Flash movie in the Applet (like the JFlashPlayer object for a Java Application -> in my first post).
Maybe you can also use a Swing component that supports html to embed the Flash movie as <object> tag in html code (like the WebBrowser object in this example: embedding a web browser in java).

Both applet ans Flash content would be part of the same HTML page.


The Flash movie can not be placed next to the applet and in my opinion to put the Flash movie in a layer over the applet is very ugly.

Would the approach I outlined in my previous post work?


You mean "LiveConnect" with JavaScript?
13 years ago
Thanks for the fast reply!

By "implement html code in a applet" I believe that the flash movie is embedded in HTML (html and flash) and is placed (for example in an HTML container) to the applet.

You have absolutely right, I would also prefer to do everything in Flash / Flex, but for this project I need to use the applet.

Sorry for my bad english ;)
13 years ago
The Java applet already exists, so I can't use other technologies such as html or use JSPs.
The Applet contains a form. If the form fields are not completed, it will be displayed in a Flash movie.

It's important to communicate from Java with the ActionsScript Methodes in the Flash movie. -> That is no problem with JavaScript.
But is it possible to implement html-code in a Applet?
So I could integrate the Flash movie in html and use JavaScript to control the communication between Java and ActionScript.
13 years ago