Different API versions

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • bazad

    #1

    Different API versions

    Let's say I have plug-in API. A number of assemblies implement
    plug-in API version 1. Over time plug-in interface changes to version
    2. How would you handle assemblies implementing old API?
  • Peter Rilling

    #2
    Re: Different API versions

    Have the plug-in installed in the GAC. Then the version can coexist, that
    is if you want to maintain legacy support.

    "bazad" <nobody@noreply .not> wrote in message
    news:slrnc8damu .21s.nobody@STA 01052.itron.com ...[color=blue]
    > Let's say I have plug-in API. A number of assemblies implement
    > plug-in API version 1. Over time plug-in interface changes to version
    > 2. How would you handle assemblies implementing old API?[/color]


    Comment

    • Peter Rilling

      #3
      Re: Different API versions

      Have the plug-in installed in the GAC. Then the version can coexist, that
      is if you want to maintain legacy support.

      "bazad" <nobody@noreply .not> wrote in message
      news:slrnc8damu .21s.nobody@STA 01052.itron.com ...[color=blue]
      > Let's say I have plug-in API. A number of assemblies implement
      > plug-in API version 1. Over time plug-in interface changes to version
      > 2. How would you handle assemblies implementing old API?[/color]


      Comment

      • bazad

        #4
        Re: Different API versions

        In article <OPRgK29JEHA.20 4@TK2MSFTNGP10. phx.gbl>, Peter Rilling wrote:[color=blue]
        > Have the plug-in installed in the GAC. Then the version can coexist, that
        > is if you want to maintain legacy support.[/color]

        There is no point to use GAC for a plug-in. Plug-in by definition has
        only one version.

        The real problem is that the same process with a newer version of the
        framework will need to be able to load assemblies. Some of these
        assemblies implement the current IPlugIn interface version and some of
        the assemblies were not upgraded and implement older version of the
        interface. How do you handle that?
        [color=blue]
        > "bazad" <nobody@noreply .not> wrote in message
        > news:slrnc8damu .21s.nobody@STA 01052.itron.com ...[color=green]
        >> Let's say I have plug-in API. A number of assemblies implement
        >> plug-in API version 1. Over time plug-in interface changes to version
        >> 2. How would you handle assemblies implementing old API?[/color]
        >
        >[/color]

        Comment

        • bazad

          #5
          Re: Different API versions

          In article <OPRgK29JEHA.20 4@TK2MSFTNGP10. phx.gbl>, Peter Rilling wrote:[color=blue]
          > Have the plug-in installed in the GAC. Then the version can coexist, that
          > is if you want to maintain legacy support.[/color]

          There is no point to use GAC for a plug-in. Plug-in by definition has
          only one version.

          The real problem is that the same process with a newer version of the
          framework will need to be able to load assemblies. Some of these
          assemblies implement the current IPlugIn interface version and some of
          the assemblies were not upgraded and implement older version of the
          interface. How do you handle that?
          [color=blue]
          > "bazad" <nobody@noreply .not> wrote in message
          > news:slrnc8damu .21s.nobody@STA 01052.itron.com ...[color=green]
          >> Let's say I have plug-in API. A number of assemblies implement
          >> plug-in API version 1. Over time plug-in interface changes to version
          >> 2. How would you handle assemblies implementing old API?[/color]
          >
          >[/color]

          Comment

          • Michael Riggio

            #6
            Re: Different API versions


            "bazad" <nobody@noreply .not> wrote in message
            news:slrnc8dpuj .21s.nobody@STA 01052.itron.com ...[color=blue]
            > In article <OPRgK29JEHA.20 4@TK2MSFTNGP10. phx.gbl>, Peter Rilling wrote:[color=green]
            > > Have the plug-in installed in the GAC. Then the version can coexist,[/color][/color]
            that[color=blue][color=green]
            > > is if you want to maintain legacy support.[/color]
            >
            > There is no point to use GAC for a plug-in. Plug-in by definition has
            > only one version.
            >
            > The real problem is that the same process with a newer version of the
            > framework will need to be able to load assemblies. Some of these
            > assemblies implement the current IPlugIn interface version and some of
            > the assemblies were not upgraded and implement older version of the
            > interface. How do you handle that?[/color]

            Isn't that breaking one of the fundamental concepts of what an interface
            provides. I always thought that once you release an interface you don't
            change it...
            [color=blue]
            >[color=green]
            > > "bazad" <nobody@noreply .not> wrote in message
            > > news:slrnc8damu .21s.nobody@STA 01052.itron.com ...[color=darkred]
            > >> Let's say I have plug-in API. A number of assemblies implement
            > >> plug-in API version 1. Over time plug-in interface changes to version
            > >> 2. How would you handle assemblies implementing old API?[/color]
            > >
            > >[/color][/color]


            Comment

            • Michael Riggio

              #7
              Re: Different API versions


              "bazad" <nobody@noreply .not> wrote in message
              news:slrnc8dpuj .21s.nobody@STA 01052.itron.com ...[color=blue]
              > In article <OPRgK29JEHA.20 4@TK2MSFTNGP10. phx.gbl>, Peter Rilling wrote:[color=green]
              > > Have the plug-in installed in the GAC. Then the version can coexist,[/color][/color]
              that[color=blue][color=green]
              > > is if you want to maintain legacy support.[/color]
              >
              > There is no point to use GAC for a plug-in. Plug-in by definition has
              > only one version.
              >
              > The real problem is that the same process with a newer version of the
              > framework will need to be able to load assemblies. Some of these
              > assemblies implement the current IPlugIn interface version and some of
              > the assemblies were not upgraded and implement older version of the
              > interface. How do you handle that?[/color]

              Isn't that breaking one of the fundamental concepts of what an interface
              provides. I always thought that once you release an interface you don't
              change it...
              [color=blue]
              >[color=green]
              > > "bazad" <nobody@noreply .not> wrote in message
              > > news:slrnc8damu .21s.nobody@STA 01052.itron.com ...[color=darkred]
              > >> Let's say I have plug-in API. A number of assemblies implement
              > >> plug-in API version 1. Over time plug-in interface changes to version
              > >> 2. How would you handle assemblies implementing old API?[/color]
              > >
              > >[/color][/color]


              Comment

              • bazad

                #8
                Re: Different API versions

                In article <uB2bNmKKEHA.39 20@TK2MSFTNGP10 .phx.gbl>, Michael Riggio wrote:[color=blue]
                >
                > "bazad" <nobody@noreply .not> wrote in message
                > news:slrnc8dpuj .21s.nobody@STA 01052.itron.com ...[color=green]
                >> In article <OPRgK29JEHA.20 4@TK2MSFTNGP10. phx.gbl>, Peter Rilling wrote:[color=darkred]
                >> > Have the plug-in installed in the GAC. Then the version can coexist,[/color][/color]
                > that[color=green][color=darkred]
                >> > is if you want to maintain legacy support.[/color]
                >>
                >> There is no point to use GAC for a plug-in. Plug-in by definition has
                >> only one version.
                >>
                >> The real problem is that the same process with a newer version of the
                >> framework will need to be able to load assemblies. Some of these
                >> assemblies implement the current IPlugIn interface version and some of
                >> the assemblies were not upgraded and implement older version of the
                >> interface. How do you handle that?[/color]
                >
                > Isn't that breaking one of the fundamental concepts of what an interface
                > provides. I always thought that once you release an interface you don't
                > change it...[/color]

                You are correct. But what do you do when requirements change over time?
                [color=blue][color=green]
                > > "bazad" <nobody@noreply .not> wrote in message[color=darkred]
                >> > news:slrnc8damu .21s.nobody@STA 01052.itron.com ...
                >> >> Let's say I have plug-in API. A number of assemblies implement
                >> >> plug-in API version 1. Over time plug-in interface changes to version
                >> >> 2. How would you handle assemblies implementing old API?[/color][/color][/color]

                Comment

                • bazad

                  #9
                  Re: Different API versions

                  In article <uB2bNmKKEHA.39 20@TK2MSFTNGP10 .phx.gbl>, Michael Riggio wrote:[color=blue]
                  >
                  > "bazad" <nobody@noreply .not> wrote in message
                  > news:slrnc8dpuj .21s.nobody@STA 01052.itron.com ...[color=green]
                  >> In article <OPRgK29JEHA.20 4@TK2MSFTNGP10. phx.gbl>, Peter Rilling wrote:[color=darkred]
                  >> > Have the plug-in installed in the GAC. Then the version can coexist,[/color][/color]
                  > that[color=green][color=darkred]
                  >> > is if you want to maintain legacy support.[/color]
                  >>
                  >> There is no point to use GAC for a plug-in. Plug-in by definition has
                  >> only one version.
                  >>
                  >> The real problem is that the same process with a newer version of the
                  >> framework will need to be able to load assemblies. Some of these
                  >> assemblies implement the current IPlugIn interface version and some of
                  >> the assemblies were not upgraded and implement older version of the
                  >> interface. How do you handle that?[/color]
                  >
                  > Isn't that breaking one of the fundamental concepts of what an interface
                  > provides. I always thought that once you release an interface you don't
                  > change it...[/color]

                  You are correct. But what do you do when requirements change over time?
                  [color=blue][color=green]
                  > > "bazad" <nobody@noreply .not> wrote in message[color=darkred]
                  >> > news:slrnc8damu .21s.nobody@STA 01052.itron.com ...
                  >> >> Let's say I have plug-in API. A number of assemblies implement
                  >> >> plug-in API version 1. Over time plug-in interface changes to version
                  >> >> 2. How would you handle assemblies implementing old API?[/color][/color][/color]

                  Comment

                  • Michael Riggio

                    #10
                    Re: Different API versions

                    comments inline...

                    "bazad" <nobody@noreply .not> wrote in message
                    news:slrnc8gheu .270.nobody@STA 01052.itron.com ...[color=blue]
                    > In article <uB2bNmKKEHA.39 20@TK2MSFTNGP10 .phx.gbl>, Michael Riggio wrote:[color=green]
                    > >
                    > > "bazad" <nobody@noreply .not> wrote in message
                    > > news:slrnc8dpuj .21s.nobody@STA 01052.itron.com ...[color=darkred]
                    > >> In article <OPRgK29JEHA.20 4@TK2MSFTNGP10. phx.gbl>, Peter Rilling wrote:
                    > >> > Have the plug-in installed in the GAC. Then the version can coexist,[/color]
                    > > that[color=darkred]
                    > >> > is if you want to maintain legacy support.
                    > >>
                    > >> There is no point to use GAC for a plug-in. Plug-in by definition has
                    > >> only one version.
                    > >>
                    > >> The real problem is that the same process with a newer version of the
                    > >> framework will need to be able to load assemblies. Some of these
                    > >> assemblies implement the current IPlugIn interface version and some of
                    > >> the assemblies were not upgraded and implement older version of the
                    > >> interface. How do you handle that?[/color]
                    > >
                    > > Isn't that breaking one of the fundamental concepts of what an interface
                    > > provides. I always thought that once you release an interface you don't
                    > > change it...[/color]
                    >
                    > You are correct. But what do you do when requirements change over time?[/color]

                    We introduce a new interface that the main object implements (so it now
                    implements both the new and old interfaces). Old clients will be able to
                    use the old interface and new clients can simply attempt to cast to the new
                    interface. Everyone is happy.

                    [color=blue][color=green][color=darkred]
                    > > > "bazad" <nobody@noreply .not> wrote in message
                    > >> > news:slrnc8damu .21s.nobody@STA 01052.itron.com ...
                    > >> >> Let's say I have plug-in API. A number of assemblies implement
                    > >> >> plug-in API version 1. Over time plug-in interface changes to[/color][/color][/color]
                    version[color=blue][color=green][color=darkred]
                    > >> >> 2. How would you handle assemblies implementing old API?[/color][/color][/color]


                    Comment

                    • Michael Riggio

                      #11
                      Re: Different API versions

                      comments inline...

                      "bazad" <nobody@noreply .not> wrote in message
                      news:slrnc8gheu .270.nobody@STA 01052.itron.com ...[color=blue]
                      > In article <uB2bNmKKEHA.39 20@TK2MSFTNGP10 .phx.gbl>, Michael Riggio wrote:[color=green]
                      > >
                      > > "bazad" <nobody@noreply .not> wrote in message
                      > > news:slrnc8dpuj .21s.nobody@STA 01052.itron.com ...[color=darkred]
                      > >> In article <OPRgK29JEHA.20 4@TK2MSFTNGP10. phx.gbl>, Peter Rilling wrote:
                      > >> > Have the plug-in installed in the GAC. Then the version can coexist,[/color]
                      > > that[color=darkred]
                      > >> > is if you want to maintain legacy support.
                      > >>
                      > >> There is no point to use GAC for a plug-in. Plug-in by definition has
                      > >> only one version.
                      > >>
                      > >> The real problem is that the same process with a newer version of the
                      > >> framework will need to be able to load assemblies. Some of these
                      > >> assemblies implement the current IPlugIn interface version and some of
                      > >> the assemblies were not upgraded and implement older version of the
                      > >> interface. How do you handle that?[/color]
                      > >
                      > > Isn't that breaking one of the fundamental concepts of what an interface
                      > > provides. I always thought that once you release an interface you don't
                      > > change it...[/color]
                      >
                      > You are correct. But what do you do when requirements change over time?[/color]

                      We introduce a new interface that the main object implements (so it now
                      implements both the new and old interfaces). Old clients will be able to
                      use the old interface and new clients can simply attempt to cast to the new
                      interface. Everyone is happy.

                      [color=blue][color=green][color=darkred]
                      > > > "bazad" <nobody@noreply .not> wrote in message
                      > >> > news:slrnc8damu .21s.nobody@STA 01052.itron.com ...
                      > >> >> Let's say I have plug-in API. A number of assemblies implement
                      > >> >> plug-in API version 1. Over time plug-in interface changes to[/color][/color][/color]
                      version[color=blue][color=green][color=darkred]
                      > >> >> 2. How would you handle assemblies implementing old API?[/color][/color][/color]


                      Comment

                      Working...