Chad Step

Greenhorn
+ Follow
since Jun 21, 2006
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 Chad Step

So I've decided I must finally begin upgrading my Java skills and I'm setting up a project to code against.

Skills I want to achieve in order of importance are:
  • Spring
  • Hibernate
  • Maven
  • Struts


  • I'm pretty unfamiliar with all of these and am hoping for some direction. I'm planning to put together a small webportal as part of this project. Not too woried about which yet, but am thinking Jetspeed2 or Liferay (would JForum work)?

    Basically individuals will be logging in and managing some personal information -- there is going to be a fair amount of reports displayed as well as different forms (think of a college registration system, need to collect demographic information, class registration and report credits & graduation progress).

    One thing I'm really hoping for is a utility similar to Drupal's Form API(which generates forms for you and is found here) & DB input (which populates objects & eliminates SQL injection possibilities).

    I'm thinking Hibernate should handle the 2nd requirement, I'm not sure if the first one can be met by any Java utilities.

    Is what I'm proposing here achievable? Any suggestions on how to use these tools to achieve my goals? Where would you suggest I host this (hoping for <$20 / month and will eventually need https:// -- uptime is more important than speed)?

    I know I'm asking for a lot in 1 topic, but its difficult to evaluate without picturing the entire goal.

    thanks in advance!
    11 years ago
    thanks for the responses.

    I know having this portion in the JSP isn't a best practice...... I've got other excuses I won't bore you with

    Thanks for the link, I learned a lot from this.

    In the end, the code below (same as example 3 in original post) did work. I had to go clear the cache out of Tomcat.



    Frustrating that that is what it was, but I'm stronger having read the article Rob posted above. I'll consider this frustration worth it.

    thanks everyone, this issue is closed!
    13 years ago
    Is there a different sub-forum that would have been more appropriate for this question? I didn't see one that I thought was, but the question itself is not very specific to JSP other than that is the what the code is being implemented.

    I just didn't see a SE General forum that I thought would be better.
    thank you.
    13 years ago
    From a JSP page, I am trying to run a shell script.

    From the command line, I call the script like:
    First Code Example

    It processes just fine in this scenario.

    Within the .jsp page, I originally tried
    2nd Code Example

    this scenario did not work. The variable that is argument1 does not get populated and the program that is being called by the shell script gives me Null-Value error. (this does not happen in the first coding example.

    A co-worker told me this would be the solution:
    3rd Code Example

    However, this gives me the same results as in the 2nd code example.

    Any suggestions on what I'm doing wrong here? The shell-script argument is not getting picked up by the Runtime Call, but I don't know how to make sure it does get picked up.

    ------------
    (If relevant, I'm doing this on Solaris 10 using Tomcat).
    -----------

    thank you for your help and insights.
    13 years ago
    Thanks Greg, will do that today and see what I come up with.

    The current solution creates 3 files, I think this will eliminate at least two of them.
    13 years ago
    I think what your looking for is session management and session variables.

    I don't know a lot about that in JSP, but I would start searching there.

    If you want someone to login before they can view a page, you'd first confirm they've established a session appropriately and then decide whether or not to display a page.
    13 years ago
    I've been following the tutorial at: http://cephas.net/blog/2004/04/01/pgp-encryption-using-bouncy-castle/.

    Following this example, I have been able to encrypt files in PGP. The problem is, I just want a few strings that I can then pass along -- I don't need an encrypted file. The strings will be passed in a web query.

    Is there a way to only encrypt Strings and not have to first write them to a file? Does the file encryption have to happen? (I'm struggling to find anything to make me believe otherwise,but that just doesn't make sense to me).

    thanks
    13 years ago
    I was not using Struts in this. Interesting that it would have this problem.

    I've only learned about it in quick research. is it kind of like Ruby-On-Rails for Java?
    14 years ago
    I'm setting out trying to get Liferay to be hosted on a GoDaddy basic hosting package that does Java.

    I'm not sure if anyone else has done this before but wanted to ask. Have you? Will you tell me how?

    Also, if you think this is not going to work, will you let me know and why?

    In the industry I'm in, its important that I get very accustomed to Liferay, so I want to start a site around it. I don't feel like paying a lot for hosting though.

    Thanks for your suggestions.
    14 years ago
    We found it, kind of a newbie mistake I guess.

    We thought that each time a servlet was requested, a new object was created-- so we assumed instance variables we encapsulated from all the other requests.

    Found this on CodeRanch: https://coderanch.com/t/451902/JSP/java/session-mix-up
    Its cleared up now that all our variables need to be in the doView method.
    14 years ago
    We have a portal (uportal) running on Tomcat. We have programmed a couple of of Portlets that for the most part run just fine.

    A few of these portlets are grabbing data from an Oracle DB and presenting it to our users -- this info is grabbed based upon a user id. Every once in a while (1 in 10,000 logins perhaps?) we get reports of users getting the data of different users, when we do get this report it seems to be from 2 or 3 different users at about the same time. We've looked through backups of the DB to see if info is written wrong and what it looks like some sort of session-data bleeding. (our portlets don't have any static variables that could accidentally be shared)

    Has anyone ever heard of Tomcat accidentally giving one user's session data to a different user? How would I begin to look at this? I'm not sure how to view/record individual session data.

    thank you for your help.
    14 years ago
    As I begin my study for the SCJA exam, do you think the Core Java 2 (J2SE 5.0) book is an ok study guide?
    17 years ago
    Hey I just saw this message. I'm beginning to study for the test, I'm taking a lot of hope in the fact that you found out about the test a week before.

    Where would you suggest beginning? I'm a programmer, but a lot better at PHP than Java.

    Did you just buy the practice test and go from there?

    Thanks
    17 years ago