Class Loader order not able to change - eclipse

I am using IBM RSA 7.5 and Websphere Server 6.1 as a application server.
I am not able to change Class Loader Order dropdown box. It has disable state.
How to enable that. I need to change the item "Classes Loaded with parent class loader first" to "Classes Loaded with application class loader first".

"The classloader options are disabled in the admininstrative console because the application was published in a "loose configuration" manner. What this means is that your application binaries and descriptor files do not reside in the WAS application repository. Since you published them via RAD (which is most likely configured to 'Run with resources in the workspace') then the application binaries exist in the output folders of your various projects and WAS is instructed to read the binaries/descriptor files from that location. As a result, the WAS admin console is not able to make changes to these files so the functionality is disabled.
Here is a document which describes how to can accomplish the task you want when using this publishing mechanism via RAD:
http://publib.boulder.ibm.com/infocenter/radhelp/v7r5/index.jsp?topic=/com.ibm.ws.ast.st.enhanced.ear.doc/topics/tapplicationsv6.html
Using this manner to change the classloader settings results in this information being stored with the application (in the EAR project) so you will no longer need to change it when the application is published to any WAS runtime (i.e. in development or production)."
From the IBM developer help website

I struggled with this one a lot, and even bumped on your question being desperate.
Although i had a different setup,publishing my application from Eclipse, unchecking "Minimize application files copied to the server" in eclipse server config solved the issue for me.

Related

App Engine localhost publication from eclipse-photon

I had been working on Google app engine for some time with great success. However, recently I was forced to upgrade to Eclipse-Photon from Eclipse-Mars.
I can run a debugging version of the server on localhost:8080 just fine except when I change any of the TypeScript files. Formerly when I would run the TypeScript compiler to generate new JavaScript the server would automatically update the server. Now when I generate a new JavaScript file, the server continues to serve the old version. I have my expirations set to 0 and I have automatic publication turned on.
For a while I could make it work by telling the server to Publish. Now that has stopped working as well. If I save any file from inside of Eclipse I see a little message flash by indicating publication and then that file serves properly. If I load the generated JavaScript file and then modify it slightly then it will publish and serve correctly.
Obviously Photon is no longer tracking file changes that way that Mars did. I could easily copy the generated file to the correct place if I knew where that place was.
Are you running your TypeScript compilation from outside of Eclipse? If so, try doing a Refresh of your project. That should sync up Eclipse's notion of the filesystem state with what is on disk.
Cloud Tools for Eclipse relies on the Web Tools and Resources frameworks to determine whether a resource has changed and needs publishing. Eclipse is normally set up to detect resource changes automatically as configured by two options on the Preferences > General > Workspace preference page: Refresh on access and Refresh using native hooks or polling.

ColdFusion Builder 3 vs. Dreamweaver & local and remote paths

