Sunday, June 28, 2020

Need help in WCS projects?

Hey folks,

Let me know if you or your company needs any work to be done for Oracle WCS and Oracle Cloud related projects.

I have been working on WCS projects and middleware technologies from past 8 years and believe that I will be able to help you or your client to meet their goals.

I have listed down type of projects which I have worked previously and am sure that I will be able to fulfill those for you or your clients as well.
  1. WCS Upgrade: Upgrade from WCS 11g (6/8) / FatWire 7.x / 12c previous release to 12c (latest) - It is already known that WCS 11g is old with no updates from Oracle and thus, upgrade to WCS 12c is necessary. One of the major challenges which any organization faces is to upgrade WCS to latest WCS 12c once the project is delivered by their vendors. It is very difficult to plan for upgrading in limited time if your team is not experienced. Furthermore, the time and costs associated with the project are unknown as it depends on various factors like infrastructure, downtime period, 3rd party integrations, resources required, knowledge of upgrade itself and experience in upgrading process. As I have already performed upgrade for clients with thousands of content, external integrations and varied infrastructure like AWS, Oracle Cloud and on-premise systems, my expertise can help your client to upgrade and stay on latest release and get regular updates from Oracle.
  2. New / Re-design website: If you are looking for releasing new website or spinning off new website from existing website within WCS or full re-design of the website, then you are at right place. In past, for one of my client I have devised solution wherein client were able to spin-off 30 country websites with different domains from a single existing website within 4 weeks and on same WCS instance without any infrastructure scaling up and with same performance. It requires proper planning, code re-usability, designing correct modules, performance tuning and experience for such requirements. I have developed fully tested various utilities and tools which can help reduce time-to-go-live for your projects.
  3. Infrastructure review / enhancements: Are you still using same old architecture to deliver website? Was your infrastructure reconsidered or improved in recent years? If not, then it is now time to review it. With deprecation of FatWire and WCS 11g, if you are planning to upgrade for WCS 12c and / or thinking to move from on-premise setup to Oracle Cloud or AWS, there it is very important to strategize your architecture and to make informed design decisions. I have helped clients in setting up infrastructure on both Oracle Cloud and AWS with same WCS licenses and with optimal costs.
  4. Performance Tuning: WCS development is little tricky until one has really worked for long time with the product. It takes a while to understand and derive right solutions for different purposes. Many customers make bad decision to upscale their system to higher compute just for making their website run okay and struggle to make them performant. In fact, they end up spending too much money on infrastructure and resources for less output. Right planning for WCS design and development is very crucial to make optimal usage of WCS and deliver performant website. This is where I can help you to re-think your development strategy, improve website performance and provide standards for future developments.
  5. Development / Website maintenance: If you are looking for full-time / part-time WCS developer on contract basis who can deliver various functionalities of website or just maintain the website, I am available.
  6. Migration: WCS is not an appropriate solution for all customers but still some of them ended up having their website on WCS and now could not decide on how to migrate on another platform / CMS. There is no out-of-the-box project export functionality available which can be used as import for other enterprise or open-source CMS. In order to migrate all data from WCS to other platform, it is very important to know the underlying mechanism of how WCS works, where exactly data is stored and how to export it. This is where my expertise lies which can help you to migrate. 
My qualifications:
  1. I have 8 years of experience working with Oracle WCS and middleware technologies
  2. I hold Oracle WebCenter Sites certification: Oracle Certified Implementation Specialist
  3. I hold many certifications on Oracle Cloud Infrastructure
  4. Worked with many big and international clients with 40-100 websites implemented and managed on WCS & related technologies
  5. Experienced working with clients from Europe, Asia, US and UAE
Technologies and tools which I work with:
 Programming    
 Java, J2EE, Groovy, Node.js, CSS, HTML, JSP, JavaScript, jQuery, XML, Dojo, PHP, LATEX
 Cloud Oracle Cloud Infrastructure (Oracle Java Cloud Service (JCS), PaaS, IaaS), Amazon Web Services (AWS) (S3, CloudFront, API Gateway, EC2, WAF,Lambda), Marketing Cloud - Eloqua
 CMS Oracle WebCenter Sites (WCS), Oracle Content and Experience Cloud, Drupal, FatWire
 Web Servers Apache Http server, Oracle Http Server, Oracle Traffic Director (OTD)
 Middleware Apache Tomcat, Oracle Weblogic Server (WLS)
 Database Oracle Database, MySQL, HSQLDB
 Development Tools Eclipse, Jenkins, Maven, ANT, SVN, GitLab, Bitbucket, SQL Developer, Toad
 Project Tools Jira, Confluence, Trello, Zoho, Win@proach, Microsoft Project Server
 Concepts Object-Oriented-Programming, Unit Testing, Agile Software Development

