Updates from garciademarina Toggle Comment Threads | Keyboard Shortcuts

  • garciademarina 2:25 pm on July 25, 2014 Permalink | Reply  

    Osclass cache – Performance testing 

    Comparison of the average download time of Osclass 3.4 with cache (memcache) and Osclass 3.3.2 without cache simulating a constant user loading on both installations. Performance testing is an non-functional testing performed to determine how a system performs in terms of responsiveness and stability under a particular workload.

    We will perform a Load/Capacity testing

    A load test is usually conducted to understand system performance under a specific expected load.

    This load can be the expected concurrent number of users on the application performing a specific number of transactions within the set duration.

    The test will give out the response time of all the important business critical transactions.

    We will make load testing using JMeter

    Apache JMeter is an Apache project that can be used as a load testing tool for analysing and measuring the performance of a variety of services, focusing on web applications.

    Our test plan:

    We need to define these parameters:

    • Number of users ( This is the number of concurrent users we want to simulate )
    • Ramp-Up period (in seconds) (If 14 users are used, and the ramp-up period is 1 second, then JMeter will take 1 second to simulate all 14 users)
    • Loop count (how many times is executed)

    We’ve added the following requests to be simulated:

    • Homepage
    • Search – Region Barcelona
    • Search – Category Cars
    • Search – Category Car Parts
    • Search – Category Animals

    Osclass 3.3.2 vs Osclass 3.4 with memcache

    Test note:

    • Unregistered users. ( no login is performed )
    • Simulates a constant traffic (14 or 58 users  browsing the web simultaneously)
    • 2 simulations, normal load (14 concurrent users) and traffic peak (58 concurrent users).
    • Target machine: 4 cpu + 8 Gb (digitaloceans vps)
    • 420.000 listings per installation.

    Normal workload

    Based on one month data

    • 300k unique visitors per month.
    • 640k page views per month.
    • 120 seconds

    14 concurrent users in 1 sec ( 50 times ) 26.3% improvement from the previous version

    High workload (peak of traffic)

    Based on the data corresponding to a possible peak

    • 1,5k visitors in one hour.
    • 3,2k páginas vistas in one hour
    • 140 seconds

    58 concurrent users in 1 sec (50 times) 31% improvement from the previous version NOTE: Factor between concurrent users and page views will vary depending on the site. A lower concurrence of users can generate more petitions in a site than another one with a lower amount of users. For this reason, knowing the server capacity to hold a given number of users may be enough or not, depending on the number of page views generated by users. 

    • Testernikk 5:41 am on February 19, 2015 Permalink | Reply

      Hey I am a old user of osclass . I have handled every starting problems and running this script but i am facing a main problem that unable to login into admin panel many time . In starting everything works fine and then Not able to login in admin panel . its very painful

  • garciademarina 4:25 pm on September 7, 2012 Permalink | Reply  

    Email templates improvements 

    Osclass have email templates for multiple purposes such as verify user account, notify new items, etc.

    You can customize your email templates like you want, going to

    ‘Admin panel -> Settings -> Email templates’

    As you can see, email templates can have email variables  like {EMAIL_VAR}  in Title and Description (  title as email subject and description as email body ).

    For example you can have a email template with a subject like this:

        ‘Hi {USER_NAME} welcome to {WEB_TITLE}’

    There are two email variables, which will be replaced before email is sent.

        {WEB_TITLE}  , will be replaced by web title.

        {USER_NAME}, will be replaced by user name.

    We will receive an email with subject like:

        ‘Hi Carlos, welcome to osclass.org’

    Recently added :

    •  Test it button, that allows you given an email to send a template preview of the actual template.
    •  A legend with short descriptions of email variables to make email templates more understandable.

    Example of Use

    Plugin name: send_email_example

    Description: This is an example that create his own email template and send emails with custom email variables.

    This plugin sends an email saying thanks and showing the number of items belonging to a user, when a listing is added by user and only if user have more than one item published.

    This plugin use EmailVariables class, that is used when edit email templates for show the legend, in this case add {NUMBER_LISTINGS} variable and set a description.

    EmailVariables::newInstance()->add(‘{NUMBER_LISTINGS}’, __(‘Number of listing that belong to user.’, ‘send_email_example’));

    Here you can download a plugin example. ( Plugin is well documented If you have any doubt don’t hesitate to ask )

    NOTE: This features are only available if you use a develop branch of Osclass. Will be added on Osclass 3.1.0.

  • garciademarina 10:37 am on July 17, 2012 Permalink | Reply
    Tags: admin, plugins,   

    Admin Menu example 

    There is an example of how to add new menu sections and submenu to your sidebar admin menu.

    • This example adds two menu sections and one submenu with external link.
    • The menu entries have a customized icon for normal and compact menu mode

    NOTE: Install like a plugin.

    Plugin structure:

    • example_adminmenu/index.php
    • example_adminmenu/ball.png
    • example_adminmenu/ballCompact.png
    • example_adminmenu/twitter.png
    • example_adminmenu/twitterCompact.png


    • Lalita 5:01 am on August 3, 2012 Permalink | Reply

      Can you help me to hide or rename menus, add custom menus and more in admin(dashboard) page?

      • garciademarina 8:11 am on August 3, 2012 Permalink | Reply

        Hi @Lalita,

        If you want to remove menu or/and submenu sections form admin menu you can take a look at hAdminMenu.php helper,
        You can remove with osc_remove_admin_menu_page(ID_MENU) the menu entry ID_MENU and all submenus with parent menu id ID_MENU.
        You can remove with osc_remove_admin_submenu_page(ID_SUBMENU) only one submenu with ID_SUBMENU as id.

        If you need to update some data in AdminMenu, you can remove the section and add it again with the proper changes.

        You can see the default menus and submenus at oc-includes/osclass/classes/AdminMenu.php (function init.php) It can help you.


    • Lalita 9:19 am on August 3, 2012 Permalink | Reply

      Wow SUPER!!! Thank You so Much…Muchas Gracias 🙂

    • greg 6:27 am on September 2, 2012 Permalink | Reply

      I installed the carousel plug in and it’s messed up the lower section of my admin menu. How can I fix this?

    • Tom shaft 12:24 pm on January 19, 2013 Permalink | Reply

      I installed and using your example, made a couple minor changes and works great. Thanks for posting.

    • Muhammad Muaz 6:13 am on March 19, 2013 Permalink | Reply

      Can you help me removing a menu item or menu from side bar of admin panel in OSClass

    • garciademarina 10:49 am on March 19, 2013 Permalink | Reply

      It’s as simple as:


      or remove submenus:


    • Juanjo 5:16 pm on August 8, 2013 Permalink | Reply

      Hi, with new version 3.2, this example has stopped working.

      We should do changes in the CSS to adjust.

      My question is for other variables that are not in use in the example.

      Function “osc_add_admin_menu_page”:
      icon_url and position

      Any idea of using it?

Compose new post
Next post/Next comment
Previous post/Previous comment
Show/Hide comments
Go to top
Go to login
Show/Hide help
shift + esc