Friedrich Ewald My Personal Website

Posts


  • Improving security for SSH

    There are two things to increase the security for ssh logins.

    Change SSH Port

    To change the SSH port, simply edit the sshd_config file with the commmand sudo nano /etc/ssh/sshd_config and change the line Port 22 to something higher. Make sure to stay below 65,000 and don’t use any port which is already used by another service like 80 (web). After changing and saving the file, simply restart the ssh daemon and reload the configuration with sudo /etc/init.d/ssh reload. Done.

    Disable password based login for SSH

    To disable the password based login for all the users, you can do the following:
    # Open the sshd config file
    sudo nano /etc/ssh/sshd_config
    
    Disable password authentication with the following settings:
    ChallengeResponseAuthentication no
    
    Allow private public key authentication with the following:
    RSAAuthentication yes
    PubkeyAuthentication yes
    
    Once this is done, restart the SSH daemon to apply the settings.
    /etc/init.d/sshd restart
    
    Additional information can be found here.

  • Building a sitemap.xml with jekyll

    While transforming this page to Jekyll I needed a sitemap.xml for the Google Webmaster Tools. A quick search showed up this result. Works perfectly.

    ---
    layout: null
    ---
    <?xml version="1.0" encoding="UTF-8"?>
    <urlset xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9 http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd" xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
      
        <url>
          <loc>https://fewald.net/2024/01/31/silicon-valley.html</loc>
          
            <lastmod>2024-01-31T17:28:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/2023/12/19/rain.html</loc>
          
            <lastmod>2023-12-19T18:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/ruby/rails/2023/08/13/ruby-testing-server-part-two.html</loc>
          
            <lastmod>2023-08-13T17:44:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/2023/07/04/july-4-2023.html</loc>
          
            <lastmod>2023-07-04T14:17:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/misc/2023/05/21/bread-recipe.html</loc>
          
            <lastmod>2023-05-21T01:30:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/python/2023/04/18/memory-profiling-memray.html</loc>
          
            <lastmod>2023-04-18T17:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/2023/01/25/updating-jekyll-to-ruby-3-2-0.html</loc>
          
            <lastmod>2023-01-25T16:35:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/home-improvement/2022/12/18/electric-closet.html</loc>
          
            <lastmod>2022-12-18T01:50:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/machine-learning/2022/12/11/chatgpt.html</loc>
          
            <lastmod>2022-12-11T16:25:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/2022/11/28/testing-email-sending.html</loc>
          
            <lastmod>2022-11-28T16:14:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/2022/11/18/heroku-price-increase.html</loc>
          
            <lastmod>2022-11-18T18:44:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/2022/11/16/change-font-size-depending-on-post-length.html</loc>
          
            <lastmod>2022-11-16T15:43:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/11/09/leetcode-house-robber-ii.html</loc>
          
            <lastmod>2022-11-09T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/11/08/leetcode-house-robber.html</loc>
          
            <lastmod>2022-11-08T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/11/07/leetcode-palindrome-linked-list.html</loc>
          
            <lastmod>2022-11-07T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/11/06/leetcode-intersection-of-two-arrays-ii.html</loc>
          
            <lastmod>2022-11-06T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/11/05/leetcode-power-of-three.html</loc>
          
            <lastmod>2022-11-05T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/11/04/leetcode-kth-smallest-element-in-matrix.html</loc>
          
            <lastmod>2022-11-04T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/11/03/leetcode-copy-list-with-random-pointer.html</loc>
          
            <lastmod>2022-11-03T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/11/02/leetcode-decode-ways.html</loc>
          
            <lastmod>2022-11-02T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/11/01/leetcode-reconstruct-binary-tree.html</loc>
          
            <lastmod>2022-11-01T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/31/leetcode-validate-binary-search-tree.html</loc>
          
            <lastmod>2022-10-31T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/30/leetcode-palindrome-partitioning.html</loc>
          
            <lastmod>2022-10-30T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/29/leetcode-remove-element-from-list.html</loc>
          
            <lastmod>2022-10-29T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/28/leetcode-array-remove-element.html</loc>
          
            <lastmod>2022-10-28T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/27/leetcode-binary-tree-zigzag-level-order-traversal.html</loc>
          
            <lastmod>2022-10-27T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/26/leetcode-binary-tree-level-order-traversal.html</loc>
          
            <lastmod>2022-10-26T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/25/leetcode-valid-sudoku.html</loc>
          
            <lastmod>2022-10-25T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/24/leetcode-top-k-frequent-elements.html</loc>
          
            <lastmod>2022-10-24T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/23/leetcode-find-peak-element.html</loc>
          
            <lastmod>2022-10-23T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/22/leetcode-minimum-stack.html</loc>
          
            <lastmod>2022-10-22T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/21/leetcode-populate-next-pointers.html</loc>
          
            <lastmod>2022-10-21T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/20/leetcode-generate-parentheses.html</loc>
          
            <lastmod>2022-10-20T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/19/leetcode-word-break.html</loc>
          
            <lastmod>2022-10-19T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/18/leetcode-maximum-product-subarray.html</loc>
          
            <lastmod>2022-10-18T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/17/leetcode-sort-list.html</loc>
          
            <lastmod>2022-10-17T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/16/leetcode-gas-station.html</loc>
          
            <lastmod>2022-10-16T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/15/leetcode-lru-cache.html</loc>
          
            <lastmod>2022-10-15T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/14/leetcode-merge-sorted-array.html</loc>
          
            <lastmod>2022-10-14T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/13/leetcode-word-search.html</loc>
          
            <lastmod>2022-10-13T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/12/leetcode-unique-paths.html</loc>
          
            <lastmod>2022-10-12T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/11/leetcode-merge-intervals.html</loc>
          
            <lastmod>2022-10-11T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/10/leetcode-remove-nth-node-from-end-of-list.html</loc>
          
            <lastmod>2022-10-10T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/09/leetcode-sort-colors.html</loc>
          
            <lastmod>2022-10-09T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/08/leetcode-find-first-and-last-position-of-element-in-sorted-arrays.html</loc>
          
            <lastmod>2022-10-08T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/07/leetcode-three-sum.html</loc>
          
            <lastmod>2022-10-07T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/06/leetcode-longest-consecutive-sequence.html</loc>
          
            <lastmod>2022-10-06T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/05/leetcode-happy-number.html</loc>
          
            <lastmod>2022-10-05T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/04/leetcode-linked-list-cycle.html</loc>
          
            <lastmod>2022-10-04T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/03/leetcode-contains-duplicate.html</loc>
          
            <lastmod>2022-10-03T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/02/leetcode-move-zeros.html</loc>
          
            <lastmod>2022-10-02T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/10/01/leetcode-reverse-string.html</loc>
          
            <lastmod>2022-10-01T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/09/30/leetcode-majority-number.html</loc>
          
            <lastmod>2022-09-30T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/09/29/leetcode-single-number.html</loc>
          
            <lastmod>2022-09-29T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/09/28/leetcode-first-unique-character-in-string.html</loc>
          
            <lastmod>2022-09-28T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/09/27/leetcode-symmetric-tree.html</loc>
          
            <lastmod>2022-09-27T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/09/26/leetcode-binary-tree-inorder-traversal.html</loc>
          
            <lastmod>2022-09-26T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/09/25/leetcode-square-root-of-x.html</loc>
          
            <lastmod>2022-09-25T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/09/24/leetcode-add-binary.html</loc>
          
            <lastmod>2022-09-24T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/09/23/leetcode-plus-one.html</loc>
          
            <lastmod>2022-09-23T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/09/22/leetcode-climbing-stairs.html</loc>
          
            <lastmod>2022-09-22T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/09/21/leetcode-best-time-to-buy-and-sell-stock.html</loc>
          
            <lastmod>2022-09-21T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/09/20/leetcode-repeated-substring-pattern.html</loc>
          
            <lastmod>2022-09-20T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/09/19/leetcode-string-in-string.html</loc>
          
            <lastmod>2022-09-19T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/09/18/leetcode-merge-two-lists.html</loc>
          
            <lastmod>2022-09-18T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/09/17/leetcode-all-possible-subsets.html</loc>
          
            <lastmod>2022-09-17T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/09/16/leetcode-permutations.html</loc>
          
            <lastmod>2022-09-16T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/ruby/rails/2022/09/15/how-to-add-devise-to-rails.html</loc>
          
            <lastmod>2022-09-15T22:31:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/leetcode/2022/09/15/leetcode-letter-case-permutation.html</loc>
          
            <lastmod>2022-09-15T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/2022/09/04/nearest-binary-search.html</loc>
          
            <lastmod>2022-09-04T16:28:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/python/2022/09/03/predictable-hash-function.html</loc>
          
            <lastmod>2022-09-03T20:33:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/machine-learning/2022/08/22/openai-api-price-reduction.html</loc>
          
            <lastmod>2022-08-22T17:41:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/ruby/rails/2022/08/08/secure-sidekiq-with-basicauth.html</loc>
          
            <lastmod>2022-08-08T23:30:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/links/2022/07/30/aaron-koblin.html</loc>
          
            <lastmod>2022-07-30T05:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/ruby/rails/2022/07/28/fast-feed-processing-in-ruby.html</loc>
          
            <lastmod>2022-07-28T16:56:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/ruby/rails/2022/07/18/rails-testing-with-static-server.html</loc>
          
            <lastmod>2022-07-18T04:33:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/2022/07/17/new-york-times-story-portrait.html</loc>
          
            <lastmod>2022-07-17T03:06:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/seo/2022/07/08/improving-search-engine-optimization.html</loc>
          
            <lastmod>2022-07-08T06:22:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/2022/07/08/improving-website-accessibility.html</loc>
          
            <lastmod>2022-07-08T06:14:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/2022/07/06/improving-page-speed.html</loc>
          
            <lastmod>2022-07-06T22:24:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/ruby-on-rails/2022/07/06/ruby-on-rails-nil-check.html</loc>
          
            <lastmod>2022-07-06T16:57:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/2022/07/05/jsonfeed-installed.html</loc>
          
            <lastmod>2022-07-05T18:42:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/2022/06/26/wisdom.html</loc>
          
            <lastmod>2022-06-26T18:37:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/2022/06/08/how-much-precision-do-you-need.html</loc>
          
            <lastmod>2022-06-08T01:10:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/2022/06/06/jekyll-compose.html</loc>
          
            <lastmod>2022-06-06T19:12:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/2022/06/06/full-url-google-chrome.html</loc>
          
            <lastmod>2022-06-06T03:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/2022/05/29/sunset-daly-city-california.html</loc>
          
            <lastmod>2022-05-29T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/2022/05/28/hermes-imessage-cli.html</loc>
          
            <lastmod>2022-05-28T02:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/programming/2022/05/11/golang-generics.html</loc>
          
            <lastmod>2022-05-11T02:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/2021/04/23/coredns_config.html</loc>
          
            <lastmod>2021-04-23T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/webdesign/development/2021/04/22/fontshare_fonts.html</loc>
          
            <lastmod>2021-04-22T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/golang/development/2020/06/16/golang-private-repository.html</loc>
          
            <lastmod>2020-06-16T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/photo/2020/05/19/sunday-afternoon-clouds.html</loc>
          
            <lastmod>2020-05-19T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/k8s/development/2020/05/09/kubernetes-namespace.html</loc>
          
            <lastmod>2020-05-09T18:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/misc/2020/05/05/rt-live.html</loc>
          
            <lastmod>2020-05-05T18:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/misc/2020/04/28/data-visualization.html</loc>
          
            <lastmod>2020-04-28T18:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/nginx/development/2020/04/19/413-nginx-ingress-k8s.html</loc>
          
            <lastmod>2020-04-19T18:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/misc/2020/02/22/writic-app.html</loc>
          
            <lastmod>2020-02-22T18:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/link/2019/06/17/the-hard-way.html</loc>
          
            <lastmod>2019-06-17T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/photo/2019/05/05/getty-center.html</loc>
          
            <lastmod>2019-05-05T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/links/2019/04/01/kubernetes-or-not.html</loc>
          
            <lastmod>2019-04-01T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/photo/2019/03/31/java-on-ocean.html</loc>
          
            <lastmod>2019-03-31T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/security/2019/03/30/decrypt-chrome-passwords-windows.html</loc>
          
            <lastmod>2019-03-30T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/python/macos/2019/03/28/setup-pip-build.html</loc>
          
            <lastmod>2019-03-28T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/security/2019/03/25/facebook-passwords.html</loc>
          
            <lastmod>2019-03-25T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/helm/2019/03/24/helm-charts.html</loc>
          
            <lastmod>2019-03-24T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/python/2019/03/04/febase62-v1-1-0.html</loc>
          
            <lastmod>2019-03-04T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/macos/2019/02/25/uuid-mac-os-shell.html</loc>
          
            <lastmod>2019-02-25T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/linux/2019/02/17/jps-java-process.html</loc>
          
            <lastmod>2019-02-17T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/google/2019/02/17/delete-google-appengine.html</loc>
          
            <lastmod>2019-02-17T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/2018/12/25/apache-spark-dataframe-count-words.html</loc>
          
            <lastmod>2018-12-25T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/2018/07/31/kafka-topic-cleanup.html</loc>
          
            <lastmod>2018-07-31T11:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/2018/07/27/apache-kafka-cheat-sheet.html</loc>
          
            <lastmod>2018-07-27T21:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/misc/2018/07/26/anki-flashcards.html</loc>
          
            <lastmod>2018-07-26T04:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/linux/2018/07/23/ps-aux-grep-java-process.html</loc>
          
            <lastmod>2018-07-23T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/json/development/2017/05/20/RSS-better-with-jsonfeed.html</loc>
          
            <lastmod>2017-05-20T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/python/2017/02/11/java-enumerations-with-values.html</loc>
          
            <lastmod>2017-02-11T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/python/2017/02/07/base62-encoding-decoding.html</loc>
          
            <lastmod>2017-02-07T00:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/vim/2016/12/02/smaller-tabs-in-vim.html</loc>
          
            <lastmod>2016-12-02T18:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/dotnet/2016/11/01/newtonsoft-json-dll-in-multiple-projects.html</loc>
          
            <lastmod>2016-11-01T18:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/2016/10/31/experiences-with-jekyll.html</loc>
          
            <lastmod>2016-10-31T18:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/python/2016/10/28/python-merge-two-lists.html</loc>
          
            <lastmod>2016-10-28T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/linux/2016/09/12/cronjob-crontab-syntax.html</loc>
          
            <lastmod>2016-09-12T21:12:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/typescipt/angular2/2016/08/30/angular2-http.html</loc>
          
            <lastmod>2016-08-30T01:54:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/tools/2016/07/15/vim-cheatsheet.html</loc>
          
            <lastmod>2016-07-15T20:31:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/performance/programming/2016/05/20/big-o-notation-cheatsheet.html</loc>
          
            <lastmod>2016-05-20T21:31:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/linux/shell/2016/04/11/show-open-ports.html</loc>
          
            <lastmod>2016-04-11T21:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/git/2016/04/07/better-git-log.html</loc>
          
            <lastmod>2016-04-07T21:31:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/linux/shell/2016/02/23/combining-csv-files.html</loc>
          
            <lastmod>2016-02-23T16:45:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/linux/shell/2016/02/19/shell-count-lines.html</loc>
          
            <lastmod>2016-02-19T19:03:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/linux/security/2016/02/12/increasing_security_ssh.html</loc>
          
            <lastmod>2016-02-12T00:10:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/web/jekyll/2016/02/09/sitemap_xml-for-jekyll.html</loc>
          
            <lastmod>2016-02-09T18:22:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/c%23/json/2016/02/08/json-serialization.html</loc>
          
            <lastmod>2016-02-08T20:13:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/c%23/2016/02/04/list-event-handler.html</loc>
          
            <lastmod>2016-02-04T02:34:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/python/2016/01/07/odoo-9.html</loc>
          
            <lastmod>2016-01-07T17:14:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/js/2015/12/19/lunch-manager.html</loc>
          
            <lastmod>2015-12-19T01:28:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/js/2015/12/14/installing-node-js.html</loc>
          
            <lastmod>2015-12-14T04:39:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/2015/12/09/git_hooks.html</loc>
          
            <lastmod>2015-12-09T20:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
        <url>
          <loc>https://fewald.net/development/2015/12/09/jekyll-experiments.html</loc>
          
            <lastmod>2015-12-09T01:00:00+00:00</lastmod>
          
          <changefreq>weekly</changefreq>
          <priority>1.0</priority>
        </url>
      
      
        
          <url>
            <loc>https://fewald.net/about/</loc>
            <lastmod></lastmod>
            <changefreq>monthly</changefreq>
            <priority></priority>
           </url>
        
      
        
      
        
          <url>
            <loc>https://fewald.net/cv/</loc>
            <lastmod></lastmod>
            <changefreq>monthly</changefreq>
            <priority></priority>
           </url>
        
      
        
      
        
      
        
          <url>
            <loc>https://fewald.net/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
      
        
          <url>
            <loc>https://fewald.net/projects/</loc>
            <lastmod></lastmod>
            <changefreq>monthly</changefreq>
            <priority>0.6</priority>
           </url>
        
      
        
      
        
      
        
      
        
      
        
          <url>
            <loc>https://fewald.net/page2/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page3/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page4/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page5/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page6/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page7/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page8/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page9/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page10/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page11/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page12/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page13/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page14/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page15/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page16/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page17/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page18/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page19/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page20/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page21/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page22/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page23/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page24/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page25/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page26/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page27/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
        
          <url>
            <loc>https://fewald.net/page28/</loc>
            <lastmod></lastmod>
            <changefreq>weekly</changefreq>
            <priority></priority>
           </url>
        
      
    </urlset>
    

  • Serialization and Deserialization with C# & JSON

    For serialization and deserialization in the .NET framework, I use the Newtonsoft JSON Serializer. This library works really fast and is very flexible. Lately I had a problem that I wanted to serialize a List<ObjA> with ObjB and ObjC. ObjB and ObjC are children of ObjA. In the code it looks as the following:

    public class ObjA
    {}
    
    public class ObjB : ObjA
    {}
    
    public class ObjC : ObjA
    {}
    
    public class Program
    {
    	public void main()
    	{
    		List<ObjA> objectList = new List<ObjA>();
    
    		string serializedObjects = JsonConvert.SerializeObject(objectList);
    
    		List<ObjA> objectListNew = JsonConvert.DeserializeObject<List<ObjA>>(serializedObjects);
    	}
    }
    
    If I now serialized this with the method SerializeObject() and later deserialized it with the method DeserializeObject<>(), all the objects were of the type ObjA instead of type ObjB or ObjC. After a short research, I found the solution:
    public class Program
    {
    	public void main()
    	{
    		List<ObjA> objectList = new List<ObjA>();
    
    		string serializedObjects = JsonConvert.SerializeObject(objectList, Formatting.Indented, new JsonSerializerSettings()
                {
                    ReferenceLoopHandling = ReferenceLoopHandling.Ignore,
                    TypeNameHandling = TypeNameHandling.All
                });
    
    		List<ObjA> objectListNew = JsonConvert.DeserializeObject<List<ObjA>>(serializedObjects, new JsonSerializerSettings() {TypeNameHandling = TypeNameHandling.Auto});
    	}
    }
    
    This preserves the types of the objects during serialization.

  • Implementing events in List

    If you want to subscribe for changes to a List<T> in C# it is very easy. All you need to do, is subclass List<T> and implement your own event handler. This could be done as following:

    using System;
    using System.Collections.Generic;
    
    namespace FEwald
    {
        public class MyList<T> : List<T>
        {
            /// <summary>
            /// EventHandler which is called when items are added.
            /// </summary>
            public event EventHandler ItemAdded;
    
            /// <summary>
            /// EventHandler which is called when items are deleted.
            /// </summary>
            public event EventHandler ItemRemoved;
    
            /// <summary>
            /// Adds an item to the list.
            /// </summary>
            /// <param name="item"></param>
            public new void Add(T item)
            {
                if (ItemAdded != null)
                {
                    ItemAdded(item, EventArgs.Empty);
                }
                base.Add(item);
                
            }
    
            /// <summary>
            /// Adds a range of items to the list.
            /// </summary>
            /// <param name="collection"></param>
            public new void AddRange(IEnumerable<T> collection)
            {
                foreach (var item in collection)
                {
                    Add(item);
                }
            }
            
            /// <summary>
            /// Removes an item from the list.
            /// </summary>
            /// <param name="item"></param>
            public new void Remove(T item)
            {
                if (ItemRemoved != null)
                {
                    ItemRemoved(item, EventArgs.Empty);
                }
                base.Remove(item);
            }
        }
    }
    

  • Updating Odoo 8 to Odoo 9

    Currently I’m updating an odoo installation from version 8 to version 9 for a customer. In this post I will give a short introduction, on how to update the installation and most common issues I observed during the update. This post ist not complete since every odoo installation is different. First of all, there is no updater or tutorial offered by the odoo company for the community edition. The company only provides support and updates for the paid enterprise licenses. Since the database structure in odoo changed in so many fields, it is almost impossible, to update the odoo database “by hand” to version 9. The other solution, OpenUpgrade is not yet ready for the current version of the ERP system and therefore also not a possible solution. Instead, I decided to upgrade the custom developed module in a fresh odoo 9 installation. As soon as it works, I install odoo 9 with a fresh database on the server and transfer (export, then import) all the data from 8 to 9. Below is a list with possible problems and the solutions I found for them.

    Custom module isn’t shown in the list of apps

    In odoo 8, the user has to be a technical user to be able to change the technical settings. This type of user no longer exists in odoo 9. Instead, one has to activate the developer mode of odoo. This is done by clicking on the currently logged in user name in the upper right corner, then about and then “activate developer mode”. After this step, root / administrator users can update the list of apps. In my case I was able to search for my module using the search box in the upper right corner. Updating the list of apps is still necessary but it is more hidden than in the previous version.

    Using the old API

    The old API is simply no longer supported in odoo 9. My module was using it in some method signatures which I had to update to the new api style, including the method decorator @api.one and @api.multi. All the variables, like cr, context, etc. still exist but have slightly different names now.

    Using variable names in email templates

    Somehow the use of variable names as it was before is no longer possible. I will update this part as soon as I have a solution for this.

    Problems with lessc

    If lessc cannot be found it is most likely not installed on the server or, in my case, the symlink to nodejs was wrong. This is easy to fix with
    sudo ln -s /usr/local/bin/nodejs /usr/bin/node
    

    Transfer old data to new database

    The data which is needed in the new database has to be transformed to match the new database structure. I my case this was done by copying the old database to a temporary database, then editing the tables exporting them, and importing them afterwards into the new database. It is important to import the data in the right order to not violate foreign key constraints. This list will be updated if new difficulties occur.

Page: 27 of 28