FAQs:
Q1. How to contact?
A1. Please contact me via email: fatwire.dev@gmail.com

Q2. What are the working rates?
A2. It would depend on type of work you would ask me to do - development, website analysis, website improvement, maintanence, upgrade and migration

Q3. Availability: How many hours and days?
A3. Minimum 4 hours from Monday to Saturday. Maximum would depend on type of work.

Q4. How to evaluate work?
A4. You provide requirements, I will analyse the cost and hours required to complete the task. Once we agree, work can be started as soon as you provide me access to relevant systems.

Q5. Are you available for travelling?
A5. Yes but obviously would depend on the location because of COVID-19 situation. Accomodation, travel and expenses should be paid by you.

Q6. Current location?
A6. I am currently living in Switzerland.

Q7. How quickly would you respond?
A7. Within 24 hours. Mostly, I will provide response as soon as I see your email.

Q8. If the work can be done remotely, do you need internet and laptop / computer ?
A8. No until I have access to relevant systems, I have my own laptop and very good internet.

Q9. What about other questions which are not listed?
A9. Please feel free to ask any questions when you would email me your requirements.

I am looking forward for the challenges which you / your client are facing. Hope to hear from you soon.

Monday, June 17, 2019

Performance: Image optimization

If you check your website using Google's tool: Pagespeed Insights, one of the basic issues with many websites is that images are not optimal for mobile devices and possible for desktop as well. As more and more people consume information via mobiles and tablets, it is very crucial for your website to be very fast and friendlier. In case of friendlier, it itself is a big topic and is out-of-scope with respect to WCS. But when it comes to performance, one of the major challenges with WCS is blobs handling and displaying correct dimension of images according to mobile and desktop devices.
Thus, I have listed down a few points which I found one should definitely try and make their site performant than now it is, if by not much.
  1. URL handling: Vanity URL is one of the best feature introduced with WCS 11g8 which has altogether removed the usage of assemblers (which used to be in old product of WCS erstwhile FatWire). Should you have vanity urls for blobs as they are simply images / docs and they don't need any urls as they are simply displayed directly. But there may a case wherein a customer might want to share image / document url to other platforms which should not change with time as people may bookmark or share it further across other channels. This is where it is important to have vanity url for blobs as well. I propose the following solution which has worked for our clients until now: In order to have vanity url for blob, you simply select blobs on vanity url screen and check "Is downloadable?" as needed. Most important thing is url pattern which one needs to configure which we learnt from our past mistakes and works well be it clustered or non-clustered infrastructure. URL pattern like following works quite well: /[may be locale value for e.g. en]/[asset id of the asset]/[blobname].[extension] for e.g. /en/1234/image1.png Having asset id within the URL itself is perfect for situation wherein RSS or WCS are clustered. Furthermore, you can add more blob header information as well with Vanity URL.
  2. Rendering / displaying images: I particularly said images not documents because WCS based websites are mostly text and images. For text, there are few compression techniques and they work well (check white space compression). For images, it is quite difficult to display the appropriate image which fits the section of a website. From my past experience, usually content editors use the same image across small box items to sliders to search boxes, etc. which becomes bottleneck for rendering the page fast as the browser may take time to download & serve the images to an end user. If you really have websites with very big images in size and dimension that can really hurt user experience if not performant enough. So how to tackle ? These are few ways which worked for us:
    • Use CDN (Content Delivery Network): This is known to many and is used to make their website faster for better user experience but does comes at a cost of configuration and maintenance.
    • Cache your images to higher TTL: This requires quite good amount of time to figure out the optimal time for images to cache and that can be still be not good enough. Configuration within WCS and RSS is another challenge.
    • Don't allow users to upload images higher than certain size. This can be achieved using WCS and already described in the developer guide (check Uploader). But still some images do need to be higher in dimension and customer may not have the most optimized image.
    • Use webserver to serve images: As it seems easier to say, it is little bit harder to make it work properly as challenge comes on how to handle during publishing and not to mention adding / updating / deleting images can also be quite tricky to setup. May be there are already such plugins available but still requires quite an effort to make it work smoothly.
    • Compress your images using free / paid services as mentioned by Google. This is what we have used for one of the clients where they have nearly thousands of images to display on their websites and thus, optimal compressed images are displayed. Clients uploads an image, which on saving asset calls the external API which provides compressed and good quality of image, store in an attribute and use the compressed image for displaying on website.
    • Use OOTB ImageOptimizationFilter flex filter: This one is my favorite as this particular flex filter generates good quality of optimized and resized images for devices configured within WCS. But as I have known from past that many customers don't want to contribute content for Touch, Desktop and NonTouch devices within WCS as that task is very tedious and repeatative, this filter may not be that helpful. For those who are already use devices, they can refer on how to use this flex filter and optimize images. For those who don't use devices or mobility feature much, still can use this filter in following way: Just follow the steps mentioned in the above link and create renditions of the images as needed which would generate 2 images: [your image name]_Touch and [your image anem]_NonTouch. As a customer or development team, you should already know which sizes of images would fit in which sections. You can display accordingly either Touch or NonTouch image and thus, can save quite a lot of bandwidth for your end users. This particularly filter is quite useful which not only compresses image size but also provides 2 renditions of images with good quality. If you need more renditions, then you can definitely write your own custom implementation of ImageOptimizationFilter as mentioned in the guide. This flex filter is optimized within 12c and works quite well.
    • Use webserver to configure default expiration for images of about certain optimal value like 7 days, 1 month or even 1 year. This is subject to client's wishes and needs to be catered accordingly.
    • Last but not least, using combination of above is certainly going to achieve a faster and good experience for end users.
