In one of my recent projects, I needed to point to different data sources by run-time environment.
In the web container, we can define jndi data sources. But what about in the batch environment?
I have heard of something like dummy jndi but I have some problem trying to understand it. So I figured out another way.
In the applicationContext.xml file, I used propertyConfigure to define location at classpath:application.${runtime}.properties.
Then I created two properties file, application.development.properties and application.production.properties.
Then in the applicationContext.xml file, I just pick up the properties.
Then in the command line, I just need to specify the "runtime" variable by using -Druntime=development or -Druntime=production.
Done.
Note: if in applicationContext we need a value "\\abc\aaa", we need to define it in the properties file as "\\\\abc\\aaa".
Friday, April 27, 2012
Tuesday, March 27, 2012
Portal Drive
A nice tool to map KM folders into Windows PC/server.
Download path:
SAP Software Download Center -> Support Packages and Patches -> N -> SAP NetWeaver -> (Your SAP Portal Version/Release) -> Entry by Component -> Frontend
I downloaded 4.4 and 4.5. I installed 4.5.
Check if WebDAV is enabled. System Administration -> System Configuration -> Knowledge Management -> Content Management -> Protocols -> WebDAV
The Enable WebDAV Server should be checked on.
Configuration url
http://:57100/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/documents/
Done.
Download path:
SAP Software Download Center -> Support Packages and Patches -> N -> SAP NetWeaver -> (Your SAP Portal Version/Release) -> Entry by Component -> Frontend
I downloaded 4.4 and 4.5. I installed 4.5.
Check if WebDAV is enabled. System Administration -> System Configuration -> Knowledge Management -> Content Management -> Protocols -> WebDAV
The Enable WebDAV Server should be checked on.
Configuration url
http://
Done.
Thursday, February 02, 2012
Unlock a document in KM
Thursday, September 08, 2011
EP Upgrade from 7.0 SP 18 to 7.01 SP 8
After the upgrade, I found a new deployment would only be effective after the SAP reboot.
Download NetWeaver Developer Studio 7.0
To download NWDS 7.0 or 7.01, search by JIDE* on SAP support portal.
Wednesday, October 20, 2010
SAP - dist/PORTAL-INF/config
We are not using NWDI. We use a third-party source code management system.
The dist/PORTAL-INF/config folder was checked into the repository. Later when we did a quick PAR upload, NWDS complained not able to delete the folder.
Tried to find a way to prevent it being checked in, but found no solution.
Finally I found if I define this folder as Derived, it won't give me any trouble.
The dist/PORTAL-INF/config folder was checked into the repository. Later when we did a quick PAR upload, NWDS complained not able to delete the folder.
Tried to find a way to prevent it being checked in, but found no solution.
Finally I found if I define this folder as Derived, it won't give me any trouble.
Thursday, September 16, 2010
Java Write Text into a Image
graph = image.getGraphics();
graph.setColor(aColor);
graph.setFont(aFont);
graph.drawString(text, x-position, y-position);
graph.setColor(aColor);
graph.setFont(aFont);
graph.drawString(text, x-position, y-position);
Friday, September 10, 2010
Some small consideration when design web applications
Sometimes I think to myself, what makes web application different from others? I find a real case when I review a real application.
This application has an edit page, on which user can select "Y" or "N" from a drop list. It also define keys for "Y" and "N" in a message properties file and this application is designed for English only.
I think there are at least two small places that the designer can do better.
This application has an edit page, on which user can select "Y" or "N" from a drop list. It also define keys for "Y" and "N" in a message properties file and this application is designed for English only.
I think there are at least two small places that the designer can do better.
- use radio button instead of drop down list, this saves one click.
- still put real messages in properties files but no need to treat a "Y"/"N" choice as a real message
Monday, August 16, 2010
SAP Portal - Multiple Node Installation of a KM Scheduler Task
In an environment with more than one CM system, you must assign one (any) CM system in the cluster to each scheduler task.
Do not assign a scheduler task to more than one CM system at the same time. In the configuration of a scheduler task, there must be only one entry in the CM Systems parameter.
To balance the load, we recommend assigning all scheduler tasks to one dedicated CM system that runs separate from the load balancer. This separation removes the load caused by running the scheduler tasks from the other nodes and makes them available solely for your users.
Do not assign a scheduler task to more than one CM system at the same time. In the configuration of a scheduler task, there must be only one entry in the CM Systems parameter.
To balance the load, we recommend assigning all scheduler tasks to one dedicated CM system that runs separate from the load balancer. This separation removes the load caused by running the scheduler tasks from the other nodes and makes them available solely for your users.
Tuesday, July 27, 2010
Wednesday, June 23, 2010
Tips - How to Rename the Suffix of a Group Files on Windows
Very simple, use cmd and go to the directory,
rename *.abc *.xyz
DONE.
rename *.abc *.xyz
DONE.
Thursday, June 10, 2010
Have fun! World Cup is coming.
Last month a world wide telephone survey was conducted by the U.N.
There was only one question asked: "Would you please give your honest opinion about solutions to the food shortage in the rest of the world?"
This survey was a HUGE failure because of the followings,
1. In Eastern Europe they didn't know what "honest" meant.
2. In Western Europe they didn't know what "shortage" meant.
3. In Africa they didn't know what "food" meant.
4. In China they didn't know what "opinion" meant
5. In the Middle East they didn't know what "solution" meant
6. In South America they didn't know what "please" meant
7. In the USA they didn't know what "the rest of the world" meant
8. In Australia they hung up as soon as they heard the Indian accent.
There was only one question asked: "Would you please give your honest opinion about solutions to the food shortage in the rest of the world?"
This survey was a HUGE failure because of the followings,
1. In Eastern Europe they didn't know what "honest" meant.
2. In Western Europe they didn't know what "shortage" meant.
3. In Africa they didn't know what "food" meant.
4. In China they didn't know what "opinion" meant
5. In the Middle East they didn't know what "solution" meant
6. In South America they didn't know what "please" meant
7. In the USA they didn't know what "the rest of the world" meant
8. In Australia they hung up as soon as they heard the Indian accent.
Wednesday, May 19, 2010
SAP Portal - Internationalization on Room Directory
NetWeaver Collaboration with Enterprise Portal 7.0.18 only supports English and German.
To internationalize it, download com.sap.netweaver.coll.appl.ui.room.par and add
UIRoomdirectoryConsts_es.properties to support Spanish and
UIRoomdirectoryConsts_fr.properties to support French.
Then redeploy the par to EP.
To internationalize it, download com.sap.netweaver.coll.appl.ui.room.par and add
UIRoomdirectoryConsts_es.properties to support Spanish and
UIRoomdirectoryConsts_fr.properties to support French.
Then redeploy the par to EP.
Monday, May 17, 2010
SAP Portal - Promote KM Changes to Next Stage
As I said in my previous posts, we created a new XML form, a couple of new predefined properties, and a new filter. Now we need to promote these changes to next stage.
Portal Content
Portal Content
- create a transport package and add the changed iView into the package
- create a configuration archive and add the following into the archive
- KM->CM->Form-Based Publishing -> Forms Availability ->Folder Settings, the new folder-form setting
- KM->CM->Global Services->Property Metadata->Properties, the new metadata
- KM->CM->Global Services->Property Metadata->Groups, the new metadata group
- KM->CM->Global Services->Property Structures->Property Groups, the new property group and the all_groups
- KM->CM->Global Services->Resource List Filters, the new resource list filter
- KM->CM->Repository Filters, the new filter class
- KM->CM->User Interface->Settings->Layout Set, the new browser
- copy the new xml form to next stage
Friday, May 07, 2010
SAP Portal - Apply XML Form to KM Folder
Thursday, May 06, 2010
SAP Portal - Use Properties in XML Form
I found almost zero documents on this subject. I figured it out finally with some common sense and some luck.
I configured some predefined properties to my KM documents. After it, I needed to create a XML form and use these properties for users to create such documents.
Here is what I had done.
I configured some predefined properties to my KM documents. After it, I needed to create a XML form and use these properties for users to create such documents.
Here is what I had done.
- Open an existing News form and save as my own project, called FM_News.
- At the left side, select the Data Model, right click on Properties and select Reload Properties
- At the editor area, add a label ABC, add three check boxes A, B, and C
- Add a label DE, add two radio boxes, D and E
- Define A - Caption A, Name ABC, Value A, Property Reference /Properties/default:ABC
- Define B - Caption B, Name ABC, Value B, Property Reference /Properties/default:ABC
- Define C - Caption C, Name ABC, Value C, Property Reference /Properties/default:ABC
- Define D - Caption D, Name DE, Value D, Property Reference /Properties/default:DE
- Define E - Caption E, Name DE, Value E, Property Reference /Properties/default:DE
- Note: check box for multiple selection and radio box for single selection, XML Form Builder may warn you to use Combo Box instead, ignore it.
- Save and generate.
Tuesday, April 27, 2010
SAP Portal - XML Forms Builder
This builder is under the Content Management tab of Content Manager role.
After every change to the form, save the project and generate the project.
This generation, my understanding, is to publish the change to portal.
To move the change to QAS or PRD, copy its xml files from \usr\sap\[sid]\SYS\global\config\cm\etc\xmlforms to QAS or PRD servers.
After every change to the form, save the project and generate the project.
This generation, my understanding, is to publish the change to portal.
To move the change to QAS or PRD, copy its xml files from \usr\sap\[sid]\SYS\global\config\cm\etc\xmlforms to QAS or PRD servers.
Wednesday, March 17, 2010
SAP Portal - How to Configure Predefined Properties for KM Documents
We use KM Navigation iView to broadcast news which are posted in KM repository.
We need to separate them by Field and by Language.
Configuration,
We need to separate them by Field and by Language.
Configuration,
- System Adminsitration -> System Configuration -> Knowledge Management -> Content Management -> Global Services -> Property Metadata -> Groups
- New

- Global Services -> Property Metadata -> Properties
- New - Unique ID = NewsGroup-Field, Property ID = Field, Namespace Alias = default, Group = NewsGroup, Mandatory = Yes, Multi-Valued = Yes, Maintainable = Yes, Default Value = Field1, Allowed Values(csv) = Field1,Field2,Field3

- New - Unique ID = NewsGroup-Language, Property ID = Language, Namespace Alias = default, Group = NewsGroup, Mandatory = Yes, Multi-Valued = No, Maintainable = Yes, Default Value = English, Allowed Values(csv) = English,French

- Global Services -> Property Structures -> Property Groups
- New

- Global Services -> Property Structures -> Property Groups, select all_groups and Edit
- Add the newly created NewsOptions to Group Items and OK
- Content Administration -> KM Content, select a document and open its Details
- Settings -> Properties -> NewsGroup tab
- Done
SAP Portal - Namespaces
Subscribe to:
Posts (Atom)

