Actually i dint get the point. The ldap would be having the data about the usernames from the beginning only and when the user logs in (authentication done against the entry within the database) and then the name would be checked in for the ldap and logged in message would appear?? is it so?
Yes you right. If the ldap has the users from the beginning, then you might not need the database, because you will authenticate them against the ldap. For the authentication use case this is the best scenario. Another good scenario would also be to authenticate against the database only, without moving the user�s information to ldap. The only scenario that doesn�t make sense to me is to authenticate against the database and copy the session information to ldap. This won�t buy you much. Better keep them in the database, eventually creating a new USER_SESSION table and forget about ldap.
So why we need the data within ldap Cant it be possible that the data is just transfered when the user is authenticated using the database
I imagine that your question is about an automatic way to transfer data from the database to ldap. Like using link tables in database, when the data is moved from one database to another. Well the answer is no, there is no miraculous way to transfer the data from database to ldap (or at least I don�t know any). You can do this only programmatically, writing JDBC code to get the data from database and writing to another ldap api in order to update ldap entry. Maybe now you�ll understand my point why it doesn�t make much sense to maintain these two different APIs, when you can just use only one of the two storage mechanism and maintain only one type of api.
As far the storage is concerned if ldap holds all the data then would it be possible for the ldap to hold more than 200 entries *what would be the extreme limit??) if tbere is any?
It will be no problem at all. It can hold much more than that, but when the number of entries is more than several thousand, ldap queries might become very slow. Databases have SQL, query optimizer, query buffering, aggressive caching, etc. and they are very mature and performat. LDAP is a relative new technology and as it stans is a very lightweight database.
And as u told to use the JSP. We had used JSP in the earlier projets of ours and so we wanned to use Swing would swing make appl slow or wat??
Swing GUI to Servlets back end, just doesn�t fit. JSP are server side components, hence they run on the server and can access implicit server side objects like HttpRequest/HttpResponse, HttpSession, ServletContext, etc. JSP have a very flexible, natural and follow a strong OOP model. In contrast your Swing GUI needs to get back the stream as it comes from the servlet, usually in html format. Next the GUI needs to parse this stream and fill up the swing components with the data from your html stream. This is a tremendous amount of extra-work and doesn�t follow an OOP approach. Even worse, this will be hard to maintain and from a design standpoint makes no sense whatsoever.
And is servlet a better option to use for transfer of the messages ?
No it's not. Actually I cannot think of any worse one. In a messaging system you need at least a producer and a consumer. While the producer is relatively easy to implement, the consumer is not quite so. A consumer can either poll or push the data. Therefore you�ll have two option (at least theoretically):
Have your GUI client checking the server for messages every 1,2,3,... minutes (this is the polling model).Have your servlet sending the message back to your GUI client, after receiving it (this is the pushing model) Without getting into any details, I�ll tell you that the second option is almost always preferred. This is actually how a truly messaging system works. The only problem here is that I can�t see how this could be achieved with servlets. My guess is that it will either never work, or it will be too complex. So you�ll end up implementing 1, which is neither a very nice nor very optimal solution.
Once again how the process to transfer the names from the database to ldap will take place
I think I answered you to this question. However there is one more hint I can give you. If you need a way to transfer your users from database to ldap you might use a third party tool, like openadaptor. This is free an you might download it form
http://www.openadaptor.org Regards.