There may be other tricks as well to handle image compression and optimization but I guess this should provide some hints on tackling performance related to images.

Need help? Click here.

Should you upgrade to WCS 12c?

It been long since Oracle introduced new version of WCS i.e. 12c and till now 4 versions of WCS have been released, you can check the details about releases on the official website here. You may want to check which are all the new and deprecated features; which I have already listed on this blog post.
Now the bigger question, why one should consider upgrading to WCS 12c. Are there any advantages on using 12c version of WCS rather than 11g ? I, myself, don't know much information about it but let's just dig into it and try to figure out what are possible reasons for you or your clients to upgrade.
  1. RIP 11g: First of all, if you are already a client or working for client on WCS project, you might already know by now that WCS 11g is discontinued and is subject to just extended support. Thus, there is no way one would like to continue using deprecated version of WCS. Not only that, Oracle stops providing fixes in form of patches once the product is discontinued, thus, it makes no brainer to figure out that you or your client needs to upgrade to WCS 12c as soon as possible.
  2. Improvements: Frankly speaking, a lot of effort has been made by Oracle in order to improve user and developers experience by improving the way it used to work in 11g. Many new features have been introduced which would help not only the contributors on how they work within WCS but also developers after introduction of new mode of development (MVC and aggregate REST API). Thus, kudos to Oracle for working so hard on introducing these features and streamlining the product.
  3. Integration to other relevant products: This is one of the best feature introduced within WCS 12c where various integration points to different products are targeted mainly for marketers and editors to enhance the web user experience before the release of the desired content on their websites. Few of the integration with other products like Oracle document cloud, Oracle Eloqua, Oracle CEC, Blukai, WebCenter Content, etc. really allows wider groups to collaborate and contribute to website with rich content within an organization. With A/B testing, it is possible to test, analyze and publish more appropriate content which suits your organization. Content Targeting with Blukai  is even easier. You can contribute your content on the fly on any device by integrating WCS with Oracle Document Cloud service. Any REST based services are capable of being integrated with WCS using proxy assets. Thus, there is now larger scope of integrating with other non-Oracle products as well within WCS.
  4. Easier for developers. Is it? Well, with introduction of MVC in WCS, I would say that it was long desired feature but really does it helps ? I don't think so. In my experience, WCS at first seems very easy product to understand and use for development but as you dig more into development and designing (which is the most important aspect for WCS projects), you will find that with introduction of MVC, it is now very crucial to built a solution which should be very optimal, easily readable and planned with more precision. Just browse through code base of avisports sample website which is shipped with Jump Start Kit (available at Oracle edelivery website), code base has grown too much and with every new layout/section, a WCS controller is needed. Basically, you might end up with so many controllers and layouts which can be quite confusing and difficult for developers to understand for bigger projects.
  5. APIs: Well, it seems Oracle did provide a robust API for content fetching, searching and rendering easier. With JSTL tags, it can be little tricky but once you get used to it, it is okay. Not that bad. Other APIs like the new aggregate REST api is good and Java APIs are updated too.
  6. Design: According to me, in past few years, whichever projects I have handled as consultant or architect or developer, the most challenging part was and is design when it comes to WCS. If you don't design content model well, be ready to face hell lot of issues while migrating, upgrading, publishing and deploying. There are currently no standards provided by Oracle for content model and template designs and that's where I feel people lack interest in product due to the complexity which grows as the project goes on. In 12c, its same so again nothing new.
  7. Others: There are a few tweaks here and there but are not listed in the official documentations. Left for the developers to decipher that.
  8. Upgrade: This is another aspect where Oracle has really provided quite good (if not optimal) functionality for customers who wish to migrate to 12c (details in official guide). I (me and my team) personally have migrated 2 projects using this upgrade tool from 11g to 12c and it was good if you use it only once. After upgrade, needs few tweaks here and there with your template code which uses some deprecated API and custom functionalities. If you want upgrade in concurrent fashion then there is this another tool: DataDiff migration tool which can migrate the content after certain dates, thus allowing to migrate content in chunks whenever needed. We faced many issues with DataDiff tool and had to resolve most of the issues by ourselves but that I guess is nothing new who have already worked with product :)
  9. Last but not least, given that now WCS 12c ships with more new and newer features from time to time, it is easy for WCS editors to curate their content as technology demands. I will write more blogs about the new features in future and will keep you updated with latest changes of WCS 12c.