I can't wrap my head around how I'm supposed to use ColdFusion Builder 3 (akin to Eclipse).
Up until this point, I've been using Dreamweaver 5, which is getting 'long-in-the-tooth', and I wanted to give CF Builder a try.
So, in Dreamweaver, it's pretty simple: you setup connections to servers using credentials... There's a Local path, which is the local copy of your code, and the webroot of the Server which is the 'live' copy of your code. Basically, you make a change to the local copy, and PUT the change to the Server. Easy peasy lemon squeezy, right?
But, how does this translate to ColdFusion Builder 3?
Just to give you an idea of our infrastructure.... we have Development and Production. Each of these boxes has multiple web instances, example: Accounting, Human Resources, IT. Each of those web instances could have multiple applications.... I'm only considered about my instance, IT, on both the Production and Development servers.
Is a workspace supposed to represent an instance on a web server?
In CFBuilder, should I configure 1 server per web app?
Is a project supposed to represent a web app?
Am I supposed to use drive mappings to the inetpub wwwroot for access to web applications? Is it even considered kosher to have a drive mapping to the web root? \server\c$\inetpub\wwwroot
Where do I keep my local copy of my code?
How do I move items from Development to Production?
My main confusion is with workspaces, projects, and servers... My intent is to debug and 'view page in browser' from CFBuilder.... However, when you setup a server, under Server Mapping and URL Prefix, you're supposed to indicate the Local and Remote paths, plus this is not directly related to the physical location of the project.... and as I've mentioned, there's multiple instances, multiple applications, and the development box is not my local machine, it's a remote server...
I would really like to know how others have made this work for them.
I really don't mind this question even though it's not directly code related because I've been using ColdFusion Builder (CFB) for years and there just isn't enough good documentation out there. I now enjoy a great experience with CFB thanks to blog posts and sharing experiences with other devs :)
My setup: CFB3 running on Windows 8.1, dev server running on a Virtual Machine so it is treated as "remote server" just like yours. I also update remote staging and production servers (although not directly from CFB).
First, let's set some reasonable expectations: Dreamweaver and CFB are very different in that CFB focuses on programming and Dreamweaver on design. CFB is built on eclipse and therefore has the advantage of benefiting from most eclipse plugins.
Your question is specifically about how to set up your projects in CFB using 2 remote servers (dev and prod). It's different for everyone but I'll share my setup with you. (sidenote: My projects are also stored in Git repositories - 1 repo for every app)
Starting from the top: A workspace in CFB deals with your whole eclipse application, not just your projects. The most important things kept in this directory are snippets and plugins. You do NOT need to keep your project files in here. This is merely the main directory where all of your settings are kept. You are not required to have more than 1 workspace (I only have one). Why would you need more than one? You may be multifaceted programmer who needs to keep separate workspaces using separate tools (like different plugins, snippets, window layouts...)
To answer your next question (1 server per web app), all you need to to is configure your dev servers in the "CF Servers" tab. You need to add 1 server per web instance for every instance that you'd like to test on. Hopefully, your dev server has RDS enabled (very helpful for remote database and file viewing, just like in Dreamweaver). During configuration, don't worry about Mappings or Virtual Host Settings (I have another recommendation later). Once configured, you'll be able to assign that server to a project.
Drive mappings: I would never recommend mapping to the webroot of a shared dev server. If you were to use that drive map as your local directory, your changes will be made directly to the development server. What you want to do is create a new project by right clicking in the Navigator area and select Import > Other > FTP. Follow the steps, choose anywhere on your local drive to store the files, then choose "New project" at the end (this will add the .project file necessary for CFB to control the project).
Once the project is created, right click on it, select ColdFusion Project and choose the CFML Dictionary version you'll be using (CF11, 10, 9...). Then, select ColdFusion Server Settings and choose the dev server. This is necessary for testing.
What you now have is a local directory with your app and eclipse knows about the remote server. In order to synchronize, you right click on the project, go to Team and synchronize from there. For detailed information about synchronization over FTP, see the help section "Guide to WebDAV and FTP".
Moving to production is not as simple as it was in Dreamweaver. The FTP configuration information only allows for 1 connection (thus giving you a list of files synchronized between your project and the dev server). Therefore, you'll need a third party FTP client to synchronize between your local project and your prod server.
As promised, my last entry will be able the "debugging" which is why I said to skip the mappings and virtual host settings in CF Server config. I really, really recommend using a third party paid plugin called FusionDebug (http://www.fusion-debug.com/). This plugin facilitates the setup and allows you to step-into all of your code (which doesn't work so well in native CFB). There's a 30 day trial and I recommend you try before your buy (or license for a year in this case!)

Error when updating p2 enabled RCP application in multiuser environment

Is that possible to implement the update of my own p2 enabled RCP application in a way that it will function in multiuser environment. What I want to do is identical to eclipse, I want to have my application installed in a location that is read-only to the user. When the user runs, he gets his own writable location, usually under his home directory. The user can install additional features that are stored under this writable location. How is that possible to do. I tested my application and it doesn't work this way by default, my application tries to download updates fails and keep restarting.
Thank you in advance.
Ulyana
When you deploy your RCP app, follow the steps in Eclipse multi-user installs to create a configuration area that you can make read-only and then run as another user.
In theory it should be something like:
rcp.exe -initialize
make RCP application directory read-only

Speeding up code changes in Eclipse Web Browser?

I'm developing an application using the Vaadin framework in Eclipse. I'm using the Tomcat v6.0 servlet and run the application in the Eclipse Web Browser. A problem I've been having though is to have recent changes show in the browser when I test the application.
No matter how many times I restart Tomcat, clean all published resources and restart the Eclipse Web Browser the changes still won't take effect. The changes seem to take effect randomly where time is the biggest factor, which is of great frustration when developing...
So my question is if anyone else has noticed this problem and have any ideas of how to solve it, if there is a configuration I can do or if I'm missing a step in the restart which blocks the changes from taking effect..?
Any help would be greatly appreciated!
In Vaadin most of the code runs in the server and is contained in normal Java files. There are three levels of resource/class changes:
The runtime "hot code replacement". If running Tomcat in debug mode some Java class changes can be published without redeploying the web application. However, if the Tomcat is configured to "auto publish" (check your server settings in Eclipse), the redeployment is automatically done whenever classes change and this causes full context reload and sessions serialization (see #2) . Hot code replacement can be enhanced using tools like JRebel.
Web application deployment. This is essentially deploying a new war file to the server. Causes the previous version to be undeployed and deploys the new version of all classes and resources. Sometimes there are some resources left in the servers work directory or classes are not reloaded, in which case the server restart (#3) is needed.
Server restart. This makes the whole JVM to reload and all the classes and web applications are also reloaded. Still cleaning the work directory separately is needed to make sure everything is reloaded.
In addition to this there is the client-side part of Vaadin (essentially a JavaScript compiled with GWT), which is treated as a static resource by Tomcat. If you modify the client-side Java code the GWT is used to recompile the JavaScript. Deployment should be simply file copying. The browsers cache the generated HTML/JS files, but GWT includes mechanism to avoid this.
You should first try to change the server settings for automatic publishing and see if that helps. Also, I've noticed that different Tomcat version behave differently. This is unfortunate, but the only thing you can do is to try to find the versions/set-up that works for you.
Just to make sure: you have been adding ?restartApplication in the URL to force application to restart on page reload, haven't you?

eclipse howto start a application client on java ee glassfish appl srv

i have installed the glassfish eclipse tools bundle...
i can start a project like dynamic web & a ear project and deploy them on the glassfish... it works perfect & under the localhost url i will get an hello world
but how i do this if i want to make an application client. please help...
at the moment i simply created an "app client project in eclipse" & added it to the same ear,
but i have no idea how to start this...
help - any tutorial how to start?!!
Not the only only answer to this question but the appclient approach mentioned in Jeff's answer is a viable approach, but I was able to execute a client using this mechanism in eclipse and I wanted to share that approach.
This approach will let you execute a java application with a main method acting as a client.
What you want to do is setup an External Tools Configuration.
Create a new Program type of external tool configuration.
Set location to point to the path of the appclient, for me
(using embedded glassfish eclipse plugin) it was [PATH TO ECLIPSE]\plugins\oracle.eclipse.runtime.glassfish_3.1.1.0\glassfish3\glassfish\bin\appclient.bat
Set working directory to your output/build directory e.g.
${project_loc}/target/classes
Set arguments to ${java_type_name}
Select the class in your project with a main method that you wish to run as the client app and then select your external tool from the run external tools menu.
There are two ways to do it. I'm afraid I can't be very specific, but I can point you in the right direction. (I'm just learning myself)
You can enable Web Start for the application client EAR in GlassFish. You can do this either in the deployment descriptor (so it's enabled every time you deploy) or you can go into the GlassFish admin console, navigate to the Application, and check the checkbox to enable it. I have made a little progress on this approach.
You can run it manually from the command line using, I believe, the "appclient" command. I have not been able to get this working yet.
Good luck, and if you learn more, I'd appreciate it if you let me know since I'm in the same boat as you.
Jeff