Cannot view project via Enterprise Editor in IBM Rad - eclipse

I think Rad has updated or done something behind the scenes but when I go to open up my project the node that expands says "Security Editor". I cannot edit any file/servlet etc in my project.
When I click on "Security Editor" I get a message stating:
"The Security Editor does not support the use of Security Annotations. All security information must be specified in the deployment descriptor to be displayed and edited with the Security Editor"
I have had a look in application.xml in the EAR file but cannot see what to do?
I am a Websphere newbie and this is my first J2EE project that nearly done. I just don't get whats changed now?

RAD is only warning you that if you define security constraints though the use of annotations, it will not show in the security editor. This prompt can be disabled from the Preferences->Java EE->Security page. You can ignore this and still use the security editor if it is your preferred method of configuring security.

Related

missing profile for a server adapter in Eclipse

I am trying to set up a dynamic web project in Eclipse 2018-12. Within the Java EE perspective, the lower panel is hosting several commonly used views (markers, console, snippets, search ), among which the Servers view offers the possibility to bind the current project to an already existing server.
If no such server is defined, this view is showing a quick link to "add new server. When one is about to define a new server, a creation wizard takes off, and the first window you get is the profile select window. I would like to set up a Tomcat server, but my initial list does not include Apache Tomcat at all.
Question: how am I supposed top populate the initial list with a desired web server profile template ?
I have searched for Eclipse download links and the first link (and the only one shown there) on the Eclipse Foundation page was Eclipse 2018-12. It seemed pretty good at the time. Now the same page shows Eclipse 2019-06 (64-bits).
Upgrading the current intallation with the JST Server Adapter Extensions did the job nicely. Thank you nitind !

Rational Application Developer: find the IDE's location on disk (from within the IDE)

I have an open instance of Rational Application Developer - an eclipse-based IDE developed by IBM. RAD is newly installed, and i haven't yet created a shortcut. So, before closing it, i would like to create a shortcut. The problem is i forgot the place where i installed it. Is there any way, from within the IDE (some of its menus, perhaps), to find the location of the IDE (the .exe file) on disk?
Note 1: unlike eclipse, RAD has no 'Installation Details' under Help menu
Note 2: I already found a way to see the IDE's location: from Start, in the "Search Programs and Files" box, i type "rational" and it shows me the program ; i right click, select Properties, and under the Shortcut tab, the 'Start in' field shows the containing folder of the IDE. However, this only works because the application is pinned to the Start menu. In case I delete the pin accidentally, or the pin is not even created on installation, because i don't check the corresponding box, the question still stands: how to find the IDE's location from within the IDE, not from outside it.
In Eclipse you would go to Help -> Installation Details -> Configuration tab
However, in RAD, there is no Installation Details under Help. Fortunately, it is accessible this way: Help -> About Rational® Application Developer -> Installation Details. Credit goes to greg-449 for pointing this out.
In the Installation Details window, under the Configuration tab, the relevant snippet is the following
-launcher
C:\Users\user_name\IBM_85\SDP\eclipse.exe
as a comparison, in eclipse it would look something like
-launcher
C:\Users\user_name\eclipse-jee-neon-3-win32-x86_64\eclipse\eclipse.exe
this information is also contained in the line starting with eclipse.home.location

JSR-109 Web Services remove in Eclipse

In Eclipse's Project Explorer view there is a project named "JSR-109 Web Services" that can not be deleted or removed.
I did not create this project. It came to Project Explorer by itself.
How do I remove this "JSR-109 Web Services"?
Select "Customize View..." on the Project Explorer view's menu (on the view's upper-right upside-down triangule button).
Select the "Content" tab and uncheck "JSR-109 Web Services Index".
Delete the folder named RemoteSystemsTempFiles in your workspace
JSR-109 Web Services is not a project. Its an implementation standard that ensures that your Web Service maintains the Standards and it (your Service) interoperate with other service there is..
Follow the link for more details.
Eclipse Documentation
and the following link has a work around on removing the same.
uncheck JSR-109 Web Services
really uncheck JSR-109 Web Services

