SlideShare a Scribd company logo
1 of 13
Download to read offline
Z-Push: advanced debugging
      Sebastian Kummer
Debugging Z-Push
Most of the time you don't see issues immediately!

    Debugging is not that easy:

    You need logs, they will be
What “usually” goes wrong – States
Problems with states
   •
     missing permissions
   •
     missing states after upgrading

States represent the synchronization state of mobile & folder on server

Missing states mean:
   •
     Server “does not know” what is already on the mobile, sends
     EVERYTHING again → duplications on mobile
   •
     Some stuff (like sending, creating & editing items) “works” somehow
   •
     Could cause loops

In Z-Push 2 a mobile will be fully resynchronized when states are missing
or invalid → missing states for many users could cause HIGH LOAD!
What “usually” goes wrong – Old versions

Old versions – especially 1.2.x and 1.3.x:
   •
     Compatibility issues
        •
          Fields not being synchronized
        •
          Some invitations/recurrences broken (also with 1.4.x)
   •
     Unimplemented features
   •
     Broken encodings - “Vielen Dank fÃŒr Ihre – Reservierung”
   •
     Nokia issues (duplicated folders)
What “usually” goes wrong – Loops

Loops
   •
     Creating 1000000(0000000000) duplicates
   •
     High load on server
   •
     High use of mobile bandwidth (could $$$$)

Loops are nasty and dynamic! Requests are triggered BY THE MOBILE.

Most common causes:
  •
    Broken items (most of times calendar, e.g. recurrences)
  •
    Timeouts (server takes to long to process request)
  •
    Fatal errors or Apache/PHP Segfaults (rarely)
  •
    Incompatibilities (mobile tries over and over again)
Approaching loops - I                              This is what you
                                                    see in the log


                   Mobile                                   Server

                     Idle                                Has a change


               Synch. request                      1. Reads state
                                                   2. calculates delta
                                                   3. exports change
       Retry
                                                   4. MAPI → ActiveSync
                                                   5. streams change
               Waits for answer                       to mobile
                                  Failure!
                       Timeout                     6. writes new state
                                                                      SEGFAULT
                     Idle
                                    Any step (1-6) can fail!
                                    Any step could take to long!
                                    Segfault could occur!
time
                                    Connection could fail (entering tunnel?)
Approaching loops - II                             This is what you
                                              see in the log – looks great!


                   Mobile                                      Server

                     Idle                            Has a 'broken' change


               Synch. request                       1. Reads state
                                                    2. calculates delta
                                                    3. exports change
       Retry
                                                    4. MAPI → ActiveSync
                                                    5. streams change
               Waits for answer                        to mobile
                                  Success!
                                                    6. writes new state

           Processes answer
                                   Faulty item is sent to the mobile!
                                   Mobile does not know how to
                   ERROR           interpret item → error!
time
Approaching loops - II                                 This is what you
                                                  see in the log – looks great!


                   Mobile                                          Server

                     Idle                                Has a 'broken' change

                                  'Broken' ...?        1. Reads state
               Synch. request
                                                       2. calculates delta
                                  Syntactical errors exports change
                                                       3.
       Retry                       - Missing elementary properties, like subject
                                                       4. MAPI → ActiveSync
                                   - Missing start or end date of change item
                                                       5. streams calendar
               Waits for answer                           to mobile
                                    Success! errors
                                  Semantic             6. writes new state
                                  - start date after end date
           Processes answer       - value not as expected (e.g. string vs. hex)
                                  - Recurrence exception: the mobile!
                                       Faulty item is sent to
                                     - Mobile does not know how to
                                        missing/faulty basedate
                                     - interpret item → error! (syntax)
                                        not a recurrence at all
