[JBoss-user] jboss-jaas.jar LdapLoginModule enhancements?
I've modified LdapLoginModule to use a different ctx.search() method because of how user roles are defined in my directory--based on group membership instead of role attributes on each user. I tried to keep my modifications so the auth.conf is compatible with either search method. I need advice on what to do with my changes. I don't want to have to update this one class in jboss-jaas.jar with every new release; OK for quick testing but not for long term. I could remove my changes and extend the original class but since almost all the "important" work is done in the createLdapInitContext() method overriding it seems like too much duplicated code. Can I submit the source for review and potentially have my changes merged into the source tree? Recommendations? Steve Swing ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
Re: [JBoss-user] seperate context
- Original Message - From: "Ferguson, Doug" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Wednesday, May 09, 2001 12:37 pm Subject: [JBoss-user] seperate context > Or some way to prevent us from stepping on each others toes, other > than installing jboss on our local machines. Out of curiosity, do you have specific reasons why you don't want to install JBoss on your local machines? Regards, Steve ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
Re: [JBoss-user] HOWTO get web app relative file system path from a JSP (was (no subject))
- Original Message - From: "Felix Munoz" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, May 07, 2001 4:25 am Subject: [JBoss-user] (no subject) > Hello: > > I am having a problem running a JSP and I was hoping for some advice. I am > running embedded Tomcat. > > I have the following setup: > > index.jsp > directory/fileA.txt > directory/fileB.txt > > The job of index.jsp is to list the files in "directory." For this, I was > trying to use something like this: > > File directory = new File("directory") > String[] fileList = directory.list(); > Did you try any of these scriptlets (using your example)? <% File directory = new File(application.getRealPath("directory")) %> <% File directory = new File(application.getResource("directory").toExternalForm()) %> <% application.getResourceAsStream("directory") %> According to the documentation getResourceAsStream() will read resources from a war file if it wasn't extracted during deployment. Some application servers don't extract ears, wars, & jars during deployment unless you instruct it to do so. This probably doesn't apply to your situation because you're serving files from a directory. > So the question is, is there a way to list files in a directory by using a > path relative to the location of a JSP page? I was going to suggest using something like the IO taglib from Apache-Jakarta http://jakarta.apache.org/taglibs/index.html. Unfortunately the IO taglib link on this page is broken. I don't know if it contains a tag specifically for this purpose but it seems like the best candidate. Perhaps you should write a tag library to list files. I suspect taglibs already exist that do this. I just didn't know of any other taglib lists off-hand. > Thanks in advance, > > Felix Munoz I hope this is helpful. Regards, Steve Swing ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
Re: [JBoss-user] It never finds beans in another *.jar's
Could you use an environment entry? ReallyRemoteBean java.lang.String t3://otherserver/application/beanB // this could be done one time and cached // I'm not certain if you need the java:comp/ prefix here String jndiName := (String)ctx.lookup("java:comp/env/ReallyRemoteBean"); BHome home = (BHome)ctx.lookup(jndiName); B bean = home.create(pk); You're doing two lookups but at least you don't have to change code. The environment entry name is hard coded instead. This is an alternative to Vinay's acceptable solution. The advantage here is the jndi name isn't in a separate properties file that must also be edited, deployed, & managed. It's in the DD where Bean B is hosted and the DD (in two or more elements) for each client of Bean B. My $1/50. Steve - Original Message - From: Vinay Menon To: JBOSS Sent: Tuesday, May 01, 2001 4:02 pm Subject: Re: [JBoss-user] It never finds beans in another *.jar's Have had quite a few chaps usually put the jndi names in something as simple as a resource bundle/properties file. Then it wouldn't need a recompile of code an option you might want to try? However, I must add that it is recommended by folks at jboss that ejbs that are referenced by one another be bundled together in a single jar... Your views? Vinay - Original Message - From: Guy Rouillier Sent: Tuesday, May 01, 2001 8:07 PM To: [EMAIL PROTECTED] Subject: Re: [JBoss-user] It never finds beans in another *.jar's I'm going to be doing this in the near future, so I took a look at the docs. It said to use a jndi-name like this: t3://otherserver/application/beanB If I understand this correctly, the JNDI name is the name we use in the ctx.lookup() call. With the above, a lookup for an external EJB on the same JBoss is different from a lookup for the same EJB on a different JBoss. Wouldn't that require a source code change? That would not be good. - Original Message - From: Vinay Menon To: JBOSS Sent: Sunday, April 29, 2001 11:47 AM Subject: Re: [JBoss-user] It never finds beans in another *.jar's Hi, Check out the section 'External EJB Reference' in chapter 6 in the online documentation for jboss at www.jboss.org\documentation\HTML\ch06s05.html Vinay ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
Re: [JBoss-user] Running the interest sample as a Servlet does not work
- Original Message - From: "Carlos Granados" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, April 30, 2001 10:28 pm Subject: [JBoss-user] Running the interest sample as a Servlet does not work > b) I transformed the code of the sample client into a servlet. The interestEJB.zip example contains a servlet named EJB.java. I see the obfuscation technique worked! I think it would be better if it were named Servlet or something. Maybe it's just me. > d) I also put some logging println lines in the lookout method of the > jnpserver (in file NamingServer.java) and I found that both in the case of > the standalone client and the servlet, the jnpserver is correctly called and > it finds the appropiate object. I put some println lines to display the name > being looked up and the object found and in both cases I got the same > information: > looking for interest/Interest > found java.rmi.MarshalledObject@53248168 > > e) So my hypothesis is that the naming server correctly finds the EJB, but > when it is sent back to the naming client, it is somehow corrupted or > something like that. This seems a RMI problem and I feel that I have run > into something too complicated for me, so this is the point to ask for help > :-) Because you're requesting a remote object it's being serialized across the "divide." The receiving side needs the same class code to deserialize it. I think your servlet can't find the class for what the java.rmi.MarshalledObject instance--acting like an envelope--holds. The servlet needs the .class files in [interest.war]/WEB-INF/classes/. The servlet doesn't need the session bean code just the home and remote interfaces. Here's the jar tf output from a sample interest.war I built: META-INF/MANIFEST.MF WEB-INF/classes/com/web_tomorrow/interest/Interest.class WEB-INF/classes/com/web_tomorrow/interest/InterestHome.class WEB-INF/classes/EJB.class WEB-INF/web.xml If you're using any utility classes in their own jar you will need a class-path entry in the manifest of the war file. For example, we're using a utility jar and have a class-path entry in the manifest for both the war and the ejb.jar. It looks something like this: ; begin [interest.war/META-INF/MANIFEST.MF] (don't include this line) Manifest-Version: 1.0 Class-Path: library/utilities.jar ; end (don't include this line) library/utilities.jar is in the .ear not the .war. BTW, I had problems with the example EJB servlet client in EJB.java. It seems that the servlet can't find the bean in the init() method. I added two lines before the m_interest==null check: try { if (m_interest == null) // added SS init(); // added SS if (m_interest == null) { out.println ("Could not connect to Interest bean. Is EJB Container running?"); } else { I also added an e.printStackTrace(); in the empty catch in the body of the init() method. Before this it would eat a naming exception when deployed. So now it displays an exception when deployed but finds the bean when servicing a request. I hope this helped. I'm new to JBoss also so if I've ignorantly misled you, someone please enlighten us both. Steve > > Carlos > ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
Re: [JBoss-user] Unsubscribe?
Unsubscribe?Go here: http://lists.sourceforge.net/lists/listinfo/jboss-user JBoss-user Subscribers section toward the bottom of the page (last form field on the page). - Original Message - From: White, Joshua To: '[EMAIL PROTECTED]' Sent: Monday, April 30, 2001 2:08 pm Subject: [JBoss-user] Unsubscribe? Does anybody know how to unsubscribe? ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user