Thanks for reading ! Stay tuned. Need help? Click here.

Sunday, November 26, 2017

Re: List of 12c new and deprecated features

It has been more than a year since WCS 12c has been released but if you check the official website, you should see 4 versions of 12c released when this article was published. So, I thought to basically jot down all the new features and list of deprecated features.

List of all new features in WCS 12c (all versions)
  1. DojoTree instead of Java applet: Hugh improvements for loading tree tabs in Admin UI, very important change for WCS administrators (Note: this feature is also available for 11g 11.1.1.8.0 Patch12+). No more battling with java plugins in browser:)
  2. Publishing from Contributor UI: Publishers can now publish assets from Contributor UI itself, no need to provide "AdvancedUser" role to editors until they really need to access Admin UI. No more technical/configuration slip-ups by editors.
  3. Content help menu: There is help menu in Contributor UI which can be used to know how-about of various basic functionalities. Another option would be to customize it and point it to Client's document or wiki page.
  4. GetURLExpressions.groovy can be customized: It has been hard in past to write some custom functions within this element and maintenance of this element has been headache but now in 12c, it is possible to create customized element and add your custom functions as needed.
  5. Content Audit Report: It has been long desired feature for any customer to have an overview of who, what and when performed which operations on assets & 12c meets this requirement aptly.
  6. History of an asset in History tab: Small but helpful feature
  7. A/B Testing: Allows editors to check their website's "more viewed or favored sections" and thus, lets them decide to set the content for the website.
  8. New security, engage and user properties. Check out properties guide.
  9. MVC framework: A slight relief for developers ? Well, all depends on design but still at least a great effort by Oracle to provide such functionality
  10. Lucene indexing test
  11. Integration with other products like Bluekai, Eloqua, Content Cloud, LDAP, Oracle Access Manager, Oracle WebCenter Content, etc. are available out-of-the-box (of course, there are some or the other nitty-gritty details which one needs to implement)
  12. Some small notable changes like separation within search assettype in Contributor UI, colored tabs according to device groups, improved mobility features, tags tree tab, etc.
  13. Log4J is replaced by ODL which is good but too much logging happens now, thus, need to configure log settings very carefully. Custom loggers are feasible in ODL which is pretty nice feature to separately log in different log files if you have deployed your own custom implementation.
  14. Logs are now visible from Admin UI which was very slow and many times not possible in 11g
  15. Logging information like ip, geo-location, etc. are possible due to inclusion of geoip library but it has been recently removed from higher version of 12c3 as these needed licenses.
  16. A very robust aggregate REST API; a very useful feature for clients to deliver micro-sites.
  17. Improved context menu for asset operations in Contributor UI
  18. Shared file system can be managed in database but it has it some caveats as well
  19. Visitor services: New API and integration points with different products
  20. Properties managed via now single json file: wcs_properties.json
  21. Passwords are mostly saved now in keystore rather than AES or SHA encryption, providing better security
  22. Installation, patching and upgrade process are improved drastically then previous 11g version
  23. Deployment of static and custom implementation is to be done as a separate war file rather than updating default war i.e. sites.war
  24. Monitoring logs files, caches, etc. in Oracle Weblogic console
