Author: dimuthul
Date: Wed Dec 5 03:29:29 2007
New Revision: 10547
Log:
Adding errors and changes.
Removed:
trunk/solutions/identity/modules/admin-ui/src/main/java/org/wso2/solutions/identity/admin/ui/action/ReportUsageAction.java
Modified:
trunk/solutions/identity/modules/admin-ui/src/main/java/org/wso2/solutions/identity/admin/ui/action/ReportSTSUsageAction.java
trunk/solutions/identity/modules/admin-ui/src/main/java/org/wso2/solutions/identity/admin/ui/action/ShowUserManagementAction.java
trunk/solutions/identity/modules/admin-ui/src/main/java/org/wso2/solutions/identity/admin/ui/action/ShowUserStoreAction.java
trunk/solutions/identity/modules/admin-ui/src/main/java/org/wso2/solutions/identity/admin/ui/action/UpdateGlobalUserManagementPropertiesAction.java
trunk/solutions/identity/modules/admin-ui/src/main/resources/org/wso2/solutions/identity/package.properties
trunk/solutions/identity/modules/admin-ui/src/main/resources/struts.xml
trunk/solutions/identity/modules/admin-ui/src/main/webapp/jsp/usermanagement.jsp
trunk/solutions/identity/modules/documentation/src/site/xdoc/idp_administratorguide.xml
Modified:
trunk/solutions/identity/modules/admin-ui/src/main/java/org/wso2/solutions/identity/admin/ui/action/ReportSTSUsageAction.java
==============================================================================
---
trunk/solutions/identity/modules/admin-ui/src/main/java/org/wso2/solutions/identity/admin/ui/action/ReportSTSUsageAction.java
(original)
+++
trunk/solutions/identity/modules/admin-ui/src/main/java/org/wso2/solutions/identity/admin/ui/action/ReportSTSUsageAction.java
Wed Dec 5 03:29:29 2007
@@ -21,7 +21,6 @@
private String username = null;
public String execute() throws Exception {
-
return SUCCESS;
}
Modified:
trunk/solutions/identity/modules/admin-ui/src/main/java/org/wso2/solutions/identity/admin/ui/action/ShowUserManagementAction.java
==============================================================================
---
trunk/solutions/identity/modules/admin-ui/src/main/java/org/wso2/solutions/identity/admin/ui/action/ShowUserManagementAction.java
(original)
+++
trunk/solutions/identity/modules/admin-ui/src/main/java/org/wso2/solutions/identity/admin/ui/action/ShowUserManagementAction.java
Wed Dec 5 03:29:29 2007
@@ -16,6 +16,8 @@
package org.wso2.solutions.identity.admin.ui.action;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
import org.wso2.solutions.identity.IdentityProviderConstants;
import org.wso2.solutions.identity.admin.ParameterAdmin;
@@ -37,29 +39,37 @@
private String username = null;
private String password = null;
+
+ private static Log log = LogFactory
+ .getLog(ShowUserManagementAction.class);
@Override
- public String execute() throws Exception {
- ParameterAdmin admin = new ParameterAdmin();
-
- this.allowUserRegistration = admin
-
.getParameter(IdentityProviderConstants.PARAM_NAME_ALLOW_USER_REGISTRATION) !=
null;
- this.enableEmailVerification = admin
-
.getParameter(IdentityProviderConstants.PARAM_NAME_ENABLE_EMAIL_VERIFICATION)
!= null;
-
- String value = admin
-
.getParameterValue(IdentityProviderConstants.PARAM_NAME_EMAIL_PORT);
- if (value != null) {
- this.port = Integer.parseInt(value);
+ public String execute() throws Exception{
+ try {
+ ParameterAdmin admin = new ParameterAdmin();
+
+ this.allowUserRegistration = admin
+
.getParameter(IdentityProviderConstants.PARAM_NAME_ALLOW_USER_REGISTRATION) !=
null;
+ this.enableEmailVerification = admin
+
.getParameter(IdentityProviderConstants.PARAM_NAME_ENABLE_EMAIL_VERIFICATION)
!= null;
+
+ String value = admin
+
.getParameterValue(IdentityProviderConstants.PARAM_NAME_EMAIL_PORT);
+ if (value != null) {
+ this.port = Integer.parseInt(value);
+ }
+ this.host = admin
+
.getParameterValue(IdentityProviderConstants.PARAM_NAME_EMAIL_HOST);
+ this.fromAddress = admin
+
.getParameterValue(IdentityProviderConstants.PARAM_NAME_EMAIL_FROM_ADDRESS);
+ this.username = admin
+
.getParameterValue(IdentityProviderConstants.PARAM_NAME_EMAIL_USERNAME);
+ this.password = admin
+
.getParameterValue(IdentityProviderConstants.PARAM_NAME_EMAIL_PASSWORD);
+ } catch (Exception e) {
+ log.error(e.getMessage(), e);
+ return ERROR;
}
- this.host = admin
-
.getParameterValue(IdentityProviderConstants.PARAM_NAME_EMAIL_HOST);
- this.fromAddress = admin
-
.getParameterValue(IdentityProviderConstants.PARAM_NAME_EMAIL_FROM_ADDRESS);
- this.username = admin
-
.getParameterValue(IdentityProviderConstants.PARAM_NAME_EMAIL_USERNAME);
- this.password = admin
-
.getParameterValue(IdentityProviderConstants.PARAM_NAME_EMAIL_PASSWORD);
return SUCCESS;
}
Modified:
trunk/solutions/identity/modules/admin-ui/src/main/java/org/wso2/solutions/identity/admin/ui/action/ShowUserStoreAction.java
==============================================================================
---
trunk/solutions/identity/modules/admin-ui/src/main/java/org/wso2/solutions/identity/admin/ui/action/ShowUserStoreAction.java
(original)
+++
trunk/solutions/identity/modules/admin-ui/src/main/java/org/wso2/solutions/identity/admin/ui/action/ShowUserStoreAction.java
Wed Dec 5 03:29:29 2007
@@ -16,14 +16,12 @@
package org.wso2.solutions.identity.admin.ui.action;
-import org.wso2.solutions.identity.persistence.IPPersistenceManager;
-import org.wso2.solutions.identity.persistence.dataobject.RealmConfigurationDO;
-
import java.util.Set;
-import com.opensymphony.xwork2.ActionSupport;
+import org.wso2.solutions.identity.persistence.IPPersistenceManager;
+import org.wso2.solutions.identity.persistence.dataobject.RealmConfigurationDO;
-public class ShowUserStoreAction extends ActionSupport {
+public class ShowUserStoreAction extends ManagedAction {
private static final long serialVersionUID = 8265273506039256750L;
@@ -40,7 +38,7 @@
public String execute() throws Exception {
if (this.configName == null) {
- return ERROR;
+ return ERROR;
}
IPPersistenceManager db = IPPersistenceManager.getPersistanceManager();
Modified:
trunk/solutions/identity/modules/admin-ui/src/main/java/org/wso2/solutions/identity/admin/ui/action/UpdateGlobalUserManagementPropertiesAction.java
==============================================================================
---
trunk/solutions/identity/modules/admin-ui/src/main/java/org/wso2/solutions/identity/admin/ui/action/UpdateGlobalUserManagementPropertiesAction.java
(original)
+++
trunk/solutions/identity/modules/admin-ui/src/main/java/org/wso2/solutions/identity/admin/ui/action/UpdateGlobalUserManagementPropertiesAction.java
Wed Dec 5 03:29:29 2007
@@ -16,6 +16,8 @@
package org.wso2.solutions.identity.admin.ui.action;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
import org.wso2.solutions.identity.IdentityProviderConstants;
import org.wso2.solutions.identity.IdentityProviderException;
import org.wso2.solutions.identity.admin.ParameterAdmin;
@@ -38,15 +40,17 @@
private String password = null;
+ private static Log log = LogFactory
+ .getLog(UpdateGlobalUserManagementPropertiesAction.class);
@Override
public String execute() throws Exception {
-
try {
ParameterAdmin admin = new ParameterAdmin();
if (enableEmailVerification) {
if (port == 0 || host == null || fromAddress == null) {
- // TODO error
+ this.addErrorMessage(getText("required_feild_missing"));
+ loadMessages();
return ERROR;
}
@@ -98,6 +102,9 @@
.removeParam(IdentityProviderConstants.PARAM_NAME_ALLOW_USER_REGISTRATION);
}
} catch (IdentityProviderException e) {
+ this.addErrorMessage(getText("error_unexpected", new
String[]{e.getMessage()}));;
+ log.error(e.getMessage(), e);
+ loadMessages();
return ERROR;
}
Modified:
trunk/solutions/identity/modules/admin-ui/src/main/resources/org/wso2/solutions/identity/package.properties
==============================================================================
---
trunk/solutions/identity/modules/admin-ui/src/main/resources/org/wso2/solutions/identity/package.properties
(original)
+++
trunk/solutions/identity/modules/admin-ui/src/main/resources/org/wso2/solutions/identity/package.properties
Wed Dec 5 03:29:29 2007
@@ -29,4 +29,7 @@
add_realm_config_required_prop_missing = Required property "{0}" missing!
-remove_rp_hostname_null = Hostname missing
\ No newline at end of file
+remove_rp_hostname_null = Hostname missing
+
+required_feild_missing = Required field missing
+error_unexpected = Error : {0} !
\ No newline at end of file
Modified:
trunk/solutions/identity/modules/admin-ui/src/main/resources/struts.xml
==============================================================================
--- trunk/solutions/identity/modules/admin-ui/src/main/resources/struts.xml
(original)
+++ trunk/solutions/identity/modules/admin-ui/src/main/resources/struts.xml
Wed Dec 5 03:29:29 2007
@@ -191,6 +191,7 @@
</action>
<action name="UpdateGlobalUserManagementProperties"
class="org.wso2.solutions.identity.admin.ui.action.UpdateGlobalUserManagementPropertiesAction">
<result name="success">jsp/usermanagement.jsp</result>
+ <result name="error">jsp/usermanagement.jsp</result>
</action>
<!-- User management : END -->
Modified:
trunk/solutions/identity/modules/admin-ui/src/main/webapp/jsp/usermanagement.jsp
==============================================================================
---
trunk/solutions/identity/modules/admin-ui/src/main/webapp/jsp/usermanagement.jsp
(original)
+++
trunk/solutions/identity/modules/admin-ui/src/main/webapp/jsp/usermanagement.jsp
Wed Dec 5 03:29:29 2007
@@ -33,7 +33,14 @@
<div class="breadcrumb"><a
class="breadcrumb-link" href="ShowMain.action">Home</a> | User Management</div>
<h1 class="headding-userstores">User
Management</h1>
-
+ <s:iterator value="errorMessages">
+ <div class="info-message"><s:property /></div>
+ </s:iterator>
+
+ <s:iterator value="infoMessages">
+ <div class="info-message"><s:property /></div>
+ </s:iterator>
+
<s:form action="UpdateGlobalUserManagementProperties"
method="post" theme="simple">
<table cellpadding="0" cellspacing="0" border="0"
class="form-table">
Modified:
trunk/solutions/identity/modules/documentation/src/site/xdoc/idp_administratorguide.xml
==============================================================================
---
trunk/solutions/identity/modules/documentation/src/site/xdoc/idp_administratorguide.xml
(original)
+++
trunk/solutions/identity/modules/documentation/src/site/xdoc/idp_administratorguide.xml
Wed Dec 5 03:29:29 2007
@@ -71,28 +71,28 @@
<strong>LDAP - org.wso2.usermanager.custom.ldap.LDAPRealm</strong>
<table>
<tr><td>Parameter Name</td><td>Description</td></tr>
- <tr><td>ConnectionUrl</td><td>LDAP connection url. For example
"ldap://localhost:389"</td></tr>
+ <tr><td>ConnectionUrl</td><td>LDAP connection url - e.g.
ldap://localhost:389</td></tr>
<tr><td>ConnectionName</td><td>LDAP connection username. This must be a
root user who can read attribute IDs</td></tr>
<tr><td>ConnectionPass</td><td>LDAP connection password.</td></tr>
- <tr><td>UserPattern</td><td>User search pattern must be given. For
example uid={0},ou=People,dc=wso2,dc=com </td></tr>
+ <tr><td>UserPattern</td><td>User search pattern must be given - e.g.
uid={0},ou=People,dc=wso2,dc=com </td></tr>
<tr><td>UserContextName</td><td>Name of the context, where user objects
are stored</td></tr>
<tr><td>AttributeIds</td><td>User Attribute IDs that will be read by
the IdP.
- Column names must be comma seperated. For example: <code>email_address,
telephone</code>. These attributes
+ Column names must be comma seperated - e.g. email_address, telephone.
These attributes
will be included in the issued SAML tokens. </td></tr>
</table>
<strong>JDBC - org.wso2.usermanager.custom.jdbc.JDBCRealm</strong>
<table>
<tr><td>Parameter Name</td><td>Description</td></tr>
- <tr><td>DriverName</td><td>JDBC Driver's class name. It must be present in
the classpath. For example
<code>org.apache.derby.jdbc.EmbeddedDriver</code></td></tr>
- <tr><td>ConnectionURL</td><td>Connection URL to the database. For example
"jdbc:derby:home/identity/database/SAMPLE_DB"</td></tr>
+ <tr><td>DriverName</td><td>JDBC Driver's class name. It must be present in
the classpath - e.g. org.apache.derby.jdbc.EmbeddedDriver</td></tr>
+ <tr><td>ConnectionURL</td><td>Connection URL to the database - e.g.
jdbc:derby:home/identity/database/SAMPLE_DB</td></tr>
<tr><td>ConnectionUserName</td><td>Connection username to the
database</td></tr>
<tr><td>ConnectionPassword</td><td>Connection password of the
username</td></tr>
<tr><td>UserTable</td><td>User table name in the database.</td></tr>
<tr><td>UserNameColumn</td><td>User name column in the User table</td></tr>
<tr><td>UserCredentialColumn</td><td>User credential column in the User
table</td></tr>
<tr><td>ColumnNames</td><td>Column names of the user table from where the
user properties will be read.
- Column names must be comma seperated. For example <code>email_address,
telephone</code>. These attributes
+ Column names must be comma seperated - e.g. email_address, telephone. These
attributes
will be included in the issued SAML tokens.
</td></tr>
</table>
_______________________________________________
Identity-dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/identity-dev