time               ERROR
'Kamikaze loop' - III                                 This is what you
                                                 see in the log – looks great!


                   Mobile                                         Server

               Has NEW item                            Has a ('broken') change

                                                      1. Reads state
               Synch. request                         2. creates item on server
                                                      3. calculates delta
       Retry                                          4. exports changes
                                                      5. MAPI → ActiveSync
                                  Success/failure!
               Waits for answer                       6. streams new ID
                                  or timeout...       7. streams changes
               Doesn't really                         8. writes new state
                 matter...
                                           Anything after 2 fails..
                                           Anything else goes wrong
                                           (previous slides)
time               ERROR
Kamikaze user
How an iPhone receives an email
  “ I can see the first lines of the mail in the preview, but when I open it
                      just says 'no body available'.....! “
                iPhone                                           Server

                  Idle                                        Has a change

                                Only 1K of plain email
            Synch. request
                                                         Retrieving and processing
                                       Success
         Waits and processes

                                   Fetch with HTML
           Fetch entire mail                             1. Retrieving
                                       Failure           2. Processing as RFC822
              Processing
                                                                          SEGFAULT

                  Idle
time
How to fix?


Error checking in loops
   •
     some syntax checking
   •
     only few semantics checks possible
   •
     Force lower maxItems

•
  Logging on user level