Eclipse gives warning on access restriction for jfxrt.jar classes

I'm using eclipse kepler with java SE 1.8 jdk system library but when I use any javafx classes or methods eclipse gives a warning like Access restriction: The type 'TableColumn<?,?>' is not API (restriction on required library 'C:\Program Files\Java\jdk1.8.0_05\jre\lib\ext\jfxrt.jar').
I have tried adding an access rule to the system library to allow access for all jars in the library using the wildcard * but the warning is still there. Am also using maven for building project.
The code works but the warning is nagging and is affecting readability as I code. Any help is appreciated.
Edit: I also tried adding #SuppressWarnings("restriction") at the beginning of my classes but this still doesn't solve the unknown cause and hides all other restriction warnings that I may need to see
I'm able to get past this by reconfiguring Java library. For example, explicitly selecting Oracle JDK does the trick.
The easy way is to install e(fx)clipse - a plugin for Eclipse to support JavaFX:
Select Help -> Install New Software
Click Add button to add the following site:
Name: efxclipse
Location: http://download.eclipse.org/efxclipse/updates-released/1.2.0/site
Click OK
In the "Work with" dropdown list, select the recently added site "efxclipse"
Check the checkbox "e(fx)clipse - install" to install all components of this selection
Move to next steps to finish the installation
Restart your Eclipse. If it still doesn't recognize JavaFX library, restart it again.
Original information can be found here: https://www.eclipse.org/efxclipse/install.html#for-the-lazy
You can choose ignore in the following settings:
Windows -> Preferences -> Java -> Compiler -> Errors/Warnings
(Project) Properties -> Java Compiler -> Errors/Warnings
Use filter to find "Forbidden reference"
Forbidden reference (access rules) : Change it to "ignore"
Add an access rule to allow access to javafx/**.
See also this answer: https://stackoverflow.com/a/32062263/1060350
For all I can tell, this is a bug in Eclipse in my opinion. I also could not find a way to configure this globally in Eclipse, but you need to redo it for every project.
Navigate to Project settings, Build path, Libraries, JRE. Click on "Access rules" which should have "No rules defined" usually. Add a new rule: "Accessible", and enter the pattern "javafx/**".
This tells the Eclipse Java compiler that javafx.* is an official API that you are allowed to use, so the warning goes away.
Clearly, allowing access to javafx only is much better than ignoring the warning.
The reason why * did not work is because you did not read the wildcard definition. In the access rules, * only matches once, you need ** to match at any depth. I.e. * will allow access to javafx.SomeClass but not not javafx.scene.SomeClass...
Add an access rule for javafx.
Right click your project > Properties > Java Build Path > Libraries tab, then:
Expand JRE System Library
select Access Rules, click Edit... button
click Add...
choose Resolution: Accessible
set Rule Pattern: javafx/**
click OK
click OK

Stop Eclipse restarting my web app on file save

I'm creating a JSF/Facelets web app in Eclipse. I've configured my project to use a Tomcat (6.0) server that is started/stopped by Eclipse.
Whenever I save a file (eg .xhtml) Eclipse restarts the app, trashing my HTTP session. This is annoying, because I'm frequently updating my .xhtml files, and the app doesn't need restarting to detect the changes.
Is there a way to stop Eclipse restarting the app? Specifically, can I configure Eclipse to only restart the app when I save files of a certain type?
In the server View, double click on your Tomcat instance.
This will open the properties of your Tomcat server.
As I am not sure of which parameter will help you to solve your problem, check the following options in the latter view:
Automatic Publishing, option "Override default settings" selected, 1 second for the publishing interval.
In server options, uncheck options "Server modules without publishing" and "publish module contexts to separate XML files".
In the modules tab, for each modules deployed, check that Auto Reload is enabled.
Hope this will help you.
I have always used this and it works fine for me. The context is reloaded only when you change classes or the web descriptor.
In your project structure where you keep .xhtml files which makes eclipse reload the context on changing?
This can happen if you have a builder in Eclipse set to deploy on save. Right click on your project -> properties -> builders
Turn off "Build Automatically"