List of all deprecated features in WCS 12c (all versions)
  1. WCS 12c cannot be deployed (not officially supported) on other application servers except Oracle Weblogic (This is a bummer for many customers) and even db is mainly restricted to Oracle database.
  2. No community or gadget server anymore.
  3. No CIP integrations like SharePoint, EMC, etc.
  4. No soap-based web services (replaced by new improved REST & aggregate REST API)
  5. No analytics
  6. No static publishing or any other publishing available out-of-the-box
Need help? Click here.

Monday, February 22, 2016

Introduction to OWCS 12c

Overview
This document is created to provide an idea on the news features of Oracle WebCenter Sites 12c. This new version of WCS introduces various marketing tools which can be used by marketers to generate web pages personalized based on the characteristics (interests, social category, context, etc.) of an individual or group of users, therefore providing them with a tailored user experience.

DEVELOPER’S PERSPECTIVE
    • Oracle has introduced new MVC pattern of coding in 12c which follows the following flow:
Controller Flow.pg.png
    • General idea is to write all the business logic in controller (WCS_Controller asset type) which serves as CONTROLLER, Templates or SiteEntry+CSElement can include controllers and should contain only basic HTML code and output from controller using <fragment> tags and thus, serve as VIEW. Output from controllers i.e. asset data are saved in MAP objects which serve as MODEL. Hence, the MVC pattern.
    • REST api was already present in older version of Oracle WebCenter Sites to access data but 12c provides simpler ways to access data in different ways. Check out this section for more details.
    • Improvements in eclipse-csdt plugin and csdt command line feature.

CLIENT’S PERSPECTIVE
    • Visitor services is a separate module which can be installed and configured with WCS 12c to capture visitor’s activity data from various multiple platforms like google, fb, twitter, etc. and saves as a unified profile within webcenter sites so that marketers can segmentize visitors on basis of these unified profiles/data and thus, target users with desired content. Details related to configuration are present here. This is very advanced topic in terms of capturing visitors data and providing personalized data. Engage is already a part of WCS 12c OOTB and can be used in tandem with Visitors services and Insights (described later) components to target end-users efficiently.
    • This component is kind of reporting tool to check specific visitor action that one can identify for tracking for e.g. number of clicks on certain asset or promotion, specific link, amount of time a visitor watches video, stays on a webpage or an ad.
    • Conversion assets can be created by marketers and works in tandem with Insights component and A/B testing to generate conversion reports.
    • The Insights component delivers a comprehensive real-time view of your website's ROI.
    • This component is again a marketing tools for marketers to drill down marketing initiatives from webpage to single asset.
    • It also provides information on the contributors which worked for contributing content within WCS during a period by generating reports.
    • Marketers can analyse website traffic and user behaviour to segmentize them at very specific content level and target them using either both Engage and Visitors Service component or just with Engage only.
    • This marketing functionality within WCS contributor interface works in tandem with Conversions and Insights components; to test a piece or group of content against each other to determine which can be best for visitors targeting and/or serving best content by testin g performance among variations of content before delivering the content to end-users. This is more of hit-and-trial kind of creating variation of content (assets), capturing data and analysing for targeting users. For A/B testing, insights component should be enabled.
  • Rest of the features are few improvements, functionality and accessibility in the WCS product itself.

Need help? Click here.

Implementing pagination on search in 12c

Pagination on search pages is quite a common requirement and with introduction of WebCenter Sites 12c, it has become even more easier to do so. If you are looking for implementing pagination on search results for 11g, you can check my old post here.