•
  New log levels, incl. Deviceid (when synching
  several devices with same account
Questions?

       Thank you for your attention!
More information at:
           http://z-push.sf.net/forums
           http://z-push.sf.net/tracker
           http://z-push.sf.net/download
           http://z-push.sf.net/compatibility

Contact:   sebastian@zarafa.com

More Related Content

More from Zarafa

Zarafa SummerCamp 2012 - Tips & tricks for running Zarafa is larger scale env...
Zarafa SummerCamp 2012 - Tips & tricks for running Zarafa is larger scale env...Zarafa SummerCamp 2012 - Tips & tricks for running Zarafa is larger scale env...
Zarafa SummerCamp 2012 - Tips & tricks for running Zarafa is larger scale env...Zarafa
 
Zararfa SummerCamp 2012 - HA, multi-tenancy and SSO in Zentyal 2 and 3.pdf
Zararfa SummerCamp 2012 - HA, multi-tenancy and SSO in Zentyal 2 and 3.pdfZararfa SummerCamp 2012 - HA, multi-tenancy and SSO in Zentyal 2 and 3.pdf
Zararfa SummerCamp 2012 - HA, multi-tenancy and SSO in Zentyal 2 and 3.pdfZarafa
 
Zararfa SummerCamp 2012 - Debian packaging Giraffe and D-push
Zararfa SummerCamp 2012 - Debian packaging Giraffe and D-pushZararfa SummerCamp 2012 - Debian packaging Giraffe and D-push
Zararfa SummerCamp 2012 - Debian packaging Giraffe and D-pushZarafa
 
Zararfa SummerCamp 2012 - Fedora update & PAM-MAPI Zarafa Ready certified com...
Zararfa SummerCamp 2012 - Fedora update & PAM-MAPI Zarafa Ready certified com...Zararfa SummerCamp 2012 - Fedora update & PAM-MAPI Zarafa Ready certified com...
Zararfa SummerCamp 2012 - Fedora update & PAM-MAPI Zarafa Ready certified com...Zarafa
 
Zararfa SummerCamp 2012 - Community update and Zarafa Development Process
Zararfa SummerCamp 2012 - Community update and Zarafa Development ProcessZararfa SummerCamp 2012 - Community update and Zarafa Development Process
Zararfa SummerCamp 2012 - Community update and Zarafa Development ProcessZarafa
 
Zararfa summer camp 2012 interesting tips & tricks when migrating to zarafa
Zararfa summer camp 2012   interesting tips & tricks when migrating to zarafaZararfa summer camp 2012   interesting tips & tricks when migrating to zarafa
Zararfa summer camp 2012 interesting tips & tricks when migrating to zarafaZarafa
 
Zarafa SummerCamp 2012 - Keynote Steve Hardy - 3 Cool innovations
Zarafa SummerCamp 2012 - Keynote Steve Hardy - 3 Cool innovationsZarafa SummerCamp 2012 - Keynote Steve Hardy - 3 Cool innovations
Zarafa SummerCamp 2012 - Keynote Steve Hardy - 3 Cool innovationsZarafa
 
Zarafa SummerCamp 2012 - Deploying Zarafa Archiver
Zarafa SummerCamp 2012 - Deploying Zarafa ArchiverZarafa SummerCamp 2012 - Deploying Zarafa Archiver
Zarafa SummerCamp 2012 - Deploying Zarafa ArchiverZarafa
 
Zarafa SummerCamp 2012 - Open Generation Gap
Zarafa SummerCamp 2012 - Open Generation GapZarafa SummerCamp 2012 - Open Generation Gap
Zarafa SummerCamp 2012 - Open Generation GapZarafa
 
Zarafa SummerCamp 2012 - Zarafa Cluster using a reverse proxy
Zarafa SummerCamp 2012 - Zarafa Cluster using a reverse proxyZarafa SummerCamp 2012 - Zarafa Cluster using a reverse proxy
Zarafa SummerCamp 2012 - Zarafa Cluster using a reverse proxyZarafa
 
Zarafa SummerCamp 2012 - Zarafa 7.1 features
Zarafa SummerCamp 2012 - Zarafa 7.1 featuresZarafa SummerCamp 2012 - Zarafa 7.1 features
Zarafa SummerCamp 2012 - Zarafa 7.1 featuresZarafa
 
Zarafa SummerCamp 2012 - Z-push 2.0 changes for administrators
Zarafa SummerCamp 2012 - Z-push 2.0 changes for administratorsZarafa SummerCamp 2012 - Z-push 2.0 changes for administrators
Zarafa SummerCamp 2012 - Z-push 2.0 changes for administratorsZarafa
 
Zararfa SummerCamp 2012 - Performing fast backups in large scale environments...
Zararfa SummerCamp 2012 - Performing fast backups in large scale environments...Zararfa SummerCamp 2012 - Performing fast backups in large scale environments...
Zararfa SummerCamp 2012 - Performing fast backups in large scale environments...Zarafa
 
Zarafa SummerCamp 2012 - Exchange Web Services on Zarafa
Zarafa SummerCamp 2012 - Exchange Web Services on ZarafaZarafa SummerCamp 2012 - Exchange Web Services on Zarafa
Zarafa SummerCamp 2012 - Exchange Web Services on ZarafaZarafa
 
Zarafa SummerCamp 2012 - Communication - how engineers can outperform
Zarafa SummerCamp 2012 - Communication - how engineers can outperformZarafa SummerCamp 2012 - Communication - how engineers can outperform
Zarafa SummerCamp 2012 - Communication - how engineers can outperformZarafa
 
Zararfa SummerCamp 2012 - From RHEL to RHEV to Cloud
Zararfa SummerCamp 2012 - From RHEL to RHEV to CloudZararfa SummerCamp 2012 - From RHEL to RHEV to Cloud
Zararfa SummerCamp 2012 - From RHEL to RHEV to CloudZarafa
 
Zararfa SummerCamp 2012 - One solution of two vendors solves plenty needs
Zararfa SummerCamp 2012  - One solution of two vendors solves plenty needsZararfa SummerCamp 2012  - One solution of two vendors solves plenty needs
Zararfa SummerCamp 2012 - One solution of two vendors solves plenty needsZarafa
 
Zarafa SummerCamp 2012 - Zarafa in the Capgemini Open Cloud
Zarafa SummerCamp 2012 - Zarafa in the Capgemini Open CloudZarafa SummerCamp 2012 - Zarafa in the Capgemini Open Cloud
Zarafa SummerCamp 2012 - Zarafa in the Capgemini Open CloudZarafa
 
Zarafa SummerCamp 2012 - DMS ECM - simply for everyone
Zarafa SummerCamp 2012 - DMS ECM - simply for everyoneZarafa SummerCamp 2012 - DMS ECM - simply for everyone
Zarafa SummerCamp 2012 - DMS ECM - simply for everyoneZarafa
 
Zarafa SummerCamp 2012 - WebApp introduction and roadmap
Zarafa SummerCamp 2012 - WebApp introduction and roadmapZarafa SummerCamp 2012 - WebApp introduction and roadmap
Zarafa SummerCamp 2012 - WebApp introduction and roadmapZarafa
 

More from Zarafa (20)

Zarafa SummerCamp 2012 - Tips & tricks for running Zarafa is larger scale env...
Zarafa SummerCamp 2012 - Tips & tricks for running Zarafa is larger scale env...Zarafa SummerCamp 2012 - Tips & tricks for running Zarafa is larger scale env...
Zarafa SummerCamp 2012 - Tips & tricks for running Zarafa is larger scale env...
 
Zararfa SummerCamp 2012 - HA, multi-tenancy and SSO in Zentyal 2 and 3.pdf
Zararfa SummerCamp 2012 - HA, multi-tenancy and SSO in Zentyal 2 and 3.pdfZararfa SummerCamp 2012 - HA, multi-tenancy and SSO in Zentyal 2 and 3.pdf
Zararfa SummerCamp 2012 - HA, multi-tenancy and SSO in Zentyal 2 and 3.pdf
 
Zararfa SummerCamp 2012 - Debian packaging Giraffe and D-push
Zararfa SummerCamp 2012 - Debian packaging Giraffe and D-pushZararfa SummerCamp 2012 - Debian packaging Giraffe and D-push
Zararfa SummerCamp 2012 - Debian packaging Giraffe and D-push
 
Zararfa SummerCamp 2012 - Fedora update & PAM-MAPI Zarafa Ready certified com...
Zararfa SummerCamp 2012 - Fedora update & PAM-MAPI Zarafa Ready certified com...Zararfa SummerCamp 2012 - Fedora update & PAM-MAPI Zarafa Ready certified com...
Zararfa SummerCamp 2012 - Fedora update & PAM-MAPI Zarafa Ready certified com...
 
Zararfa SummerCamp 2012 - Community update and Zarafa Development Process
Zararfa SummerCamp 2012 - Community update and Zarafa Development ProcessZararfa SummerCamp 2012 - Community update and Zarafa Development Process
Zararfa SummerCamp 2012 - Community update and Zarafa Development Process
 
Zararfa summer camp 2012 interesting tips & tricks when migrating to zarafa
Zararfa summer camp 2012   interesting tips & tricks when migrating to zarafaZararfa summer camp 2012   interesting tips & tricks when migrating to zarafa
Zararfa summer camp 2012 interesting tips & tricks when migrating to zarafa
 
Zarafa SummerCamp 2012 - Keynote Steve Hardy - 3 Cool innovations
Zarafa SummerCamp 2012 - Keynote Steve Hardy - 3 Cool innovationsZarafa SummerCamp 2012 - Keynote Steve Hardy - 3 Cool innovations
Zarafa SummerCamp 2012 - Keynote Steve Hardy - 3 Cool innovations
 
Zarafa SummerCamp 2012 - Deploying Zarafa Archiver
Zarafa SummerCamp 2012 - Deploying Zarafa ArchiverZarafa SummerCamp 2012 - Deploying Zarafa Archiver
Zarafa SummerCamp 2012 - Deploying Zarafa Archiver
 
Zarafa SummerCamp 2012 - Open Generation Gap
Zarafa SummerCamp 2012 - Open Generation GapZarafa SummerCamp 2012 - Open Generation Gap
Zarafa SummerCamp 2012 - Open Generation Gap
 
Zarafa SummerCamp 2012 - Zarafa Cluster using a reverse proxy
Zarafa SummerCamp 2012 - Zarafa Cluster using a reverse proxyZarafa SummerCamp 2012 - Zarafa Cluster using a reverse proxy
Zarafa SummerCamp 2012 - Zarafa Cluster using a reverse proxy
 
Zarafa SummerCamp 2012 - Zarafa 7.1 features
Zarafa SummerCamp 2012 - Zarafa 7.1 featuresZarafa SummerCamp 2012 - Zarafa 7.1 features
Zarafa SummerCamp 2012 - Zarafa 7.1 features
 
Zarafa SummerCamp 2012 - Z-push 2.0 changes for administrators
Zarafa SummerCamp 2012 - Z-push 2.0 changes for administratorsZarafa SummerCamp 2012 - Z-push 2.0 changes for administrators
Zarafa SummerCamp 2012 - Z-push 2.0 changes for administrators
 
Zararfa SummerCamp 2012 - Performing fast backups in large scale environments...
Zararfa SummerCamp 2012 - Performing fast backups in large scale environments...Zararfa SummerCamp 2012 - Performing fast backups in large scale environments...
Zararfa SummerCamp 2012 - Performing fast backups in large scale environments...
 
Zarafa SummerCamp 2012 - Exchange Web Services on Zarafa
Zarafa SummerCamp 2012 - Exchange Web Services on ZarafaZarafa SummerCamp 2012 - Exchange Web Services on Zarafa
Zarafa SummerCamp 2012 - Exchange Web Services on Zarafa
 
Zarafa SummerCamp 2012 - Communication - how engineers can outperform
Zarafa SummerCamp 2012 - Communication - how engineers can outperformZarafa SummerCamp 2012 - Communication - how engineers can outperform
Zarafa SummerCamp 2012 - Communication - how engineers can outperform
 
Zararfa SummerCamp 2012 - From RHEL to RHEV to Cloud
Zararfa SummerCamp 2012 - From RHEL to RHEV to CloudZararfa SummerCamp 2012 - From RHEL to RHEV to Cloud
Zararfa SummerCamp 2012 - From RHEL to RHEV to Cloud
 
Zararfa SummerCamp 2012 - One solution of two vendors solves plenty needs
Zararfa SummerCamp 2012  - One solution of two vendors solves plenty needsZararfa SummerCamp 2012  - One solution of two vendors solves plenty needs
Zararfa SummerCamp 2012 - One solution of two vendors solves plenty needs
 
Zarafa SummerCamp 2012 - Zarafa in the Capgemini Open Cloud
Zarafa SummerCamp 2012 - Zarafa in the Capgemini Open CloudZarafa SummerCamp 2012 - Zarafa in the Capgemini Open Cloud
Zarafa SummerCamp 2012 - Zarafa in the Capgemini Open Cloud
 
Zarafa SummerCamp 2012 - DMS ECM - simply for everyone
Zarafa SummerCamp 2012 - DMS ECM - simply for everyoneZarafa SummerCamp 2012 - DMS ECM - simply for everyone
Zarafa SummerCamp 2012 - DMS ECM - simply for everyone
 
Zarafa SummerCamp 2012 - WebApp introduction and roadmap
Zarafa SummerCamp 2012 - WebApp introduction and roadmapZarafa SummerCamp 2012 - WebApp introduction and roadmap
Zarafa SummerCamp 2012 - WebApp introduction and roadmap
 

Recently uploaded

What is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdfWhat is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdfMounikaPolabathina
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Mark Simos
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity PlanDatabarracks
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Manik S Magar
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxLoriGlavin3
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr BaganFwdays
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxLoriGlavin3
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...Rick Flair
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteDianaGray10
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.Curtis Poe
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
Generative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersGenerative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersRaghuram Pandurangan
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningLars Bell
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenHervé Boutemy
 

Recently uploaded (20)

What is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdfWhat is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdf
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity Plan
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test Suite
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
Generative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersGenerative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information Developers
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine Tuning
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache Maven
 

Z-Push debugging

  • 1. Z-Push: advanced debugging Sebastian Kummer
  • 2. Debugging Z-Push Most of the time you don't see issues immediately! Debugging is not that easy: You need logs, they will be
  • 3. What “usually” goes wrong – States Problems with states • missing permissions • missing states after upgrading States represent the synchronization state of mobile & folder on server Missing states mean: • Server “does not know” what is already on the mobile, sends EVERYTHING again → duplications on mobile • Some stuff (like sending, creating & editing items) “works” somehow • Could cause loops In Z-Push 2 a mobile will be fully resynchronized when states are missing or invalid → missing states for many users could cause HIGH LOAD!
  • 4. What “usually” goes wrong – Old versions Old versions – especially 1.2.x and 1.3.x: • Compatibility issues • Fields not being synchronized • Some invitations/recurrences broken (also with 1.4.x) • Unimplemented features • Broken encodings - “Vielen Dank fÃŒr Ihre – Reservierung” • Nokia issues (duplicated folders)
  • 5. What “usually” goes wrong – Loops Loops • Creating 1000000(0000000000) duplicates • High load on server • High use of mobile bandwidth (could $$$$) Loops are nasty and dynamic! Requests are triggered BY THE MOBILE. Most common causes: • Broken items (most of times calendar, e.g. recurrences) • Timeouts (server takes to long to process request) • Fatal errors or Apache/PHP Segfaults (rarely) • Incompatibilities (mobile tries over and over again)
  • 6. Approaching loops - I This is what you see in the log Mobile Server Idle Has a change Synch. request 1. Reads state 2. calculates delta 3. exports change Retry 4. MAPI → ActiveSync 5. streams change Waits for answer to mobile Failure! Timeout 6. writes new state SEGFAULT Idle Any step (1-6) can fail! Any step could take to long! Segfault could occur! time Connection could fail (entering tunnel?)
  • 7. Approaching loops - II This is what you see in the log – looks great! Mobile Server Idle Has a 'broken' change Synch. request 1. Reads state 2. calculates delta 3. exports change Retry 4. MAPI → ActiveSync 5. streams change Waits for answer to mobile Success! 6. writes new state Processes answer Faulty item is sent to the mobile! Mobile does not know how to ERROR interpret item → error! time
  • 8. Approaching loops - II This is what you see in the log – looks great! Mobile Server Idle Has a 'broken' change 'Broken' ...? 1. Reads state Synch. request 2. calculates delta Syntactical errors exports change 3. Retry - Missing elementary properties, like subject 4. MAPI → ActiveSync - Missing start or end date of change item 5. streams calendar Waits for answer to mobile Success! errors Semantic 6. writes new state - start date after end date Processes answer - value not as expected (e.g. string vs. hex) - Recurrence exception: the mobile! Faulty item is sent to - Mobile does not know how to missing/faulty basedate - interpret item → error! (syntax) not a recurrence at all time ERROR
  • 9. 'Kamikaze loop' - III This is what you see in the log – looks great! Mobile Server Has NEW item Has a ('broken') change 1. Reads state Synch. request 2. creates item on server 3. calculates delta Retry 4. exports changes 5. MAPI → ActiveSync Success/failure! Waits for answer 6. streams new ID or timeout... 7. streams changes Doesn't really 8. writes new state matter... Anything after 2 fails.. Anything else goes wrong (previous slides) time ERROR
  • 11. How an iPhone receives an email “ I can see the first lines of the mail in the preview, but when I open it just says 'no body available'.....! “ iPhone Server Idle Has a change Only 1K of plain email Synch. request Retrieving and processing Success Waits and processes Fetch with HTML Fetch entire mail 1. Retrieving Failure 2. Processing as RFC822 Processing SEGFAULT Idle time
  • 12. How to fix? Error checking in loops • some syntax checking • only few semantics checks possible • Force lower maxItems • Logging on user level • New log levels, incl. Deviceid (when synching several devices with same account
  • 13. Questions? Thank you for your attention! More information at: http://z-push.sf.net/forums http://z-push.sf.net/tracker http://z-push.sf.net/download http://z-push.sf.net/compatibility Contact: sebastian@zarafa.com