With introduction of new server-side api, its very easy to perform CRUD operation on assets. For searching assets, Searcher helper class provides methods to include various options which is very easier to implement.
Note: For using Searcher, global indexes for the assettype should be enabled.

Following is simple illustration of searching product assets of particular locale (en_US) in FirstSiteII, it can also search on product name, order by date and shows 10 results per page.

Click here to download this sample groovy class.

Need help? Click here.

Sunday, January 3, 2016

Using controllers for development

Welcome to Oracle WebCenter Sites 12c development! After the introduction of MVC framework in Oracle WebCenter Sites, it is now very very easy to perform CRUD operations on assets as OOTB Controller assets are sufficient to carry out nearly 99% of your WCS development. Developers now need to learn little bit of groovy but its okay even if you know JAVA and jstl programming. But still in current release of 12c, legacy tags and asset api can also be used.

If you browse through Samples site, all new concepts are described aptly in the site's sections itself so its redundant to write the same thing in this post. I just wanted to list down few simple cases which are not present or not explained in detail in Samples or Avisports site.

1. Debugging using watchers:

Debugging is little bit difficult when it comes to WebCenter Sites; if not aware of various core functions which are used in background. And seems like that hasn't changed much as it is same case while using controllers. Whenever there is error thrown from controller, you get detailed error log in sites.log but sometimes it may be difficult to decipher the root cause. Thus, the role of watchers is very useful not only during debugging but also gives detail on output of your data in the model object. For every function, you can just add your own watchers and print them in your JSP code.

Syntax to define in controller: watch("__my_watch__")
Syntax to print output in JSP: $("__my_watch__")

Watchers are very useful when you just want to check output from your controller's method. For e.g. Create one controller and add any method which is defined in Samples site and then create one template (applies to various asset type, can be called from browser, uncached) and assign your controller. In template code, just add the following line of code within <cs:ftcs> opening and closing tag, which is basically default watcher: ${__$WATCH$__}
Now, call your template directly from browser using following url: <hostname>:<port>/sites/Satellite?pagename=<sitename where template was created>/<template name>&c=Page&cid=<Some random id> --> which should print the output of your controller's method. Note: Output will be from the asset of what c and cid is used in controller.

2. Accessing attribute values:

To fetch attributes of data type: string, text, number, float, date, int, money ; use the following syntax in JSP template or CSElement:
${asset.YOUR_ATTRIBUTE_NAME} or ${asset["YOUR_ATTRIBUTE_NAME"]}  
where asset is the model object containing the map values which was defined in controller.

To fetch asset of type blob, use the following syntax:  
${asset._bloblink_} or ${asset.YOURATTRIBUTENAME_bloblink_}

To fetch hyperlink for an asset: ${asset._link_}

To fetch attribute of type - asset: ${asset.YOURATTRIBUTENAME} but it will just provide your associated asset id. So to get detail/summary/link template fragment of this associated asset, fetch id in your controller using following syntax: models.asset.YOURATTRIBUTENAME whose output is basically an arraylist. Loop through list and get each id values. Create one empty List<Fragment> and add as TemplateFragment or SiteEntryFragment or ElementFragment to it to be used in Template or CSElement code. For eg: Suppose product assets are associated to one attribute: RelatedProducts and you want to show them using Summary template, then your code will be as followed:

 
and jsp code as followed (don't forget to include jstl core library at top of your element):

<c:if test="${not empty relatedProducts}">
   <c:forEach begin="0" end="${relatedProducts.size()-1}" var="product">
      <fragment:include name="relatedProducts" index="${product}"/>
   </c:forEach>
</c:if>

3. Formatting date is now very simple using jstl fmt:formatDate tag. Just pass ${asset.DATE_ATTRIBUTE_NAME} and desired format to get the formatted date.

4. Apart from watchers, you can directly log the desired output using already defined logger for controller:  
log.info("AssetMap: " + assetMap) OR log.info(JsonOutput.prettyPrint(JsonOutput.toJson(assetMap)))

5. Although methods related to search are explained but fails to provide info on how to sort and search against locale/dimension content. Following code searches against Page of only particular locale - en_US, sorts by updateddate descending and sets only the latest updated page into model object.

That's all for now, will share as I explore more.

Need help? Click here.